File smenu-gcc15.patch of Package smenu

diff -upr smenu-1.4.0.orig/ctxopt.c smenu-1.4.0/ctxopt.c
--- smenu-1.4.0.orig/ctxopt.c	2025-04-30 14:28:19.963796848 +0000
+++ smenu-1.4.0/ctxopt.c	2025-04-30 14:46:30.672418979 +0000
@@ -4654,7 +4654,7 @@ ctxopt_add_opt_settings(settings s, ...)
     case actions:
     {
       void *data;
-      void (*function)();
+      void (*function)(char *, char *, char *, int,  char **, int,  void **, int,  void **);
       int nb_data = 0;
 
       /* The second argument must be the name of an existing option. */
@@ -4664,7 +4664,7 @@ ctxopt_add_opt_settings(settings s, ...)
       if ((opt = locate_opt(ptr)) != NULL)
       {
         typedef void
-        fn(char *, char *, char *, int, char **, int, void *, int, void **);
+        fn(char *, char *, char *, int, char **, int, void **, int, void **);
 
         /* The third argument must be the callback function. */
         /* """"""""""""""""""""""""""""""""""""""""""""""""" */
@@ -4696,7 +4696,7 @@ ctxopt_add_opt_settings(settings s, ...)
     {
       char         *value;
       constraint_t *cstr;
-      int (*function)();
+      int (*function)(int, char **, char *, char *);
 
       /* The second argument must be a string. */
       /* """"""""""""""""""""""""""""""""""""" */
@@ -4704,7 +4704,7 @@ ctxopt_add_opt_settings(settings s, ...)
 
       if ((opt = locate_opt(ptr)) != NULL)
       {
-        typedef int fn(int, char **, char *);
+        typedef int fn(int, char **, char *, char *);
 
         /* The third argument must be a function. */
         /* """""""""""""""""""""""""""""""""""""" */
@@ -4964,13 +4964,13 @@ ctxopt_add_ctx_settings(settings s, ...)
     {
       void *ptr;
       void *data;
-      int (*function)();
+      int (*function)(char *, int, char *, int, void **);
       int nb_data = 0;
 
       ptr = va_arg(args, char *);
       if ((ctx = locate_ctx(ptr)) != NULL)
       {
-        typedef int fn(char *, direction, char *, int, void **);
+        typedef int fn(char *, int, char *, int, void **);
 
         function    = va_arg(args, fn *);
         ctx->action = function;
Only in smenu-1.4.0: ctxopt.o
Only in smenu-1.4.0: smenu
openSUSE Build Service is sponsored by