diff options
-rw-r--r-- | src/monitor/monitor.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/monitor/monitor.c b/src/monitor/monitor.c index 4c0c22ce9..a99cdfe87 100644 --- a/src/monitor/monitor.c +++ b/src/monitor/monitor.c @@ -2626,9 +2626,11 @@ static void mt_svc_exit_handler(int pid, int wait_status, void *pvt) tv = tevent_timeval_current_ofs(restart_delay, 0); te = tevent_add_timer(svc->mt_ctx->ev, svc, tv, mt_svc_restart, svc); - if (!te) { + if (te == NULL) { /* Nothing much we can do */ - DEBUG(SSSDBG_CRIT_FAILURE, ("Out of memory?!\n")); + DEBUG(SSSDBG_CRIT_FAILURE, + ("Failed to allocate timed event: mt_svc_restart.\n")); + talloc_free(svc); return; } } |