sasc re-write

David Cuthbert dacut at kanga.org
Mon Jan 17 22:36:47 PST 2005


-On [20050118 05:02], David Cuthbert (dacut at xxxxxxxxx) wrote:
Heh... this is one of those areas where there seem to be two distinct 
camps with little grey area. :-)
Jeroen Ruigrok/asmodai wrote:
I think that this says enough:

intro(2):

Successful calls never set errno; once set, it remains until another error
occurs.  It should only be examined after an error.
Different issue.  That just says that you can't rely on errno if the 
call is successful -- this is unambiguous.

The camps I was referring to are:

    if (errno)
        do_something();
vs.:

    if (errno != 0)
        do_something();
Clearly, the latter is The Way God Intended(tm), and the former is the 
way only infidels check integral values.  I also have it on good 
authority that God Prefers Emacs and the UN has passed a resolution 
banning VHDL in favor of Verilog.  And if you believe any of this 
paragraph, I have an amazing multi-level marketing opportunity for you! :-)

Dave





More information about the Kernel mailing list