[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH] cpu: Improve error reporting on incompatible CPUs



On 04/19/2012 07:45 AM, Jiri Denemark wrote:

>> +#define virX86CpuIncompatible(MSG, CPU_DEF)                             \
>> +        do {                                                            \

>> +        } while (0);
> 
> I can't think of any case where ";;" would be a problem but I'd remove the ';'
> from the end of this macro anyway

I can:

if (cond)
    virX86CpuIncompatible(msg, def);
else
    do_something_else();

that bogus ';' in the #define means you now have a syntax error.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]