missing includes, intializers, consts
[apps/madmutt.git] / main.c
diff --git a/main.c b/main.c
index aaa8877..022d5ec 100644 (file)
--- a/main.c
+++ b/main.c
@@ -42,6 +42,9 @@
 
 #ifdef HAVE_GETOPT_H
 #include <getopt.h>
 
 #ifdef HAVE_GETOPT_H
 #include <getopt.h>
+#else
+extern char *optarg;
+extern int optind;
 #endif
 
 #ifdef HAVE_LIBIDN
 #endif
 
 #ifdef HAVE_LIBIDN
@@ -56,7 +59,7 @@
 #include <libesmtp.h>
 #endif
 
 #include <libesmtp.h>
 #endif
 
-#if USE_HCACHE
+#ifdef USE_HCACHE
 #if HAVE_QDBM
 #include <depot.h>
 #elif HAVE_GDBM
 #if HAVE_QDBM
 #include <depot.h>
 #elif HAVE_GDBM
@@ -229,7 +232,7 @@ static void show_version (void)
   printf ("  libESMTP %s\n", buf);
 #endif
 
   printf ("  libESMTP %s\n", buf);
 #endif
 
-#if USE_HCACHE
+#ifdef USE_HCACHE
 #if HAVE_QDBM
   printf ("  qdbm %s\n", dpversion);
 #elif HAVE_GDBM
 #if HAVE_QDBM
   printf ("  qdbm %s\n", dpversion);
 #elif HAVE_GDBM
@@ -297,7 +300,7 @@ static void show_version (void)
 #else
          "-USE_INODESORT   "
 #endif
 #else
          "-USE_INODESORT   "
 #endif
-#if USE_HCACHE
+#ifdef USE_HCACHE
          "+USE_HCACHE  "
 #else
          "-USE_HCACHE  "
          "+USE_HCACHE  "
 #else
          "-USE_HCACHE  "
@@ -573,8 +576,6 @@ int main (int argc, char **argv)
   int i;
   int explicit_folder = 0;
   int dump_variables = -1;
   int i;
   int explicit_folder = 0;
   int dump_variables = -1;
-  extern char *optarg;
-  extern int optind;
 
   /* initialize random number for tmp file creation */ 
   srand ((unsigned int) time (NULL));
 
   /* initialize random number for tmp file creation */ 
   srand ((unsigned int) time (NULL));