Skip to content

Commit

Permalink
[nrf fromtree] net: lib: coap_client: Const pointers in request
Browse files Browse the repository at this point in the history
CoAP client does not modify any of the members, so
change all pointers to const.

Signed-off-by: Seppo Takalo <[email protected]>
(cherry picked from commit bc4f026)
  • Loading branch information
SeppoTakalo committed Nov 28, 2024
1 parent f6004fc commit 4148a01
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions include/zephyr/net/coap_client.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,16 +53,16 @@ typedef void (*coap_client_response_cb_t)(int16_t result_code,
* @brief Representation of a CoAP client request.
*/
struct coap_client_request {
enum coap_method method; /**< Method of the request */
bool confirmable; /**< CoAP Confirmable/Non-confirmable message */
const char *path; /**< Path of the requested resource */
enum coap_content_format fmt; /**< Content format to be used */
uint8_t *payload; /**< User allocated buffer for send request */
size_t len; /**< Length of the payload */
coap_client_response_cb_t cb; /**< Callback when response received */
struct coap_client_option *options; /**< Extra options to be added to request */
uint8_t num_options; /**< Number of extra options */
void *user_data; /**< User provided context */
enum coap_method method; /**< Method of the request */
bool confirmable; /**< CoAP Confirmable/Non-confirmable message */
const char *path; /**< Path of the requested resource */
enum coap_content_format fmt; /**< Content format to be used */
const uint8_t *payload; /**< User allocated buffer for send request */
size_t len; /**< Length of the payload */
coap_client_response_cb_t cb; /**< Callback when response received */
const struct coap_client_option *options; /**< Extra options to be added to request */
uint8_t num_options; /**< Number of extra options */
void *user_data; /**< User provided context */
};

/**
Expand Down

0 comments on commit 4148a01

Please sign in to comment.