Author: asomers
Date: Thu Sep 19 17:42:17 2019
New Revision: 352534
URL: https://svnweb.freebsd.org/changeset/base/352534

Log:
  MFC r352417:
  
  Fix an off-by-one error from r351961
  
  That revision addressed a Coverity CID that could lead to a buffer overflow,
  but it had an off-by-one error in the buffer size check.
  
  Reported by:  Coverity
  Coverity CID: 1405530
  MFC-With:     351961
  Sponsored by: The FreeBSD Foundation

Modified:
  stable/12/sys/fs/fuse/fuse_internal.c
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/sys/fs/fuse/fuse_internal.c
==============================================================================
--- stable/12/sys/fs/fuse/fuse_internal.c       Thu Sep 19 17:42:02 2019        
(r352533)
+++ stable/12/sys/fs/fuse/fuse_internal.c       Thu Sep 19 17:42:17 2019        
(r352534)
@@ -390,7 +390,7 @@ fuse_internal_invalidate_entry(struct mount *mp, struc
        if ((err = uiomove(&fnieo, sizeof(fnieo), uio)) != 0)
                return (err);
 
-       if (fnieo.namelen > sizeof(name))
+       if (fnieo.namelen >= sizeof(name))
                return (EINVAL);
 
        if ((err = uiomove(name, fnieo.namelen, uio)) != 0)
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to