X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fipmi.c;h=f23601eaede6cc98bb139f80c21e3f112cfbe484;hb=9c3ed6462c15fd1cb664cd0ec2a5efb289aa1af6;hp=c631574d982fa462ecc13615d9e18c03a2eda604;hpb=a5177bd853eedbe69d87869316093a0e9526e931;p=collectd.git diff --git a/src/ipmi.c b/src/ipmi.c index c631574d..f23601ea 100644 --- a/src/ipmi.c +++ b/src/ipmi.c @@ -557,7 +557,7 @@ static int thread_init (os_handler_t **ret_os_handler) ipmi_domain_id_t domain_id; int status; - os_handler = ipmi_posix_thread_setup_os_handler (SIGUSR2); + os_handler = ipmi_posix_thread_setup_os_handler (SIGIO); if (os_handler == NULL) { ERROR ("ipmi plugin: ipmi_posix_thread_setup_os_handler failed."); @@ -664,11 +664,12 @@ static int c_ipmi_init (void) int status; /* Don't send `ADD' notifications during startup (~ 1 minute) */ - c_ipmi_init_in_progress = 1 + (60 / interval_g); + time_t iv = CDTIME_T_TO_TIME_T (plugin_get_interval ()); + c_ipmi_init_in_progress = 1 + (60 / iv); c_ipmi_active = 1; - status = pthread_create (&thread_id, /* attr = */ NULL, thread_main, + status = plugin_thread_create (&thread_id, /* attr = */ NULL, thread_main, /* user data = */ NULL); if (status != 0) {