From a239728ec064666025de2723997d87b176d57fd6 Mon Sep 17 00:00:00 2001 From: Maciej Zenczykowski Date: Mon, 4 Apr 2011 15:30:32 +0200 Subject: mark newly opened fds as FD_CLOEXEC (close on exec) (This is iptables-1.4.3.1-cloexec.patch from RedHat iptables.src.rpm) Signed-off-by: Maciej Zenczykowski Signed-off-by: Patrick McHardy --- ip6tables-save.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ip6tables-save.c') diff --git a/ip6tables-save.c b/ip6tables-save.c index dc189e99..c3b8ec0d 100644 --- a/ip6tables-save.c +++ b/ip6tables-save.c @@ -41,7 +41,7 @@ static int for_each_table(int (*func)(const char *tablename)) FILE *procfile = NULL; char tablename[IP6T_TABLE_MAXNAMELEN+1]; - procfile = fopen("/proc/net/ip6_tables_names", "r"); + procfile = fopen("/proc/net/ip6_tables_names", "re"); if (!procfile) return ret; -- cgit v1.2.3