]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - net/ipv4/netfilter/ipt_recent.c
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6
[linux-2.6-omap-h63xx.git] / net / ipv4 / netfilter / ipt_recent.c
index 50e06690eb5b8fa6bceff977ea09127adb18bfb9..3974d7cae5c02a05219e712ede460a7091fac964 100644 (file)
@@ -305,10 +305,10 @@ static void recent_mt_destroy(const struct xt_match *match, void *matchinfo)
                spin_lock_bh(&recent_lock);
                list_del(&t->list);
                spin_unlock_bh(&recent_lock);
-               recent_table_flush(t);
 #ifdef CONFIG_PROC_FS
                remove_proc_entry(t->name, proc_dir);
 #endif
+               recent_table_flush(t);
                kfree(t);
        }
        mutex_unlock(&recent_mutex);
@@ -340,7 +340,7 @@ static void *recent_seq_start(struct seq_file *seq, loff_t *pos)
 static void *recent_seq_next(struct seq_file *seq, void *v, loff_t *pos)
 {
        struct recent_iter_state *st = seq->private;
-       struct recent_table *t = st->table;
+       const struct recent_table *t = st->table;
        struct recent_entry *e = v;
        struct list_head *head = e->list.next;
 
@@ -361,7 +361,7 @@ static void recent_seq_stop(struct seq_file *s, void *v)
 
 static int recent_seq_show(struct seq_file *seq, void *v)
 {
-       struct recent_entry *e = v;
+       const struct recent_entry *e = v;
        unsigned int i;
 
        i = (e->index - 1) % ip_pkt_list_tot;
@@ -396,7 +396,7 @@ static int recent_seq_open(struct inode *inode, struct file *file)
 static ssize_t recent_proc_write(struct file *file, const char __user *input,
                                 size_t size, loff_t *loff)
 {
-       struct proc_dir_entry *pde = PDE(file->f_path.dentry->d_inode);
+       const struct proc_dir_entry *pde = PDE(file->f_path.dentry->d_inode);
        struct recent_table *t = pde->data;
        struct recent_entry *e;
        char buf[sizeof("+255.255.255.255")], *c = buf;