Backed out changeset 82cd657ce425 (bug 1906260) for causing mochitest failures @ test_interactive_widget.html & pup wd test failures CLOSED TREE
This commit is contained in:
@@ -20,7 +20,7 @@ async function runFirefox(args) {
|
|||||||
"headless_test_screenshot_profile"
|
"headless_test_screenshot_profile"
|
||||||
);
|
);
|
||||||
const prefsPath = PathUtils.join(profilePath, mochiPrefsName);
|
const prefsPath = PathUtils.join(profilePath, mochiPrefsName);
|
||||||
const firefoxArgs = ["-profile", profilePath];
|
const firefoxArgs = ["-profile", profilePath, "-no-remote"];
|
||||||
|
|
||||||
await IOUtils.makeDirectory(profilePath);
|
await IOUtils.makeDirectory(profilePath);
|
||||||
await IOUtils.copy(mochiPrefsPath, prefsPath);
|
await IOUtils.copy(mochiPrefsPath, prefsPath);
|
||||||
|
|||||||
@@ -65,7 +65,7 @@ followed by the command line you'd like to run, like this:
|
|||||||
|
|
||||||
.. code:: bash
|
.. code:: bash
|
||||||
|
|
||||||
$ lldb -- obj-ff-dbg/dist/Nightly.app/Contents/MacOS/firefox -profile /path/to/profile
|
$ lldb -- obj-ff-dbg/dist/Nightly.app/Contents/MacOS/firefox -no-remote -profile /path/to/profile
|
||||||
|
|
||||||
Then set breakpoints you need and start the process:
|
Then set breakpoints you need and start the process:
|
||||||
|
|
||||||
|
|||||||
@@ -148,7 +148,8 @@ These steps were last updated for Xcode 15:
|
|||||||
debugging purposes" below. Select the "Arguments" tab in the scheme
|
debugging purposes" below. Select the "Arguments" tab in the scheme
|
||||||
editor, and click the '+' below the "Arguments passed on launch"
|
editor, and click the '+' below the "Arguments passed on launch"
|
||||||
field. Add "-P *profilename*", where *profilename* is the name of a
|
field. Add "-P *profilename*", where *profilename* is the name of a
|
||||||
profile you created previously.
|
profile you created previously. Repeat that to also add the argument
|
||||||
|
"-no-remote".
|
||||||
#. Also in the "Arguments" panel, you may want to add an environment
|
#. Also in the "Arguments" panel, you may want to add an environment
|
||||||
variable MOZ_DEBUG_CHILD_PROCESS set to the value 1 to help with
|
variable MOZ_DEBUG_CHILD_PROCESS set to the value 1 to help with
|
||||||
debugging e10s.
|
debugging e10s.
|
||||||
|
|||||||
@@ -262,7 +262,18 @@ Running two instances of Mozilla simultaneously
|
|||||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
You can run two instances of Mozilla (e.g. debug and optimized)
|
You can run two instances of Mozilla (e.g. debug and optimized)
|
||||||
simultaneously by specifying the profile to use with the ``-P profile_name``
|
simultaneously by setting the environment variable ``MOZ_NO_REMOTE``:
|
||||||
|
|
||||||
|
.. code::
|
||||||
|
|
||||||
|
set MOZ_NO_REMOTE=1
|
||||||
|
|
||||||
|
Or, starting with Firefox 2 and other Gecko 1.8.1-based applications,
|
||||||
|
you can use the ``-no-remote`` command-line switch instead (implemented
|
||||||
|
in
|
||||||
|
`bug 325509 <https://bugzilla.mozilla.org/show_bug.cgi?id=325509>`__).
|
||||||
|
|
||||||
|
You can also specify the profile to use with the ``-P profile_name``
|
||||||
command-line argument.
|
command-line argument.
|
||||||
|
|
||||||
Debugging JavaScript
|
Debugging JavaScript
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ export MOZ_DISABLE_CONTENT_SANDBOX=1
|
|||||||
|
|
||||||
Run the Firefox browser
|
Run the Firefox browser
|
||||||
```
|
```
|
||||||
~/mozilla-central/obj-opt64/dist/bin/firefox -profile ~/mozilla-central/obj-opt64/tmp/profile-default &
|
~/mozilla-central/obj-opt64/dist/bin/firefox -no-remote -profile ~/mozilla-central/obj-opt64/tmp/profile-default &
|
||||||
```
|
```
|
||||||
|
|
||||||
Navigate to the test case, but do not start it yet. Then hover over the tab to get the content process PID.
|
Navigate to the test case, but do not start it yet. Then hover over the tab to get the content process PID.
|
||||||
|
|||||||
@@ -121,7 +121,7 @@ simultaneous capture of non-heap data.
|
|||||||
|
|
||||||
To start a trace session, launching a new Firefox instance:
|
To start a trace session, launching a new Firefox instance:
|
||||||
|
|
||||||
`xperf -on base xperf -start heapsession -heap -PidNewProcess "./firefox.exe -P test" -stackwalk HeapAlloc+HeapRealloc -BufferSize 512 -MinBuffers 128 -MaxBuffers 512`
|
`xperf -on base xperf -start heapsession -heap -PidNewProcess "./firefox.exe -P test -no-remote" -stackwalk HeapAlloc+HeapRealloc -BufferSize 512 -MinBuffers 128 -MaxBuffers 512`
|
||||||
|
|
||||||
To stop a session and merge the resulting files:
|
To stop a session and merge the resulting files:
|
||||||
|
|
||||||
|
|||||||
@@ -435,7 +435,7 @@ class RemoteReftest(RefTest):
|
|||||||
startTime = datetime.datetime.now()
|
startTime = datetime.datetime.now()
|
||||||
status = 0
|
status = 0
|
||||||
profileDirectory = self.remoteProfile + "/"
|
profileDirectory = self.remoteProfile + "/"
|
||||||
cmdargs.extend(("-profile", profileDirectory))
|
cmdargs.extend(("-no-remote", "-profile", profileDirectory))
|
||||||
|
|
||||||
pid = rpm.launch(
|
pid = rpm.launch(
|
||||||
binary,
|
binary,
|
||||||
|
|||||||
@@ -1404,6 +1404,12 @@ def _get_desktop_run_parser():
|
|||||||
group.add_argument(
|
group.add_argument(
|
||||||
"--app", help="Path to executable to run (default: output of ./mach build)"
|
"--app", help="Path to executable to run (default: output of ./mach build)"
|
||||||
)
|
)
|
||||||
|
group.add_argument(
|
||||||
|
"--remote",
|
||||||
|
"-r",
|
||||||
|
action="store_true",
|
||||||
|
help="Do not pass the --no-remote argument by default.",
|
||||||
|
)
|
||||||
group.add_argument(
|
group.add_argument(
|
||||||
"--background",
|
"--background",
|
||||||
"-b",
|
"-b",
|
||||||
@@ -1928,6 +1934,7 @@ def _run_desktop(
|
|||||||
params,
|
params,
|
||||||
packaged,
|
packaged,
|
||||||
app,
|
app,
|
||||||
|
remote,
|
||||||
background,
|
background,
|
||||||
noprofile,
|
noprofile,
|
||||||
disable_e10s,
|
disable_e10s,
|
||||||
@@ -2012,6 +2019,9 @@ def _run_desktop(
|
|||||||
if params:
|
if params:
|
||||||
args.extend(params)
|
args.extend(params)
|
||||||
|
|
||||||
|
if not remote:
|
||||||
|
args.append("-no-remote")
|
||||||
|
|
||||||
if not background and sys.platform == "darwin":
|
if not background and sys.platform == "darwin":
|
||||||
args.append("-foreground")
|
args.append("-foreground")
|
||||||
|
|
||||||
@@ -3143,7 +3153,7 @@ def repackage_snap_install(command_context, snap_file, snap_name, sudo=None):
|
|||||||
logging.INFO,
|
logging.INFO,
|
||||||
"repackage-snap-install-howto-run",
|
"repackage-snap-install-howto-run",
|
||||||
{},
|
{},
|
||||||
"Example usage: snap run {}".format(snap_name),
|
"Example usage: snap run {} --no-remote".format(snap_name),
|
||||||
)
|
)
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
|
|||||||
@@ -59,7 +59,7 @@ describe('Firefox', () => {
|
|||||||
it('should launch a Firefox browser', async () => {
|
it('should launch a Firefox browser', async () => {
|
||||||
const userDataDir = path.join(tmpDir, 'profile');
|
const userDataDir = path.join(tmpDir, 'profile');
|
||||||
function getArgs(): string[] {
|
function getArgs(): string[] {
|
||||||
const firefoxArguments = [];
|
const firefoxArguments = ['--no-remote'];
|
||||||
switch (os.platform()) {
|
switch (os.platform()) {
|
||||||
case 'darwin':
|
case 'darwin':
|
||||||
firefoxArguments.push('--foreground');
|
firefoxArguments.push('--foreground');
|
||||||
|
|||||||
@@ -217,7 +217,7 @@ export class FirefoxLauncher extends ProductLauncher {
|
|||||||
userDataDir = null,
|
userDataDir = null,
|
||||||
} = options;
|
} = options;
|
||||||
|
|
||||||
const firefoxArguments = [];
|
const firefoxArguments = ['--no-remote'];
|
||||||
|
|
||||||
switch (os.platform()) {
|
switch (os.platform()) {
|
||||||
case 'darwin':
|
case 'darwin':
|
||||||
|
|||||||
@@ -405,6 +405,7 @@ describe('Launcher specs', function () {
|
|||||||
);
|
);
|
||||||
} else if (isFirefox) {
|
} else if (isFirefox) {
|
||||||
expect(puppeteer.defaultArgs()).toContain('--headless');
|
expect(puppeteer.defaultArgs()).toContain('--headless');
|
||||||
|
expect(puppeteer.defaultArgs()).toContain('--no-remote');
|
||||||
if (os.platform() === 'darwin') {
|
if (os.platform() === 'darwin') {
|
||||||
expect(puppeteer.defaultArgs()).toContain('--foreground');
|
expect(puppeteer.defaultArgs()).toContain('--foreground');
|
||||||
} else {
|
} else {
|
||||||
@@ -484,8 +485,8 @@ describe('Launcher specs', function () {
|
|||||||
const defaultArgs = puppeteer.defaultArgs();
|
const defaultArgs = puppeteer.defaultArgs();
|
||||||
const {browser, close} = await launch(
|
const {browser, close} = await launch(
|
||||||
Object.assign({}, defaultBrowserOptions, {
|
Object.assign({}, defaultBrowserOptions, {
|
||||||
// All arguments are optional.
|
// Only the first argument is fixed, others are optional.
|
||||||
ignoreDefaultArgs: [],
|
ignoreDefaultArgs: [defaultArgs[0]!],
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
try {
|
try {
|
||||||
@@ -493,7 +494,8 @@ describe('Launcher specs', function () {
|
|||||||
if (!spawnargs) {
|
if (!spawnargs) {
|
||||||
throw new Error('spawnargs not present');
|
throw new Error('spawnargs not present');
|
||||||
}
|
}
|
||||||
expect(spawnargs.indexOf(defaultArgs[0]!)).not.toBe(-1);
|
expect(spawnargs.indexOf(defaultArgs[0]!)).toBe(-1);
|
||||||
|
expect(spawnargs.indexOf(defaultArgs[1]!)).not.toBe(-1);
|
||||||
} finally {
|
} finally {
|
||||||
await close();
|
await close();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -369,6 +369,7 @@ def mozharness_test_on_generic_worker(config, job, taskdesc):
|
|||||||
"artifact-reference": "<build/public/build/mozharness.zip>"
|
"artifact-reference": "<build/public/build/mozharness.zip>"
|
||||||
},
|
},
|
||||||
"MOZILLA_BUILD_URL": {"task-reference": installer},
|
"MOZILLA_BUILD_URL": {"task-reference": installer},
|
||||||
|
"MOZ_NO_REMOTE": "1",
|
||||||
"NEED_XVFB": "false",
|
"NEED_XVFB": "false",
|
||||||
"XPCOM_DEBUG_BREAK": "warn",
|
"XPCOM_DEBUG_BREAK": "warn",
|
||||||
"NO_FAIL_ON_TEST_ERRORS": "1",
|
"NO_FAIL_ON_TEST_ERRORS": "1",
|
||||||
|
|||||||
@@ -400,7 +400,7 @@ class GeckoInstance(object):
|
|||||||
args = {
|
args = {
|
||||||
"binary": self.binary,
|
"binary": self.binary,
|
||||||
"profile": self.profile,
|
"profile": self.profile,
|
||||||
"cmdargs": ["-marionette"] + self.app_args,
|
"cmdargs": ["-no-remote", "-marionette"] + self.app_args,
|
||||||
"env": env,
|
"env": env,
|
||||||
"symbols_path": self.symbols_path,
|
"symbols_path": self.symbols_path,
|
||||||
"process_args": process_args,
|
"process_args": process_args,
|
||||||
|
|||||||
@@ -365,7 +365,7 @@ class MochiRemote(MochitestDesktop):
|
|||||||
profileDirectory = self.remoteProfile + "/"
|
profileDirectory = self.remoteProfile + "/"
|
||||||
args = []
|
args = []
|
||||||
args.extend(extraArgs)
|
args.extend(extraArgs)
|
||||||
args.extend(("-profile", profileDirectory))
|
args.extend(("-no-remote", "-profile", profileDirectory))
|
||||||
|
|
||||||
pid = rpm.launch(
|
pid = rpm.launch(
|
||||||
app,
|
app,
|
||||||
|
|||||||
@@ -38,6 +38,9 @@ class GeckoRuntimeRunner(BaseRunner):
|
|||||||
# its execution.
|
# its execution.
|
||||||
self.cmdargs.append("--wait-for-browser")
|
self.cmdargs.append("--wait-for-browser")
|
||||||
|
|
||||||
|
# allows you to run an instance of Firefox separately from any other instances
|
||||||
|
self.env["MOZ_NO_REMOTE"] = "1"
|
||||||
|
|
||||||
# Disable crash reporting dialogs that interfere with debugging
|
# Disable crash reporting dialogs that interfere with debugging
|
||||||
self.env["GNOME_DISABLE_CRASH_DIALOG"] = "1"
|
self.env["GNOME_DISABLE_CRASH_DIALOG"] = "1"
|
||||||
self.env["XRE_NO_WINDOWS_CRASH_DIALOG"] = "1"
|
self.env["XRE_NO_WINDOWS_CRASH_DIALOG"] = "1"
|
||||||
|
|||||||
@@ -160,9 +160,12 @@ impl FirefoxRunner {
|
|||||||
/// i.e. _/Applications/Firefox.app_, as well as to an executable program
|
/// i.e. _/Applications/Firefox.app_, as well as to an executable program
|
||||||
/// such as _/Applications/Firefox.app/Content/MacOS/firefox_.
|
/// such as _/Applications/Firefox.app/Content/MacOS/firefox_.
|
||||||
pub fn new(path: &Path, profile: Option<Profile>) -> FirefoxRunner {
|
pub fn new(path: &Path, profile: Option<Profile>) -> FirefoxRunner {
|
||||||
|
let mut envs: HashMap<OsString, OsString> = HashMap::new();
|
||||||
|
envs.insert("MOZ_NO_REMOTE".into(), "1".into());
|
||||||
|
|
||||||
FirefoxRunner {
|
FirefoxRunner {
|
||||||
path: path.to_path_buf(),
|
path: path.to_path_buf(),
|
||||||
envs: HashMap::new(),
|
envs,
|
||||||
profile,
|
profile,
|
||||||
args: vec![],
|
args: vec![],
|
||||||
stdout: None,
|
stdout: None,
|
||||||
|
|||||||
@@ -158,6 +158,12 @@ def run_tests(config, browser_config):
|
|||||||
else:
|
else:
|
||||||
browser_config["extra_args"] = []
|
browser_config["extra_args"] = []
|
||||||
|
|
||||||
|
# pass --no-remote to firefox launch, if --develop is specified
|
||||||
|
# we do that to allow locally the user to have another running firefox
|
||||||
|
# instance
|
||||||
|
if browser_config["develop"]:
|
||||||
|
browser_config["extra_args"].append("--no-remote")
|
||||||
|
|
||||||
# Pass subtests filter argument via a preference
|
# Pass subtests filter argument via a preference
|
||||||
if browser_config["subtests"]:
|
if browser_config["subtests"]:
|
||||||
browser_config["preferences"]["talos.subtests"] = browser_config["subtests"]
|
browser_config["preferences"]["talos.subtests"] = browser_config["subtests"]
|
||||||
|
|||||||
@@ -49,6 +49,7 @@ class TPSTestRunner(object):
|
|||||||
"MOZ_CRASHREPORTER_DISABLE": "1",
|
"MOZ_CRASHREPORTER_DISABLE": "1",
|
||||||
"GNOME_DISABLE_CRASH_DIALOG": "1",
|
"GNOME_DISABLE_CRASH_DIALOG": "1",
|
||||||
"XRE_NO_WINDOWS_CRASH_DIALOG": "1",
|
"XRE_NO_WINDOWS_CRASH_DIALOG": "1",
|
||||||
|
"MOZ_NO_REMOTE": "1",
|
||||||
"XPCOM_DEBUG_BREAK": "warn",
|
"XPCOM_DEBUG_BREAK": "warn",
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ add_task(async function test_backgroundtask_automatic_restart() {
|
|||||||
|
|
||||||
// Test restart functionality.
|
// Test restart functionality.
|
||||||
let exitCode = await do_backgroundtask("automaticrestart", {
|
let exitCode = await do_backgroundtask("automaticrestart", {
|
||||||
extraArgs: [`-no-wait`, path, `-attach-console`],
|
extraArgs: [`-no-wait`, path, `-attach-console`, `-no-remote`],
|
||||||
onStdoutLine: line => stdoutLines.push(line),
|
onStdoutLine: line => stdoutLines.push(line),
|
||||||
});
|
});
|
||||||
Assert.equal(0, exitCode);
|
Assert.equal(0, exitCode);
|
||||||
|
|||||||
@@ -4439,6 +4439,8 @@ function createAppInfo(aID, aName, aVersion, aPlatformVersion) {
|
|||||||
* would otherwise pollute the xpcshell log.
|
* would otherwise pollute the xpcshell log.
|
||||||
*
|
*
|
||||||
* Command line arguments used when launching the application:
|
* Command line arguments used when launching the application:
|
||||||
|
* -no-remote prevents shell integration from being affected by an existing
|
||||||
|
* application process.
|
||||||
* -test-process-updates makes the application exit after being relaunched by
|
* -test-process-updates makes the application exit after being relaunched by
|
||||||
* the updater.
|
* the updater.
|
||||||
* the platform specific string defined by PIPE_TO_NULL to output both stdout
|
* the platform specific string defined by PIPE_TO_NULL to output both stdout
|
||||||
@@ -4479,7 +4481,7 @@ function getProcessArgs(aExtraArgs) {
|
|||||||
scriptContents += "export XRE_PROFILE_PATH=" + profilePath + "\n";
|
scriptContents += "export XRE_PROFILE_PATH=" + profilePath + "\n";
|
||||||
scriptContents +=
|
scriptContents +=
|
||||||
appBinPath +
|
appBinPath +
|
||||||
" -test-process-updates " +
|
" -no-remote -test-process-updates " +
|
||||||
aExtraArgs.join(" ") +
|
aExtraArgs.join(" ") +
|
||||||
" " +
|
" " +
|
||||||
PIPE_TO_NULL;
|
PIPE_TO_NULL;
|
||||||
@@ -4496,6 +4498,7 @@ function getProcessArgs(aExtraArgs) {
|
|||||||
appBinPath,
|
appBinPath,
|
||||||
"-profile",
|
"-profile",
|
||||||
profilePath,
|
profilePath,
|
||||||
|
"-no-remote",
|
||||||
"-test-process-updates",
|
"-test-process-updates",
|
||||||
"-wait-for-browser",
|
"-wait-for-browser",
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -318,6 +318,7 @@ extern const char gToolkitBuildID[];
|
|||||||
static nsIProfileLock* gProfileLock;
|
static nsIProfileLock* gProfileLock;
|
||||||
#if defined(MOZ_HAS_REMOTE)
|
#if defined(MOZ_HAS_REMOTE)
|
||||||
static nsRemoteService* gRemoteService;
|
static nsRemoteService* gRemoteService;
|
||||||
|
bool gRestartWithoutRemote = false;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
int gRestartArgc;
|
int gRestartArgc;
|
||||||
@@ -2089,6 +2090,8 @@ static void DumpHelp() {
|
|||||||
" --migration Start with migration wizard.\n"
|
" --migration Start with migration wizard.\n"
|
||||||
" --ProfileManager Start with ProfileManager.\n"
|
" --ProfileManager Start with ProfileManager.\n"
|
||||||
#ifdef MOZ_HAS_REMOTE
|
#ifdef MOZ_HAS_REMOTE
|
||||||
|
" --no-remote Do not accept or send remote commands; implies\n"
|
||||||
|
" --new-instance.\n"
|
||||||
" --new-instance Open new instance, not a new window in running "
|
" --new-instance Open new instance, not a new window in running "
|
||||||
"instance.\n"
|
"instance.\n"
|
||||||
#endif
|
#endif
|
||||||
@@ -2508,6 +2511,12 @@ nsresult LaunchChild(bool aBlankCommandLine, bool aTryExec) {
|
|||||||
gRestartArgv[gRestartArgc] = nullptr;
|
gRestartArgv[gRestartArgc] = nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(MOZ_HAS_REMOTE)
|
||||||
|
if (gRestartWithoutRemote) {
|
||||||
|
SaveToEnv("MOZ_NO_REMOTE=1");
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
SaveToEnv("MOZ_LAUNCHED_CHILD=1");
|
SaveToEnv("MOZ_LAUNCHED_CHILD=1");
|
||||||
#if defined(MOZ_LAUNCHER_PROCESS)
|
#if defined(MOZ_LAUNCHER_PROCESS)
|
||||||
SaveToEnv("MOZ_LAUNCHER_PROCESS=1");
|
SaveToEnv("MOZ_LAUNCHER_PROCESS=1");
|
||||||
@@ -3689,6 +3698,7 @@ class XREMain {
|
|||||||
bool mStartOffline = false;
|
bool mStartOffline = false;
|
||||||
#if defined(MOZ_HAS_REMOTE)
|
#if defined(MOZ_HAS_REMOTE)
|
||||||
bool mDisableRemoteClient = false;
|
bool mDisableRemoteClient = false;
|
||||||
|
bool mDisableRemoteServer = false;
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -4316,12 +4326,20 @@ int XREMain::XRE_mainInit(bool* aExitFlag) {
|
|||||||
CrashReporter::RegisterAnnotationBool(CrashReporter::Annotation::SafeMode,
|
CrashReporter::RegisterAnnotationBool(CrashReporter::Annotation::SafeMode,
|
||||||
&gSafeMode);
|
&gSafeMode);
|
||||||
|
|
||||||
// Strip the now unsupported no-remote command line argument.
|
|
||||||
CheckArg("no-remote");
|
|
||||||
|
|
||||||
#if defined(MOZ_HAS_REMOTE)
|
#if defined(MOZ_HAS_REMOTE)
|
||||||
// Handle the --new-instance command line arguments. Setup the environment to
|
// Handle --no-remote and --new-instance command line arguments. Setup
|
||||||
// better accommodate other components and various restart scenarios.
|
// the environment to better accommodate other components and various
|
||||||
|
// restart scenarios.
|
||||||
|
ar = CheckArg("no-remote");
|
||||||
|
if (ar == ARG_FOUND || EnvHasValue("MOZ_NO_REMOTE")) {
|
||||||
|
mDisableRemoteClient = true;
|
||||||
|
mDisableRemoteServer = true;
|
||||||
|
gRestartWithoutRemote = true;
|
||||||
|
// We don't want to propagate MOZ_NO_REMOTE to potential child
|
||||||
|
// process.
|
||||||
|
SaveToEnv("MOZ_NO_REMOTE=");
|
||||||
|
}
|
||||||
|
|
||||||
ar = CheckArg("new-instance");
|
ar = CheckArg("new-instance");
|
||||||
if (ar == ARG_FOUND || EnvHasValue("MOZ_NEW_INSTANCE")) {
|
if (ar == ARG_FOUND || EnvHasValue("MOZ_NEW_INSTANCE")) {
|
||||||
mDisableRemoteClient = true;
|
mDisableRemoteClient = true;
|
||||||
@@ -4329,6 +4347,7 @@ int XREMain::XRE_mainInit(bool* aExitFlag) {
|
|||||||
#else
|
#else
|
||||||
// These arguments do nothing in platforms with no remoting support but we
|
// These arguments do nothing in platforms with no remoting support but we
|
||||||
// should remove them from the command line anyway.
|
// should remove them from the command line anyway.
|
||||||
|
CheckArg("no-remote");
|
||||||
CheckArg("new-instance");
|
CheckArg("new-instance");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -4704,6 +4723,7 @@ int XREMain::XRE_mainStartup(bool* aExitFlag) {
|
|||||||
#ifdef MOZ_HAS_REMOTE
|
#ifdef MOZ_HAS_REMOTE
|
||||||
if (gfxPlatform::IsHeadless()) {
|
if (gfxPlatform::IsHeadless()) {
|
||||||
mDisableRemoteClient = true;
|
mDisableRemoteClient = true;
|
||||||
|
mDisableRemoteServer = true;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -4824,7 +4844,7 @@ int XREMain::XRE_mainStartup(bool* aExitFlag) {
|
|||||||
#if defined(MOZ_HAS_REMOTE)
|
#if defined(MOZ_HAS_REMOTE)
|
||||||
// handle --remote now that xpcom is fired up
|
// handle --remote now that xpcom is fired up
|
||||||
mRemoteService = new nsRemoteService(gAppData->remotingName);
|
mRemoteService = new nsRemoteService(gAppData->remotingName);
|
||||||
if (mRemoteService) {
|
if (mRemoteService && !mDisableRemoteServer) {
|
||||||
mRemoteService->LockStartup();
|
mRemoteService->LockStartup();
|
||||||
gRemoteService = mRemoteService;
|
gRemoteService = mRemoteService;
|
||||||
}
|
}
|
||||||
@@ -5683,7 +5703,7 @@ nsresult XREMain::XRE_mainRun() {
|
|||||||
#if defined(MOZ_HAS_REMOTE)
|
#if defined(MOZ_HAS_REMOTE)
|
||||||
// if we have X remote support, start listening for requests on the
|
// if we have X remote support, start listening for requests on the
|
||||||
// proxy window.
|
// proxy window.
|
||||||
if (mRemoteService) {
|
if (mRemoteService && !mDisableRemoteServer) {
|
||||||
mRemoteService->StartupServer();
|
mRemoteService->StartupServer();
|
||||||
mRemoteService->UnlockStartup();
|
mRemoteService->UnlockStartup();
|
||||||
gRemoteService = nullptr;
|
gRemoteService = nullptr;
|
||||||
@@ -6027,7 +6047,7 @@ int XREMain::XRE_main(int argc, char* argv[], const BootstrapConfig& aConfig) {
|
|||||||
// Shut down the remote service. We must do this before calling LaunchChild
|
// Shut down the remote service. We must do this before calling LaunchChild
|
||||||
// if we're restarting because otherwise the new instance will attempt to
|
// if we're restarting because otherwise the new instance will attempt to
|
||||||
// remote to this instance.
|
// remote to this instance.
|
||||||
if (mRemoteService) {
|
if (mRemoteService && !mDisableRemoteServer) {
|
||||||
mRemoteService->ShutdownServer();
|
mRemoteService->ShutdownServer();
|
||||||
}
|
}
|
||||||
#endif /* MOZ_WIDGET_GTK */
|
#endif /* MOZ_WIDGET_GTK */
|
||||||
|
|||||||
@@ -238,6 +238,7 @@ function run_test() {
|
|||||||
|
|
||||||
let testTry = function testTry() {
|
let testTry = function testTry() {
|
||||||
let shell = wrapLaunchInShell(getFirefoxExecutableFile(), [
|
let shell = wrapLaunchInShell(getFirefoxExecutableFile(), [
|
||||||
|
"-no-remote",
|
||||||
"-test-launch-without-hang",
|
"-test-launch-without-hang",
|
||||||
]);
|
]);
|
||||||
info("Try attempt #" + triesStarted);
|
info("Try attempt #" + triesStarted);
|
||||||
|
|||||||
Reference in New Issue
Block a user