mirror of
https://github.com/nodejs/node.git
synced 2026-11-09 15:11:11 -05:00
Add IsNearDeath assertion to ObjectWrap destructor
This commit is contained in:
1 parent
56c785ceae
commit
edbae656d6
1 file changed
+1
@@ -15,6 +15,7 @@ class ObjectWrap {
|
||||
|
||||
virtual ~ObjectWrap ( ) {
|
||||
if (!handle_.IsEmpty()) {
|
||||
assert(handle_.IsNearDeath());
|
||||
handle_->SetInternalField(0, v8::Undefined());
|
||||
handle_.Dispose();
|
||||
handle_.Clear();
|
||||
|
||||
Reference in new issue
Block a user