[libvirt] [PATCH python] Fix use of virDomainEventRegister in python bindings
Eric Blake
eblake at redhat.com
Tue Dec 3 16:32:59 UTC 2013
On 12/03/2013 08:59 AM, Daniel P. Berrange wrote:
> From: "Daniel P. Berrange" <berrange at redhat.com>
>
> If an app used the virDomainEventRegister binding instead
> of the virDomainEventRegisterAny binding, it would never
> have its callback invoked. This is because the code for
> dispatching from the C libvirt_virConnectDomainEventCallback
> method was totally fubar.
>
> If DEBUG macro was set in the python build the error would
> become visible
>
> "libvirt_virConnectDomainEventCallback dom_class is not a class!"
>
> The code in libvirt_virConnectDomainEventCallback was
> inexplicably complex and has apparently never worked. The
> fix is to write it the same way as the other callback handlers.
>
> Signed-off-by: Daniel P. Berrange <berrange at redhat.com>
> ---
> libvirt-override-virConnect.py | 2 +-
> libvirt-override.c | 64 ++++--------------------------------------
> 2 files changed, 6 insertions(+), 60 deletions(-)
ACK. Wow - that was a LOT of cruft.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 621 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20131203/cc294ecc/attachment-0001.sig>
More information about the libvir-list
mailing list