Fix botched backout (bug 1524687). r=bustage
authorKris Maglione <maglione.k@gmail.com>
Thu, 14 Feb 2019 17:54:00 -0800
changeset 517406 7436c0f5b8b1
parent 517405 7fdcdef43871
child 517407 bf8e35be76d8
push id10862
push userffxbld-merge
push dateMon, 11 Mar 2019 13:01:11 +0000
treeherdermozilla-beta@a2e7f5c935da [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbustage
bugs1524687
milestone67.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Fix botched backout (bug 1524687). r=bustage
dom/presentation/tests/xpcshell/test_multicast_dns_device_provider.js
netwerk/dns/mdns/libmdns/moz.build
--- a/dom/presentation/tests/xpcshell/test_multicast_dns_device_provider.js
+++ b/dom/presentation/tests/xpcshell/test_multicast_dns_device_provider.js
@@ -95,17 +95,17 @@ ContractHook.prototype = {
   reset() {},
 
   cleanup() {
     this.reset();
 
     this.unregister();
     let prevContract = this.hookedMap.get(this._contractID).pop();
 
-    if (prevContract.factory) {
+    if (prevContract.classID) {
       registrar.registerFactory(prevContract.classID,
                                 "",
                                 this._contractID,
                                 prevContract.factory);
     }
   },
 
   unregister() {
@@ -115,17 +115,21 @@ ContractHook.prototype = {
       classID = registrar.contractIDToCID(this._contractID);
       factory = Cm.getClassObject(Cc[this._contractID], Ci.nsIFactory);
     } catch (ex) {
       classID = "";
       factory = null;
     }
 
     if (factory) {
-      registrar.unregisterFactory(classID, factory);
+      try {
+        registrar.unregisterFactory(classID, factory);
+      } catch (e) {
+        factory = null;
+      }
     }
 
     return { classID, factory };
   },
 };
 
 function MockDNSServiceInfo() {}
 MockDNSServiceInfo.prototype = {
--- a/netwerk/dns/mdns/libmdns/moz.build
+++ b/netwerk/dns/mdns/libmdns/moz.build
@@ -22,20 +22,16 @@ else:
         'fallback/DataWriter.jsm',
         'fallback/DNSPacket.jsm',
         'fallback/DNSRecord.jsm',
         'fallback/DNSResourceRecord.jsm',
         'fallback/DNSTypes.jsm',
         'fallback/MulticastDNS.jsm',
     ]
 
-    XPCOM_MANIFESTS += [
-        'components.conf',
-    ]
-
     if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'android':
         EXTRA_JS_MODULES += [
             'MulticastDNSAndroid.jsm',
         ]
 
 UNIFIED_SOURCES += [
     'nsDNSServiceInfo.cpp',
     'nsMulticastDNSModule.cpp',