]> diplodocus.org Git - nmh/blobdiff - uip/rcvstore.c
sbr/mts.c: Delete mmdlm2; use same-valued mmdlm1 instead.
[nmh] / uip / rcvstore.c
index 25bb8780dd6eb66ae96f7ee0fc39ad6f27966bdc..e9654b489b8cebb25426a06d5765f069b9073c8d 100644 (file)
@@ -1,6 +1,4 @@
-
-/*
- * rcvstore.c -- asynchronously add mail to a folder
+/* rcvstore.c -- asynchronously add mail to a folder
  *
  * This code is Copyright (c) 2002, by the authors of nmh.  See the
  * COPYRIGHT file in the root directory of the nmh distribution for
  *
  * This code is Copyright (c) 2002, by the authors of nmh.  See the
  * COPYRIGHT file in the root directory of the nmh distribution for
@@ -11,6 +9,10 @@
 #include <fcntl.h>
 #include <h/signals.h>
 #include <h/mts.h>
 #include <fcntl.h>
 #include <h/signals.h>
 #include <h/mts.h>
+#include <h/utils.h>
+#include "../sbr/m_maildir.h"
+#include "../sbr/m_mktemp.h"
+#include "../sbr/makedir.h"
 
 #define RCVSTORE_SWITCHES \
     X("create", 0, CRETSW) \
 
 #define RCVSTORE_SWITCHES \
     X("create", 0, CRETSW) \
@@ -175,7 +177,7 @@ main (int argc, char **argv)
     /* don't add file if it is empty */
     if (st.st_size == 0) {
        (void) m_unlink (tmpfilenam);
     /* don't add file if it is empty */
     if (st.st_size == 0) {
        (void) m_unlink (tmpfilenam);
-       advise (NULL, "empty file");
+       inform("empty file");
        done (0);
     }
 
        done (0);
     }
 
@@ -222,7 +224,7 @@ main (int argc, char **argv)
 /*
  * Clean up and exit
  */
 /*
  * Clean up and exit
  */
-static void
+static void NORETURN
 unlink_done(int status)
 {
     if (tmpfilenam && *tmpfilenam)
 unlink_done(int status)
 {
     if (tmpfilenam && *tmpfilenam)