Skip to content

Commit 4417f99

Browse files
targosAli Sheikh
authored and
Ali Sheikh
committed
src: replace usage of deprecated SetMessageHandler
PR-URL: #5159 Reviewed-By: Ben Noordhuis <[email protected]>
1 parent 8894f27 commit 4417f99

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/debug-agent.cc

+2-2
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ bool Agent::Start(int port, bool wait) {
120120

121121

122122
void Agent::Enable() {
123-
v8::Debug::SetMessageHandler(MessageHandler);
123+
v8::Debug::SetMessageHandler(parent_env()->isolate(), MessageHandler);
124124

125125
// Assign environment to the debugger's context
126126
// NOTE: The debugger context is created after `SetMessageHandler()` call
@@ -135,7 +135,7 @@ void Agent::Stop() {
135135
return;
136136
}
137137

138-
v8::Debug::SetMessageHandler(nullptr);
138+
v8::Debug::SetMessageHandler(parent_env()->isolate(), nullptr);
139139

140140
// Send empty message to terminate things
141141
EnqueueMessage(new AgentMessage(nullptr, 0));

0 commit comments

Comments
 (0)