mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-08 19:04:45 +00:00
Bug 1049688 - Allow override of MOZ_DISABLE_NONLOCAL_CONNECTIONS. r=froydnj
This commit is contained in:
parent
bc41d84178
commit
7204b2e48f
@ -508,8 +508,11 @@ class Automation(object):
|
||||
else:
|
||||
env['MOZ_CRASHREPORTER_DISABLE'] = '1'
|
||||
|
||||
# Crash on non-local network connections.
|
||||
env['MOZ_DISABLE_NONLOCAL_CONNECTIONS'] = '1'
|
||||
# Crash on non-local network connections by default.
|
||||
# MOZ_DISABLE_NONLOCAL_CONNECTIONS can be set to "0" to temporarily
|
||||
# enable non-local connections for the purposes of local testing. Don't
|
||||
# override the user's choice here. See bug 1049688.
|
||||
env.setdefault('MOZ_DISABLE_NONLOCAL_CONNECTIONS', '1')
|
||||
|
||||
env['GNOME_DISABLE_CRASH_DIALOG'] = '1'
|
||||
env['XRE_NO_WINDOWS_CRASH_DIALOG'] = '1'
|
||||
|
@ -432,8 +432,11 @@ def environment(xrePath, env=None, crashreporter=True, debugger=False, dmdPath=N
|
||||
else:
|
||||
env['MOZ_CRASHREPORTER_DISABLE'] = '1'
|
||||
|
||||
# Crash on non-local network connections.
|
||||
env['MOZ_DISABLE_NONLOCAL_CONNECTIONS'] = '1'
|
||||
# Crash on non-local network connections by default.
|
||||
# MOZ_DISABLE_NONLOCAL_CONNECTIONS can be set to "0" to temporarily
|
||||
# enable non-local connections for the purposes of local testing. Don't
|
||||
# override the user's choice here. See bug 1049688.
|
||||
env.setdefault('MOZ_DISABLE_NONLOCAL_CONNECTIONS', '1')
|
||||
|
||||
# Set WebRTC logging in case it is not set yet
|
||||
env.setdefault('NSPR_LOG_MODULES', 'signaling:5,mtransport:5,datachannel:5')
|
||||
|
@ -74,8 +74,11 @@ class RemoteAutomation(Automation):
|
||||
else:
|
||||
env['MOZ_CRASHREPORTER_DISABLE'] = '1'
|
||||
|
||||
# Crash on non-local network connections.
|
||||
env['MOZ_DISABLE_NONLOCAL_CONNECTIONS'] = '1'
|
||||
# Crash on non-local network connections by default.
|
||||
# MOZ_DISABLE_NONLOCAL_CONNECTIONS can be set to "0" to temporarily
|
||||
# enable non-local connections for the purposes of local testing.
|
||||
# Don't override the user's choice here. See bug 1049688.
|
||||
env.setdefault('MOZ_DISABLE_NONLOCAL_CONNECTIONS', '1')
|
||||
|
||||
return env
|
||||
|
||||
|
@ -1185,7 +1185,15 @@ nsSocketTransport::InitiateSocket()
|
||||
{
|
||||
SOCKET_LOG(("nsSocketTransport::InitiateSocket [this=%p]\n", this));
|
||||
|
||||
static bool crashOnNonLocalConnections = !!getenv("MOZ_DISABLE_NONLOCAL_CONNECTIONS");
|
||||
static int crashOnNonLocalConnections = -1;
|
||||
if (crashOnNonLocalConnections == -1) {
|
||||
const char *s = getenv("MOZ_DISABLE_NONLOCAL_CONNECTIONS");
|
||||
if (s) {
|
||||
crashOnNonLocalConnections = !!strncmp(s, "0", 1);
|
||||
} else {
|
||||
crashOnNonLocalConnections = 0;
|
||||
}
|
||||
}
|
||||
|
||||
nsresult rv;
|
||||
bool isLocal;
|
||||
|
@ -861,8 +861,11 @@ class XPCShellTests(object):
|
||||
# Capturing backtraces is very slow on some platforms, and it's
|
||||
# disabled by automation.py too
|
||||
self.env["NS_TRACE_MALLOC_DISABLE_STACKS"] = "1"
|
||||
# Don't permit remote connections.
|
||||
self.env["MOZ_DISABLE_NONLOCAL_CONNECTIONS"] = "1"
|
||||
# Don't permit remote connections by default.
|
||||
# MOZ_DISABLE_NONLOCAL_CONNECTIONS can be set to "0" to temporarily
|
||||
# enable non-local connections for the purposes of local testing.
|
||||
# Don't override the user's choice here. See bug 1049688.
|
||||
self.env.setdefault('MOZ_DISABLE_NONLOCAL_CONNECTIONS', '1')
|
||||
|
||||
def buildEnvironment(self):
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user