Open GoogleCodeExporter opened 8 years ago
seems like someone wasn't taught to free allocated memory properly. Faced the problem yesterday, in library folder (Arduino/libraries/MODBUS/ in my case) edit modbusSlave.cpp:
change near line 276
if( (_msg[0] != 0xFF) && (_msg[0] != _device->getId()) ) return;
to
if( (_msg[0] != 0xFF) && (_msg[0] != _device->getId()) ) {free(_msg);return;}
and also
near line 283
if ( _crc != ((_msg[_len - 2] << 8) + _msg[_len - 1])) return;
change to
if ( _crc != ((_msg[_len - 2] << 8) + _msg[_len - 1])) {free(_msg);return;}
Original issue reported on code.google.com by
poonam...@gmail.com
on 30 Jun 2015 at 8:35