From: Andre Noll Date: Sun, 11 Jan 2009 16:06:03 +0000 (+0100) Subject: server.c: Init the now timeval early. X-Git-Tag: v0.3.4~75^2~21 X-Git-Url: http://git.tue.mpg.de/?a=commitdiff_plain;h=cf3c87c56287ce84e0bb10ea8866294578ede489;p=paraslash.git server.c: Init the now timeval early. It is used at least in init_vss() which gets called before schedule(). --- diff --git a/server.c b/server.c index 96a40f33..287b628b 100644 --- a/server.c +++ b/server.c @@ -64,6 +64,7 @@ #include #include +#include #include "para.h" #include "error.h" @@ -486,6 +487,8 @@ static void server_init(int argc, char **argv) parse_config(0); log_welcome("para_server", conf.loglevel_arg); shm_init(); /* init mmd struct */ + /* make sure, the global now pointer is uptodate */ + gettimeofday(now, NULL); server_uptime(UPTIME_SET); /* reset server uptime */ init_user_list(user_list_file); /* become daemon */