lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1310755099-32438-1-git-send-email-dan@archlinux.org>
Date:	Fri, 15 Jul 2011 13:38:19 -0500
From:	Dan McGee <dan@...hlinux.org>
To:	netdev@...r.kernel.org
Cc:	Dan McGee <dan@...hlinux.org>,
	"Eric W. Biederman" <ebiederm@...ssion.com>
Subject: [PATCH] Rename static setns() function

Fixes the following error:

    gcc -D_GNU_SOURCE -O2 -Wstrict-prototypes -Wall -I../include
    -DRESOLVE_HOSTNAMES -DLIBDIR=\"/usr/lib/\"   -c -o ipnetns.o ipnetns.c
    ipnetns.c:31:12: error: static declaration of ‘setns’ follows non-static
    declaration
    /usr/include/bits/sched.h:93:12: note: previous declaration of ‘setns’
    was here
    make[1]: *** [ipnetns.o] Error 1

Fixes issue introduced in commit 0dc34c7713bb7055.

Signed-off-by: Dan McGee <dan@...hlinux.org>
---
 ip/ipnetns.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/ip/ipnetns.c b/ip/ipnetns.c
index db7007c..46230ad 100644
--- a/ip/ipnetns.c
+++ b/ip/ipnetns.c
@@ -28,7 +28,7 @@
 #define MNT_DETACH	0x00000002	/* Just detach from the tree */
 #endif /* MNT_DETACH */
 
-static int setns(int fd, int nstype)
+static int do_setns(int fd, int nstype)
 {
 #ifdef __NR_setns
 	return syscall(__NR_setns, fd, nstype);
@@ -150,7 +150,7 @@ static int netns_exec(int argc, char **argv)
 			strerror(errno));
 		return -1;
 	}
-	if (setns(netns, CLONE_NEWNET) < 0) {
+	if (do_setns(netns, CLONE_NEWNET) < 0) {
 		fprintf(stderr, "seting the network namespace failed: %s\n",
 			strerror(errno));
 		return -1;
-- 
1.7.6

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ