mkjeff / secs4net

SECS-II/HSMS-SS/GEM implementation on .NET
https://mkjeff.github.io/secs4net/
MIT License
443 stars 195 forks source link

NullReferenceException #60

Open zhuxuan1997 opened 2 years ago

zhuxuan1997 commented 2 years ago

Describe the bug NullReferenceException To Reproduce Steps to reproduce the behavior:

  1. start SecsDevice and DeviceWorkerService two projects simultaneously in VS
  2. after the main form appear, make the break point at the MessageHeader.cs file EncodeTo method buffer.Advance(10) (49 line)
  3. press F11 to run step by step
  4. in the HsmsConnection.cs file StopPipeDecoder method, 324 line will occur a NullReferenceException bug

Expected behavior A clear and concise description of what you expected to happen.

Desktop (please complete the following information): Windows 10, VS2022

Additional context Add any other context about the problem here.