Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(499)

Unified Diff: third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp

Issue 2116563003: [DevTools] Report unhandled exceptions and promise rejections through Runtime. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tests pass Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp
diff --git a/third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp b/third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp
index 687ba7ea4e08e5fd507fb48d00b86e54d6c37d5e..ad79801a909db619315e95e7ac1339a8bd879dd7 100644
--- a/third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp
+++ b/third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp
@@ -123,6 +123,11 @@ void MainThreadDebugger::contextWillBeDestroyed(ScriptState* scriptState)
debugger()->contextDestroyed(scriptState->context());
}
+void MainThreadDebugger::exceptionUnhandled(LocalFrame* frame, const String& errorMessage, std::unique_ptr<SourceLocation> location)
+{
+ debugger()->exceptionUnhandled(contextGroupId(frame), errorMessage, location->url(), location->lineNumber(), location->columnNumber(), location->cloneStackTrace(), location->scriptId());
+}
+
int MainThreadDebugger::contextGroupId(LocalFrame* frame)
{
LocalFrame* localFrameRoot = frame->localFrameRoot();

Powered by Google App Engine
This is Rietveld 408576698