X-Git-Url: http://git.marmaro.de/?a=blobdiff_plain;f=uip%2Finc.c;h=d31cdf7688fbc947ed702f3bc34dfc4faddd9e4a;hb=03bf20a885b3953a0385e814ba4e0196b46f6159;hp=f2d2e77901635e0f49c4196c037cd0af301e0e41;hpb=56a805299de35d8924969138aef4d0f1580daa6d;p=mmh diff --git a/uip/inc.c b/uip/inc.c index f2d2e77..d31cdf7 100644 --- a/uip/inc.c +++ b/uip/inc.c @@ -223,7 +223,7 @@ static FILE *in; */ char *map_name(char *); -static int inc_done(int); +static void inc_done(int) NORETURN; #ifdef POP static int pop_action(char *); static int pop_pack(char *); @@ -236,18 +236,18 @@ main (int argc, char **argv) { int chgflag = 1, trnflag = 1; int noisy = 1, width = 0; - int rpop, i, hghnum, msgnum; + int rpop, i, hghnum = 0, msgnum = 0; int kpop = 0, sasl = 0; - char *cp, *maildir, *folder = NULL; + char *cp, *maildir = NULL, *folder = NULL; char *format = NULL, *form = NULL; char *host = NULL, *user = NULL, *proxy = NULL; char *audfile = NULL, *from = NULL, *saslmech = NULL; char buf[BUFSIZ], **argp, *nfs, **arguments; - struct msgs *mp; + struct msgs *mp = NULL; struct stat st, s1; FILE *aud = NULL; - char b[MAXPATHLEN + 1]; - char *maildir_copy; /* copy of mail directory because the static gets overwritten */ + char b[MAXPATHLEN + 1]; + char *maildir_copy = NULL; /* copy of mail directory because the static gets overwritten */ #ifdef POP int nmsgs, nbytes, p = 0; @@ -545,7 +545,7 @@ main (int argc, char **argv) adios (NULL, "no mail to incorporate"); if ((cp = strdup(newmail)) == (char *)0) - adios (maildir, "error allocating memory to copy newmail"); + adios (NULL, "error allocating memory to copy newmail"); newmail = cp; } @@ -952,7 +952,8 @@ go_to_it: seq_setunseen (mp, 0); /* set the Unseen-Sequence */ seq_save (mp); /* synchronize sequences */ context_save (); /* save the context file */ - return done (0); + done (0); + return 1; } @@ -989,7 +990,7 @@ cpymsg (FILE *in, FILE *out) #endif /* if 0 */ -static int +static void inc_done (int status) { #ifdef POP @@ -1003,7 +1004,6 @@ inc_done (int status) DROPGROUPPRIVS(); } exit (status); - return 1; /* dead code to satisfy the compiler */ } #ifdef POP