aboutsummaryrefslogtreecommitdiff
path: root/locale
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2013-09-23 23:03:34 +0000
committerJoseph Myers <joseph@codesourcery.com>2013-09-23 23:03:34 +0000
commita3a6c3129f4bdf3f54122355ff8d6843fe40a7ac (patch)
treefcd066c519ae6e3ab90d69ebc9de705be80c188a /locale
parent5057e7ce826bb0be3f476408b2ae364042f2a9bb (diff)
downloadglibc-a3a6c3129f4bdf3f54122355ff8d6843fe40a7ac.zip
glibc-a3a6c3129f4bdf3f54122355ff8d6843fe40a7ac.tar.gz
glibc-a3a6c3129f4bdf3f54122355ff8d6843fe40a7ac.tar.bz2
Make locale archive hash function architecture-independent.
Diffstat (limited to 'locale')
-rw-r--r--locale/hashval.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/locale/hashval.h b/locale/hashval.h
index 737162f..88e7839 100644
--- a/locale/hashval.h
+++ b/locale/hashval.h
@@ -37,7 +37,7 @@ compute_hashval (const void *key, size_t keylen)
while (cnt < keylen)
{
hval = (hval << 9) | (hval >> (sizeof hval * CHAR_BIT - 9));
- hval += (hashval_t) *(((char *) key) + cnt++);
+ hval += (hashval_t) ((const unsigned char *) key)[cnt++];
}
return hval != 0 ? hval : ~((hashval_t) 0);
}