Skip to content

Commit

Permalink
src: remove NodeCategorySet destructor
Browse files Browse the repository at this point in the history
This currently crashes during environment cleanup because
the object would be torn down while there are enabled categories.

I’m not sure about the exact semantics here, but since the
object cannot be garbage collected at this point anyway
because it’s `Persistent` handle is strong, removing the
destructor at least doesn’t make anything worse than it is
right now (i.e. the destructor would never have been called
before anyway).

PR-URL: #19377
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
addaleax committed May 14, 2018
1 parent 97d939a commit 9e1dcdc
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions src/node_trace_events.cc
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,6 @@ using v8::Value;

class NodeCategorySet : public BaseObject {
public:
~NodeCategorySet() override {
// Verify that the thing was properly disabled before gc
CHECK_NE(enabled_, true);
}

static void New(const FunctionCallbackInfo<Value>& args);
static void Enable(const FunctionCallbackInfo<Value>& args);
static void Disable(const FunctionCallbackInfo<Value>& args);
Expand Down

0 comments on commit 9e1dcdc

Please sign in to comment.