Web Inspector: fix exception when hovering over bound function in heap profiler.
authorpodivilov@chromium.org <podivilov@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 16 Mar 2012 16:49:45 +0000 (16:49 +0000)
committerpodivilov@chromium.org <podivilov@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 16 Mar 2012 16:49:45 +0000 (16:49 +0000)
https://bugs.webkit.org/show_bug.cgi?id=81362

Reviewed by Yury Semikhatsky.

* inspector/front-end/DebuggerPresentationModel.js:
(WebInspector.DebuggerPresentationModel.Linkifier.prototype.linkifyRawLocation):

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

Source/WebCore/ChangeLog
Source/WebCore/inspector/front-end/DebuggerPresentationModel.js

index 9f56abccc0c8139a0fc26198d494c598076535df..0c430232799355376a34cf37cf8467a9268a5f68 100644 (file)
@@ -1,3 +1,13 @@
+2012-03-16  Pavel Podivilov  <podivilov@chromium.org>
+
+        Web Inspector: fix exception when hovering over bound function in heap profiler.
+        https://bugs.webkit.org/show_bug.cgi?id=81362
+
+        Reviewed by Yury Semikhatsky.
+
+        * inspector/front-end/DebuggerPresentationModel.js:
+        (WebInspector.DebuggerPresentationModel.Linkifier.prototype.linkifyRawLocation):
+
 2012-03-16  Yoshifumi Inoue  <yosin@chromium.org>
 
         [Forms] The "progress" element should not be a form-associated element.
index 4f865aa1bbf851866584c11c815849e70beeab2b..41161bfd5806ae259f3aa1eedae32338f9487471 100644 (file)
@@ -877,6 +877,8 @@ WebInspector.DebuggerPresentationModel.Linkifier.prototype = {
      */
     linkifyRawLocation: function(rawLocation, classes)
     {
+        if (!WebInspector.debuggerModel.scriptForSourceID(rawLocation.scriptId))
+            return null;
         var anchor = WebInspector.linkifyURLAsNode("", "", classes, false);
         var liveLocation = this._model.createLiveLocation(rawLocation, this._updateAnchor.bind(this, anchor));
         liveLocation.init();