X-Git-Url: http://git.marmaro.de/?a=blobdiff_plain;ds=sidebyside;f=uip%2Frcvdist.c;h=922670b52448c74d97d181cf3c240dc8e97e6ae4;hb=794dab6aa5027ffaf024506140c258f6a0a9322d;hp=b210696fc1ef4281b51f9de99e6838c86b17b7a6;hpb=1691e80890e5d8ba258c51c214a3e91880e1db2b;p=mmh diff --git a/uip/rcvdist.c b/uip/rcvdist.c index b210696..922670b 100644 --- a/uip/rcvdist.c +++ b/uip/rcvdist.c @@ -28,7 +28,7 @@ static char tmpfil[BUFSIZ] = ""; * prototypes */ static void rcvdistout (FILE *, char *, char *); -void done (int); +int done (int); int @@ -117,7 +117,8 @@ main (int argc, char **argv) default: done (pidXwait(child_id, postproc)); } -/* NOTREACHED */ + + return 0; /* dead code to satisfy the compiler */ } /* very similar to routine in replsbr.c */ @@ -205,13 +206,14 @@ rcvdistout (FILE *inb, char *form, char *addrs) } else { i = strlen (cp = cptr->c_text) - 1; - if (cp[i] == '\n') + if (cp[i] == '\n') { if (cptr->c_type & CT_ADDR) { cp[i] = 0; cp = add (",\n\t", cp); } else cp = add ("\t", cp); + } cptr->c_text = add (tmpbuf, cp); } while (state == FLDPLUS) { @@ -252,7 +254,7 @@ finished: ; fclose (out); free (scanl); - for (nxtbuf = compbuffers, i = ncomps; cptr = *savecomp++; nxtbuf++, i--) + for (nxtbuf = compbuffers, i = ncomps; (cptr = *savecomp++); nxtbuf++, i--) free (cptr->c_text); while (i-- > 0) free (*nxtbuf++); @@ -261,7 +263,7 @@ finished: ; } -void +int done (int status) { if (backup[0]) @@ -272,4 +274,5 @@ done (int status) unlink (tmpfil); exit (status ? RCV_MBX : RCV_MOK); + return 1; /* dead code to satisfy the compiler */ }