From 3abbed1a7393b4e59152bda1b37f67b8c440f5b6 Mon Sep 17 00:00:00 2001 Message-Id: <3abbed1a7393b4e59152bda1b37f67b8c440f5b6.1378475168.git.jdenemar@redhat.com> From: Guan Qiang Date: Wed, 4 Sep 2013 13:09:49 -0600 Subject: [PATCH] python: Fix a PyList usage mistake 7.0: https://bugzilla.redhat.com/show_bug.cgi?id=1002558 Fix PyList usage mistake in Function libvirt_lxc_virDomainLxcOpenNamespace. https://bugzilla.redhat.com/show_bug.cgi?id=1002383 Signed-off-by: Eric Blake (cherry picked from commit c26181495f3c98870d0794052246718f5d3d8dd6) --- python/libvirt-lxc-override.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/libvirt-lxc-override.c b/python/libvirt-lxc-override.c index 03bf2df..f76ff4b 100644 --- a/python/libvirt-lxc-override.c +++ b/python/libvirt-lxc-override.c @@ -80,7 +80,7 @@ libvirt_lxc_virDomainLxcOpenNamespace(PyObject *self ATTRIBUTE_UNUSED, if (c_retval < 0) return VIR_PY_NONE; - py_retval = PyList_New(c_retval); + py_retval = PyList_New(0); for (i = 0; i < c_retval; i++) { PyObject *item = NULL; -- 1.8.3.2