diff options
author | Phil Sutter <phil@nwl.cc> | 2024-11-05 22:27:34 +0100 |
---|---|---|
committer | Phil Sutter <phil@nwl.cc> | 2024-11-05 23:53:12 +0100 |
commit | 4220bd83187b6deac7a93d6775aa5e4423b8e2e5 (patch) | |
tree | 32e2048060a27e35401302b06c4332cc9ffc15de | |
parent | 401d91326bc9c3a5bab2fd319acdc844f511bb7e (diff) |
conntrack: Fix for ENOENT in mnl_nfct_delete_cb()
Align behaviour with that of mnl_nfct_update_cb(): Just free the
nf_conntrack object and return. Do not increment counter variable, and
certainly do not try to print an uninitialized buffer.
Fixes: a7abf3f5dc7c4 ("conntrack: skip ENOENT when -U/-D finds a stale conntrack entry")
Reviewed-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Phil Sutter <phil@nwl.cc>
-rw-r--r-- | src/conntrack.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/conntrack.c b/src/conntrack.c index a51a3ef..52ba4ac 100644 --- a/src/conntrack.c +++ b/src/conntrack.c @@ -2030,7 +2030,7 @@ static int mnl_nfct_delete_cb(const struct nlmsghdr *nlh, void *data) if (res < 0) { /* the entry has vanish in middle of the delete */ if (errno == ENOENT) - goto done; + goto destroy_ok; exit_error(OTHER_PROBLEM, "Operation failed: %s", err2str(errno, CT_DELETE)); |