Commit 09a5c855 authored by Kim-Anh Tran's avatar Kim-Anh Tran Committed by Commit Bot

[wasm][debug] Keep breakpointIdToDebuggerBreakpointIds alive on reload

Until now the breakpointIdToDebuggerBreakpointIds was cleared on page
reload. It keeps a map from breakpointIds to debuggerBreakpointIds,
with the latter being necessary for removing breakpoints.

If a breakpoint is set and we trigger a page reload, the
information about that breakpoint will be removed from the map,
even if it still exists. If we later want to remove the breakpoint
we look into the map, but the meta data is no longer existing.

Thus, reloading the page again will lead to hitting the breakpoint,
even if we removed it in the front-end.

This change keeps the map alive on page reset, so that we still
keep track of set breakpoints after a page reload.

Bug: chromium:1073071
Change-Id: I82192777bac7afc406245a5a1cff0620e8174499
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2253842Reviewed-by: 's avatarClemens Backes <clemensb@chromium.org>
Reviewed-by: 's avatarYang Guo <yangguo@chromium.org>
Commit-Queue: Kim-Anh Tran <kimanh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#68433}
parent f510c66b
......@@ -1840,7 +1840,6 @@ void V8DebuggerAgentImpl::reset() {
m_scripts.clear();
m_cachedScriptIds.clear();
m_cachedScriptSize = 0;
m_breakpointIdToDebuggerBreakpointIds.clear();
}
void V8DebuggerAgentImpl::ScriptCollected(const V8DebuggerScript* script) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment