[libvirt] [PATCH v4 4/7] Add network events to the remote driver

Eric Blake eblake at redhat.com
Fri Jan 10 02:50:19 UTC 2014


On 12/12/2013 07:30 AM, Cedric Bosdonnat wrote:
> Hi John,
> 

>>> +    event = virNetworkEventLifecycleNew(net->name, net->uuid, msg->event);
>>> +    virNetworkFree(net);
>>> +    remoteDomainEventQueue(priv, event);

>> Essentially - you need to check for NULL event.
> 
> Sure, but the weird thing it that it should also complain on the similar
> functions for domain events, right above this one in the same file.

Revisiting this.  The problem can only happen on OOM situations, so it's
not that likely to hit in real life; but we should indeed fix our code.
 I think the easiest way is to fix remoteDomainEventQueue to gracefully
do nothing on a NULL event (events are best effort, and if OOM occurs,
skipping event delivery is an acceptable action, since we have no way of
reporting the error).  I'll post a patch.

-- 
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: 604 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20140109/26307388/attachment-0001.sig>


More information about the libvir-list mailing list