From 2fc8fe04388f276c85ed45a0093215c90ff579b8 Mon Sep 17 00:00:00 2001 From: Daniel-Constantin Mierla Date: Tue, 12 Dec 2023 10:55:16 +0100 Subject: [PATCH] declare msg_create() with parameter - even not used, one is given when function is executed - fix for warning: passing arguments to 'msg_create' without a prototype is deprecated in all versions of C and is not supported in C2x --- src/sip_msg.c | 2 +- src/sip_msg.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/sip_msg.c b/src/sip_msg.c index 379a40a3..88f1a646 100644 --- a/src/sip_msg.c +++ b/src/sip_msg.c @@ -33,7 +33,7 @@ #include "sip.h" sip_msg_t * -msg_create() +msg_create(const char *payload) { sip_msg_t *msg; if (!(msg = sng_malloc(sizeof(sip_msg_t)))) diff --git a/src/sip_msg.h b/src/sip_msg.h index 902623d2..619979da 100644 --- a/src/sip_msg.h +++ b/src/sip_msg.h @@ -84,7 +84,7 @@ struct sip_msg { * @return a new allocated message */ sip_msg_t * -msg_create(); +msg_create(const char *payload); /** * @brief Destroy a SIP message and free its memory