Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 7 Mar 2002 08:55:50 -0700
From:      Nate Williams <nate@yogotech.com>
To:        obrien@FreeBSD.org
Cc:        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:  <15495.36230.517729.174507@caddis.yogotech.com>
In-Reply-To: <20020307030244.B63484@dragon.nuxi.com>
References:  <200203042027.g24KRc978637@freefall.freebsd.org> <20020307030244.B63484@dragon.nuxi.com>

next in thread | previous in thread | raw e-mail | index | archive | help
> -       if ((fd = mkstemp(tmpname)) == -1 || !(fp = fdopen(fd, "r+")))
> +       fd = mkstemp(tmpname);
> +       fp = fdopen(fd, "r+");
> +       if (fd == -1 || !fp)
> 
> Why did you need to do such code restructuring?

It also changes the logic of the code, since the fdopen wouldn't get
called if the mkstemp command failed.

Consider me another person who is *very* concerned with Mark's recent
lint changes.


Nate

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?15495.36230.517729.174507>