mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-24 21:58:06 +00:00
Bug 665610 - Fix unused debug variable warnings in netwerk/; r=biesi
This commit is contained in:
parent
59ebdc4587
commit
cdd2b64d2f
@ -54,6 +54,7 @@
|
||||
#include "nsEscape.h"
|
||||
#include "nsNetError.h"
|
||||
#include "nsIProgrammingLanguage.h"
|
||||
#include "mozilla/Util.h" // for DebugOnly
|
||||
|
||||
static NS_DEFINE_CID(kThisSimpleURIImplementationCID,
|
||||
NS_THIS_SIMPLEURI_IMPLEMENTATION_CID);
|
||||
@ -226,7 +227,7 @@ nsSimpleURI::SetSpec(const nsACString &aSpec)
|
||||
return NS_ERROR_MALFORMED_URI;
|
||||
|
||||
mScheme.Truncate();
|
||||
PRInt32 n = spec.Left(mScheme, colonPos);
|
||||
mozilla::DebugOnly<PRInt32> n = spec.Left(mScheme, colonPos);
|
||||
NS_ASSERTION(n == colonPos, "Left failed");
|
||||
ToLowerCase(mScheme);
|
||||
|
||||
|
5
netwerk/cache/nsCacheService.cpp
vendored
5
netwerk/cache/nsCacheService.cpp
vendored
@ -72,6 +72,7 @@
|
||||
#include "nsIPrivateBrowsingService.h"
|
||||
#include "nsNetCID.h"
|
||||
#include <math.h> // for log()
|
||||
#include "mozilla/Util.h" // for DebugOnly
|
||||
#include "mozilla/Services.h"
|
||||
|
||||
#include "mozilla/FunctionTimer.h"
|
||||
@ -1818,7 +1819,7 @@ nsCacheService::EnsureEntryHasDevice(nsCacheEntry * entry)
|
||||
if (predictedDataSize != -1 &&
|
||||
entry->StoragePolicy() != nsICache::STORE_ON_DISK_AS_FILE &&
|
||||
mDiskDevice->EntryIsTooBig(predictedDataSize)) {
|
||||
nsresult rv = nsCacheService::DoomEntry(entry);
|
||||
DebugOnly<nsresult> rv = nsCacheService::DoomEntry(entry);
|
||||
NS_ASSERTION(NS_SUCCEEDED(rv),"DoomEntry() failed.");
|
||||
return nsnull;
|
||||
}
|
||||
@ -1841,7 +1842,7 @@ nsCacheService::EnsureEntryHasDevice(nsCacheEntry * entry)
|
||||
// Bypass the cache if Content-Length says entry will be too big
|
||||
if (predictedDataSize != -1 &&
|
||||
mMemoryDevice->EntryIsTooBig(predictedDataSize)) {
|
||||
nsresult rv = nsCacheService::DoomEntry(entry);
|
||||
DebugOnly<nsresult> rv = nsCacheService::DoomEntry(entry);
|
||||
NS_ASSERTION(NS_SUCCEEDED(rv),"DoomEntry() failed.");
|
||||
return nsnull;
|
||||
}
|
||||
|
@ -83,6 +83,7 @@
|
||||
#include "nsNetCID.h"
|
||||
#include "mozilla/storage.h"
|
||||
#include "mozilla/FunctionTimer.h"
|
||||
#include "mozilla/Util.h" // for DebugOnly
|
||||
|
||||
using namespace mozilla::net;
|
||||
|
||||
@ -1945,7 +1946,7 @@ nsCookieService::CancelAsyncRead(PRBool aPurgeReadSet)
|
||||
// Cancel the pending read, kill the read listener, and empty the array
|
||||
// of data already read in on the background thread.
|
||||
mDefaultDBState->readListener->Cancel();
|
||||
nsresult rv = mDefaultDBState->pendingRead->Cancel();
|
||||
mozilla::DebugOnly<nsresult> rv = mDefaultDBState->pendingRead->Cancel();
|
||||
NS_ASSERT_SUCCESS(rv);
|
||||
|
||||
mDefaultDBState->stmtReadDomain = nsnull;
|
||||
|
Loading…
x
Reference in New Issue
Block a user