]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Use strlcpy() instead of strncpy() to ensure that qf->fsname is NUL
authortruckman <truckman@FreeBSD.org>
Fri, 13 May 2016 00:26:14 +0000 (00:26 +0000)
committertruckman <truckman@FreeBSD.org>
Fri, 13 May 2016 00:26:14 +0000 (00:26 +0000)
commit61eb4d5d8afa53a504d7065b957da20e85fc4878
treea52e785831b3911a38ea3afee000a4c8070d529a
parent4e9e03d38e852ee3ab1911310614b99fa17cc82f
Use strlcpy() instead of strncpy() to ensure that qf->fsname is NUL
terminated.  Don't bother checking for truncation since the subsequent
stat() call should detect that and fail.

Reported by: Coverity
CID: 1018189
MFC after: 1 week
lib/libutil/quotafile.c