DEBUG(0,("Got sig[%d] terminate (is_parent=%d)\n",
signum, (int)*is_parent));
+
+ /* if the parent killed us due to a timeout log where we were */
+ if (signum == SIGXCPU) {
+ log_stack_trace_with_level(1);
+ }
+
terminate(*is_parent);
}
return false;
}
+ se = tevent_add_signal(winbind_event_context(),
+ is_parent,
+ SIGXCPU, 0,
+ winbindd_sig_term_handler,
+ is_parent);
+ if (!se) {
+ DEBUG(0,("failed to setup SIGXCPU handler"));
+ talloc_free(is_parent);
+ return false;
+ }
return true;
}
BlockSignals(False, SIGUSR2);
BlockSignals(False, SIGHUP);
BlockSignals(False, SIGCHLD);
+ BlockSignals(False, SIGXCPU);
if (!interactive)
become_daemon(Fork, no_process_group);