diff options
author | 2012-02-08 17:33:22 +0800 | |
---|---|---|
committer | 2012-02-09 12:07:26 +0800 | |
commit | 4165d68aaabbf262fe4050ddcf1b68bff5a6b0c8 (patch) | |
tree | 3abce6c23710319cd0b7747219735f40f5cacc36 | |
parent | qemu: fix persistent setting of blkiodevice weights (diff) | |
download | libvirt-4165d68aaabbf262fe4050ddcf1b68bff5a6b0c8.tar.gz libvirt-4165d68aaabbf262fe4050ddcf1b68bff5a6b0c8.tar.bz2 libvirt-4165d68aaabbf262fe4050ddcf1b68bff5a6b0c8.zip |
python: Correct arguments number for migrateSetMaxSpeed
The API definition accepts "flags" argument, however, the
implementation ignores it, though "flags" is unused currently,
we should expose it instead of hard coding, the API
implementation inside hypervisor driver is responsible to check
if the passed "flags" is valid.
-rw-r--r-- | python/libvirt-override.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/python/libvirt-override.c b/python/libvirt-override.c index 33a841de1..2c6e7cfbe 100644 --- a/python/libvirt-override.c +++ b/python/libvirt-override.c @@ -5062,14 +5062,16 @@ libvirt_virDomainMigrateGetMaxSpeed(PyObject *self ATTRIBUTE_UNUSED, PyObject *a unsigned long bandwidth; virDomainPtr domain; PyObject *pyobj_domain; + unsigned int flags = 0; - if (!PyArg_ParseTuple(args, (char *)"O:virDomainMigrateGetMaxSpeed", &pyobj_domain)) + if (!PyArg_ParseTuple(args, (char *)"Oi:virDomainMigrateGetMaxSpeed", + &pyobj_domain, &flags)) return(NULL); domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain); LIBVIRT_BEGIN_ALLOW_THREADS; - c_retval = virDomainMigrateGetMaxSpeed(domain, &bandwidth, 0); + c_retval = virDomainMigrateGetMaxSpeed(domain, &bandwidth, flags); LIBVIRT_END_ALLOW_THREADS; if (c_retval < 0) |