MangoAutomation / modbus4j

A high-performance and ease-of-use implementation of the Modbus protocol written in Java. Supports ASCII, RTU, TCP, and UDP transports as slave or master, automatic request partitioning and response data type parsing.
GNU General Public License v3.0
897 stars 370 forks source link

fix an error when using scanForSlaveNodes #72

Closed ly2837 closed 2 months ago

ly2837 commented 3 months ago

When using scanForSlaveNodes, the removeConsumer method will be called multiple times, and a null pointer exception will occur the second time the removeConsumer method is called