diff --git a/src/modbus-rtu.c b/src/modbus-rtu.c index acbbaad..976620f 100644 --- a/src/modbus-rtu.c +++ b/src/modbus-rtu.c @@ -20,6 +20,7 @@ #include #include #include +#include #include "modbus.h" #include "modbus-private.h" @@ -250,6 +251,8 @@ ssize_t _modbus_rtu_recv(modbus_t *ctx, uint8_t *rsp, int rsp_length) #endif } +int _modbus_rtu_flush(modbus_t *); + /* The check_crc16 function shall return the message length if the CRC is valid. Otherwise it shall return -1 and set errno to EMBADCRC. */ int _modbus_rtu_check_integrity(modbus_t *ctx, uint8_t *msg, diff --git a/src/modbus-tcp.c b/src/modbus-tcp.c index 7d7e75a..a142b3b 100644 --- a/src/modbus-tcp.c +++ b/src/modbus-tcp.c @@ -22,6 +22,7 @@ #include #include #include +#include #include #ifdef NATIVE_WIN32