[Pkg-mozext-commits] [firebug] 34/56: Remove work-around for bug 982153 in >= Fx36

David Prévot taffit at moszumanska.debian.org
Wed Nov 19 21:01:44 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository firebug.

commit a6de0e987595a22fb1f81ddecbed1a46e1e696aa
Author: Simon Lindholm <simon.lindholm10 at gmail.com>
Date:   Mon Oct 27 18:19:07 2014 +0100

    Remove work-around for bug 982153 in >= Fx36
---
 extension/content/firebug/debugger/script/sourceTool.js | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/extension/content/firebug/debugger/script/sourceTool.js b/extension/content/firebug/debugger/script/sourceTool.js
index 077a212..d289d0f 100644
--- a/extension/content/firebug/debugger/script/sourceTool.js
+++ b/extension/content/firebug/debugger/script/sourceTool.js
@@ -59,6 +59,7 @@ var versionComparator = Cc["@mozilla.org/xpcom/version-comparator;1"]
     .getService(Ci.nsIVersionComparator);
 var fx30 = (versionComparator.compare(appInfo.version, "30a1") >= 0 &&
     versionComparator.compare(appInfo.version, "30.*") <= 0);
+var fx35OrEarlier = (versionComparator.compare(appInfo.version, "36a1") < 0);
 
 var dynamicTypesMap = {
     "eval": CompilationUnit.EVAL,
@@ -614,13 +615,13 @@ function buildStackFrame(frame, context)
         // Use proper (dynamically generated) URL.
         stackFrame.href = sourceFile.href;
 
-        // xxxHonza: line numbers seem to be wrong for 'scriptElement' scripts,
-        // but only for those that are injected into the page using textContent
+        // Prior to Firefox 36, line numbers were wrong for dynamically injected
+        // 'scriptElement' scripts that don't refer to an external resource, e.g.:
         // var script = document.createElement("script");
         // script.textContent = source;
         // document.body.appendChild(scriptTag);
-        // https://bugzilla.mozilla.org/show_bug.cgi?id=982153
-        if (script.source.introductionType == "scriptElement")
+        // See https://bugzilla.mozilla.org/show_bug.cgi?id=982153.
+        if (fx35OrEarlier && script.source.introductionType == "scriptElement")
         {
             var element = DebuggerLib.unwrapDebuggeeValue(script.source.element);
             var src = element.getAttribute("src");

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/firebug.git



More information about the Pkg-mozext-commits mailing list