Comment # 21
on bug 8070
from Shoichi Sakane
(In reply to comment #19)
> 2nd question:
> In the code below in dissect_coap_opt_uri_query(),
> if 'opt_length' == 0 then 'coap_uri_query' will be
> concatenated with a '?' or '&' by itself without the string "(null)".
> Is this as intended ?
> (This is similar to what is done in dissect_coap_opt_uri_path()).
>
>
> if (coap_uri_query[0] == '\0')
> g_strlcat(coap_uri_query, "?", sizeof(coap_uri_query));
> else
> g_strlcat(coap_uri_query, "&", sizeof(coap_uri_query));
>
> if (opt_length == 0) {
> str = nullstr;
> } else {
> str = tvb_get_string(wmem_packet_scope(), tvb, offset, opt_length);
> g_strlcat(coap_uri_str, str, sizeof(coap_uri_str));
> }
Yes, intended. coap_uri_query is intended to show the whole query string
concatinated. "str" is the buffer to show the option itself. "str" only takes
a nullstr.
You are receiving this mail because:
- You are watching all bug changes.