Skip to content

Commit

Permalink
netfilter: xt_CT: fix wrong checking in the timeout assignment path
Browse files Browse the repository at this point in the history
The current checking always succeeded. We have to check the first
character of the string to check that it's empty, thus, skipping
the timeout path.

This fixes the use of the CT target without the timeout option.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
  • Loading branch information
Pablo Neira Ayuso committed Apr 30, 2012
1 parent 8537de8 commit 6cf5185
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/netfilter/xt_CT.c
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ static int xt_ct_tg_check_v1(const struct xt_tgchk_param *par)
}

#ifdef CONFIG_NF_CONNTRACK_TIMEOUT
if (info->timeout) {
if (info->timeout[0]) {
typeof(nf_ct_timeout_find_get_hook) timeout_find_get;
struct nf_conn_timeout *timeout_ext;

Expand Down

0 comments on commit 6cf5185

Please sign in to comment.