From: Ralph Corderoy Date: Mon, 15 May 2017 13:40:52 +0000 (+0100) Subject: sbr/m_mktemp.h: Create with missing prototypes. X-Git-Url: https://diplodocus.org/git/nmh/commitdiff_plain/dcbbebd768c6444e2fbf83de2b3dc6c76b513a54?ds=inline;hp=--cc sbr/m_mktemp.h: Create with missing prototypes. Some of sbr/m_mktemp.c's functions didn't have prototypes in a header file so callers were declaring prototypes themselves. Have them include the new header file instead. --- dcbbebd768c6444e2fbf83de2b3dc6c76b513a54 diff --git a/Makefile.am b/Makefile.am index 38fc3e7c..7a894680 100644 --- a/Makefile.am +++ b/Makefile.am @@ -358,6 +358,7 @@ noinst_HEADERS = \ h/utils.h \ mts/smtp/smtp.h \ sbr/ctype-checked.h \ + sbr/m_mktemp.h \ thirdparty/jsmn/jsmn.h \ uip/mhfree.h \ # diff --git a/sbr/m_mktemp.c b/sbr/m_mktemp.c index 338302c0..56810445 100644 --- a/sbr/m_mktemp.c +++ b/sbr/m_mktemp.c @@ -8,6 +8,7 @@ #include #include #include +#include "m_mktemp.h" static void register_for_removal(const char *); diff --git a/sbr/m_mktemp.h b/sbr/m_mktemp.h new file mode 100644 index 00000000..dbc614fe --- /dev/null +++ b/sbr/m_mktemp.h @@ -0,0 +1,9 @@ +/* m_mktemp.h -- Construct a temporary file. + * + * 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. + */ + +void remove_registered_files_atexit(void); +void remove_registered_files(int sig); diff --git a/sbr/signals.c b/sbr/signals.c index 97ac780c..accb6950 100644 --- a/sbr/signals.c +++ b/sbr/signals.c @@ -7,9 +7,7 @@ #include #include - -/* sbr/m_mktemp.c */ -extern void remove_registered_files(int); +#include "m_mktemp.h" /* diff --git a/sbr/utils.c b/sbr/utils.c index 7abf8e60..e0725148 100644 --- a/sbr/utils.c +++ b/sbr/utils.c @@ -8,11 +8,9 @@ #include #include #include +#include "m_mktemp.h" #include -/* sbr/m_mktemp.c */ -extern void remove_registered_files_atexit(void); - extern char *mhdocdir; /* plurals gives the letter ess to indicate a plural noun, or an empty