Skip to content

Commit

Permalink
netfilter: assign PDE->fops before gluing PDE into /proc tree
Browse files Browse the repository at this point in the history
Replace create_proc_entry with specially created for this purpose proc_create.

Signed-off-by: Denis V. Lunev <den@openvz.org>
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Denis V. Lunev authored and David S. Miller committed May 2, 2008
1 parent 84841c3 commit 52c0e11
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions net/netfilter/nf_conntrack_standalone.c
Original file line number Diff line number Diff line change
Expand Up @@ -296,11 +296,11 @@ static int nf_conntrack_standalone_init_proc(void)
pde = proc_net_fops_create(&init_net, "nf_conntrack", 0440, &ct_file_ops);
if (!pde)
goto out_nf_conntrack;
pde = create_proc_entry("nf_conntrack", S_IRUGO, init_net.proc_net_stat);

pde = proc_create("nf_conntrack", S_IRUGO, init_net.proc_net_stat,
&ct_cpu_seq_fops);
if (!pde)
goto out_stat_nf_conntrack;
pde->proc_fops = &ct_cpu_seq_fops;
pde->owner = THIS_MODULE;
return 0;

out_stat_nf_conntrack:
Expand Down

0 comments on commit 52c0e11

Please sign in to comment.