Bug 1330496 - Part 2: Remove mochitest use of MOZ_WIN_INHERIT_STD_HANDLES_PRE_VISTA. r?jmaher draft
authorChris Peterson <cpeterson@mozilla.com>
Tue, 10 Jan 2017 23:47:32 -0800
changeset 459516 5de185791d7cd032b6359d4a82205fcfeb7c21f8
parent 459513 44e03181133ceff8c0777c05bf564296733b5b64
child 459517 7b616e49fc65d8689018d851b469bbe1ca16067d
push id41249
push usercpeterson@mozilla.com
push dateThu, 12 Jan 2017 03:26:13 +0000
reviewersjmaher
bugs1330496
milestone53.0a1
Bug 1330496 - Part 2: Remove mochitest use of MOZ_WIN_INHERIT_STD_HANDLES_PRE_VISTA. r?jmaher MozReview-Commit-ID: LX8F53hVySp
testing/mochitest/runrobocop.py
testing/mochitest/runtests.py
testing/mochitest/runtestsremote.py
testing/talos/talos/ffsetup.py
--- a/testing/mochitest/runrobocop.py
+++ b/testing/mochitest/runrobocop.py
@@ -391,18 +391,16 @@ class RobocopTestRunner(MochitestDesktop
            Return an environment dictionary suitable for remote use.
 
            This is similar to buildBrowserEnv in runtestsremote.py.
         """
         browserEnv = self.environment(
             xrePath=None,
             debugger=None)
         # remove desktop environment not used on device
-        if "MOZ_WIN_INHERIT_STD_HANDLES_PRE_VISTA" in browserEnv:
-            del browserEnv["MOZ_WIN_INHERIT_STD_HANDLES_PRE_VISTA"]
         if "XPCOM_MEM_BLOAT_LOG" in browserEnv:
             del browserEnv["XPCOM_MEM_BLOAT_LOG"]
         browserEnv["MOZ_LOG_FILE"] = os.path.join(
             self.remoteMozLog,
             self.mozLogName)
 
         try:
             browserEnv.update(
--- a/testing/mochitest/runtests.py
+++ b/testing/mochitest/runtests.py
@@ -1472,24 +1472,16 @@ toolbar#nav-bar {
             debugger=debugger,
             dmdPath=options.dmdPath,
             lsanPath=lsanPath)
 
         # These variables are necessary for correct application startup; change
         # via the commandline at your own risk.
         browserEnv["XPCOM_DEBUG_BREAK"] = "stack"
 
-        # When creating child processes on Windows pre-Vista (e.g. Windows XP) we
-        # don't normally inherit stdout/err handles, because you can only do it by
-        # inheriting all other inheritable handles as well.
-        # We need to inherit them for plain mochitests for test logging purposes, so
-        # we do so on the basis of a specific environment variable.
-        if options.flavor == 'plain':
-            browserEnv["MOZ_WIN_INHERIT_STD_HANDLES_PRE_VISTA"] = "1"
-
         # interpolate environment passed with options
         try:
             browserEnv.update(
                 dict(
                     parseKeyValue(
                         options.environment,
                         context='--setenv')))
         except KeyValueParseError as e:
--- a/testing/mochitest/runtestsremote.py
+++ b/testing/mochitest/runtestsremote.py
@@ -261,18 +261,16 @@ class MochiRemote(MochitestDesktop):
         return None
 
     def buildBrowserEnv(self, options, debugger=False):
         browserEnv = MochitestDesktop.buildBrowserEnv(
             self,
             options,
             debugger=debugger)
         # remove desktop environment not used on device
-        if "MOZ_WIN_INHERIT_STD_HANDLES_PRE_VISTA" in browserEnv:
-            del browserEnv["MOZ_WIN_INHERIT_STD_HANDLES_PRE_VISTA"]
         if "XPCOM_MEM_BLOAT_LOG" in browserEnv:
             del browserEnv["XPCOM_MEM_BLOAT_LOG"]
         # override mozLogs to avoid processing in MochitestDesktop base class
         self.mozLogs = None
         browserEnv["MOZ_LOG_FILE"] = os.path.join(
             self.remoteMozLog,
             self.mozLogName)
         return browserEnv
--- a/testing/talos/talos/ffsetup.py
+++ b/testing/talos/talos/ffsetup.py
@@ -59,19 +59,16 @@ class FFSetup(object):
         self.profile_dir = os.path.join(self._tmp_dir, 'profile')
         self.sps_profile = None
 
     def _init_env(self):
         self.env = dict(os.environ)
         for k, v in self.browser_config['env'].iteritems():
             self.env[k] = str(v)
         self.env['MOZ_CRASHREPORTER_NO_REPORT'] = '1'
-        # for winxp e10s logging:
-        # https://bugzilla.mozilla.org/show_bug.cgi?id=1037445
-        self.env['MOZ_WIN_INHERIT_STD_HANDLES_PRE_VISTA'] = '1'
         if self.browser_config['symbols_path']:
             self.env['MOZ_CRASHREPORTER'] = '1'
         else:
             self.env['MOZ_CRASHREPORTER_DISABLE'] = '1'
 
         self.env['MOZ_DISABLE_NONLOCAL_CONNECTIONS'] = '1'
 
         self.env["LD_LIBRARY_PATH"] = \