X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fmodbus.c;h=08871a25732f60ab7bc5ef9c67fe248a303ecd48;hb=26314b8c3fb08e1f0017ee9a6277b7fe370bf2a0;hp=25aa7e2e5f80b614f9cc49a4b51106051827b5bf;hpb=09c6a320f3cb36b5dbb2c2ce43858f33be7acf9b;p=collectd.git diff --git a/src/modbus.c b/src/modbus.c index 25aa7e2e..08871a25 100644 --- a/src/modbus.c +++ b/src/modbus.c @@ -27,7 +27,7 @@ #include -#include +#include #ifndef LIBMODBUS_VERSION_CHECK /* Assume version 2.0.3 */ @@ -426,7 +426,7 @@ static int mb_read_data (mb_host_t *host, mb_slave_t *slave, /* {{{ */ uint16_t values[2]; int values_num; const data_set_t *ds; - int status; + int status = 0; if ((host == NULL) || (slave == NULL) || (data == NULL)) return (EINVAL);