summaryrefslogtreecommitdiffstats
path: root/testing/ipt-netflow-grsec/0001-Fix-compilation-with-3.10.y-kernel.patch
blob: 99ebffe380c5ca006075c6a7796abb16121732d6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
From b1588f736edbeeb2b3de6081e92dde8840cef66d Mon Sep 17 00:00:00 2001
From: Natanael Copa <ncopa@alpinelinux.org>
Date: Mon, 5 Aug 2013 12:56:19 +0000
Subject: [PATCH] Fix compilation with 3.10.y kernel

use proc_create instead of create_proc_entry
---
 ipt_NETFLOW.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ipt_NETFLOW.c b/ipt_NETFLOW.c
index 4e1b9f3..758bccc 100644
--- a/ipt_NETFLOW.c
+++ b/ipt_NETFLOW.c
@@ -1432,12 +1432,12 @@ static int __init ipt_netflow_init(void)
 	}
 
 #ifdef CONFIG_PROC_FS
-	proc_stat = create_proc_entry("ipt_netflow", S_IRUGO, INIT_NET(proc_net_stat));
+	proc_stat = proc_create("ipt_netflow", S_IRUGO, INIT_NET(proc_net_stat),
+				&nf_seq_fops);
 	if (!proc_stat) {
 		printk(KERN_ERR "Unable to create /proc/net/stat/ipt_netflow entry\n");
 		goto err_free_netflow_slab;
 	}
-	proc_stat->proc_fops = &nf_seq_fops;
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30)
 	proc_stat->owner = THIS_MODULE;
 #endif
-- 
1.8.3.4