nspanel
nspanel copied to clipboard
Fix end of payload.
The detection of the end of the payload is wrong. There are 3 bytes after the payload. What the current implementation does it searching from the end backwards for the '}' character. I assume that these 3 extra bytes contain a checksum of some sort since the data can be any value. If one of those 3 bytes happen to be 0x125 which is the same as the '}' character, the detection is wrong and you end up with payloads like {"id":"3"}} or {"id":"4"}B} which are obviously not the correct payloads.
What is prohibiting this change ?
It should already be fixed by #28