[libvirt] [PATCH 09/11] Inhibit desktop shutdown while any virtual machines are running
Eric Blake
eblake at redhat.com
Thu Nov 1 12:46:28 UTC 2012
On 11/01/2012 05:47 AM, Alexander Larsson wrote:
>> @@ -1065,6 +1173,8 @@ void virNetServerDispose(void *obj)
>> virNetServerPtr srv = obj;
>> int i;
>>
>> + VIR_FORCE_CLOSE(srv->autoShutdownInhibitFd);
>> +
>
> Don't these have to check if autoShutdownInhibitFd != -1 before closing?
VIR_FORCE_CLOSE() does the checking on your behalf. It's entirely safe
to pass -1 to our close wrapper.
--
Eric Blake eblake at 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: 617 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20121101/8623bfa0/attachment-0001.sig>
More information about the libvir-list
mailing list