From: Ralph Corderoy Date: Sat, 11 Nov 2017 14:49:08 +0000 (+0000) Subject: m_draft.c: Move interface to own file. X-Git-Url: https://diplodocus.org/git/nmh/commitdiff_plain/3a6910790ab3a1d75a3c53827e0fb4f8523e82af m_draft.c: Move interface to own file. --- diff --git a/Makefile.am b/Makefile.am index d32f5fe4..a467d256 100644 --- a/Makefile.am +++ b/Makefile.am @@ -390,6 +390,7 @@ noinst_HEADERS = \ sbr/m_atoi.h \ sbr/m_backup.h \ sbr/m_convert.h \ + sbr/m_draft.h \ sbr/m_maildir.h \ sbr/m_mktemp.h \ sbr/m_popen.h \ diff --git a/h/prototypes.h b/h/prototypes.h index a3793868..f12bf371 100644 --- a/h/prototypes.h +++ b/h/prototypes.h @@ -113,8 +113,6 @@ char *get_charset(void); /* Return malloc'd copy of str, or of "" if NULL, exit on failure. */ char *getcpy(const char *str); -char *m_draft (char *, char *, int, int *); - m_getfld_state_t m_getfld_state_init(FILE *iob); void m_getfld_state_reset (m_getfld_state_t *); void m_getfld_state_destroy (m_getfld_state_t *); diff --git a/sbr/m_draft.c b/sbr/m_draft.c index 1a4aab5d..6e662a1b 100644 --- a/sbr/m_draft.c +++ b/sbr/m_draft.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "m_draft.h" #include "m_convert.h" #include "folder_read.h" #include "folder_realloc.h" diff --git a/sbr/m_draft.h b/sbr/m_draft.h new file mode 100644 index 00000000..7d462236 --- /dev/null +++ b/sbr/m_draft.h @@ -0,0 +1,8 @@ +/* m_draft.h -- construct the name of a draft message + * + * 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. */ + +/* Does not return NULL. */ +char *m_draft(char *, char *, int, int *); diff --git a/uip/anno.c b/uip/anno.c index c0e98b25..59a5b99d 100644 --- a/uip/anno.c +++ b/uip/anno.c @@ -42,6 +42,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/m_convert.h" #include "sbr/getfolder.h" #include "sbr/folder_read.h" diff --git a/uip/comp.c b/uip/comp.c index adffcbb6..027ba3db 100644 --- a/uip/comp.c +++ b/uip/comp.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/m_convert.h" #include "sbr/getfolder.h" #include "sbr/fdcompare.h" diff --git a/uip/dist.c b/uip/dist.c index 8b05d9e1..1aa57276 100644 --- a/uip/dist.c +++ b/uip/dist.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/m_convert.h" #include "sbr/getfolder.h" #include "sbr/folder_read.h" diff --git a/uip/forw.c b/uip/forw.c index fa56b02a..84c94c13 100644 --- a/uip/forw.c +++ b/uip/forw.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/m_convert.h" #include "sbr/getfolder.h" #include "sbr/folder_read.h" diff --git a/uip/refile.c b/uip/refile.c index 8cf59026..eb63c9a5 100644 --- a/uip/refile.c +++ b/uip/refile.c @@ -7,6 +7,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/m_convert.h" #include "sbr/getfolder.h" #include "sbr/folder_read.h" diff --git a/uip/repl.c b/uip/repl.c index 6d4e125b..198b3f02 100644 --- a/uip/repl.c +++ b/uip/repl.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/m_convert.h" #include "sbr/getfolder.h" #include "sbr/folder_read.h" diff --git a/uip/send.c b/uip/send.c index f19ecba3..0a893a1e 100644 --- a/uip/send.c +++ b/uip/send.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/m_convert.h" #include "sbr/folder_read.h" #include "sbr/context_save.h" diff --git a/uip/show.c b/uip/show.c index 697dbd80..7753c831 100644 --- a/uip/show.c +++ b/uip/show.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/m_convert.h" #include "sbr/getfolder.h" #include "sbr/folder_read.h" diff --git a/uip/whatnowsbr.c b/uip/whatnowsbr.c index 2addfe7b..c4549f18 100644 --- a/uip/whatnowsbr.c +++ b/uip/whatnowsbr.c @@ -38,6 +38,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/m_backup.h" #include "sbr/geteditor.h" #include "sbr/context_save.h" diff --git a/uip/whom.c b/uip/whom.c index 56ae6b46..c2d1a304 100644 --- a/uip/whom.c +++ b/uip/whom.c @@ -6,6 +6,7 @@ */ #include "h/mh.h" +#include "sbr/m_draft.h" #include "sbr/context_find.h" #include "sbr/brkstring.h" #include "sbr/ambigsw.h"