Bug 1175771 (part 1) - Fix indentation in nsHostResolver::FlushCache(). r=michal.

--HG--
extra : rebase_source : e158de557cdf93c132627268c8dd2342d4c3de5f
This commit is contained in:
Nicholas Nethercote 2015-06-10 17:09:32 -07:00
parent 8e2753e13c
commit 601e5edf97

View File

@ -632,24 +632,24 @@ nsHostResolver::ClearPendingQueue(PRCList *aPendingQ)
void
nsHostResolver::FlushCache()
{
MutexAutoLock lock(mLock);
mEvictionQSize = 0;
MutexAutoLock lock(mLock);
mEvictionQSize = 0;
// Clear the evictionQ and remove all its corresponding entries from
// the cache first
if (!PR_CLIST_IS_EMPTY(&mEvictionQ)) {
PRCList *node = mEvictionQ.next;
while (node != &mEvictionQ) {
nsHostRecord *rec = static_cast<nsHostRecord *>(node);
node = node->next;
PR_REMOVE_AND_INIT_LINK(rec);
PL_DHashTableRemove(&mDB, (nsHostKey *) rec);
NS_RELEASE(rec);
}
}
// Clear the evictionQ and remove all its corresponding entries from
// the cache first
if (!PR_CLIST_IS_EMPTY(&mEvictionQ)) {
PRCList *node = mEvictionQ.next;
while (node != &mEvictionQ) {
nsHostRecord *rec = static_cast<nsHostRecord *>(node);
node = node->next;
PR_REMOVE_AND_INIT_LINK(rec);
PL_DHashTableRemove(&mDB, (nsHostKey *) rec);
NS_RELEASE(rec);
}
}
// Refresh the cache entries that are resolving RIGHT now, remove the rest.
PL_DHashTableEnumerate(&mDB, HostDB_PruneEntry, nullptr);
// Refresh the cache entries that are resolving RIGHT now, remove the rest.
PL_DHashTableEnumerate(&mDB, HostDB_PruneEntry, nullptr);
}
void