From: Jan Mojžíš <jan.mojzis@gmail.com>
Date: Fri, 05 Sep 2025 07:21:51 +0200
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1097235
Subject: FTBFS fix gcc-15

diff --git a/src/store/memory/memstore.c b/src/store/memory/memstore.c
index 4243ad6..061f088 100755
--- a/src/store/memory/memstore.c
+++ b/src/store/memory/memstore.c
@@ -1394,7 +1394,10 @@ ngx_int_t nchan_memstore_publish_generic(memstore_channel_head_t *head, nchan_ms
 
 static ngx_int_t chanhead_messages_delete(memstore_channel_head_t *ch);
 
-static ngx_int_t empty_callback(){
+static ngx_int_t empty_callback(ngx_int_t a, void *b, void *c){
+  (void) a;
+  (void) b;
+  (void) c;
   return NGX_OK;
 }
 
diff --git a/src/subscribers/longpoll.c b/src/subscribers/longpoll.c
index 71400c6..04c4174 100644
--- a/src/subscribers/longpoll.c
+++ b/src/subscribers/longpoll.c
@@ -17,7 +17,14 @@ ngx_int_t memstore_slot(void);
 
 static const subscriber_t new_longpoll_sub;
 
-static void empty_handler() { }
+static void empty_handler_cln(void *a) {
+  (void) a;
+}
+
+static void empty_handler(subscriber_t *a, void *b) {
+  (void) a;
+  (void) b;
+}
 
 static void sudden_abort_handler(subscriber_t *sub) {
   if(sub->request && sub->status != DEAD) {
@@ -296,7 +303,7 @@ static ngx_int_t longpoll_respond_message(subscriber_t *self, nchan_msg_t *msg)
   }
   if(!cf->longpoll_multimsg) {
     //disable abort handler
-    fsub->data.cln->handler = empty_handler;
+    fsub->data.cln->handler = empty_handler_cln;
     
     assert(fsub->data.already_responded != 1);
     fsub->data.already_responded = 1;
@@ -344,7 +351,7 @@ static ngx_int_t longpoll_multipart_respond(full_subscriber_t *fsub) {
   nchan_longpoll_multimsg_t *first, *cur;
   
   //disable abort handler
-  fsub->data.cln->handler = empty_handler;
+  fsub->data.cln->handler = empty_handler_cln;
   
   first = fsub->data.multimsg_first;
   
@@ -457,7 +464,7 @@ static ngx_int_t longpoll_respond_status(subscriber_t *self, ngx_int_t status_co
   nchan_set_msgid_http_response_headers(r, NULL, &self->last_msgid);
   
   //disable abort handler
-  fsub->data.cln->handler = empty_handler;
+  fsub->data.cln->handler = empty_handler_cln;
   
   nchan_respond_status(r, status_code, status_line, status_body, 0);
 
diff --git a/src/subscribers/memstore_ipc.c b/src/subscribers/memstore_ipc.c
index a0a2579..35b19db 100644
--- a/src/subscribers/memstore_ipc.c
+++ b/src/subscribers/memstore_ipc.c
@@ -26,7 +26,10 @@ struct sub_data_s {
   ngx_event_t                   timeout_ev;
 }; //sub_data_t
 
-static ngx_int_t empty_callback(){
+static ngx_int_t empty_callback(ngx_int_t a, void *b, void *c){
+  (void) a;
+  (void) b;
+  (void) c;
   return NGX_OK;
 }
 
diff --git a/src/subscribers/websocket.c b/src/subscribers/websocket.c
index f8e8e0e..e91d594 100644
--- a/src/subscribers/websocket.c
+++ b/src/subscribers/websocket.c
@@ -213,7 +213,10 @@ struct full_subscriber_s {
   unsigned                awaiting_destruction:1;
 };// full_subscriber_t
 
-static void empty_handler() { }
+static void empty_handler(struct subscriber_s *a, void *b) {
+  (void) a;
+  (void) b;
+}
 
 static ngx_int_t websocket_send_frame(full_subscriber_t *fsub, const u_char opcode, off_t len, ngx_chain_t *chain);
 static void set_buf_to_str(ngx_buf_t *buf, const ngx_str_t *str);
