From: Ralph Corderoy Date: Mon, 15 May 2017 14:14:44 +0000 (+0100) Subject: uip/mhoutsbr.c: Move exported prototype to new header file. X-Git-Url: https://diplodocus.org/git/nmh/commitdiff_plain/a30ef3465250ae21bb3928a6e120ba4351cf8ff0?ds=inline;hp=--cc uip/mhoutsbr.c: Move exported prototype to new header file. Alter the callers to include the new header file instead of having their own copy of the prototype. --- a30ef3465250ae21bb3928a6e120ba4351cf8ff0 diff --git a/Makefile.am b/Makefile.am index 7a894680..89c84b91 100644 --- a/Makefile.am +++ b/Makefile.am @@ -361,6 +361,7 @@ noinst_HEADERS = \ sbr/m_mktemp.h \ thirdparty/jsmn/jsmn.h \ uip/mhfree.h \ + uip/mhoutsbr.h \ # ## diff --git a/uip/mhbuild.c b/uip/mhbuild.c index 1ef90e36..686941ff 100644 --- a/uip/mhbuild.c +++ b/uip/mhbuild.c @@ -16,6 +16,7 @@ #include #include "../sbr/m_mktemp.h" #include "mhfree.h" +#include "mhoutsbr.h" #define MHBUILD_SWITCHES \ X("auto", 0, AUTOSW) \ @@ -93,9 +94,6 @@ static int unlink_outfile = 0; static void unlink_done (int) NORETURN; -/* mhbuildsbr.c */ -int output_message_fp (CT, FILE *, char*); - int main (int argc, char **argv) diff --git a/uip/mhfixmsg.c b/uip/mhfixmsg.c index 9d676cbe..549cffe9 100644 --- a/uip/mhfixmsg.c +++ b/uip/mhfixmsg.c @@ -12,6 +12,7 @@ #include #include "../sbr/m_mktemp.h" #include "mhfree.h" +#include "mhoutsbr.h" #include #define MHFIXMSG_SWITCHES \ @@ -63,9 +64,6 @@ extern int bogus_mp_content; /* flag from InitMultiPart */ /* flags to/from parse_header_attrs */ extern int suppress_extraneous_trailing_semicolon_warning; -/* mhoutsbr.c */ -int output_message_fp (CT, FILE *, char *); - /* mhmisc.c */ void flush_errors (void); diff --git a/uip/mhoutsbr.c b/uip/mhoutsbr.c index bbddbc90..65d9640c 100644 --- a/uip/mhoutsbr.c +++ b/uip/mhoutsbr.c @@ -14,13 +14,9 @@ #include #include #include +#include "mhoutsbr.h" -/* - * prototypes - */ -int output_message_fp (CT, FILE *, char *); - /* * static prototypes */ diff --git a/uip/mhoutsbr.h b/uip/mhoutsbr.h new file mode 100644 index 00000000..97b2eed0 --- /dev/null +++ b/uip/mhoutsbr.h @@ -0,0 +1,8 @@ +/* mhoutsbr.h -- output MIME messages from a Content structure. + * + * 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. + */ + +int output_message_fp(CT ct, FILE *fp, char *file);