diff options
author | thompsa <thompsa@FreeBSD.org> | 2007-04-09 22:55:14 +0000 |
---|---|---|
committer | thompsa <thompsa@FreeBSD.org> | 2007-04-09 22:55:14 +0000 |
commit | 496a4e8d2f0fd318133eb3880e26ccc13cc92bbb (patch) | |
tree | 3e7a18e5db372dd1ce8aab831414009cd9b2675f /sys/sys/hash.h | |
parent | 0daf602ef9b7c12a0a3f62c7bc4dbcb3236e8593 (diff) | |
download | FreeBSD-src-496a4e8d2f0fd318133eb3880e26ccc13cc92bbb.zip FreeBSD-src-496a4e8d2f0fd318133eb3880e26ccc13cc92bbb.tar.gz |
Fix a compiler warning so hash.h can be included in the kernel. This changes
the args for hash32_stre and hash32_strne but there are no consumers in the
base system and openbgpd does not use it which the initial import was for.
Silence on: hackers
Diffstat (limited to 'sys/sys/hash.h')
-rw-r--r-- | sys/sys/hash.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/sys/hash.h b/sys/sys/hash.h index 6ce4fdc..6ad89c5 100644 --- a/sys/sys/hash.h +++ b/sys/sys/hash.h @@ -86,7 +86,7 @@ hash32_strn(const void *buf, size_t len, uint32_t hash) * namei() hashing of path name parts. */ static __inline uint32_t -hash32_stre(const void *buf, int end, char **ep, uint32_t hash) +hash32_stre(const void *buf, int end, const char **ep, uint32_t hash) { const unsigned char *p = buf; @@ -94,7 +94,7 @@ hash32_stre(const void *buf, int end, char **ep, uint32_t hash) hash = HASHSTEP(hash, *p++); if (ep) - *ep = (char *)p; + *ep = p; return hash; } @@ -105,7 +105,8 @@ hash32_stre(const void *buf, int end, char **ep, uint32_t hash) * as a helper for the namei() hashing of path name parts. */ static __inline uint32_t -hash32_strne(const void *buf, size_t len, int end, char **ep, uint32_t hash) +hash32_strne(const void *buf, size_t len, int end, const char **ep, + uint32_t hash) { const unsigned char *p = buf; @@ -113,7 +114,7 @@ hash32_strne(const void *buf, size_t len, int end, char **ep, uint32_t hash) hash = HASHSTEP(hash, *p++); if (ep) - *ep = (char *)p; + *ep = p; return hash; } |