diff options
Diffstat (limited to 'net')
-rw-r--r-- | net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c | 5 | ||||
-rw-r--r-- | net/netfilter/nf_conntrack_core.c | 5 |
2 files changed, 5 insertions, 5 deletions
diff --git a/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c b/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c index 167619f638c6..6c8624a54933 100644 --- a/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c +++ b/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c | |||
@@ -529,15 +529,10 @@ static int init_or_cleanup(int init) | |||
529 | goto cleanup_localinops; | 529 | goto cleanup_localinops; |
530 | } | 530 | } |
531 | #endif | 531 | #endif |
532 | |||
533 | /* For use by REJECT target */ | ||
534 | ip_ct_attach = __nf_conntrack_attach; | ||
535 | |||
536 | return ret; | 532 | return ret; |
537 | 533 | ||
538 | cleanup: | 534 | cleanup: |
539 | synchronize_net(); | 535 | synchronize_net(); |
540 | ip_ct_attach = NULL; | ||
541 | #ifdef CONFIG_SYSCTL | 536 | #ifdef CONFIG_SYSCTL |
542 | unregister_sysctl_table(nf_ct_ipv4_sysctl_header); | 537 | unregister_sysctl_table(nf_ct_ipv4_sysctl_header); |
543 | cleanup_localinops: | 538 | cleanup_localinops: |
diff --git a/net/netfilter/nf_conntrack_core.c b/net/netfilter/nf_conntrack_core.c index 0ce337a1d974..d622ddf08bb0 100644 --- a/net/netfilter/nf_conntrack_core.c +++ b/net/netfilter/nf_conntrack_core.c | |||
@@ -1556,6 +1556,8 @@ void nf_conntrack_cleanup(void) | |||
1556 | { | 1556 | { |
1557 | int i; | 1557 | int i; |
1558 | 1558 | ||
1559 | ip_ct_attach = NULL; | ||
1560 | |||
1559 | /* This makes sure all current packets have passed through | 1561 | /* This makes sure all current packets have passed through |
1560 | netfilter framework. Roll on, two-stage module | 1562 | netfilter framework. Roll on, two-stage module |
1561 | delete... */ | 1563 | delete... */ |
@@ -1715,6 +1717,9 @@ int __init nf_conntrack_init(void) | |||
1715 | nf_ct_l3protos[i] = &nf_conntrack_generic_l3proto; | 1717 | nf_ct_l3protos[i] = &nf_conntrack_generic_l3proto; |
1716 | write_unlock_bh(&nf_conntrack_lock); | 1718 | write_unlock_bh(&nf_conntrack_lock); |
1717 | 1719 | ||
1720 | /* For use by REJECT target */ | ||
1721 | ip_ct_attach = __nf_conntrack_attach; | ||
1722 | |||
1718 | /* Set up fake conntrack: | 1723 | /* Set up fake conntrack: |
1719 | - to never be deleted, not in any hashes */ | 1724 | - to never be deleted, not in any hashes */ |
1720 | atomic_set(&nf_conntrack_untracked.ct_general.use, 1); | 1725 | atomic_set(&nf_conntrack_untracked.ct_general.use, 1); |