From 07ddcb3052fa2d6c52bde62aa1abab5769ed307a Mon Sep 17 00:00:00 2001 From: Jameson Nash Date: Thu, 16 Jan 2020 17:36:36 -0500 Subject: [PATCH] osx,fsevent: clear pointer when deleting it [NFCI] MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Set this to NULL just before disposing it to make mistakes more painfully obvious, hopefully. PR-URL: https://github.com/libuv/libuv/pull/2626 Reviewed-By: Ben Noordhuis Reviewed-By: Saúl Ibarra Corretgé --- src/unix/fsevents.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/unix/fsevents.c b/src/unix/fsevents.c index ec90d46a..448921f8 100644 --- a/src/unix/fsevents.c +++ b/src/unix/fsevents.c @@ -747,6 +747,8 @@ static void* uv__cf_loop_runner(void* arg) { state->signal_source, *pkCFRunLoopDefaultMode); + state->loop = NULL; + return NULL; }