From 57e301539bff2599974b7269a56377330c9b730e Mon Sep 17 00:00:00 2001 From: Anna Henningsen Date: Sun, 10 Jun 2018 16:40:13 +0200 Subject: src: enable more detailed memory tracking This will enable more detailed heap snapshots based on a newer V8 API. This commit itself is not tied to that API and could be backported. PR-URL: https://github.com/nodejs/node/pull/21742 Reviewed-By: James M Snell --- src/timer_wrap.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/timer_wrap.cc') diff --git a/src/timer_wrap.cc b/src/timer_wrap.cc index 9da209bef4..c3962e83ee 100644 --- a/src/timer_wrap.cc +++ b/src/timer_wrap.cc @@ -67,7 +67,9 @@ class TimerWrap : public HandleWrap { ->GetFunction(env->context()).ToLocalChecked()).FromJust(); } - size_t self_size() const override { return sizeof(*this); } + void MemoryInfo(MemoryTracker* tracker) const override { + tracker->TrackThis(this); + } private: static void SetupTimers(const FunctionCallbackInfo& args) { -- cgit v1.2.1