firefox web history indexing: typo in memory reallocation call might have caused problems in highly improbable case

This commit is contained in:
Jean-Francois Dockes 2011-09-29 11:59:54 +02:00
parent 70e931233c
commit 8923d64fea

View File

@ -1117,7 +1117,7 @@ static void *allocmem(
return cp; return cp;
} }
int inc = (*np > maxinc) ? : *np; int inc = (*np > maxinc) ? maxinc : *np;
if ((cp = realloc(cp, (*np + inc) * sz)) != 0) if ((cp = realloc(cp, (*np + inc) * sz)) != 0)
*np += inc; *np += inc;
return cp; return cp;