Re: [PATCH]: if (cond); foo() in firewire

From: Adrian Chadd <adrian_at_freebsd.org>
Date: Tue, 23 Jun 2009 07:10:14 +0800
2009/6/22 Andriy Gapon <avg_at_icyb.net.ua>:
> You confuse me. It is a "vanilla userland transfer", but so?
> Current code always goes to "out" label regardless if uimove succeeded or not.
> I think the idea was to go "out" only if uimove failed and execute some code
> between if and out-label otherwise.

Because now you have a code path being run which hasn't been run for
quite a while.

I'm just saying be careful, and don't assume that "clang found a bug".
It found a bad code construct. Changing that bit of code changes the
flow of execution and may change things unexpectedly in later code.
It's the same with any bug - this "found by clang" bug should be
looked at by someone who knows the firewire code and they haven't
replied to this thread. :)

I'm glad clang has this lexical analysis magic. Shouldn't there be
some kind of weird, magical, standalone "lint" program to do this kind
of lexical checking for us? :)


Adrian




Adrian
Received on Mon Jun 22 2009 - 21:10:15 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:50 UTC