From 538170628aa83b2000089d485386cca5596cc67f Mon Sep 17 00:00:00 2001 From: Olaf Bergmann Date: Mon, 18 Jul 2016 22:03:22 +0200 Subject: [PATCH] coap_dtls.c: Fixed dummy functions for --disable-dtls build When compiled without support for DTLS, coap_dtls.c contains a set of dummy functions to make certain compilers and linkers happy. As the function signature now differs from the prototype, the attribute has been removed entirely (causing a set of warnings that report the unused parameters.) --- src/coap_dtls.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/src/coap_dtls.c b/src/coap_dtls.c index edee3651..c77bd305 100644 --- a/src/coap_dtls.c +++ b/src/coap_dtls.c @@ -537,20 +537,23 @@ coap_dtls_get_session(struct coap_context_t *coap_context UNUSED, } int -coap_dtls_send(struct coap_context_t *coap_context UNUSED, - struct coap_dtls_session_t *session UNUSED, - const unsigned char *data UNUSED, size_t data_len UNUSED) { +coap_dtls_send(struct coap_context_t *coap_context, + struct coap_dtls_session_t *session, + const coap_pdu_t *pdu) { return -1; } struct coap_dtls_session_t * -coap_dtls_new_session(const coap_endpoint_t *local_interface UNUSED, - const coap_address_t *remote UNUSED) { +coap_dtls_new_session(struct coap_dtls_context_t *dtls_context, + const coap_endpoint_t *local_interface, + const coap_address_t *remote) { return NULL; } +struct coap_dtls_session_t; void -coap_dtls_free_session(coap_dtls_session_t *session UNUSED) {} +coap_dtls_free_session(struct coap_dtls_context_t *dtls_context, + struct coap_dtls_session_t *session) {} int coap_dtls_handle_message(struct coap_context_t *coap_context UNUSED,