Bug#532813: openvz fix netns crash of ss test
Package: linux-2.6
Version: 2.6.26-16
Severity: important
oops fixed in belows upstream commit
>From b1f08edfb39da75799222c2b76acae30e833067d Mon Sep 17 00:00:00 2001
From: Pavel Emelyanov <xemul@openvz.org>
Date: Wed, 22 Apr 2009 19:05:03 +0400
Subject: [PATCH 85/86] net: avoid double free on net->gen pointer on error
If we failed with netns creation net->gen will be kfree-ed twice.
http://bugzilla.openvz.org/show_bug.cgi?id=1241
Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
---
net/core/net_namespace.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/net/core/net_namespace.c b/net/core/net_namespace.c
index 523eba0..64b0a40 100644
--- a/net/core/net_namespace.c
+++ b/net/core/net_namespace.c
@@ -75,6 +75,7 @@ out_undo:
}
rcu_barrier();
+ net->gen = NULL;
kfree(ng);
goto out;
}
--
1.6.3.1
-- System Information:
Debian Release: squeeze/sid
APT prefers testing
APT policy: (900, 'testing'), (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.30-rc8-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Reply to: