[OpenBIOS] r117 - openbios-devel/drivers

Blue Swirl blueswir1 at hotmail.com
Sat Apr 7 21:49:36 CEST 2007


> >      if (size > OBIO_CMDLINE_MAX) size = OBIO_CMDLINE_MAX;
> >      memcpy(obio_cmdline, nv_info.cmdline, size);
> > -    obio_cmdline[size-1] = '\0';
> > +    obio_cmdline[size] = '\0';
>
>Looks like you need to change the declaration of
>"obio_cmdline[]" or the maximum value "size" is
>clamped to, as well?

Good point. The attached untested patch should fix the overflow possibility.

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix_cmdline.diff
Type: text/x-patch
Size: 633 bytes
Desc: not available
Url : http://lists.openbios.org/pipermail/openbios/attachments/20070407/e0d824bc/attachment.diff 


More information about the OpenBIOS mailing list