[libvirt] [PATCH] build: fix building with '--enable-test-locking'
Eric Blake
eblake at redhat.com
Wed Dec 18 13:34:43 UTC 2013
On 12/18/2013 06:25 AM, Martin Kletzander wrote:
>>> pipefd[bool] fail (obviously). Forcing the subscript to be bool by
>>> double negation fixes the build breaker.
>>
>> I don't get how this could possibly make a difference. The 'output'
>> variable is declared bool, and then only ever assigned 'false' or
>> 'true', which if bool is replaced by gnulib are still guaranteed to be 0
>> and 1, so using it directly as an array index is still safe.
>>
>
> But the thing is that due to -Dbool=char the variable is declared
> char, not bool.
But if the variable contains exactly 0 or 1, it still makes no
difference as an array index whether it was typed bool or char.
--
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/20131218/1ff59ca7/attachment-0001.sig>
More information about the libvir-list
mailing list