Re: [PATCH 09/14] tools lib traceevent: Get rid of die() in add_right()

From: Namhyung Kim
Date: Mon Dec 09 2013 - 18:47:36 EST


Hi Steve,

On Mon, 9 Dec 2013 11:32:56 -0500, Steven Rostedt wrote:
> On Mon, 09 Dec 2013 15:59:26 +0900
> Namhyung Kim <namhyung@xxxxxxxxxx> wrote:
>
>> Hi Ilia,
>>
>> On Mon, 9 Dec 2013 01:28:26 -0500, Ilia Mirkin wrote:
>> > That should probably be
>> >
>> > if (!op->str.buffer)
>>
>> Argh.. you're right!
>
> I was thinking that it was better to do it Namhyung's way, with:
>
> if (op->str.buffer == NULL)
>
> than my preferred way of:
>
> if (!op->str.buffer)
>
> because I thought this mistake is more prevalent with my way. But It's
> good to know that this bug happens regardless of which way you
> prefer ;-)

Well, while I prefer explicit "buf == NULL" style, I was using "!buf"
style at that time since the previous line of "!op->str.val" already
used that style so that's why the typo came in. Just FYI. :)

Thanks,
Namhyung
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/