summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 31ec341)
raw | patch | inline | side by side (parent: 31ec341)
author | Florian Forster <octo@collectd.org> | |
Sun, 19 Feb 2012 11:42:57 +0000 (12:42 +0100) | ||
committer | Florian Forster <octo@collectd.org> | |
Sun, 19 Feb 2012 11:42:57 +0000 (12:42 +0100) |
Since "interval_g" was changed to "cdtime_t", the plugin would sleep 2^30 times
as long as intended. D'oh! Thanks to Xavier for reporting this!
Change-Id: I8e9992307a1fdbb2df799a5359eb6695409684df
as long as intended. D'oh! Thanks to Xavier for reporting this!
Change-Id: I8e9992307a1fdbb2df799a5359eb6695409684df
src/amqp.c | patch | blob | history |
diff --git a/src/amqp.c b/src/amqp.c
index f0abd44b461a38c5c7fade0b1e96b92f11897ec7..55eba670bc712f195ee7b6117f8dc98d72db5d8a 100644 (file)
--- a/src/amqp.c
+++ b/src/amqp.c
if (status != 0)
{
ERROR ("amqp plugin: camqp_connect failed. "
- "Will sleep for %i seconds.", interval_g);
- sleep (interval_g);
+ "Will sleep for %u seconds.",
+ (unsigned int) CDTIME_T_TO_TIME_T (interval_g));
+ sleep ((unsigned int) CDTIME_T_TO_TIME_T (interval_g));
continue;
}
if (status < 0)
{
ERROR ("amqp plugin: amqp_simple_wait_frame failed. "
- "Will sleep for %i seconds.", interval_g);
+ "Will sleep for %u seconds.",
+ (unsigned int) CDTIME_T_TO_TIME_T (interval_g));
camqp_close_connection (conf);
- sleep (interval_g);
+ sleep ((unsigned int) CDTIME_T_TO_TIME_T (interval_g));
continue;
}