Bug 1393692 (part 2) - Fix forcedCharset assignment. r=jorgk
authorNicholas Nethercote <nnethercote@mozilla.com>
Fri, 25 Aug 2017 16:38:11 +1000
changeset 22041 40598e80284974c52925d38b04031c54783e0adc
parent 22040 ac14ca6da23824d04c49339e1dc2f913babdbac5
child 22042 351c858c276cde469744e36303ce3e82fb20f8bd
push id13454
push usermozilla@jorgk.com
push dateFri, 25 Aug 2017 20:03:46 +0000
treeherdercomm-central@0a3658e44fd7 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjorgk
bugs1393692
Bug 1393692 (part 2) - Fix forcedCharset assignment. r=jorgk nsIDocShell.forcedCharset is an `ACString` attribute. viewlog.js currently assigns it an atom. This patch changes it to a string. (It's likely this code is unused, because it was clearly broken: mAtomService is not mentioned anywhere else in the code.)
im/content/viewlog.js
--- a/im/content/viewlog.js
+++ b/im/content/viewlog.js
@@ -98,18 +98,17 @@ var logWindow = {
       });
     }
     else {
       // Legacy text log.
       deck.selectedIndex = 0;
       let browser = document.getElementById("text-browser");
       findbar.browser = browser;
       FullZoom.applyPrefValue();
-      browser.docShell.forcedCharset =
-        browser.mAtomService.getAtom("UTF-8");
+      browser.docShell.forcedCharset = "UTF-8";
       let file = Cc["@mozilla.org/file/local;1"].createInstance(Ci.nsIFile);
       file.initWithPath(log.path);
       browser.loadURI(Services.io.newFileURI(file).spec);
     }
   },
 
   _colorCache: {},
   // Duplicated code from conversation.xml :-(