-
This fixes the message "error: 'for' loop initial declarations are only allowed in C99 mode", spotted during cross-compiling of libmodbus. The compiler (gcc) actually does support -std=c99 but it gets not enabled by default. So a solution would be to enforce c99 mode via CFLAGS, but this will knock out all compilers which do not support this mode. Moving the declaration out of the loop initialisation, seems to be the simpler solution. Signed-off-by: Michael Heimpold <mhei@heimpold.de>
-
Function modbus_receive_from has no implementation in the library and is not used anywhere.
-
It concerns only the files in 'tests' directory.
-
Protects against crafted write requests with a large quantity but a small byte count. If address + quantity was in the mapping space of the server and quantity greater than the response size, it was possible to crash the server. The sleep/flush sequence improves the handling of following requests.
-
Thank you MarjanTomas and SwissKnife.
-
Thank you Petr Gladkiy and MarjanTomas. Sorry for the delay...
-
From Michael Heimpold: Just a nitpick: the INADDR_* macros are defined in host byte order, compare INADDR_LOOPBACK. So it would be reasonable to wrap this with htonl(INADDR_ANY). However, every experienced socket programmer should know that INADDR_ANY equals 0.0.0.0, passing it through htonl does not have any effect.
-
- protect against NULL IP address BTW - update documentation
-
- allow an empty string or NULL for node argument - protect against NULL in service argument - new test for NULL service - update documentation
-
Thanks to vgrin for the report
-
It's never too late to remove 261 lines of code ;)
-
Thanks to Marjan Tomas
-
Thanks to Marjan Tomas
-
Thank you Marjan Tomas.
-
Thanks to MarjanTomas.
-
Change API of function for libmodbus v3.2.0
-
Thanks to Perry Kundert for bug report and initial patches.
-
The report slave id function returns the number of bytes as the _return_ value, and does not include it as the first byte in the dest buffer. Update documentation to reflect reality. There's no missing functionality, just slightly confusing documentation.
-
- add byte timeout tests (TCP backend only) - update and improve documentation - long timeout values are now uint32_t so it changes the API to disable byte timeout
-
Thank you AlexMaz.