projects
/
mmh
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use hyphen, not plus (corresponding to previous RCx naming convention)
[mmh]
/
uip
/
inc.c
diff --git
a/uip/inc.c
b/uip/inc.c
index
a2ecb44
..
ef1b08f
100644
(file)
--- a/
uip/inc.c
+++ b/
uip/inc.c
@@
-223,8
+223,8
@@
static FILE *in;
*/
char *map_name(char *);
*/
char *map_name(char *);
+static void inc_done(int);
#ifdef POP
#ifdef POP
-int done(int);
static int pop_action(char *);
static int pop_pack(char *);
static int map_count(void);
static int pop_action(char *);
static int pop_pack(char *);
static int map_count(void);
@@
-263,6
+263,8
@@
main (int argc, char **argv)
struct hes_postoffice *po;
#endif
struct hes_postoffice *po;
#endif
+ done=inc_done;
+
/* absolutely the first thing we do is save our privileges,
* and drop them if we can.
*/
/* absolutely the first thing we do is save our privileges,
* and drop them if we can.
*/
@@
-563,10
+565,15
@@
main (int argc, char **argv)
if ((maildir_copy = strdup(maildir)) == (char *)0)
adios (maildir, "error allocating memory to copy maildir");
if ((maildir_copy = strdup(maildir)) == (char *)0)
adios (maildir, "error allocating memory to copy maildir");
- if (noisy)
- create_folder(maildir, 0, done);
- else
- done (1);
+ if (!folder_exists(maildir)) {
+ /* If the folder doesn't exist, and we're given the -silent flag,
+ * just fail.
+ */
+ if (noisy)
+ create_folder(maildir, 0, done);
+ else
+ done (1);
+ }
if (chdir (maildir) == NOTOK)
adios (maildir, "unable to change directory to");
if (chdir (maildir) == NOTOK)
adios (maildir, "unable to change directory to");
@@
-945,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 */
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;
}
}
@@
-982,8
+990,8
@@
cpymsg (FILE *in, FILE *out)
#endif /* if 0 */
#endif /* if 0 */
-int
-done (int status)
+static void
+inc_done (int status)
{
#ifdef POP
if (packfile && pd != NOTOK)
{
#ifdef POP
if (packfile && pd != NOTOK)
@@
-996,7
+1004,6
@@
done (int status)
DROPGROUPPRIVS();
}
exit (status);
DROPGROUPPRIVS();
}
exit (status);
- return 1; /* dead code to satisfy the compiler */
}
#ifdef POP
}
#ifdef POP