The sn_coap_handle_blockwise_message doesnt build in the ACK response the uri query and the coap server after block #0 responds with internal server error, resource not found.
Adding the following code in line 2064 fixes it:
if (previous_blockwise_msg_ptr->coap_msg_ptr->options_list_ptr->uri_query_ptr) {
src_coap_blockwise_ack_msg_ptr->options_list_ptr->uri_query_ptr = sn_coap_protocol_malloc_copy(handle, previous_blockwise_msg_ptr->coap_msg_ptr->options_list_ptr->uri_query_ptr, previous_blockwise_msg_ptr->coap_msg_ptr->options_list_ptr->uri_query_len);
if (!src_coap_blockwise_ack_msg_ptr->options_list_ptr->uri_query_ptr) {
sn_coap_parser_release_allocated_coap_msg_mem(handle, src_coap_blockwise_ack_msg_ptr);
tr_error("sn_coap_handle_blockwise_message - failed to allocate for uri query ptr!");
return NULL;
}
src_coap_blockwise_ack_msg_ptr->options_list_ptr->uri_query_len = previous_blockwise_msg_ptr->coap_msg_ptr->options_list_ptr->uri_query_len;
}
Hi,
When doing a GET in the format:
coap://192.168.0.1/XXX?name=product-xxxx
The sn_coap_handle_blockwise_message doesnt build in the ACK response the uri query and the coap server after block #0 responds with internal server error, resource not found.
Adding the following code in line 2064 fixes it: