forked from pool/libvirt
Build phyp driver, fate#307096
OBS-URL: https://build.opensuse.org/package/show/Virtualization/libvirt?expand=0&rev=14
This commit is contained in:
parent
4c875c0a43
commit
82df7d10ec
@ -1,3 +1,11 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Oct 12 22:39:42 MDT 2009 - jfehlig@novell.com
|
||||||
|
|
||||||
|
- Build phyp driver ifarch ppc64
|
||||||
|
fate#307096
|
||||||
|
- Fix memory leaks in libvirtd's message processing
|
||||||
|
msg-proc-memleak.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Sep 29 08:34:28 MDT 2009 - jfehlig@novell.com
|
Tue Sep 29 08:34:28 MDT 2009 - jfehlig@novell.com
|
||||||
|
|
||||||
|
10
libvirt.spec
10
libvirt.spec
@ -20,6 +20,7 @@
|
|||||||
%define with_xen 1
|
%define with_xen 1
|
||||||
%define with_lxc 0
|
%define with_lxc 0
|
||||||
%define with_selinux 0
|
%define with_selinux 0
|
||||||
|
%define with_phyp 0
|
||||||
# Xen is available only on i386 x86_64
|
# Xen is available only on i386 x86_64
|
||||||
%ifnarch %ix86 x86_64
|
%ifnarch %ix86 x86_64
|
||||||
%define with_xen 0
|
%define with_xen 0
|
||||||
@ -28,6 +29,10 @@
|
|||||||
%define with_lxc 1
|
%define with_lxc 1
|
||||||
%define with_selinux 1
|
%define with_selinux 1
|
||||||
%endif
|
%endif
|
||||||
|
# Build phyp backend for IBM Power systems
|
||||||
|
%ifarch ppc64
|
||||||
|
%define with_phyp 1
|
||||||
|
%endif
|
||||||
|
|
||||||
Name: libvirt
|
Name: libvirt
|
||||||
BuildRequires: bridge-utils cyrus-sasl-devel device-mapper-devel fdupes gettext gnutls-devel hal-devel iptables-devel libxml2-devel lvm2 ncurses-devel parted-devel pkg-config python-devel readline-devel util-linux xhtml-dtd
|
BuildRequires: bridge-utils cyrus-sasl-devel device-mapper-devel fdupes gettext gnutls-devel hal-devel iptables-devel libxml2-devel lvm2 ncurses-devel parted-devel pkg-config python-devel readline-devel util-linux xhtml-dtd
|
||||||
@ -50,6 +55,9 @@ BuildRequires: polkit >= 0.9
|
|||||||
%else
|
%else
|
||||||
BuildRequires: PolicyKit-devel >= 0.6
|
BuildRequires: PolicyKit-devel >= 0.6
|
||||||
%endif
|
%endif
|
||||||
|
%if %{with_phyp}
|
||||||
|
BuildRequires: libssh2-devel
|
||||||
|
%endif
|
||||||
# Only for directory ownership:
|
# Only for directory ownership:
|
||||||
BuildRequires: gtk-doc
|
BuildRequires: gtk-doc
|
||||||
Url: http://libvirt.org/
|
Url: http://libvirt.org/
|
||||||
@ -86,6 +94,7 @@ Source1: libvirtd.init
|
|||||||
Patch0: devmap-no-pkgconfig.patch
|
Patch0: devmap-no-pkgconfig.patch
|
||||||
Patch1: xen-refcnt.patch
|
Patch1: xen-refcnt.patch
|
||||||
Patch2: vshdeinit-recurse.patch
|
Patch2: vshdeinit-recurse.patch
|
||||||
|
Patch3: msg-proc-memleak.patch
|
||||||
# Need to go upstream
|
# Need to go upstream
|
||||||
Patch100: socat.patch
|
Patch100: socat.patch
|
||||||
Patch101: clone.patch
|
Patch101: clone.patch
|
||||||
@ -190,6 +199,7 @@ Authors:
|
|||||||
%patch0 -p1
|
%patch0 -p1
|
||||||
%patch1 -p1
|
%patch1 -p1
|
||||||
%patch2 -p1
|
%patch2 -p1
|
||||||
|
%patch3 -p1
|
||||||
%patch100 -p1
|
%patch100 -p1
|
||||||
%patch101
|
%patch101
|
||||||
%patch102 -p1
|
%patch102 -p1
|
||||||
|
48
msg-proc-memleak.patch
Normal file
48
msg-proc-memleak.patch
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
Index: libvirt-0.7.1/qemud/dispatch.c
|
||||||
|
===================================================================
|
||||||
|
--- libvirt-0.7.1.orig/qemud/dispatch.c
|
||||||
|
+++ libvirt-0.7.1/qemud/dispatch.c
|
||||||
|
@@ -191,6 +191,7 @@ remoteSerializeError(struct qemud_client
|
||||||
|
|
||||||
|
xdr_error:
|
||||||
|
xdr_destroy(&xdr);
|
||||||
|
+ VIR_FREE(msg);
|
||||||
|
fatal_error:
|
||||||
|
xdr_free((xdrproc_t)xdr_remote_error, (char *)rerr);
|
||||||
|
return -1;
|
||||||
|
@@ -336,6 +337,7 @@ remoteDispatchClientRequest (struct qemu
|
||||||
|
struct qemud_client *client,
|
||||||
|
struct qemud_client_message *msg)
|
||||||
|
{
|
||||||
|
+ int ret;
|
||||||
|
remote_error rerr;
|
||||||
|
|
||||||
|
memset(&rerr, 0, sizeof rerr);
|
||||||
|
@@ -364,7 +366,12 @@ remoteDispatchClientRequest (struct qemu
|
||||||
|
}
|
||||||
|
|
||||||
|
error:
|
||||||
|
- return remoteSerializeReplyError(client, &rerr, &msg->hdr);
|
||||||
|
+ ret = remoteSerializeReplyError(client, &rerr, &msg->hdr);
|
||||||
|
+
|
||||||
|
+ if (ret >= 0)
|
||||||
|
+ VIR_FREE(msg);
|
||||||
|
+
|
||||||
|
+ return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@@ -521,8 +528,12 @@ remoteDispatchClientCall (struct qemud_s
|
||||||
|
rpc_error:
|
||||||
|
/* Semi-bad stuff happened, we can still try to send back
|
||||||
|
* an RPC error message to client */
|
||||||
|
- return remoteSerializeReplyError(client, &rerr, &msg->hdr);
|
||||||
|
+ rv = remoteSerializeReplyError(client, &rerr, &msg->hdr);
|
||||||
|
+
|
||||||
|
+ if (rv >= 0)
|
||||||
|
+ VIR_FREE(msg);
|
||||||
|
|
||||||
|
+ return rv;
|
||||||
|
|
||||||
|
xdr_error:
|
||||||
|
/* Seriously bad stuff happened, so we'll kill off this client
|
Loading…
Reference in New Issue
Block a user