Skip to content

Commit 1018ffe

Browse files
LukasWoodtlicarlescufi
authored andcommitted
net: coap: Update documentation for adding options
CoAP options do not need to be added in the order of their code number. The function documentation is updated accordingly. Signed-off-by: Lukas Woodtli <[email protected]>
1 parent 3b4e54e commit 1018ffe

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

include/zephyr/net/coap.h

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -442,9 +442,8 @@ int coap_find_options(const struct coap_packet *cpkt, uint16_t code,
442442
/**
443443
* @brief Appends an option to the packet.
444444
*
445-
* Note: options must be added in numeric order of their codes. Otherwise
446-
* error will be returned.
447-
* TODO: Add support for placing options according to its delta value.
445+
* Note: options can be added out of numeric order of their codes. But
446+
* it's more efficient to add them in order.
448447
*
449448
* @param cpkt Packet to be updated
450449
* @param code Option code to add to the packet, see #coap_option_num

0 commit comments

Comments
 (0)