This is the mail archive of the cygwin-patches@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] setup.exe: Stop NetIO_HTTP from treating entire stream as a header


On Wed, Nov 28, 2001 at 09:12:20AM +1100, Robert Collins wrote:
>On Wed, 2001-11-28 at 05:42, Christopher Faylor wrote:
>
>> >Ah, better yet.  Jeez you guys are clever ;-).  But how about we make it:
>> >
>> >	while (((l = s->gets ()) != 0) && (*l != '\0'))
>> >
>> >in the interest of making it a bit more self-documenting?
>> 
>> Actually, how about not using != 0.  Use NULL in this context.
>> 
>> I don't think that *l is hard to understand, fwiw.
>
>I think *l is ok. As for 0 vs NULL, in C++ NULL is deprecated, 0 is the
>correct test for an invalid pointer.

References?  A simple google search for 'NULL C++ deprecated' didn't
unearth this information.

Regardless, I strenuously disagree with this.  It certainly is not
deprecated in the Cygwin DLL.

cgf


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]