Also revert the inclusion of <stdbool.h> as per our coding guidelines.
The native C99 _Bool is used instead.
* Florian octo Forster <octo at collectd.org>
**/
-#include <stdbool.h>
#include "collectd.h"
#include "common.h"
#include "plugin.h"
{
struct VSM_data *vd;
const c_varnish_stats_t *stats;
- bool test;
+ _Bool ok;
user_config_t *conf;
}
#if HAVE_VARNISH_V3
- test = VSC_Open (vd, /* diag = */ 1);
+ ok = (VSC_Open (vd, /* diag = */ 1) == 0);
#else /* if HAVE_VARNISH_V4 */
- test = VSM_Open (vd);
+ ok = (VSM_Open (vd) == 0);
#endif
- if (test)
+ if (!ok)
{
VSM_Delete (vd);
ERROR ("varnish plugin: Unable to open connection.");