[libvirt] [PATCH] virsh: fix mingw failure on creating nonblocking pipe

Eric Blake eblake at redhat.com
Fri Apr 1 14:54:55 UTC 2011


On 04/01/2011 03:44 AM, Daniel P. Berrange wrote:
> On Thu, Mar 31, 2011 at 04:12:09PM -0600, Eric Blake wrote:
>> On 03/31/2011 04:03 PM, Eric Blake wrote:
>>> * .gnulib: Update to latest, for nonblocking module.
>>> * bootstrap.conf (gnulib_modules): Add nonblocking.
>>> * src/util/util.c (virSetBlocking): Defer to gnulib.
>>> ---
>>>
>>> Matthias, does this work for you on your mingw build?  So far,
>>> I have only tested that it cross-compiles, and that the new
>>> gnulib module passes its self-test when run in isolation on mingw.
>>>
>>>  int virSetBlocking(int fd, bool blocking) {
>>
>>> -    if (blocking)
>>> -        flags &= ~O_NONBLOCK;
>>
>>> +    return set_nonblocking_flag (fd, blocking);
>>
>> Oops - that _can't_ work.  s/blocking/!blocking/ in that return statement.
> 
> ACK with that fix :-)

I ran a sanity check that the corrected version could still start and
stop qemu guests on Linux, then pushed the corrected version.

For the record, the gnulib patches include:

* .gnulib 790645d...dec3475 (5):
  > nonblocking: fix mingw test failures
  > Fix bug with gl_WARN_ON_USE_PREPARE, introduced on 2011-01-23.
  > nonblocking: Tweak comment.
  > nonblocking: new module
  > Fix recent ChangeLog entries.

-- 
Eric Blake   eblake at redhat.com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 619 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20110401/f3653db1/attachment-0001.sig>


More information about the libvir-list mailing list