зеркало из https://github.com/mozilla/gecko-dev.git
Bug 792581 - part 1: Replace LL_IS_ZERO macro with standard relation. r=ehsan
This commit is contained in:
Родитель
2b93b54e8e
Коммит
816b3752e7
|
@ -6881,7 +6881,7 @@ nsDocument::RetrieveRelevantHeaders(nsIChannel *aChannel)
|
|||
}
|
||||
}
|
||||
|
||||
if (LL_IS_ZERO(modDate)) {
|
||||
if (modDate == 0) {
|
||||
// We got nothing from our attempt to ask nsIFileChannel and
|
||||
// nsIHttpChannel for the last modified time. Return the current
|
||||
// time.
|
||||
|
|
|
@ -694,7 +694,7 @@ nsXULTemplateQueryProcessorRDF::CompareResults(nsIXULTemplateResult* aLeft,
|
|||
int64_t delta;
|
||||
LL_SUB(delta, ldate, rdate);
|
||||
|
||||
if (LL_IS_ZERO(delta))
|
||||
if (delta == 0)
|
||||
*aResult = 0;
|
||||
else if (LL_GE_ZERO(delta))
|
||||
*aResult = 1;
|
||||
|
|
|
@ -284,7 +284,7 @@ nsSHistory::CalcMaxTotalViewers()
|
|||
// 4096 Mb 8
|
||||
uint64_t bytes = PR_GetPhysicalMemorySize();
|
||||
|
||||
if (LL_IS_ZERO(bytes))
|
||||
if (bytes == 0)
|
||||
return 0;
|
||||
|
||||
// Conversion from unsigned int64 to double doesn't work on all platforms.
|
||||
|
|
|
@ -3692,7 +3692,7 @@ nsPluginHost::CreateTempFileToPost(const char *aPostDataURL, nsIFile **aTmpFile)
|
|||
rv = inFile->GetNativePath(filename);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
if (!LL_IS_ZERO(fileSize)) {
|
||||
if (fileSize != 0) {
|
||||
nsCOMPtr<nsIInputStream> inStream;
|
||||
rv = NS_NewLocalFileInputStream(getter_AddRefs(inStream), inFile);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
|
|
@ -623,7 +623,7 @@ gfxUserFontSet::IncrementGeneration()
|
|||
{
|
||||
// add one, increment again if zero
|
||||
LL_ADD(sFontSetGeneration, sFontSetGeneration, 1);
|
||||
if (LL_IS_ZERO(sFontSetGeneration))
|
||||
if (sFontSetGeneration == 0)
|
||||
LL_ADD(sFontSetGeneration, sFontSetGeneration, 1);
|
||||
mGeneration = sFontSetGeneration;
|
||||
}
|
||||
|
|
|
@ -418,7 +418,7 @@ nsCRLManager::ComputeNextAutoUpdateTime(nsICRLInfo *info,
|
|||
LL_SUB(diff, now, lastUpdate); //diff is the no of micro sec between now and last update
|
||||
LL_DIV(cycleCnt, diff, microsecInDayCnt); //temp is the number of full cycles from lst update
|
||||
LL_MOD(temp, diff, microsecInDayCnt);
|
||||
if(!(LL_IS_ZERO(temp))) {
|
||||
if(temp != 0) {
|
||||
LL_ADD(cycleCnt,cycleCnt,1); //no of complete cycles till next autoupdate instant
|
||||
}
|
||||
LL_MUL(temp,cycleCnt,microsecInDayCnt); //micro secs from last update
|
||||
|
|
|
@ -278,7 +278,7 @@ static int cvt_ll(SprintfState *ss, int64_t num, int width, int prec,
|
|||
int64_t rad;
|
||||
|
||||
/* according to the man page this needs to happen */
|
||||
if ((prec == 0) && (LL_IS_ZERO(num))) {
|
||||
if (prec == 0 && num == 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -290,7 +290,7 @@ static int cvt_ll(SprintfState *ss, int64_t num, int width, int prec,
|
|||
LL_I2L(rad, radix);
|
||||
cvt = &cvtbuf[0] + ELEMENTS_OF(cvtbuf);
|
||||
digits = 0;
|
||||
while (!LL_IS_ZERO(num)) {
|
||||
while (num != 0) {
|
||||
int32_t digit;
|
||||
int64_t quot, rem;
|
||||
LL_UDIVMOD(", &rem, num, rad);
|
||||
|
|
Загрузка…
Ссылка в новой задаче