[Bug 192528] pwd_mkdb fails if /etc/shells contains duplicates
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Thu May 14 20:14:36 UTC 2015
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=192528
--- Comment #3 from tmwalaszek at gmail.com ---
Hi,
Problem is in function _local_initshells in file lib/libc/gen/getusershell.c
Function is reading /etc/shells and put every shell path to line[MAXPATHLEN +
1]
It looks like this '/bin/csh\0/usr/local/bin/zsh\0/usr/local/bin/bash', it does
not clean this array (and not set pointer at the beggining) on every iteration
so if we have many lines in /etc/shells it will overflow.
Simple patch is in the attachment. Works for me ;)
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-bugs
mailing list