Signed-off-by: Florian Forster <octo@huhu.verplant.org>
struct timespec ts_int;
hostlist_t *hl;
struct timespec ts_int;
hostlist_t *hl;
pthread_mutex_lock (&ping_lock);
pthread_mutex_lock (&ping_lock);
ping_setopt (pingobj, PING_OPT_TTL, (void *) &ping_ttl);
/* Add all the hosts to the ping object. */
ping_setopt (pingobj, PING_OPT_TTL, (void *) &ping_ttl);
/* Add all the hosts to the ping object. */
for (hl = hostlist_head; hl != NULL; hl = hl->next)
{
for (hl = hostlist_head; hl != NULL; hl = hl->next)
{
- int tmp_status;
- tmp_status = ping_host_add (pingobj, hl->host);
- if (tmp_status != 0)
+ int status;
+ status = ping_host_add (pingobj, hl->host);
+ if (status != 0)
WARNING ("ping plugin: ping_host_add (%s) failed.", hl->host);
else
WARNING ("ping plugin: ping_host_add (%s) failed.", hl->host);
else
{
ERROR ("ping plugin: No host could be added to ping object. Giving up.");
ping_thread_error = 1;
{
ERROR ("ping plugin: No host could be added to ping object. Giving up.");
ping_thread_error = 1;