summaryrefslogtreecommitdiff
path: root/src/run.c
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@netfilter.org>2011-10-24 12:01:26 +0200
committerPablo Neira Ayuso <pablo@netfilter.org>2011-10-24 12:01:26 +0200
commit482c167dffd033915f693c13eb3c47e6f6f77a27 (patch)
treebb196279e47214a1675e805ad127184256280c02 /src/run.c
parentdaa3b849286222a131e0829676ba98140de7241b (diff)
downloadconntrack-tools-482c167dffd033915f693c13eb3c47e6f6f77a27.tar.gz
conntrack-tools-482c167dffd033915f693c13eb3c47e6f6f77a27.zip
conntrackd: add missing initial caching of gettimeofday()
Thus, we fix conntrackd -i for flows that were just retrieved from the kernel: tcp 6 ESTABLISHED src=192.168.1.135 dst=208.68.163.220 sport=42179 dport=5222 src=208.68.163.220 dst=192.168.1.135 sport=5222 dport=42179 [ASSURED] mark=0 [active since 1319450515s] Note the wrong "active since" value. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'src/run.c')
-rw-r--r--src/run.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/run.c b/src/run.c
index 6dfc8d4..265a949 100644
--- a/src/run.c
+++ b/src/run.c
@@ -321,6 +321,8 @@ static int get_handler(enum nf_conntrack_msg_type type,
int
init(void)
{
+ do_gettimeofday();
+
if (CONFIG(flags) & CTD_STATS_MODE)
STATE(mode) = &stats_mode;
else if (CONFIG(flags) & CTD_SYNC_MODE)