aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJonathan McCrohan <jmccrohan@gmail.com>2012-03-26 22:37:16 +0100
committerJonathan McCrohan <jmccrohan@gmail.com>2012-03-26 22:37:16 +0100
commit2a2b4e8e041c8f795f519b93f6b4a0a2b87a7359 (patch)
tree7edb18bf637b79fa6fd6c952f15bbca32a0e6d6a /src
parent67b3bfe5cf9b13820c934687d8930aa51c2dd902 (diff)
downloadverteco-2a2b4e8e041c8f795f519b93f6b4a0a2b87a7359.tar.gz
modbuslog: add 1 second sleep before modbus retries
Diffstat (limited to '')
-rw-r--r--src/modbuslog.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/modbuslog.c b/src/modbuslog.c
index 46a1516..43d102d 100644
--- a/src/modbuslog.c
+++ b/src/modbuslog.c
@@ -266,6 +266,7 @@ int main(int argc, char *argv[]) {
if (rc == -1) {
syslog(LOG_ERR, "libmodbus error: [%s]",
modbus_strerror(errno));
+ sleep(1);
}
retry++;
} while ((rc == -1) && (retry < (modbus_retry + 1)));