Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 7 Mar 2002 12:31:41 +0100 (CET)
From:      Harti Brandt <brandt@fokus.gmd.de>
To:        Will Andrews <will@csociety.org>
Cc:        "David O'Brien" <obrien@FreeBSD.ORG>, Mark Murray <markm@FreeBSD.ORG>, <cvs-committers@FreeBSD.ORG>, <cvs-all@FreeBSD.ORG>
Subject:   Re: cvs commit: src/usr.bin/rwall rwall.c
Message-ID:  <20020307122950.H99061-100000@beagle.fokus.gmd.de>
In-Reply-To: <20020307111707.GK53073@squall.waterspout.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 7 Mar 2002, Will Andrews wrote:

WA>On Thu, Mar 07, 2002 at 03:02:44AM -0800, David O'Brien wrote:
WA>> -       if ((fd = mkstemp(tmpname)) == -1 || !(fp = fdopen(fd, "r+")))
WA>> +       fd = mkstemp(tmpname);
WA>> +       fp = fdopen(fd, "r+");
WA>> +       if (fd == -1 || !fp)
WA>>
WA>> Why did you need to do such code restructuring?
WA>
WA>In my opinion, the above change makes the code clearer.  The
WA>previous construct obfuscates the logic.

For each medium-experienced C-programmer the one-liner is far faster and
easier to read and understand. Are we going to rewrite everything in
Pascal?

harti
-- 
harti brandt, http://www.fokus.gmd.de/research/cc/cats/employees/hartmut.brandt/private
              brandt@fokus.fhg.de


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020307122950.H99061-100000>