Merge with /pub/scm/linux/kernel/git/torvalds/linux-2.6.git
[powerpc.git] / net / netfilter / nf_conntrack_core.c
index 9a67c79..1da6783 100644 (file)
@@ -387,7 +387,7 @@ nf_ct_invert_tuple(struct nf_conntrack_tuple *inverse,
 static void nf_ct_unlink_expect(struct nf_conntrack_expect *exp)
 {
        ASSERT_WRITE_LOCK(&nf_conntrack_lock);
-       NF_CT_ASSERT(!timer_pending(&exp_timeout));
+       NF_CT_ASSERT(!timer_pending(&exp->timeout));
        list_del(&exp->list);
        NF_CT_STAT_INC(expect_delete);
        exp->master->expecting--;
@@ -1395,6 +1395,13 @@ void nf_conntrack_cleanup(void)
        kmem_cache_destroy(nf_conntrack_expect_cachep);
        free_conntrack_hash(nf_conntrack_hash, nf_conntrack_vmalloc,
                            nf_conntrack_htable_size);
+
+       /* free l3proto protocol tables */
+       for (i = 0; i < PF_MAX; i++)
+               if (nf_ct_protos[i]) {
+                       kfree(nf_ct_protos[i]);
+                       nf_ct_protos[i] = NULL;
+               }
 }
 
 static struct list_head *alloc_hashtable(int size, int *vmalloced)