Unix Technical Forum

Re: Properly handle zero sized buffers returned by fgets

This is a discussion on Re: Properly handle zero sized buffers returned by fgets within the mailing.openbsd.tech forums, part of the OpenBSD category; --> > However, within context, if you are assuming there > may be binary data read in from the stream, ...


Go Back   Unix Technical Forum > Unix Operating Systems > OpenBSD > mailing.openbsd.tech

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-18-2008, 09:59 AM
Charles Longeau
 
Posts: n/a
Default Re: Properly handle zero sized buffers returned by fgets

> However, within context, if you are assuming there
> may be binary data read in from the stream, then
> the entire function rad_config has problems, since
> it is assuming non-binary data in buf. Therefore,
> much evasive changes are required to address this
> issue than the proposed diff.


I may be wrong, but I don't think so. I've read the rad_config function,
and it is using split function to parse the buffer returned by fgets. If
some binary data is there, rad_config will gracefully fail, because
expected data will not be there.

So my patch is legitimate, in my humble opinion.

Best regards,

Charles Longeau

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 07:05 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com