]> CyberLeo.Net >> Repos - FreeBSD/stable/9.git/commit
MFstable/10 r301782:
authorngie <ngie@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Fri, 10 Jun 2016 14:10:51 +0000 (14:10 +0000)
committerngie <ngie@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Fri, 10 Jun 2016 14:10:51 +0000 (14:10 +0000)
commit16241a27a9b0e357514fd902eb53b367a15ece63
treec8b1a3fbadc51df74bfa0317f1b6342db1a5cd48
parentc653aff45764abb88394954b03e913b4524e8a35
MFstable/10 r301782:

MFC r299460:
r299460 (by cem):

fsck_ffs: Don't overrun mount device buffer

Maybe this case is impossible.  Either way, when attempting to "/dev/"-prefix a
non-global device name, check that we do not overrun the f_mntfromname buffer.

In this case, truncating (with strlcpy or similar) would not be useful, since
the f_mntfromname result of getmntpt() is passed directly to open(2) later.

CID: 1006789

git-svn-id: svn://svn.freebsd.org/base/stable/9@301783 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sbin/fsck_ffs/main.c