static void init_config();
static void c_interface();
static void print_config();
+struct interface ifs[MAX_IFACES];
+int ifs_top;
static int clineno;
static int cerrflag;
struct message *m;
{
unsigned char buf[MAX_SIZE], *p;
- int n, hdr_len, fromlen;
+ int n, hdr_len;
+ unsigned int fromlen;
#ifdef LINUX
struct iphdr *ipptr;
#else
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-int debugd;
-int debugt;
-char progname[32];
-int no_timestamp;
-int stat_interval;
+extern int debugd;
+extern int debugt;
+extern char progname[];
+extern int no_timestamp;
+extern int stat_interval;
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
#ifdef LINUX
-struct ipip_route rts[MAX_ROUTES];
+extern struct ipip_route rts[MAX_ROUTES];
#else
struct route rts[MAX_ROUTES];
#endif
-int rts_top;
+extern int rts_top;
-struct interface ifs[MAX_IFACES];
-int ifs_top;
+extern struct interface ifs[MAX_IFACES];
+extern int ifs_top;
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/*
static void hupper(int sig);
jmp_buf term_env;
static void terminator();
+int stat_interval;
+int no_timestamp;
+int debugd;
+int debugt;
+char progname[32];
char *configfile, *routefile;
int version_only;
-void
+int
main(argc, argv)
int argc;
char *argv[];
{
int n, i, oops, help;
- time_t now;
FILE *pid_file;
debugd = 0;
if(setjmp(term_env)!=0){
send_stats(1); /* force print of statistics */
- now = time(NULL);
syslog(LOG_CRIT, "exit (killed)");
exit(0);
}
static int rlineno;
static int rerrflag;
+int rts_top;
+struct ipip_route rts[MAX_ROUTES];
/*
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *