Bug 1652762 - Make mURISetByDetection an Atomic, r=necko-reviewers,valentin

Differential Revision: https://phabricator.services.mozilla.com/D83616
This commit is contained in:
Kershaw Chang 2020-07-20 08:18:48 +00:00
parent 7fa11883f2
commit ec9d1eb9d5
2 changed files with 3 additions and 2 deletions

View File

@ -16,7 +16,7 @@ namespace net {
extern mozilla::LazyLogModule gHostResolverLog;
#define LOG(args) MOZ_LOG(gHostResolverLog, mozilla::LogLevel::Debug, args)
TRRServiceBase::TRRServiceBase() : mMode(0) {}
TRRServiceBase::TRRServiceBase() : mMode(0), mURISetByDetection(false) {}
void TRRServiceBase::ProcessURITemplate(nsACString& aURI) {
// URI Template, RFC 6570.

View File

@ -36,10 +36,11 @@ class TRRServiceBase {
nsCString mPrivateURI;
// Pref caches should only be used on the main thread.
bool mURIPrefHasUserValue = false;
bool mURISetByDetection = false;
nsCString mURIPref;
nsCString mRolloutURIPref;
Atomic<uint32_t, Relaxed> mMode;
Atomic<bool, Relaxed> mURISetByDetection;
};
} // namespace net