We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In [0] there is the check of the variable byte integer buffer length
uint32 readFrom(const uint8 * buffer, uint32 bufLength) { for (size = 0; size < 4;) { if ((uint32)(size+1) > bufLength) return NotEnoughData; value[size] = buffer[size]; if (value[size++] < 0x80) break; } return size < 4 ? size : (uint32)BadData; }
for buffer = {0x8c, 0xda, 0xc4, 0x09} and bufLength = 4 this will result in BadData but it should be a valid input. Is the return condition correct?
buffer = {0x8c, 0xda, 0xc4, 0x09}
bufLength = 4
BadData
[0] https://github.com/X-Ryl669/eMQTT5/blob/2f261615d3c2adc5e0c273876cfb35a0c7304b95/lib/include/Protocol/MQTT/MQTT.hpp#L692C31-L692C31
The text was updated successfully, but these errors were encountered:
Fix bug reported in #17.
cd2a9c4
You're right, the condition is too restricted.
I believe the last commit should have fixed it. Please confirm it's ok for you.
Sorry, something went wrong.
yes, now it seems to be ok. thanks
No branches or pull requests
In [0] there is the check of the variable byte integer buffer length
for
buffer = {0x8c, 0xda, 0xc4, 0x09}
andbufLength = 4
this will result inBadData
but it should be a valid input.Is the return condition correct?
[0] https://github.com/X-Ryl669/eMQTT5/blob/2f261615d3c2adc5e0c273876cfb35a0c7304b95/lib/include/Protocol/MQTT/MQTT.hpp#L692C31-L692C31
The text was updated successfully, but these errors were encountered: