use temporary handlescope to deinit inspector

This commit is contained in:
Pierre Tachoire
2026-01-09 11:25:34 +01:00
parent 78ebd5faf8
commit f57cf1be75

View File

@@ -63,6 +63,10 @@ pub fn init(allocator: Allocator, isolate: v8.Isolate, ctx: anytype) !Inspector
} }
pub fn deinit(self: *const Inspector) void { pub fn deinit(self: *const Inspector) void {
var temp_scope: v8.HandleScope = undefined;
v8.HandleScope.init(&temp_scope, self.isolate);
defer temp_scope.deinit();
self.session.deinit(); self.session.deinit();
self.inner.deinit(); self.inner.deinit();
} }