mirror of
https://github.com/obgm/libcoap.git
synced 2026-12-05 20:02:19 +03:00
server.c: Declare unused parameters to make -Wunused quiet
This commit is contained in:
1 parent
eb2251f06f
commit
9b1ab5eef3
1 file changed
+21
-15
+21
-15
@@ -48,9 +48,15 @@ struct coap_resource_t *time_resource = NULL;
|
||||
static coap_async_state_t *async = NULL;
|
||||
#endif /* WITHOUT_ASYNC */
|
||||
|
||||
#ifdef __GNUC__
|
||||
#define UNUSED_PARAM __attribute__ ((unused))
|
||||
#else /* not a GCC */
|
||||
#define UNUSED_PARAM
|
||||
#endif /* GCC */
|
||||
|
||||
/* SIGINT handler: set quit to 1 for graceful termination */
|
||||
void
|
||||
handle_sigint(int signum) {
|
||||
handle_sigint(int signum UNUSED_PARAM) {
|
||||
quit = 1;
|
||||
}
|
||||
|
||||
@@ -58,9 +64,9 @@ handle_sigint(int signum) {
|
||||
"Copyright (C) 2010--2013 Olaf Bergmann <bergmann@tzi.org>\n\n"
|
||||
|
||||
void
|
||||
hnd_get_index(coap_context_t *ctx, struct coap_resource_t *resource,
|
||||
const coap_endpoint_t *local_interface,
|
||||
coap_address_t *peer, coap_pdu_t *request, str *token,
|
||||
hnd_get_index(coap_context_t *ctx UNUSED_PARAM, struct coap_resource_t *resource UNUSED_PARAM,
|
||||
const coap_endpoint_t *local_interface UNUSED_PARAM,
|
||||
coap_address_t *peer UNUSED_PARAM, coap_pdu_t *request UNUSED_PARAM, str *token UNUSED_PARAM,
|
||||
coap_pdu_t *response) {
|
||||
unsigned char buf[3];
|
||||
|
||||
@@ -77,7 +83,7 @@ hnd_get_index(coap_context_t *ctx, struct coap_resource_t *resource,
|
||||
|
||||
void
|
||||
hnd_get_time(coap_context_t *ctx, struct coap_resource_t *resource,
|
||||
const coap_endpoint_t *local_interface,
|
||||
const coap_endpoint_t *local_interface UNUSED_PARAM,
|
||||
coap_address_t *peer, coap_pdu_t *request, str *token,
|
||||
coap_pdu_t *response) {
|
||||
coap_opt_iterator_t opt_iter;
|
||||
@@ -135,9 +141,9 @@ hnd_get_time(coap_context_t *ctx, struct coap_resource_t *resource,
|
||||
}
|
||||
|
||||
void
|
||||
hnd_put_time(coap_context_t *ctx, struct coap_resource_t *resource,
|
||||
const coap_endpoint_t *local_interface,
|
||||
coap_address_t *peer, coap_pdu_t *request, str *token,
|
||||
hnd_put_time(coap_context_t *ctx UNUSED_PARAM, struct coap_resource_t *resource UNUSED_PARAM,
|
||||
const coap_endpoint_t *local_interface UNUSED_PARAM,
|
||||
coap_address_t *peer UNUSED_PARAM, coap_pdu_t *request, str *token UNUSED_PARAM,
|
||||
coap_pdu_t *response) {
|
||||
coap_tick_t t;
|
||||
size_t size;
|
||||
@@ -168,10 +174,10 @@ hnd_put_time(coap_context_t *ctx, struct coap_resource_t *resource,
|
||||
}
|
||||
|
||||
void
|
||||
hnd_delete_time(coap_context_t *ctx, struct coap_resource_t *resource,
|
||||
const coap_endpoint_t *local_interface,
|
||||
coap_address_t *peer, coap_pdu_t *request, str *token,
|
||||
coap_pdu_t *response) {
|
||||
hnd_delete_time(coap_context_t *ctx UNUSED_PARAM, struct coap_resource_t *resource UNUSED_PARAM,
|
||||
const coap_endpoint_t *local_interface UNUSED_PARAM,
|
||||
coap_address_t *peer UNUSED_PARAM, coap_pdu_t *request UNUSED_PARAM, str *token UNUSED_PARAM,
|
||||
coap_pdu_t *response UNUSED_PARAM) {
|
||||
my_clock_base = 0; /* mark clock as "deleted" */
|
||||
|
||||
/* type = request->hdr->type == COAP_MESSAGE_CON */
|
||||
@@ -180,9 +186,9 @@ hnd_delete_time(coap_context_t *ctx, struct coap_resource_t *resource,
|
||||
|
||||
#ifndef WITHOUT_ASYNC
|
||||
void
|
||||
hnd_get_async(coap_context_t *ctx, struct coap_resource_t *resource,
|
||||
const coap_endpoint_t *local_interface,
|
||||
coap_address_t *peer, coap_pdu_t *request, str *token,
|
||||
hnd_get_async(coap_context_t *ctx, struct coap_resource_t *resource UNUSED_PARAM,
|
||||
const coap_endpoint_t *local_interface UNUSED_PARAM,
|
||||
coap_address_t *peer, coap_pdu_t *request, str *token UNUSED_PARAM,
|
||||
coap_pdu_t *response) {
|
||||
coap_opt_iterator_t opt_iter;
|
||||
coap_opt_t *option;
|
||||
|
||||
Reference in new issue
Block a user