зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1641496 - P7: Allow to use SSLTokensCache in parent process with socket process enabled r=dragana
Differential Revision: https://phabricator.services.mozilla.com/D78228
This commit is contained in:
Родитель
f325bc0048
Коммит
8a93345ab3
|
@ -76,11 +76,12 @@ NS_IMPL_ISUPPORTS(SSLTokensCache, nsIMemoryReporter)
|
|||
nsresult SSLTokensCache::Init() {
|
||||
StaticMutexAutoLock lock(sLock);
|
||||
|
||||
if (nsIOService::UseSocketProcess()) {
|
||||
if (!XRE_IsSocketProcess()) {
|
||||
return NS_OK;
|
||||
}
|
||||
} else if (!XRE_IsParentProcess()) {
|
||||
// SSLTokensCache should be only used in parent process and socket process.
|
||||
// Ideally, parent process should not use this when socket process is enabled.
|
||||
// However, some xpcsehll tests may need to create and use sockets directly,
|
||||
// so we still allow to use this in parent process no matter socket process is
|
||||
// enabled or not.
|
||||
if (!(XRE_IsSocketProcess() || XRE_IsParentProcess())) {
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче