diff options
author | /C=EU/ST=EU/CN=Pablo Neira Ayuso/emailAddress=pablo@netfilter.org </C=EU/ST=EU/CN=Pablo Neira Ayuso/emailAddress=pablo@netfilter.org> | 2007-06-25 14:55:18 +0000 |
---|---|---|
committer | /C=EU/ST=EU/CN=Pablo Neira Ayuso/emailAddress=pablo@netfilter.org </C=EU/ST=EU/CN=Pablo Neira Ayuso/emailAddress=pablo@netfilter.org> | 2007-06-25 14:55:18 +0000 |
commit | 6575518b416eb625b562fa9f3d35533dfa8c1ca4 (patch) | |
tree | c417dc1943143a9ba2dc5fec24460adfcd4a53a9 /src/sync-mode.c | |
parent | 3f3a6701978df8ca16ebb5988eb7a46771deb964 (diff) | |
download | conntrack-tools-6575518b416eb625b562fa9f3d35533dfa8c1ca4.tar.gz conntrack-tools-6575518b416eb625b562fa9f3d35533dfa8c1ca4.zip |
fork when internal/external dump and commit requests are received
Diffstat (limited to 'src/sync-mode.c')
-rw-r--r-- | src/sync-mode.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/sync-mode.c b/src/sync-mode.c index 8433532..38ab016 100644 --- a/src/sync-mode.c +++ b/src/sync-mode.c @@ -244,8 +244,12 @@ static int local_handler_sync(int fd, int type, void *data) } break; case COMMIT: - dlog(STATE(log), "[REQ] commit external cache to master table"); - cache_commit(STATE_SYNC(external)); + ret = fork(); + if (ret == 0) { + dlog(STATE(log), "[REQ] committing external cache"); + cache_commit(STATE_SYNC(external)); + exit(EXIT_SUCCESS); + } break; case FLUSH_CACHE: dlog(STATE(log), "[REQ] flushing caches"); |