Bug 1894380 - Fix the nsUrlClassifierPrefixSet destructor. r=dimi
Differential Revision: https://phabricator.services.mozilla.com/D210625
This commit is contained in:
@@ -37,6 +37,8 @@ nsUrlClassifierPrefixSet::Init(const nsACString& aName) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
nsUrlClassifierPrefixSet::~nsUrlClassifierPrefixSet() {
|
nsUrlClassifierPrefixSet::~nsUrlClassifierPrefixSet() {
|
||||||
|
MutexAutoLock lock(mLock);
|
||||||
|
|
||||||
for (uint32_t i = 0; i < mIndexDeltas.Length(); i++) {
|
for (uint32_t i = 0; i < mIndexDeltas.Length(); i++) {
|
||||||
mIndexDeltas[i].Clear();
|
mIndexDeltas[i].Clear();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ class nsUrlClassifierPrefixSet final : public nsIUrlClassifierPrefixSet {
|
|||||||
friend class mozilla::safebrowsing::VariableLengthPrefixSet;
|
friend class mozilla::safebrowsing::VariableLengthPrefixSet;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
virtual ~nsUrlClassifierPrefixSet();
|
virtual ~nsUrlClassifierPrefixSet() MOZ_REQUIRES(mLock);
|
||||||
|
|
||||||
static const uint32_t DELTAS_LIMIT = 120;
|
static const uint32_t DELTAS_LIMIT = 120;
|
||||||
static const uint32_t MAX_INDEX_DIFF = (1 << 16);
|
static const uint32_t MAX_INDEX_DIFF = (1 << 16);
|
||||||
|
|||||||
Reference in New Issue
Block a user