Author: pfg
Date: Thu May  5 01:35:42 2016
New Revision: 299107
URL: https://svnweb.freebsd.org/changeset/base/299107

Log:
  MFC r298732:
  sys/devfs: unsign an index to prevent signed integer overflow.
  
  cdp_maxdirent in struct:cdev_priv is of type u_int.  Use the same
  type for the corresponding index in devfs_revoke().

Modified:
  stable/9/sys/fs/devfs/devfs_vnops.c
Directory Properties:
  stable/9/sys/   (props changed)
  stable/9/sys/fs/   (props changed)

Modified: stable/9/sys/fs/devfs/devfs_vnops.c
==============================================================================
--- stable/9/sys/fs/devfs/devfs_vnops.c Thu May  5 01:34:58 2016        
(r299106)
+++ stable/9/sys/fs/devfs/devfs_vnops.c Thu May  5 01:35:42 2016        
(r299107)
@@ -1374,7 +1374,7 @@ devfs_revoke(struct vop_revoke_args *ap)
        struct cdev *dev;
        struct cdev_priv *cdp;
        struct devfs_dirent *de;
-       int i;
+       u_int i;
 
        KASSERT((ap->a_flags & REVOKEALL) != 0, ("devfs_revoke !REVOKEALL"));
 
_______________________________________________
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