diff options
| author | Arno Töll <arno@debian.org> | 2013-10-15 20:19:13 +0200 |
|---|---|---|
| committer | Arno Töll <arno@debian.org> | 2013-10-15 20:19:13 +0200 |
| commit | e2b24c8fd106ecd3efb7a03db0a8dbf6153f9b9e (patch) | |
| tree | bcbcf401b0739078884c0e51e87d19a33f0540f0 /src/lemon.c | |
| parent | 8aaa5891149f731a0975998f5d81d9a264cf8bb9 (diff) | |
| parent | 1380410981681f011377225708e9c530330fd5a0 (diff) | |
| download | lighttpd-e2b24c8fd106ecd3efb7a03db0a8dbf6153f9b9e.tar.gz | |
Merge tag 'upstream/1.4.33'
Upstream version 1.4.33
Diffstat (limited to 'src/lemon.c')
| -rw-r--r-- | src/lemon.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lemon.c b/src/lemon.c index c3d72eb..8751737 100644 --- a/src/lemon.c +++ b/src/lemon.c @@ -3105,7 +3105,7 @@ int mhflag; /* True if generating makeheaders output */ stddt[j] = 0; hash = 0; for(j=0; stddt[j]; j++){ - hash = hash*53 + stddt[j]; + hash = (unsigned int)hash*53u + (unsigned int) stddt[j]; } hash = (hash & 0x7fffffff)%arraysize; while( types[hash] ){ @@ -3751,8 +3751,8 @@ char *s2; PRIVATE int strhash(x) char *x; { - int h = 0; - while( *x) h = h*13 + *(x++); + unsigned int h = 0; + while( *x) h = h*13u + (unsigned int) *(x++); return h; } @@ -4124,9 +4124,9 @@ struct config *b; PRIVATE int statehash(a) struct config *a; { - int h=0; + unsigned int h=0; while( a ){ - h = h*571 + a->rp->index*37 + a->dot; + h = h*571u + (unsigned int)a->rp->index*37u + (unsigned int)a->dot; a = a->bp; } return h; |
