Re: bus_add_device() losing an error return from the probe() method

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

 



Rene Herman <[email protected]> wrote:
> Andrew Morton wrote:

>> Looks sane, but please don't sprinkle `return' statements all over a
>> function in this manner.
> 
> I actually prefer the multiple returns. You then don't have to "visually
> scroll down" to the label to see what would happen when reading the
> code. Even when there's common code before the return, I've never seen
> GCC not optimise that to the goto form itself. You obviously the boss
> though.

I tried both, and I found out that having multiple non-trivial points of
return enables you to easily create a lot of bugs.
-- 
Ich danke GMX dafür, die Verwendung meiner Adressen mittels per SPF
verbreiteten Lügen zu sabotieren.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux