not get block2 option in server
lx121451 opened this issue · comments
When I send a Get Message with block2 option,but in server side Options.HasOption(message.Block2) return false。Is there anything that needs special attention?
@jkralik I think this is the relevant code:
go-coap/net/blockwise/blockwise.go
Lines 534 to 540 in 49cae1c
Do you recall why the Block2
option is removed from the message before its passed to the next
handler function? Maybe the error check is inverted?
@lx121451 Pls, why do you need block2
? Thx
Do you recall why the
Block2
option is removed from the message before its passed to thenext
handler function? Maybe the error check is inverted?
No, it's correct.
@lx121451 Pls, why do you need
block2
? Thx
Just for test,I'm simulating a file transfer server with separate response!
For test you can use https://github.com/plgd-dev/go-coap/blob/master/options/commonOptions.go#L278 to watch all messages that comes to server in v3
.
I will close the issue, feel free to reopen it.