New issue
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
Problem with blockwise transfers that are even increments of block_size #24
Comments
Hi Chris, Thanks for your report. I tried to reproduce your problem but I couldn't get even that far. Write request goes through fine with 4096 bytes but when reading value back Leshan just timeouts. Wireshark capture shows that client is requesting more blocks but server is not sending new GET request. Can you share the steps how you were able to see this problem? |
ARM Internal Ref: IOTCLT-1904 |
Antti, Try this version of Leshan: https://hudson.eclipse.org/leshan/job/leshan/297/artifact/leshan-server-demo.jar I am doing a read when the issue occurs. Notice packet 87 (Block #3) the More flag is set. This is a 4096 byte message. When Leshan tries to read Block #4 because the More bit was set, it gets back nothing (hence the really small size of Packet 89). Here is my main.cpp from mbed-client-linux-example. Read /4/0/2 after the first "Incrementing Resource Value". It will show a timeout in Leshan due to the bug, but wireshark should show it. Let me know if you need any further info to reproduce this. |
Fixes error reported in Github. - PelionIoT/mbed-coap#24 - #4374
This has been fixed so closing the issue. |
Sending via blockwise response a 4096 byte packet with 1024 byte blocks, the last packet (Block 3) still sets the more flag. This is causing the server (Leshan) to fault. Appears issue is using a ">" check rather than a ">=" check on sn_coap_protocol.c:1602 and sn_coap_protocol.c:1976.
Thanks,
Chris
The text was updated successfully, but these errors were encountered: