[PATCH] Minor fix in gethostent_r()
Joel Sherrill
joel.sherrill at OARcorp.com
Fri Nov 26 19:22:19 UTC 2010
On 11/26/2010 01:16 PM, Simon Perreault wrote:
> Hi all,
>
> I'm not sure if this is the right venue for contributing fixes, so
> please kindly tell me if there is a better way.
>
> Here goes...
>
The "official" ways is bugzilla.rtems.org. That way it can be found
by people in the future.
Please note which version you found it in.
Thanks.
>> Index: cpukit/libnetworking/libc/gethostbyht.c
>> ===================================================================
>> RCS file: /usr1/CVS/rtems/cpukit/libnetworking/libc/gethostbyht.c,v
>> retrieving revision 1.11
>> diff -u -p -r1.11 gethostbyht.c
>> --- cpukit/libnetworking/libc/gethostbyht.c 27 Mar 2010 04:00:52 -0000 1.11
>> +++ cpukit/libnetworking/libc/gethostbyht.c 26 Nov 2010 19:08:56 -0000
>> @@ -223,7 +223,7 @@ struct hostent* gethostent_r(char* buf,
>> int curlen;
>>
>>
>> - if (hostf<0) return 0;
>> + if (hostf==NULL) return 0;
>> fseek(hostf,0,SEEK_END);
>> curlen=ftell(hostf);
>> fseek(hostf,0,SEEK_SET);
> Simon
More information about the users
mailing list