]> diplodocus.org Git - nmh/commitdiff
Use `void' in prototypes for functions with no parameters.
authorRalph Corderoy <ralph@inputplus.co.uk>
Mon, 15 May 2017 12:39:08 +0000 (13:39 +0100)
committerRalph Corderoy <ralph@inputplus.co.uk>
Mon, 15 May 2017 12:39:08 +0000 (13:39 +0100)
The old-style `int foo()' still lived on in a few places.

h/addrsbr.h
h/fmt_scan.h
h/prototypes.h
sbr/addrsbr.c
sbr/credentials.c
sbr/fmt_new.c
sbr/m_mktemp.c
uip/scansbr.c

index 3e6bffd20e752f3f1c5f5675777f09ccc6ef69ed..a9e989781282939db574cf7a4a392b577fc73fdc 100644 (file)
@@ -42,7 +42,7 @@ int ismymbox(struct mailname *);
  * Enable Email Address Internationalization, which requires
  * support of 8-bit addresses.
  */
-void enable_eai();
+void enable_eai(void);
 
 /*
  * Parse an address header, and return a sequence of email addresses.
index faedecda37785b0899d6126793aa32fa18f47a3a..4f14b65c48e0ecca889feb1356a1b50e9297ae22 100644 (file)
@@ -116,7 +116,7 @@ char *new_fs (char *form, char *format, char *default_fs);
  * Free memory allocated by new_fs().  It allocates to a static so
  * no argument is necessary.
  */
-void free_fs ();
+void free_fs(void);
 
 /*
  * Compile a format string into a set of format instructions.  Arguments are:
index dfc3b5cfc272f72158d154b0ec80fa0eeb095934..74bf725558e162d0fe2e3b3487cf6cb64732c139 100644 (file)
@@ -260,7 +260,7 @@ int m_rand (unsigned char *, size_t);
 char *m_mktemp(const char *, int *, FILE **);
 char *m_mktemp2(const char *, const char *, int *, FILE **);
 char *m_mktemps(const char *pfx, const char *suffix, int *, FILE **);
-char *get_temp_dir();
+char *get_temp_dir(void);
 
 /*
  * Create a subprocess and redirect our standard output to it.
@@ -340,7 +340,7 @@ void ruserpass (const char *host, char **aname, char **apass, int flags);
 
 int remdir (char *);
 void scan_detect_mbox_style (FILE *);
-void scan_finished ();
+void scan_finished(void);
 void scan_reset_m_getfld_state ();
 int seq_addmsg (struct msgs *, char *, int, int, int);
 int seq_addsel (struct msgs *, char *, int, int);
@@ -507,7 +507,7 @@ void hexify (const unsigned char *, size_t, char **);
 /*
  * credentials management
  */
-void init_credentials_file ();
+void init_credentials_file(void);
 
 /*
  * Allocate and return a credentials structure.  The credentials structure
index a9f16d8f9dec788413b4f177706f51db8742ccb6..6d883ea1ae485c99f5c76755290edf188611cd7a 100644 (file)
@@ -77,7 +77,7 @@ static char adr[BUFSIZ];
 static int eai = 0;
 
 void
-enable_eai() {
+enable_eai(void) {
     eai = 1;
 }
 
index b34b967395949dbca85ec8ab742fbc9a8c339289..f6fd15de9f0ae2febe1ef83071397826b51c04da 100644 (file)
@@ -16,7 +16,7 @@ struct nmh_creds {
 };
 
 void
-init_credentials_file () {
+init_credentials_file(void) {
     if (credentials_file == NULL) {
         char *cred_style = context_find ("credentials");
 
index c832e7fa9db165661a76de6cde0b54f371e88db9..c699dbd9c2e4d8b4a8bdf17bd135968d8490190c 100644 (file)
@@ -56,7 +56,7 @@ new_fs (char *form, char *format, char *default_fs)
 
 
 void
-free_fs (){
+free_fs(void) {
     free (formats);
     formats = 0;
 }
index 2a10ed8cf0826cb27a2e9b9b91909a01f3b619a8..f4d5c3fa179f37d1d49e1ca3b5fb75c49182e36a 100644 (file)
@@ -228,7 +228,7 @@ m_mktemps(
 
 
 char *
-get_temp_dir()
+get_temp_dir(void)
 {
     /* Ignore envvars if we are setuid */
     if ((getuid()==geteuid()) && (getgid()==getegid())) {
index 7023502fbf84b4574d84d51f0201205fb1330fa5..7d81b5138a33efecf5aac149b39a757b4fc9f2f0 100644 (file)
@@ -336,7 +336,7 @@ finished:
 
 /* The following two functions allow access to the global gstate above. */
 void
-scan_finished () {
+scan_finished(void) {
     m_getfld_state_destroy (&gstate);
 }