Make SA_RESETHAND conditional on its existance.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Mon Aug 1 22:03:45 CEST 2011 on sn-devel-104
#include <setjmp.h>
#endif
-#ifndef SA_RESETHAND
-#define SA_RESETHAND SA_ONESHOT
-#endif
-
#if !defined(HAVE_SIG_ATOMIC_T_TYPE)
typedef int sig_atomic_t;
#endif
#ifdef SA_RESTART
se1 = event_add_signal(ev_ctx, ev_ctx, SIGALRM, SA_RESTART, count_handler, &alarm_count);
#endif
+#ifdef SA_RESETHAND
se2 = event_add_signal(ev_ctx, ev_ctx, SIGALRM, SA_RESETHAND, count_handler, &alarm_count);
+#endif
#ifdef SA_SIGINFO
se3 = event_add_signal(ev_ctx, ev_ctx, SIGUSR1, SA_SIGINFO, count_handler, &info_count);
#endif
(void*)&sig_state->sig_info[i][ofs],
se->private_data);
}
+#ifdef SA_RESETHAND
if (se->sa_flags & SA_RESETHAND) {
talloc_free(se);
}
+#endif
continue;
}
#endif
se->handler(ev, se, i, count, NULL, se->private_data);
+#ifdef SA_RESETHAND
if (se->sa_flags & SA_RESETHAND) {
talloc_free(se);
}
+#endif
}
#ifdef SA_SIGINFO