svn commit: r225897 - head/lib/libc/gen
Garrett Cooper
yanegomi at gmail.com
Sat Oct 1 19:43:15 UTC 2011
On Sat, Oct 1, 2011 at 5:19 AM, Ed Schouten <ed at freebsd.org> wrote:
> Author: ed
> Date: Sat Oct 1 12:19:48 2011
> New Revision: 225897
> URL: http://svn.freebsd.org/changeset/base/225897
...
> + if (s == NULL) {
> + s = def;
> + dlen = sizeof(def) - LEN_PATH_DEV;
> + } else
> + dlen = L_ctermid - LEN_PATH_DEV;
> + strcpy(s, _PATH_TTY);
Why not use strlcpy, etc with dlen?
-Garrett
More information about the svn-src-all
mailing list