diff --git a/src/modules/resource/acquire.c b/src/modules/resource/acquire.c index 785c04cd6f46..1642c6027594 100644 --- a/src/modules/resource/acquire.c +++ b/src/modules/resource/acquire.c @@ -379,6 +379,7 @@ void acquire_destroy (struct acquire *acquire) if (acquire) { int saved_errno = errno; flux_msg_handler_delvec (acquire->handlers); + reslog_set_callback (acquire->ctx->reslog, NULL, NULL); if (acquire->request) { if (flux_respond_error (acquire->ctx->h, acquire->request->msg, diff --git a/src/modules/resource/discover.c b/src/modules/resource/discover.c index 63bbf636301a..27a56a0662ae 100644 --- a/src/modules/resource/discover.c +++ b/src/modules/resource/discover.c @@ -278,6 +278,7 @@ void discover_destroy (struct discover *discover) { if (discover) { int saved_errno = errno; + monitor_set_callback (discover->ctx->monitor, NULL, NULL); flux_subprocess_destroy (discover->p); flux_future_destroy (discover->f); flux_msg_handler_delvec (discover->handlers);