From: Ralph Corderoy Date: Sun, 12 Nov 2017 13:08:02 +0000 (+0000) Subject: m_name.c: Move interface to own file. X-Git-Url: https://diplodocus.org/git/nmh/commitdiff_plain/f9754b35f2f3b4c5cb0890f154181d2bab66c679?hp=b54c3cca7632b31faf33e57f35631e9589551e1a m_name.c: Move interface to own file. --- diff --git a/Makefile.am b/Makefile.am index 25f212cb..94f82fcc 100644 --- a/Makefile.am +++ b/Makefile.am @@ -409,6 +409,7 @@ noinst_HEADERS = \ sbr/m_gmprot.h \ sbr/m_maildir.h \ sbr/m_mktemp.h \ + sbr/m_name.h \ sbr/m_popen.h \ sbr/m_rand.h \ sbr/makedir.h \ diff --git a/h/prototypes.h b/h/prototypes.h index 3cec8aea..d47ac224 100644 --- a/h/prototypes.h +++ b/h/prototypes.h @@ -15,8 +15,6 @@ char *etcpath(char *) NONNULL(1); struct msgs_array; -char *m_name (int); - int pidwait (pid_t, int); void scan_detect_mbox_style (FILE *); diff --git a/sbr/folder_addmsg.c b/sbr/folder_addmsg.c index 903a0771..a18f1ce7 100644 --- a/sbr/folder_addmsg.c +++ b/sbr/folder_addmsg.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "m_name.h" #include "cpydata.h" #include "m_atoi.h" #include "ext_hook.h" diff --git a/sbr/folder_delmsgs.c b/sbr/folder_delmsgs.c index 936dbf6a..533ab9ba 100644 --- a/sbr/folder_delmsgs.c +++ b/sbr/folder_delmsgs.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "m_name.h" #include "seq_save.h" #include "m_backup.h" #include "ext_hook.h" diff --git a/sbr/folder_pack.c b/sbr/folder_pack.c index 6a2b9509..ba84d1f7 100644 --- a/sbr/folder_pack.c +++ b/sbr/folder_pack.c @@ -7,6 +7,7 @@ */ #include "h/mh.h" +#include "m_name.h" #include "seq_setcur.h" #include "ext_hook.h" #include "folder_realloc.h" diff --git a/sbr/m_draft.c b/sbr/m_draft.c index b5d252ab..342f44f0 100644 --- a/sbr/m_draft.c +++ b/sbr/m_draft.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "m_name.h" #include "seq_setprev.h" #include "seq_setcur.h" #include "seq_save.h" diff --git a/sbr/m_name.c b/sbr/m_name.c index 835c1ba2..8bf8ac04 100644 --- a/sbr/m_name.c +++ b/sbr/m_name.c @@ -7,6 +7,7 @@ #include #include "h/mh.h" +#include "m_name.h" #include "h/utils.h" #define STR(s) #s diff --git a/sbr/m_name.h b/sbr/m_name.h new file mode 100644 index 00000000..6ddfdf86 --- /dev/null +++ b/sbr/m_name.h @@ -0,0 +1,7 @@ +/* m_name.h -- return a message number as a string + * + * This code is Copyright (c) 2017, by the authors of nmh. See the + * COPYRIGHT file in the root directory of the nmh distribution for + * complete copyright information. */ + +char *m_name(int); diff --git a/sbr/seq_list.c b/sbr/seq_list.c index 2ebf6dd6..0aef35e3 100644 --- a/sbr/seq_list.c +++ b/sbr/seq_list.c @@ -7,6 +7,7 @@ */ #include "h/mh.h" +#include "m_name.h" #include "seq_list.h" #include "seq_getnum.h" #include "h/utils.h" diff --git a/uip/anno.c b/uip/anno.c index 0207d472..bba94082 100644 --- a/uip/anno.c +++ b/uip/anno.c @@ -42,6 +42,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/getarguments.h" #include "sbr/seq_setcur.h" #include "sbr/seq_save.h" diff --git a/uip/burst.c b/uip/burst.c index 5503e5e3..09ecb992 100644 --- a/uip/burst.c +++ b/uip/burst.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" diff --git a/uip/comp.c b/uip/comp.c index ae32f695..6a22dd30 100644 --- a/uip/comp.c +++ b/uip/comp.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/read_switch_multiword.h" diff --git a/uip/dist.c b/uip/dist.c index 0302b93b..30ae67d9 100644 --- a/uip/dist.c +++ b/uip/dist.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/read_switch_multiword.h" diff --git a/uip/fmttest.c b/uip/fmttest.c index 782ce516..94c3b979 100644 --- a/uip/fmttest.c +++ b/uip/fmttest.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_getfld.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" diff --git a/uip/forw.c b/uip/forw.c index 86462216..a79fcc05 100644 --- a/uip/forw.c +++ b/uip/forw.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/read_switch_multiword.h" diff --git a/uip/inc.c b/uip/inc.c index 1a3b28b1..ac39f725 100644 --- a/uip/inc.c +++ b/uip/inc.c @@ -31,6 +31,7 @@ #endif #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/concat.h" diff --git a/uip/mhfixmsg.c b/uip/mhfixmsg.c index 35160708..eedee6cc 100644 --- a/uip/mhfixmsg.c +++ b/uip/mhfixmsg.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/m_getfld.h" #include "sbr/getarguments.h" diff --git a/uip/mhlist.c b/uip/mhlist.c index ea9d8de4..b3bba8ba 100644 --- a/uip/mhlist.c +++ b/uip/mhlist.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" diff --git a/uip/mhn.c b/uip/mhn.c index c576eeb5..cc50a13c 100644 --- a/uip/mhn.c +++ b/uip/mhn.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" diff --git a/uip/mhpath.c b/uip/mhpath.c index 46b24361..03b902f5 100644 --- a/uip/mhpath.c +++ b/uip/mhpath.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" #include "sbr/seq_save.h" diff --git a/uip/mhshow.c b/uip/mhshow.c index 1c6bdd8d..66d2366b 100644 --- a/uip/mhshow.c +++ b/uip/mhshow.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/seq_setunseen.h" diff --git a/uip/mhstore.c b/uip/mhstore.c index 21bf0d18..9cbdc69a 100644 --- a/uip/mhstore.c +++ b/uip/mhstore.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" diff --git a/uip/packf.c b/uip/packf.c index c61d6552..3b9ce9d4 100644 --- a/uip/packf.c +++ b/uip/packf.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/getarguments.h" #include "sbr/read_yes_or_no_if_tty.h" diff --git a/uip/pick.c b/uip/pick.c index 6ca9eaac..9abb8266 100644 --- a/uip/pick.c +++ b/uip/pick.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" #include "sbr/seq_save.h" diff --git a/uip/refile.c b/uip/refile.c index 68202ae8..5994d905 100644 --- a/uip/refile.c +++ b/uip/refile.c @@ -7,6 +7,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" #include "sbr/seq_setcur.h" diff --git a/uip/repl.c b/uip/repl.c index 7581c17f..3e3b1dce 100644 --- a/uip/repl.c +++ b/uip/repl.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/getarguments.h" #include "sbr/read_switch_multiword.h" #include "sbr/concat.h" diff --git a/uip/replsbr.c b/uip/replsbr.c index 9c1cd8ed..a76444b1 100644 --- a/uip/replsbr.c +++ b/uip/replsbr.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/m_getfld.h" #include "sbr/read_switch.h" diff --git a/uip/scan.c b/uip/scan.c index 65347680..654f378a 100644 --- a/uip/scan.c +++ b/uip/scan.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" #include "sbr/seq_save.h" diff --git a/uip/scansbr.c b/uip/scansbr.c index fc66c829..28c382fe 100644 --- a/uip/scansbr.c +++ b/uip/scansbr.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_gmprot.h" #include "sbr/m_getfld.h" #include "sbr/getcpy.h" diff --git a/uip/send.c b/uip/send.c index 08c87b45..6c3dc939 100644 --- a/uip/send.c +++ b/uip/send.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/getarguments.h" #include "sbr/read_switch_multiword.h" #include "sbr/concat.h" diff --git a/uip/sendsbr.c b/uip/sendsbr.c index 1b65efb8..5163b1b7 100644 --- a/uip/sendsbr.c +++ b/uip/sendsbr.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_getfld.h" #include "sbr/concat.h" #include "sbr/cpydgst.h" diff --git a/uip/show.c b/uip/show.c index ec56e537..004a2921 100644 --- a/uip/show.c +++ b/uip/show.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_getfld.h" #include "sbr/getarguments.h" #include "sbr/seq_setunseen.h" diff --git a/uip/sortm.c b/uip/sortm.c index b43934ca..e2b6185c 100644 --- a/uip/sortm.c +++ b/uip/sortm.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/m_getfld.h" #include "sbr/getarguments.h" #include "sbr/seq_setprev.h" diff --git a/uip/whatnowproc.c b/uip/whatnowproc.c index 8f5b534f..3c6e2ef7 100644 --- a/uip/whatnowproc.c +++ b/uip/whatnowproc.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_name.h" #include "sbr/r1bindex.h" #include "sbr/geteditor.h" #include "sbr/context_save.h"