From 6127da32e48fe64e4f6c2f65691eef0871861fb5 Mon Sep 17 00:00:00 2001 From: nosuz Date: Thu, 28 Apr 2022 14:27:08 +0900 Subject: [PATCH] Fixed the commented out coap_new_optlist() example in the coap_client example. coap_new_optlist() requires 3 arguments but the example had 2 arguments. --- examples/protocols/coap_client/main/coap_client_example_main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/protocols/coap_client/main/coap_client_example_main.c b/examples/protocols/coap_client/main/coap_client_example_main.c index 1a59e37b27..6b071f573c 100644 --- a/examples/protocols/coap_client/main/coap_client_example_main.c +++ b/examples/protocols/coap_client/main/coap_client_example_main.c @@ -436,7 +436,8 @@ static void coap_example_client(void *p) * coap_insert_optlist(&optlist, * coap_new_optlist(COAP_OPTION_CONTENT_FORMAT, * coap_encode_var_safe (buf, sizeof (buf), - * COAP_MEDIATYPE_APPLICATION_JSON)); + * COAP_MEDIATYPE_APPLICATION_JSON), + * buf)); * Add in here the POST data of length length. E.G. * coap_add_data_large_request(session, request length, data, NULL, NULL); */