Commit beca20d2 by Joseph Myers Committed by Joseph Myers

* objc/hash.h (hash_string): Don't use a cast as an lvalue.

From-SVN: r72722
parent d4d1ebc1
2003-10-20 Joseph S. Myers <jsm@polyomino.org.uk>
* objc/hash.h (hash_string): Don't use a cast as an lvalue.
2003-10-17 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE> 2003-10-17 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
* Makefile.in (runtime-info.h): Use MULTIFLAGS. * Makefile.in (runtime-info.h): Use MULTIFLAGS.
......
...@@ -172,10 +172,10 @@ hash_string (cache_ptr cache, const void *key) ...@@ -172,10 +172,10 @@ hash_string (cache_ptr cache, const void *key)
{ {
unsigned int ret = 0; unsigned int ret = 0;
unsigned int ctr = 0; unsigned int ctr = 0;
const char *ckey = key;
while (*ckey) {
while (*(const char *) key) { ret ^= *ckey++ << ctr;
ret ^= *((const char *) key)++ << ctr;
ctr = (ctr + 1) % sizeof (void *); ctr = (ctr + 1) % sizeof (void *);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment