X-Git-Url: http://git.marmaro.de/?p=mmh;a=blobdiff_plain;f=uip%2Fmhstore.c;h=add5c0281bee1b9ac177fa5cec46c7c2a0f27119;hp=2b413d4cf685bdb583b69b9a489e12bbc345c53e;hb=ced6090a330d3d83d0bce709f756aa3d7d65fea4;hpb=337338b404931f06f0db2119c9e145e8ca5a9860 diff --git a/uip/mhstore.c b/uip/mhstore.c index 2b413d4..add5c02 100644 --- a/uip/mhstore.c +++ b/uip/mhstore.c @@ -1,10 +1,10 @@ /* - * mhstore.c -- store the contents of MIME messages - * - * This code is Copyright (c) 2002, by the authors of nmh. See the - * COPYRIGHT file in the root directory of the nmh distribution for - * complete copyright information. - */ +** mhstore.c -- store the contents of MIME messages +** +** This code is Copyright (c) 2002, by the authors of nmh. See the +** COPYRIGHT file in the root directory of the nmh distribution for +** complete copyright information. +*/ #include #include @@ -52,8 +52,8 @@ static struct swit switches[] = { { "help", 0 }, /* - * switches for debugging - */ +** switches for debugging +*/ #define DEBUGSW 13 { "debug", -5 }, { NULL, 0 } @@ -103,8 +103,8 @@ extern CT *cts; void freects_done (int) NORETURN; /* - * static prototypes - */ +** static prototypes +*/ static RETSIGTYPE pipeser (int); @@ -134,8 +134,8 @@ main (int argc, char **argv) argp = arguments; /* - * Parse arguments - */ + ** Parse arguments + */ while ((cp = *argp++)) { if (*cp == '-') { switch (smatch (++cp, switches)) { @@ -238,8 +238,8 @@ do_cache: set_endian (); /* - * Check if we've specified an additional profile - */ + ** Check if we've specified an additional profile + */ if ((cp = getenv ("MHSTORE"))) { if ((fp = fopen (cp, "r"))) { readconfig ((struct node **) 0, fp, cp, 0); @@ -250,8 +250,8 @@ do_cache: } /* - * Read the standard profile setup - */ + ** Read the standard profile setup + */ if ((fp = fopen (cp = etcpath ("mhn.defaults"), "r"))) { readconfig ((struct node **) 0, fp, cp, 0); fclose (fp); @@ -267,15 +267,15 @@ do_cache: cache_private = getcpy (m_maildir (cache_private)); /* - * Cache the current directory before we do any chdirs()'s. - */ + ** Cache the current directory before we do any chdirs()'s. + */ cwd = getcpy (pwd()); /* - * Check for storage directory. If specified, - * then store temporary files there. Else we - * store them in standard nmh directory. - */ + ** Check for storage directory. If specified, + ** then store temporary files there. Else we + ** store them in standard nmh directory. + */ if ((cp = context_find (nmhstorage)) && *cp) tmp = concat (cp, "/", invo_name, NULL); else @@ -288,8 +288,8 @@ do_cache: adios (NULL, "cannot specify msg and file at same time!"); /* - * check if message is coming from file - */ + ** check if message is coming from file + */ if (file) { if (!(cts = (CT *) calloc ((size_t) 2, sizeof(*cts)))) adios (NULL, "out of memory"); @@ -299,8 +299,8 @@ do_cache: *ctp++ = ct; } else { /* - * message(s) are coming from a folder - */ + ** message(s) are coming from a folder + */ if (!msgs.size) app_msgarg(&msgs, "cur"); if (!folder) @@ -324,7 +324,8 @@ do_cache: done (1); seq_setprev (mp); /* set the previous-sequence */ - if (!(cts = (CT *) calloc ((size_t) (mp->numsel + 1), sizeof(*cts)))) + if (!(cts = (CT *) calloc ((size_t) (mp->numsel + 1), + sizeof(*cts)))) adios (NULL, "out of memory"); ctp = cts; @@ -347,8 +348,8 @@ do_cache: SIGNAL (SIGPIPE, pipeser); /* - * Get the associated umask for the relevant contents. - */ + ** Get the associated umask for the relevant contents. + */ for (ctp = cts; *ctp; ctp++) { struct stat st; @@ -362,8 +363,8 @@ do_cache: } /* - * Store the message content - */ + ** Store the message content + */ store_all_messages (cts); /* Now free all the structures for the content */