##// END OF EJS Templates
bdiff.c: cast to unsigned char when computing hash value
Markus F.X.J. Oberhumer -
r13730:df978f28 default
parent child Browse files
Show More
@@ -84,7 +84,7 b' static int splitlines(const char *a, int'
84 h = 0;
84 h = 0;
85 for (p = a; p < a + len; p++) {
85 for (p = a; p < a + len; p++) {
86 /* Leonid Yuriev's hash */
86 /* Leonid Yuriev's hash */
87 h = (h * 1664525) + *p + 1013904223;
87 h = (h * 1664525) + (unsigned char)*p + 1013904223;
88
88
89 if (*p == '\n' || p == plast) {
89 if (*p == '\n' || p == plast) {
90 l->h = h;
90 l->h = h;
General Comments 0
You need to be logged in to leave comments. Login now