summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoryurys@google.com <yurys@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-04-09 17:30:10 +0000
committeryurys@google.com <yurys@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-04-09 17:30:10 +0000
commitddbab02846a8ffda0b54d7c5c877383869b6261e (patch)
tree2cd741fb3d15398a95d145e5e66311f14d39209f
parent2586294b13b0d4b08d348ed2853d91654ce35b29 (diff)
downloadchromium_src-ddbab02846a8ffda0b54d7c5c877383869b6261e.zip
chromium_src-ddbab02846a8ffda0b54d7c5c877383869b6261e.tar.gz
chromium_src-ddbab02846a8ffda0b54d7c5c877383869b6261e.tar.bz2
Read script ids for call stack frames from 'backtrace' response.
This change depends on v8 change http://codereview.chromium.org/65006/show Review URL: http://codereview.chromium.org/65007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13430 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--webkit/glue/devtools/js/debugger_agent.js9
1 files changed, 8 insertions, 1 deletions
diff --git a/webkit/glue/devtools/js/debugger_agent.js b/webkit/glue/devtools/js/debugger_agent.js
index fe9e72b..84ae57e 100644
--- a/webkit/glue/devtools/js/debugger_agent.js
+++ b/webkit/glue/devtools/js/debugger_agent.js
@@ -364,6 +364,13 @@ devtools.DebuggerAgent.prototype.handleBacktraceResponse_ = function(msg) {
* the format expected by ScriptsPanel and its panes.
*/
devtools.DebuggerAgent.formatCallFrame_ = function(stackFrame, script, msg) {
+ var sourceId = script.id;
+ var func = msg.lookup(stackFrame.func.ref);
+ var funcScript = msg.lookup(func.script.ref);
+ if (funcScript && 'id' in funcScript) {
+ sourceId = funcScript.id;
+ }
+
var funcName = devtools.DebuggerAgent.formatFunction_(stackFrame, msg);
var scope = {};
@@ -379,7 +386,7 @@ devtools.DebuggerAgent.formatCallFrame_ = function(stackFrame, script, msg) {
scope['this'] = devtools.DebuggerAgent.formatObject_(thisObject, msg);
return {
- 'sourceID': script.id,
+ 'sourceID': sourceId,
'line': stackFrame.line - script.lineOffset +1,
'type': 'function',
'functionName': funcName, //stackFrame.text,