Better fix for Layout Test fast/parser/external-entities-in-xslt.xml is flaky on...
authormitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 3 Feb 2016 06:14:12 +0000 (06:14 +0000)
committermitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 3 Feb 2016 06:14:12 +0000 (06:14 +0000)
https://bugs.webkit.org/show_bug.cgi?id=153683

Reviewed by Darin Adler.

* Scripts/webkitpy/port/driver.py:
(Driver._setup_environ_for_driver): Reverted change from r196013. DUMPRENDERTREE_TEMP is not
  used by any code in the Web Content process. If that ever changed, we should send it over
  as a bundle parameter.

* Scripts/webkitpy/port/ios.py:
(IOSSimulatorPort.setup_environ_for_server): Reverted change from r196013.

* Scripts/webkitpy/port/mac.py:
(MacPort.setup_environ_for_server): Ditto.

* WebKitTestRunner/InjectedBundle/ios/InjectedBundleIOS.mm:
(WTR::InjectedBundle::platformInitialize): Set XML_CATALOG_FILES in the Web Process
  environment. This is early enough that libxml2 has not been initialized yet.

* WebKitTestRunner/InjectedBundle/mac/InjectedBundleMac.mm:
(WTR::InjectedBundle::platformInitialize): Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@196048 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Tools/ChangeLog
Tools/Scripts/webkitpy/port/driver.py
Tools/Scripts/webkitpy/port/ios.py
Tools/Scripts/webkitpy/port/mac.py
Tools/WebKitTestRunner/InjectedBundle/ios/InjectedBundleIOS.mm
Tools/WebKitTestRunner/InjectedBundle/mac/InjectedBundleMac.mm

index 96ee8c5..5636004 100644 (file)
@@ -1,5 +1,30 @@
 2016-02-02  Dan Bernstein  <mitz@apple.com>
 
+        Better fix for Layout Test fast/parser/external-entities-in-xslt.xml is flaky on El Capitan (but fails most of the time)
+        https://bugs.webkit.org/show_bug.cgi?id=153683
+
+        Reviewed by Darin Adler.
+
+        * Scripts/webkitpy/port/driver.py:
+        (Driver._setup_environ_for_driver): Reverted change from r196013. DUMPRENDERTREE_TEMP is not
+          used by any code in the Web Content process. If that ever changed, we should send it over
+          as a bundle parameter.
+
+        * Scripts/webkitpy/port/ios.py:
+        (IOSSimulatorPort.setup_environ_for_server): Reverted change from r196013.
+
+        * Scripts/webkitpy/port/mac.py:
+        (MacPort.setup_environ_for_server): Ditto.
+
+        * WebKitTestRunner/InjectedBundle/ios/InjectedBundleIOS.mm:
+        (WTR::InjectedBundle::platformInitialize): Set XML_CATALOG_FILES in the Web Process
+          environment. This is early enough that libxml2 has not been initialized yet.
+
+        * WebKitTestRunner/InjectedBundle/mac/InjectedBundleMac.mm:
+        (WTR::InjectedBundle::platformInitialize): Ditto.
+
+2016-02-02  Dan Bernstein  <mitz@apple.com>
+
         Layout Test fast/parser/external-entities-in-xslt.xml is flaky on El Capitan (but fails most of the time)
         https://bugs.webkit.org/show_bug.cgi?id=153683
 
index e369ee4..44a745e 100644 (file)
@@ -321,7 +321,6 @@ class Driver(object):
         environment['DIRHELPER_USER_DIR_SUFFIX'] = str(os.path.basename(str(self._driver_tempdir)))
         # Put certain normally persistent files into the temp directory (e.g. IndexedDB storage).
         environment['DUMPRENDERTREE_TEMP'] = str(self._driver_tempdir)
-        environment['__XPC_DUMPRENDERTREE_TEMP'] = environment['DUMPRENDERTREE_TEMP']
         environment['LOCAL_RESOURCE_ROOT'] = str(self._port.layout_tests_dir())
         environment['ASAN_OPTIONS'] = "allocator_may_return_null=1"
         environment['__XPC_ASAN_OPTIONS'] = environment['ASAN_OPTIONS']
index 2a822a7..d33bb2c 100644 (file)
@@ -271,9 +271,7 @@ class IOSSimulatorPort(Port):
                 self._append_value_colon_separated(env, 'DYLD_INSERT_LIBRARIES', '/usr/lib/libgmalloc.dylib')
                 self._append_value_colon_separated(env, '__XPC_DYLD_INSERT_LIBRARIES', '/usr/lib/libgmalloc.dylib')
             self._append_value_colon_separated(env, 'DYLD_INSERT_LIBRARIES', self._build_path("libWebCoreTestShim.dylib"))
-        # work around missing /etc/catalog <rdar://problem/4292995>
-        env['XML_CATALOG_FILES'] = ''
-        env['__XPC_XML_CATALOG_FILES'] = ''
+        env['XML_CATALOG_FILES'] = ''  # work around missing /etc/catalog <rdar://problem/4292995>
         return env
 
     def operating_system(self):
index a7f9fba..f5bb9d7 100644 (file)
@@ -106,9 +106,7 @@ class MacPort(ApplePort):
                 self._append_value_colon_separated(env, 'DYLD_INSERT_LIBRARIES', '/usr/lib/libgmalloc.dylib')
                 self._append_value_colon_separated(env, '__XPC_DYLD_INSERT_LIBRARIES', '/usr/lib/libgmalloc.dylib')
             self._append_value_colon_separated(env, 'DYLD_INSERT_LIBRARIES', self._build_path("libWebCoreTestShim.dylib"))
-        # work around missing /etc/catalog <rdar://problem/4292995>
-        env['XML_CATALOG_FILES'] = ''
-        env['__XPC_XML_CATALOG_FILES'] = ''
+        env['XML_CATALOG_FILES'] = ''  # work around missing /etc/catalog <rdar://problem/4292995>
         return env
 
     def _clear_global_caches_and_temporary_files(self):
index 030f905..269318b 100644 (file)
@@ -35,6 +35,9 @@ namespace WTR {
 
 void InjectedBundle::platformInitialize(WKTypeRef)
 {
+    // Work around missing /etc/catalog <rdar://problem/4292995>.
+    setenv("XML_CATALOG_FILES", "", 0);
+
     // Language was set up earlier in main(). Don't clobber it.
     NSArray *languages = [[[NSUserDefaults standardUserDefaults] volatileDomainForName:NSArgumentDomain] valueForKey:@"AppleLanguages"];
 
index d812b25..375fa9d 100644 (file)
@@ -42,6 +42,9 @@ void InjectedBundle::platformInitialize(WKTypeRef)
     static const int NoFontSmoothing = 0;
     static const int BlueTintedAppearance = 1;
 
+    // Work around missing /etc/catalog <rdar://problem/4292995>.
+    setenv("XML_CATALOG_FILES", "", 0);
+
     // Language was set up earlier in main(). Don't clobber it.
     NSArray *languages = [[[NSUserDefaults standardUserDefaults] volatileDomainForName:NSArgumentDomain] valueForKey:@"AppleLanguages"];
     if (!languages)