RIOT icon indicating copy to clipboard operation
RIOT copied to clipboard

nanocoap_sock: always use coap_opt_put_uri_pathquery()

Open benpicco opened this issue 1 year ago • 2 comments

Contribution description

This is pretty subtle: coap_opt_put_uri_pathquery() will detect the presense of a query parameter, coap_opt_put_uri_path() will not.

That means that when you request path/to/resource?option=1 with coap_opt_put_uri_path() you get the path resource?option=1 whereas with coap_opt_put_uri_pathquery() you get the path resource with query parameter option=1.

We really want the latter.

Testing procedure

Issues/PRs references

benpicco avatar Jan 11 '24 15:01 benpicco

Murdock results

:heavy_check_mark: PASSED

eb76b8ea628e54f0277115cb0fbb6df37e91092d nanocoap: allow lastonum=NULL in coap_opt_put_uri_pathquery()

Success Failures Total Runtime
8101 0 8101 10m:26s

Artifacts

riot-ci avatar Jan 11 '24 15:01 riot-ci

To me it feels more like a bug fix than an API change - when I added the functions I was not aware of the difference between coap_opt_put_uri_pathquery() and coap_opt_put_uri_path() (or that there are in fact two different functions) :sweat_smile:

benpicco avatar Jan 12 '24 09:01 benpicco

Is there anything I can do to move this forward?

benpicco avatar Feb 19 '24 18:02 benpicco

Thank you!

benpicco avatar Feb 19 '24 21:02 benpicco