The method for decoding a frame has an invalid structure to analyze datastreams

Issue #1 resolved
Victor Christian Paredes Cauna created an issue

The current method to decode frames searches for the first appearance of the characters S and T. After that, the decoder thinks that the subsequent frames are full bit sized, thus checks S and T immediately on the next frame, however, the bug happens whenever a frame have more bytes than expected, introducing a shift error on the next frames, causing a decoding error on the whole data stream.

For example, if we expect N bytes after Header (say S T), and we have this erroneous frame:

S T <N + 1 bytes>

The decoder will read S T <N Bytes>, and the next frame will have a different Header: BitN S

This is causing critical errors due to the loss of (a lot of) data.

Comments (1)

  1. Log in to comment