devtools: Pass steppingType to onPop hook (#43995)

Fixes crashes when stepping in certain situations.

Testing: Ran `mach test-devtools` and manual testing
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
This commit is contained in:
eri
2026-04-07 11:57:20 +02:00
committed by GitHub
parent 88a08d775c
commit 4f13fcc38d

View File

@@ -410,7 +410,9 @@ function makeSteppingHooks(steppingType, startFrame) {
this.reportedPop = true;
suspendedFrame = startFrame;
if (steppingType !== "finish") {
return handlePauseAndRespond(startFrame, completion);
// TODO: completion contains the return value, we have to send it back
// <https://searchfox.org/firefox-main/source/devtools/server/actors/thread.js#1026>
return handlePauseAndRespond(startFrame, { type_: steppingType });
}
attachSteppingHooks("next", startFrame);
},