Fix AIX bustage. patch=jdunn, r=gordon, sr=darin, a=mkaply.
git-svn-id: svn://10.0.0.236/trunk@141717 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
2
mozilla/netwerk/cache/src/nsCacheService.cpp
vendored
2
mozilla/netwerk/cache/src/nsCacheService.cpp
vendored
@@ -1333,7 +1333,7 @@ nsCacheService::CacheMemoryAvailable()
|
||||
if (kbytes == 0) return 0;
|
||||
if (kbytes < 0) kbytes = LONG_MAX; // cap overflows
|
||||
|
||||
double x = log(kbytes)/log(2) - 14;
|
||||
double x = log((double)kbytes)/log((double)2) - 14;
|
||||
if (x > 0) {
|
||||
capacity = (PRInt32)(x * x - x + 2.001); // add .001 for rounding
|
||||
capacity *= 1024;
|
||||
|
||||
Reference in New Issue
Block a user