OpenVZ Forum


Home » Mailing lists » Devel » [NETNS45][PATCH 1/1] Fix network namespace unshare support.
[NETNS45][PATCH 1/1] Fix network namespace unshare support. [message #20289] Fri, 14 September 2007 16:26 Go to previous message
Benjamin Thery is currently offline  Benjamin Thery
Messages: 79
Registered: March 2007
Member
Add CLONE_NEWNET flag in sys_unshare() test.

This patch should be merged with commit: 
"net: Add network namespace clone & unshare support."

Signed-off-by: Benjamin Thery <benjamin.thery@bull.net>
---
 kernel/fork.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Index: linux-2.6-netns/kernel/fork.c
===================================================================
--- linux-2.6-netns.orig/kernel/fork.c
+++ linux-2.6-netns/kernel/fork.c
@@ -1608,7 +1608,8 @@ asmlinkage long sys_unshare(unsigned lon
 	err = -EINVAL;
 	if (unshare_flags & ~(CLONE_THREAD|CLONE_FS|CLONE_NEWNS|CLONE_SIGHAND|
 				CLONE_VM|CLONE_FILES|CLONE_SYSVSEM|
-				CLONE_NEWUTS|CLONE_NEWIPC|CLONE_NEWUSER))
+				CLONE_NEWUTS|CLONE_NEWIPC|CLONE_NEWUSER|
+				CLONE_NEWNET))
 		goto bad_unshare_out;
 
 	if ((err = unshare_thread(unshare_flags)))

-- 
_______________________________________________
Containers mailing list
Containers@lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers
 
Read Message
Read Message
Previous Topic: [PATCH][NETNS] Use list_for_each_entry_continue_reverse in setup_net
Next Topic: [RFC][PATCH 0/3] Kernel memory accounting container (v2)
Goto Forum:
  


Current Time: Fri Aug 22 02:08:53 GMT 2025

Total time taken to generate the page: 0.05722 seconds