From 2c2a73506db39f424f5c004f98275f37bdec60dd Mon Sep 17 00:00:00 2001 From: JeroenSt Date: Wed, 17 Aug 2022 19:55:41 +0200 Subject: [PATCH] Work in progress. --- tasmota/tasmota_xdrv_driver/xdrv_63_modbus_bridge.ino | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tasmota/tasmota_xdrv_driver/xdrv_63_modbus_bridge.ino b/tasmota/tasmota_xdrv_driver/xdrv_63_modbus_bridge.ino index 1b4f8027b..7958fe388 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_63_modbus_bridge.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_63_modbus_bridge.ino @@ -562,7 +562,7 @@ void CmndModbusBridgeSend(void) } else { - writeData = (uint16_t *)malloc(writeDataSize); + writeData = (uint16_t *)malloc(writeDataSize*2); for (uint8_t jsonDataArrayPointer = 0; jsonDataArrayPointer < writeDataSize; jsonDataArrayPointer++) { writeData[jsonDataArrayPointer] = jsonDataArray[jsonDataArrayPointer].getUInt(0);