qemu-trivial
[Top][All Lists]
Advanced

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

Re: [Qemu-trivial] [Qemu-devel] [PATCH v2 1/1] qtest: Fix the bug about


From: Peter Crosthwaite
Subject: Re: [Qemu-trivial] [Qemu-devel] [PATCH v2 1/1] qtest: Fix the bug about disabling vnc causes "make check" hang
Date: Wed, 1 Jan 2014 14:39:06 +1000

On Wed, Jan 1, 2014 at 12:29 PM, Kewei Yu <address@hidden> wrote:
>
> 2014/1/1 Peter Maydell <address@hidden>
>>
>> On 31 December 2013 13:29, Kewei Yu <address@hidden> wrote:
>> > 2013/12/31 Peter Crosthwaite <address@hidden>
>> >>
>> >> On Tue, Dec 31, 2013 at 2:42 PM, Kewei Yu <address@hidden> wrote:
>> >> >                                    "%s", qemu_binary, s->socket_path,
>> >> >                                    s->qmp_socket_path, pid_file,
>> >> > +                                  qtest_vnc_param ?: "",
>> >>
>> >> I do vaguely remember someone going to efforts to remove uses of "? :
>> >> foo" (with the blank true value).
>> >
>> >  I'm not clear the sentence's meaning.
>>
>> Using the ternary operator "X ? Y : Z" with an empty 2nd operand
>> "X ?: Y" is not standard C. It's a GCC extension. There was a
>> suggestion a year or so back that we should remove the uses of
>> it, but the consensus was that this was unnecessary, since in
>> practice we rely on other GCC extensions. Clang also supports
>> this syntax, and it's the only other compiler we care about.
>>
>
> Oh! Thank you, I got it.
>
>> In this case it seems reasonable, especially since the line
>> immediately below this addition is using it too.
>
>
> But,do I need to fix them to be "X ? Y : Z" and keep them consistent?
>

No, it's already consistent. No change to patch required. Apart from
the grammar and spelling.

Regards,
Peter

> Faithfully yours
> Kewei Yu
>
>> thanks
>> -- PMM
>
>
>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]