mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2025-01-11 17:04:19 +01:00
Close PR #12651: the hash calculation routine has changed in other
parts of the kernel but was not updated in nfs_readdirplusrpc().
This commit is contained in:
parent
f069164876
commit
44fe63e5e7
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=49239
@ -34,7 +34,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)nfs_vnops.c 8.16 (Berkeley) 5/27/95
|
||||
* $Id: nfs_vnops.c,v 1.135 1999/07/01 13:32:54 peter Exp $
|
||||
* $Id: nfs_vnops.c,v 1.136 1999/07/30 04:02:04 wpaul Exp $
|
||||
*/
|
||||
|
||||
|
||||
@ -2357,7 +2357,7 @@ nfs_readdirplusrpc(vp, uiop, cred)
|
||||
cnp->cn_hash = 0;
|
||||
for (cp = cnp->cn_nameptr, i = 1; i <= len;
|
||||
i++, cp++)
|
||||
cnp->cn_hash += (unsigned char)*cp * i;
|
||||
cnp->cn_hash += (unsigned char)*cp;
|
||||
cache_enter(ndp->ni_dvp, ndp->ni_vp, cnp);
|
||||
}
|
||||
} else {
|
||||
|
@ -34,7 +34,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)nfs_vnops.c 8.16 (Berkeley) 5/27/95
|
||||
* $Id: nfs_vnops.c,v 1.135 1999/07/01 13:32:54 peter Exp $
|
||||
* $Id: nfs_vnops.c,v 1.136 1999/07/30 04:02:04 wpaul Exp $
|
||||
*/
|
||||
|
||||
|
||||
@ -2357,7 +2357,7 @@ nfs_readdirplusrpc(vp, uiop, cred)
|
||||
cnp->cn_hash = 0;
|
||||
for (cp = cnp->cn_nameptr, i = 1; i <= len;
|
||||
i++, cp++)
|
||||
cnp->cn_hash += (unsigned char)*cp * i;
|
||||
cnp->cn_hash += (unsigned char)*cp;
|
||||
cache_enter(ndp->ni_dvp, ndp->ni_vp, cnp);
|
||||
}
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user