-
When compiling with gcc and option -Wconversion it fixes the warning message warning: conversion from ‘X’ {aka ‘x’} to ‘Y’ {aka ‘y’} may change value Signed-off-by: José Bollo <jose.bollo@iot.bzh>
-
In case resulting value should be negative it is incorrect to use '+' operator to construct it from pieces, because highest bytes will result in negative number after bitwise shift while others will stay positive. Replacing addition with '|' should solve the issue.
-
Since SPDX release 3.0 LGPL-2.1+ became LGPL-2.1-or-later. Hence replace the deprecated identifiers.
-
I can't believe I committed that copy/paste mistake. Sorry Maor Vermucht and Or Peles, excepted naming your original patch was OK. Thank you Karl Palsson for your review.
-
Closes #461
-
This patch was contributed by Maor Vermucht and Or Peles from VDOO Connected Trust.
-
Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
-
Thanks to @JCWren
-
I hope this was the correct place to fix it. I don't know asciidoc.
-
Found with the help of clang-format (from another branch)
-
According to the Modbus standard, the unit identifier is choosen by the TCP client and can be any value: "This field is used for intra-system routing purpose. It is typically used to communicate to a MODBUS+ or a MODBUS serial line slave through a gateway between an Ethernet TCP-IP network and a MODBUS serial line. This field is set by the MODBUS Client in the request and must be returned with the same value in the response by the server." So the current check in modbus_reply must be extended to check whether we are in a RTU or TCP context. Also the unit-test has to be adjusted. Signed-off-by: Michael Heimpold <mhei@heimpold.de>
-
fixed small typo
-
This reverts commit 1d3c6401f8186b54453ba64606758a90b6ec3fca. TravisCI reports: ../src/.libs/libmodbus.so: undefined reference to `__builtin_bswap16' with gcc 4.6.3
-
Thanks to dreamflow for the issue.
-
Current code could dereference NULL pointer in case an inner malloc fails. Check for this and exit gracefully. Signed-off-by: Michael Heimpold <mhei@heimpold.de>
-
EMBBADCRC, not EMBADCRC
-
The result of LIBMODBUS_VERSION_HEX is left-shifted by an extra factor of 8 bits. For example, current implementation for version 1.2.3 would be encoded like 0x01020300 instead of 0x010203.
-
The socket management belongs to the application. The return code was missing in modbus_tcp_pi_accept().
-
Making all in src CC modbus.lo CC modbus-data.lo modbus-data.c:51:5: attention : #warning "Fallback on C functions for bswap_16" [-Wcpp] # warning "Fallback on C functions for bswap_16" ^ modbus-data.c:52:24: erreur: redefinition of ‘bswap_16’ static inline uint16_t bswap_16(uint16_t x) -
Thanks to paperwork
-
Thanks to Rüdiger Ranft for the idea.
-
Related to 52ab1bbea760ed8eaca184f7d875a2f52a116d0f. The arguments have been changed (see documentation). https://groups.google.com/d/msg/libmodbus/aXO8nBzW4Ew/uVGTDmvvBAAJ