[uClibc]Bug in libc/stdlib/bsd_getpt.c

Kim B. Heino Kim.Heino at bluegiga.com
Thu Aug 30 11:13:25 UTC 2001


Hello,

In the libc/stdlib/bsd_getpt.c file you have line:

memcpy (buf, _PATH_PTY, sizeof (_PATH_PTY) - 1);

It really should be:

memcpy (buf, _PATH_PTY, sizeof (_PATH_PTY) );

The last nul character must be copied too because the next line uses
strlen() to get buf's length.







More information about the uClibc mailing list