Mercurial > yaffs-ecoscentric-gpl
changeset 116:29e76174345a
Fix negative hash problem
| author | charles <charles> |
|---|---|
| date | Thu, 02 Feb 2006 22:14:44 +0000 |
| parents | 06a072660af9 |
| children | 790b53277ea9 |
| files | yaffs_guts.c |
| diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/yaffs_guts.c +++ b/yaffs_guts.c @@ -13,7 +13,7 @@ */ const char *yaffs_guts_c_version = - "$Id: yaffs_guts.c,v 1.27 2005-12-20 04:02:18 charles Exp $"; + "$Id: yaffs_guts.c,v 1.28 2006-02-02 22:14:44 charles Exp $"; #include "yportenv.h" @@ -335,6 +335,7 @@ static Y_INLINE int yaffs_StillSomeChunk static Y_INLINE int yaffs_HashFunction(int n) { + n = abs(n); return (n % YAFFS_NOBJECT_BUCKETS); }
