summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@netfilter.org>2009-01-25 17:52:56 +0100
committerPablo Neira Ayuso <pablo@netfilter.org>2009-01-25 17:52:56 +0100
commiteec8fdf57f34fe0d80b884ad0e376ed24c63ffcc (patch)
tree427578697aef733b0f0ac089aa127e42033d81ca /include
parentb9ee88a0fdb20ed847f05efce1b0abdc8afbabaf (diff)
downloadconntrack-tools-eec8fdf57f34fe0d80b884ad0e376ed24c63ffcc.tar.gz
conntrack-tools-eec8fdf57f34fe0d80b884ad0e376ed24c63ffcc.zip
src: change behaviour of `-t' option
With this patch, the `-t' option adds an alarm that will flush the cache after CONFIG(purge_timeout) seconds specified in the config file. This looks much cleaner and more performance that looping on the entire conntrack table to set the new timeout of every single entry. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include')
-rw-r--r--include/cache.h1
-rw-r--r--include/conntrackd.h2
2 files changed, 2 insertions, 1 deletions
diff --git a/include/cache.h b/include/cache.h
index bb0ca4d..5e96dd3 100644
--- a/include/cache.h
+++ b/include/cache.h
@@ -126,6 +126,5 @@ void cache_dump(struct cache *c, int fd, int type);
void cache_commit(struct cache *c);
void cache_flush(struct cache *c);
void cache_bulk(struct cache *c);
-void cache_reset_timers(struct cache *c);
#endif
diff --git a/include/conntrackd.h b/include/conntrackd.h
index 99b9caa..3e10a2f 100644
--- a/include/conntrackd.h
+++ b/include/conntrackd.h
@@ -158,6 +158,8 @@ struct ct_sync_state {
struct nlif_handle *mcast_iface;
struct queue *tx_queue;
+ struct alarm_block reset_cache_alarm;
+
struct sync_mode *sync; /* sync mode */
/* statistics */