Hello community, here is the log from the commit of package libvirt-python for openSUSE:Factory checked in at 2015-04-12 00:10:02 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/libvirt-python (Old) and /work/SRC/openSUSE:Factory/.libvirt-python.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "libvirt-python" Changes: -------- --- /work/SRC/openSUSE:Factory/libvirt-python/libvirt-python.changes 2015-03-11 09:58:35.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.libvirt-python.new/libvirt-python.changes 2015-04-12 00:10:05.000000000 +0200 @@ -1,0 +2,6 @@ +Thu Apr 2 14:10:37 MDT 2015 - jfeh...@suse.com + +- Update to 1.2.14 + - Add all new APIs and constants in libvirt 1.2.14 + +------------------------------------------------------------------- Old: ---- libvirt-python-1.2.13.tar.gz libvirt-python-1.2.13.tar.gz.asc New: ---- libvirt-python-1.2.14.tar.gz libvirt-python-1.2.14.tar.gz.asc ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ libvirt-python.spec ++++++ --- /var/tmp/diff_new_pack.xhAAjd/_old 2015-04-12 00:10:05.000000000 +0200 +++ /var/tmp/diff_new_pack.xhAAjd/_new 2015-04-12 00:10:05.000000000 +0200 @@ -18,7 +18,7 @@ Name: libvirt-python Url: http://libvirt.org/ -Version: 1.2.13 +Version: 1.2.14 Release: 0 Summary: Library providing a simple virtualization API License: LGPL-2.1+ ++++++ libvirt-python-1.2.13.tar.gz -> libvirt-python-1.2.14.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/AUTHORS new/libvirt-python-1.2.14/AUTHORS --- old/libvirt-python-1.2.13/AUTHORS 2015-03-02 04:45:23.000000000 +0100 +++ new/libvirt-python-1.2.14/AUTHORS 2015-04-02 09:56:33.000000000 +0200 @@ -435,6 +435,11 @@ Jiri Denemark <jdene...@redhat.com> Jiri Denemark <jiri.denem...@gmail.com> John Ferlan <jfer...@redhat.com> + John Ferlan <jfer...@redhat.com> + John Ferlan <jfer...@redhat.com> + Ján Tomko <jto...@redhat.com> + Ján Tomko <jto...@redhat.com> + Ján Tomko <jto...@redhat.com> Ján Tomko <jto...@redhat.com> KAMEZAWA Hiroyuki <kamezawa.hir...@jp.fujitsu.com> Lai Jiangshan <la...@cn.fujitsu.com> @@ -531,6 +536,8 @@ Pavel Hrdina <phrd...@redhat.com> Pavel Hrdina <phrd...@redhat.com> Pavel Hrdina <phrd...@redhat.com> + Pavel Hrdina <phrd...@redhat.com> + Pavel Hrdina <phrd...@redhat.com> Pavel Hrdina <phrd...@redhat.com> Pavel Hrdina <phrd...@redhat.com> Pavel Hrdina <phrd...@redhat.com> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/ChangeLog new/libvirt-python-1.2.14/ChangeLog --- old/libvirt-python-1.2.13/ChangeLog 2015-03-02 04:45:23.000000000 +0100 +++ new/libvirt-python-1.2.14/ChangeLog 2015-04-02 09:56:33.000000000 +0200 @@ -1,3 +1,97 @@ +2015-03-28 Pavel Hrdina <phrd...@redhat.com> + + Expose virDomainInterfacesAddresses to python binding + examples/Makefile.am: + * Add new file domipaddrs.py + + examples/README: + * Add documentation for the python example + + libvirt-override-api.xml: + * Add new symbol for virDomainInterfacesAddresses + + libvirt-override.c: + * Hand written python api + + Example: + $ python examples/domipaddrs.py qemu:///system f18 + Interface MAC address Protocol Address + vnet0 52:54:00:20:70:3d ipv4 192.168.105.240/16 + + + +2015-03-26 Ján Tomko <jto...@redhat.com> + + Rename virDomainGetIOThreadsInfo to virDomainGetIOThreadInfo + + +2015-03-26 Ján Tomko <jto...@redhat.com> + + Rename virDomainIOThreadsInfoFree to virDomainIOThreadInfoFree + + +2015-03-19 Pavel Hrdina <phrd...@redhat.com> + + Post-release version bump to 1.2.14 + + +2015-03-11 John Ferlan <jfer...@redhat.com> + + Support virDomainPinIOThread + Support the libvirt_virDomainSetIOThreads method using code that mimics + the existing libvirt_virDomainPinVcpuFlags method + + The following is a sample session assuming guest 'iothr-gst' has IOThreads + configured (it's currently running, too) + + >>> import libvirt + >>> con=libvirt.open("qemu:///system") + >>> dom=con.lookupByName('iothr-gst') + >>> dom.ioThreadsInfo() + [(1, [False, False, True, False]), (2, [False, False, False, True]), (3, [True, True, True, True])] + >>> cpumap=(True,True,True,False) + >>> dom.pinIOThread(3,cpumap) + 0 + >>> print dom.ioThreadsInfo() + [(1, [False, False, True, False]), (2, [False, False, False, True]), (3, [True, True, True, False])] + >>> + + merge + + +2015-03-11 John Ferlan <jfer...@redhat.com> + + Support virDomainGetIOThreadsInfo and virDomainIOThreadsInfoFree + Add support for the libvirt_virDomainGetIOThreadsInfo method. This + code mostly follows the libvirt_virDomainGetVcpuPinInfo method, but + also takes some from the libvirt_virNodeGetCPUMap method with respect + to building the cpumap into the returned tuple rather than two separate + tuples which vcpu pinning generates + + Assuming two domains, one with IOThreads defined (eg, 'iothr-gst') and + one without ('noiothr-gst'), execute the following in an 'iothr.py' file: + + import libvirt + con=libvirt.open("qemu:///system") + dom=con.lookupByName('iothr-gst') + print dom.ioThreadsInfo() + dom2=con.lookupByName('noiothr-gst') + print dom2.ioThreadsInfo() + + $ python iothr.py + [(1, [False, False, True, False]), (2, [False, False, False, True]), (3, [True, True, True, True])] + [] + $ + + +2015-03-05 Ján Tomko <jto...@redhat.com> + + Clarify description for virNodeGetSecurityModel + s/host/hypervisor/ to match the wording used by the C binding. + + https://bugzilla.redhat.com/show_bug.cgi?id=1198518 + + 2015-01-27 Daniel P. Berrange <berra...@redhat.com> Post-release version bump to 1.2.13 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/PKG-INFO new/libvirt-python-1.2.14/PKG-INFO --- old/libvirt-python-1.2.13/PKG-INFO 2015-03-02 04:45:24.000000000 +0100 +++ new/libvirt-python-1.2.14/PKG-INFO 2015-04-02 09:56:33.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 1.0 Name: libvirt-python -Version: 1.2.13 +Version: 1.2.14 Summary: The libvirt virtualization API Home-page: http://www.libvirt.org Author: Libvirt Maintainers diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/examples/domipaddrs.py new/libvirt-python-1.2.14/examples/domipaddrs.py --- old/libvirt-python-1.2.13/examples/domipaddrs.py 1970-01-01 01:00:00.000000000 +0100 +++ new/libvirt-python-1.2.14/examples/domipaddrs.py 2015-04-02 09:37:06.000000000 +0200 @@ -0,0 +1,57 @@ +#!/usr/bin/env python +# domipaddrs - print domain interfaces along with their MAC and IP addresses + +import libvirt +import sys + +def usage(): + print "Usage: %s [URI] DOMAIN" % sys.argv[0] + print " Print domain interfaces along with their MAC and IP addresses" + +uri = None +name = None +args = len(sys.argv) + +if args == 2: + name = sys.argv[1] +elif args == 3: + uri = sys.argv[1] + name = sys.argv[2] +else: + usage() + sys.exit(2) + +conn = libvirt.open(uri) +if conn == None: + print "Unable to open connection to libvirt" + sys.exit(1) + +try: + dom = conn.lookupByName(name) +except libvirt.libvirtError: + print "Domain %s not found" % name + sys.exit(0) + +ifaces = dom.interfaceAddresses(libvirt.VIR_DOMAIN_INTERFACE_ADDRESSES_SRC_LEASE); +if (ifaces == None): + print "Failed to get domain interfaces" + sys.exit(0) + +print " {0:10} {1:20} {2:12} {3}".format("Interface", "MAC address", "Protocol", "Address") + +def toIPAddrType(addrType): + if addrType == libvirt.VIR_IP_ADDR_TYPE_IPV4: + return "ipv4" + elif addrType == libvirt.VIR_IP_ADDR_TYPE_IPV6: + return "ipv6" + +for (name, val) in ifaces.iteritems(): + if val['addrs']: + for addr in val['addrs']: + print " {0:10} {1:19}".format(name, val['hwaddr']), + print " {0:12} {1}/{2} ".format(toIPAddrType(addr['type']), addr['addr'], addr['prefix']), + print + else: + print " {0:10} {1:19}".format(name, val['hwaddr']), + print " {0:12} {1}".format("N/A", "N/A"), + print diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/generator.py new/libvirt-python-1.2.14/generator.py --- old/libvirt-python-1.2.13/generator.py 2015-01-21 08:24:08.000000000 +0100 +++ new/libvirt-python-1.2.14/generator.py 2015-04-02 09:37:06.000000000 +0200 @@ -435,6 +435,8 @@ 'virDomainGetVcpuPinInfo', 'virDomainGetEmulatorPinInfo', 'virDomainPinEmulator', + 'virDomainGetIOThreadInfo', + 'virDomainPinIOThread', 'virSecretGetValue', 'virSecretSetValue', 'virSecretGetUUID', @@ -481,6 +483,7 @@ 'virDomainBlockCopy', 'virNodeAllocPages', 'virDomainGetFSInfo', + 'virDomainInterfaceAddresses', ) lxc_skip_impl = ( @@ -592,6 +595,8 @@ 'virNetworkDHCPLeaseFree', # only useful in C, python code uses list 'virDomainStatsRecordListFree', # only useful in C, python uses dict 'virDomainFSInfoFree', # only useful in C, python code uses list + 'virDomainIOThreadInfoFree', # only useful in C, python code uses list + 'virDomainInterfaceFree', # only useful in C, python code uses list ) lxc_skip_function = ( @@ -1144,6 +1149,9 @@ elif name[0:20] == "virDomainGetCPUStats": func = name[9:] func = func[0:1].lower() + func[1:] + elif name[0:24] == "virDomainGetIOThreadInfo": + func = name[12:] + func = func[0:2].lower() + func[2:] elif name[0:18] == "virDomainGetFSInfo": func = name[12:] func = func[0:2].lower() + func[2:] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/libvirt-override-api.xml new/libvirt-python-1.2.14/libvirt-override-api.xml --- old/libvirt-python-1.2.13/libvirt-override-api.xml 2014-12-13 03:42:57.000000000 +0100 +++ new/libvirt-python-1.2.14/libvirt-override-api.xml 2015-04-02 09:37:06.000000000 +0200 @@ -105,7 +105,7 @@ <arg name='conn' type='virConnectPtr' info='pointer to the hypervisor connection'/> </function> <function name='virNodeGetSecurityModel' file='python'> - <info>Extract information about the host security model</info> + <info>Extract information about the hypervisor security model</info> <return type='char *' info='the list of information or None in case of error'/> <arg name='conn' type='virConnectPtr' info='pointer to the hypervisor connection'/> </function> @@ -278,6 +278,20 @@ <arg name='cpumap' type='unsigned char *' info='pointer to a bit map of real CPUs (in 8-bit bytes) (IN) Each bit set to 1 means that corresponding CPU is usable. Bytes are stored in little-endian order: CPU0-7, 8-15... In each byte, lowest CPU number is least significant bit.'/> <arg name='flags' type='int' info='flags to specify'/> </function> + <function name='virDomainGetIOThreadInfo' file='python'> + <info>Query the CPU affinity setting of the IOThreads of the domain</info> + <arg name='domain' type='virDomainPtr' info='pointer to domain object, or NULL for Domain0'/> + <arg name='flags' type='int' info='an OR'ed set of virDomainModificationImpact'/> + <return type='char *' info="list of IOThreads information including the iothread_id, the cpumap, and the cpumap length for each iothread_id."/> + </function> + <function name='virDomainPinIOThread' file='python'> + <info>Dynamically change the real CPUs which can be allocated to an IOThread. This function requires privileged access to the hypervisor.</info> + <return type='int' info='0 in case of success, -1 in case of failure.'/> + <arg name='domain' type='virDomainPtr' info='pointer to domain object'/> + <arg name='iothread_val' type='unsigned int' info='iothread_id number'/> + <arg name='cpumap' type='unsigned char *' info='pointer to a bit map of real CPUs (in 8-bit bytes) (IN) Each bit set to 1 means that corresponding CPU is usable. Bytes are stored in little-endian order: CPU0-7, 8-15... In each byte, lowest CPU number is least significant bit.'/> + <arg name='flags' type='int' info='an OR'ed set of virDomainModificationImpact'/> + </function> <function name='virDomainSetSchedulerParameters' file='python'> <info>Change the scheduler parameters</info> <return type='int' info='-1 in case of error, 0 in case of success.'/> @@ -664,5 +678,12 @@ <arg name='flags' type='unsigned int' info='unused, pass 0'/> <return type='char *' info="list of mounted filesystems information"/> </function> + <function name='virDomainInterfaceAddresses' file='python'> + <info>returns a dictionary of domain interfaces along with their MAC and IP addresses</info> + <arg name='dom' type='virDomainPtr' info='pointer to the domain'/> + <arg name='source' type='unsigned int' info='the data source'/> + <arg name='flags' type='unsigned int' info='extra flags; not used yet, so callers should always pass 0'/> + <return type='char *' info="dictionary of domain interfaces along with their MAC and IP addresses"/> + </function> </symbols> </api> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/libvirt-override.c new/libvirt-python-1.2.14/libvirt-override.c --- old/libvirt-python-1.2.13/libvirt-override.c 2015-01-21 08:24:08.000000000 +0100 +++ new/libvirt-python-1.2.14/libvirt-override.c 2015-04-02 09:37:06.000000000 +0200 @@ -1990,6 +1990,162 @@ } #endif /* LIBVIR_CHECK_VERSION(0, 10, 0) */ +#if LIBVIR_CHECK_VERSION(1, 2, 14) +static PyObject * +libvirt_virDomainGetIOThreadInfo(PyObject *self ATTRIBUTE_UNUSED, + PyObject *args) +{ + virDomainPtr domain; + PyObject *pyobj_domain; + PyObject *py_retval = NULL; + PyObject *py_iothrinfo = NULL; + virDomainIOThreadInfoPtr *iothrinfo = NULL; + unsigned int flags; + size_t pcpu, i; + int niothreads, cpunum; + + if (!PyArg_ParseTuple(args, (char *)"OI:virDomainGetIOThreadInfo", + &pyobj_domain, &flags)) + return NULL; + domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain); + + if ((cpunum = getPyNodeCPUCount(virDomainGetConnect(domain))) < 0) + return VIR_PY_NONE; + + LIBVIRT_BEGIN_ALLOW_THREADS; + niothreads = virDomainGetIOThreadInfo(domain, &iothrinfo, flags); + LIBVIRT_END_ALLOW_THREADS; + + if (niothreads < 0) { + py_retval = VIR_PY_NONE; + goto cleanup; + } + + /* convert to a Python list */ + if ((py_iothrinfo = PyList_New(niothreads)) == NULL) + goto cleanup; + + /* NOTE: If there are zero IOThreads we will return an empty list */ + for (i = 0; i < niothreads; i++) { + PyObject *iothrtpl = NULL; + PyObject *iothrid = NULL; + PyObject *iothrmap = NULL; + virDomainIOThreadInfoPtr iothr = iothrinfo[i]; + + if (iothr == NULL) { + py_retval = VIR_PY_NONE; + goto cleanup; + } + + if ((iothrtpl = PyTuple_New(2)) == NULL || + PyList_SetItem(py_iothrinfo, i, iothrtpl) < 0) { + Py_XDECREF(iothrtpl); + goto cleanup; + } + + /* 0: IOThread ID */ + if ((iothrid = libvirt_uintWrap(iothr->iothread_id)) == NULL || + PyTuple_SetItem(iothrtpl, 0, iothrid) < 0) { + Py_XDECREF(iothrid); + goto cleanup; + } + + /* 1: CPU map */ + if ((iothrmap = PyList_New(cpunum)) == NULL || + PyTuple_SetItem(iothrtpl, 1, iothrmap) < 0) { + Py_XDECREF(iothrmap); + goto cleanup; + } + for (pcpu = 0; pcpu < cpunum; pcpu++) { + PyObject *pyused; + if ((pyused = PyBool_FromLong(VIR_CPU_USED(iothr->cpumap, + pcpu))) == NULL) { + py_retval = VIR_PY_NONE; + goto cleanup; + } + if (PyList_SetItem(iothrmap, pcpu, pyused) < 0) { + Py_XDECREF(pyused); + goto cleanup; + } + } + } + + py_retval = py_iothrinfo; + py_iothrinfo = NULL; + +cleanup: + for (i = 0; i < niothreads; i++) + virDomainIOThreadInfoFree(iothrinfo[i]); + VIR_FREE(iothrinfo); + Py_XDECREF(py_iothrinfo); + return py_retval; +} + +static PyObject * +libvirt_virDomainPinIOThread(PyObject *self ATTRIBUTE_UNUSED, + PyObject *args) +{ + virDomainPtr domain; + PyObject *pyobj_domain, *pycpumap; + PyObject *ret = NULL; + unsigned char *cpumap; + int cpumaplen, iothread_val, tuple_size, cpunum; + size_t i; + unsigned int flags; + int i_retval; + + if (!PyArg_ParseTuple(args, (char *)"OiOI:virDomainPinIOThread", + &pyobj_domain, &iothread_val, &pycpumap, &flags)) + return NULL; + domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain); + + if ((cpunum = getPyNodeCPUCount(virDomainGetConnect(domain))) < 0) + return VIR_PY_INT_FAIL; + + if (PyTuple_Check(pycpumap)) { + if ((tuple_size = PyTuple_Size(pycpumap)) == -1) + return ret; + } else { + PyErr_SetString(PyExc_TypeError, "Unexpected type, tuple is required"); + return ret; + } + + cpumaplen = VIR_CPU_MAPLEN(cpunum); + if (VIR_ALLOC_N(cpumap, cpumaplen) < 0) + return PyErr_NoMemory(); + + for (i = 0; i < tuple_size; i++) { + PyObject *flag = PyTuple_GetItem(pycpumap, i); + bool b; + + if (!flag || libvirt_boolUnwrap(flag, &b) < 0) + goto cleanup; + + if (b) + VIR_USE_CPU(cpumap, i); + else + VIR_UNUSE_CPU(cpumap, i); + } + + for (; i < cpunum; i++) + VIR_UNUSE_CPU(cpumap, i); + + LIBVIRT_BEGIN_ALLOW_THREADS; + i_retval = virDomainPinIOThread(domain, iothread_val, + cpumap, cpumaplen, flags); + LIBVIRT_END_ALLOW_THREADS; + if (i_retval < 0) { + ret = VIR_PY_INT_FAIL; + goto cleanup; + } + ret = VIR_PY_INT_SUCCESS; + +cleanup: + VIR_FREE(cpumap); + return ret; +} + +#endif /* LIBVIR_CHECK_VERSION(1, 2, 14) */ /************************************************************************ * * @@ -4964,6 +5120,131 @@ return py_retval; } + +#if LIBVIR_CHECK_VERSION(1, 2, 14) +static PyObject * +libvirt_virDomainInterfaceAddresses(PyObject *self ATTRIBUTE_UNUSED, + PyObject *args) +{ + PyObject *py_retval = VIR_PY_NONE; + PyObject *pyobj_domain; + virDomainPtr domain; + virDomainInterfacePtr *ifaces = NULL; + unsigned int source; + unsigned int flags; + int ifaces_count = 0; + size_t i, j; + + if (!PyArg_ParseTuple(args, (char *) "Oii:virDomainInterfaceAddresses", + &pyobj_domain, &source, &flags)) + goto error; + + domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain); + + LIBVIRT_BEGIN_ALLOW_THREADS; + ifaces_count = virDomainInterfaceAddresses(domain, &ifaces, source, flags); + LIBVIRT_END_ALLOW_THREADS; + + if (ifaces_count < 0) + goto cleanup; + + if (!(py_retval = PyDict_New())) + goto error; + + for (i = 0; i < ifaces_count; i++) { + virDomainInterfacePtr iface = ifaces[i]; + PyObject *py_addrs = NULL; + PyObject *py_iface = NULL; + PyObject *py_iname = NULL; + PyObject *py_ivalue = NULL; + + if (!(py_iface = PyDict_New())) + goto error; + + if ((py_iname = libvirt_charPtrWrap(iface->name)) == NULL || + PyDict_SetItem(py_retval, py_iname, py_iface) < 0) { + Py_XDECREF(py_iname); + Py_DECREF(py_iface); + goto error; + } + + if (iface->naddrs) { + if (!(py_addrs = PyList_New(iface->naddrs))) { + goto error; + } + } else { + py_addrs = VIR_PY_NONE; + } + + if ((py_iname = libvirt_constcharPtrWrap("addrs")) == NULL || + PyDict_SetItem(py_iface, py_iname, py_addrs) < 0) { + Py_XDECREF(py_iname); + Py_DECREF(py_addrs); + goto error; + } + + if ((py_iname = libvirt_constcharPtrWrap("hwaddr")) == NULL || + (py_ivalue = libvirt_constcharPtrWrap(iface->hwaddr)) == NULL || + PyDict_SetItem(py_iface, py_iname, py_ivalue) < 0) { + Py_XDECREF(py_iname); + Py_XDECREF(py_ivalue); + goto error; + } + + for (j = 0; j < iface->naddrs; j++) { + virDomainIPAddressPtr addr = &(iface->addrs[j]); + PyObject *py_addr = PyDict_New(); + + if (!py_addr) + goto error; + + if (PyList_SetItem(py_addrs, j, py_addr) < 0) { + Py_DECREF(py_addr); + goto error; + } + + if ((py_iname = libvirt_constcharPtrWrap("addr")) == NULL || + (py_ivalue = libvirt_constcharPtrWrap(addr->addr)) == NULL || + PyDict_SetItem(py_addr, py_iname, py_ivalue) < 0) { + Py_XDECREF(py_iname); + Py_XDECREF(py_ivalue); + goto error; + } + if ((py_iname = libvirt_constcharPtrWrap("prefix")) == NULL || + (py_ivalue = libvirt_intWrap(addr->prefix)) == NULL || + PyDict_SetItem(py_addr, py_iname, py_ivalue) < 0) { + Py_XDECREF(py_iname); + Py_XDECREF(py_ivalue); + goto error; + } + if ((py_iname = libvirt_constcharPtrWrap("type")) == NULL || + (py_ivalue = libvirt_intWrap(addr->type)) == NULL || + PyDict_SetItem(py_addr, py_iname, py_ivalue) < 0) { + Py_XDECREF(py_iname); + Py_XDECREF(py_ivalue); + goto error; + } + } + } + +cleanup: + if (ifaces && ifaces_count > 0) { + for (i = 0; i < ifaces_count; i++) { + virDomainInterfaceFree(ifaces[i]); + } + } + VIR_FREE(ifaces); + + return py_retval; + +error: + Py_XDECREF(py_retval); + py_retval = NULL; + goto cleanup; +} +#endif /* LIBVIR_CHECK_VERSION(1, 2, 14) */ + + /******************************************* * Helper functions to avoid importing modules * for every callback @@ -8483,6 +8764,10 @@ {(char *) "virDomainGetEmulatorPinInfo", libvirt_virDomainGetEmulatorPinInfo, METH_VARARGS, NULL}, {(char *) "virDomainPinEmulator", libvirt_virDomainPinEmulator, METH_VARARGS, NULL}, #endif /* LIBVIR_CHECK_VERSION(0, 10, 0) */ +#if LIBVIR_CHECK_VERSION(1, 2, 14) + {(char *) "virDomainGetIOThreadInfo", libvirt_virDomainGetIOThreadInfo, METH_VARARGS, NULL}, + {(char *) "virDomainPinIOThread", libvirt_virDomainPinIOThread, METH_VARARGS, NULL}, +#endif /* LIBVIR_CHECK_VERSION(1, 2, 14) */ {(char *) "virConnectListStoragePools", libvirt_virConnectListStoragePools, METH_VARARGS, NULL}, {(char *) "virConnectListDefinedStoragePools", libvirt_virConnectListDefinedStoragePools, METH_VARARGS, NULL}, #if LIBVIR_CHECK_VERSION(0, 10, 2) @@ -8590,6 +8875,9 @@ #if LIBVIR_CHECK_VERSION(1, 2, 11) {(char *) "virDomainGetFSInfo", libvirt_virDomainGetFSInfo, METH_VARARGS, NULL}, #endif /* LIBVIR_CHECK_VERSION(1, 2, 11) */ +#if LIBVIR_CHECK_VERSION(1, 2, 14) + {(char *) "virDomainInterfaceAddresses", libvirt_virDomainInterfaceAddresses, METH_VARARGS, NULL}, +#endif /* LIBVIR_CHECK_VERSION(1, 2, 14) */ {NULL, NULL, 0, NULL} }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/libvirt-python.spec new/libvirt-python-1.2.14/libvirt-python.spec --- old/libvirt-python-1.2.13/libvirt-python.spec 2015-03-02 04:45:23.000000000 +0100 +++ new/libvirt-python-1.2.14/libvirt-python.spec 2015-04-02 09:56:33.000000000 +0200 @@ -6,7 +6,7 @@ Summary: The libvirt virtualization API python2 binding Name: libvirt-python -Version: 1.2.13 +Version: 1.2.14 Release: 1%{?dist}%{?extra_release} Source0: http://libvirt.org/sources/python/%{name}-%{version}.tar.gz Url: http://libvirt.org diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/sanitytest.py new/libvirt-python-1.2.14/sanitytest.py --- old/libvirt-python-1.2.13/sanitytest.py 2015-01-21 08:24:08.000000000 +0100 +++ new/libvirt-python-1.2.14/sanitytest.py 2015-04-02 09:37:06.000000000 +0200 @@ -142,6 +142,12 @@ if name[0:19] == "virDomainFSInfoFree": continue + if name[0:25] == "virDomainIOThreadInfoFree": + continue + + if name[0:22] == "virDomainInterfaceFree": + continue + if name[0:21] == "virDomainListGetStats": name = "virConnectDomainListGetStats" @@ -276,6 +282,8 @@ func = "nwfilter" + func[8:] if func[0:8] == "fSFreeze" or func[0:6] == "fSThaw" or func[0:6] == "fSInfo": func = "fs" + func[2:] + if func[0:12] == "iOThreadInfo": + func = "ioThreadInfo" if klass == "virNetwork": func = func.replace("dHCP", "DHCP") diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libvirt-python-1.2.13/setup.py new/libvirt-python-1.2.14/setup.py --- old/libvirt-python-1.2.13/setup.py 2015-03-02 04:44:16.000000000 +0100 +++ new/libvirt-python-1.2.14/setup.py 2015-04-02 09:37:06.000000000 +0200 @@ -309,7 +309,7 @@ _c_modules, _py_modules = get_module_lists() setup(name = 'libvirt-python', - version = '1.2.13', + version = '1.2.14', url = 'http://www.libvirt.org', maintainer = 'Libvirt Maintainers', maintainer_email = 'libvir-l...@redhat.com',