File: gcc-15.patch

package info (click to toggle)
ruby-fusefs 0.7.0-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 372 kB
  • sloc: ansic: 1,141; ruby: 760; sh: 10; makefile: 2
file content (77 lines) | stat: -rw-r--r-- 3,283 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
Description: Fix FTBFS issues with GCC-15
 The underlying issue being fixed here is that in C23, functions declared with
 no arguments are now understood as taking no arguments instead of an undefined
 number of arguments.
 This is also related to a Ruby bug reported at
 https://bugs.ruby-lang.org/issues/20908.
Author: Athos Ribeiro <athos@debian.org>
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1097813
Forwarded: no
Last-Update: 2025-11-04
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
--- a/ext/fusefs_fuse.c
+++ b/ext/fusefs_fuse.c
@@ -49,12 +49,17 @@
 }
 
 static void
-fusefs_ehandler() {
+fusefs_ehandler(int) {
   if (fuse_instance != NULL) {
     fusefs_unmount();
   }
 }
 
+static void
+wrap_fusefs_ehandler() {
+  fusefs_ehandler(0);
+}
+
 int
 fusefs_setup(char *mountpoint, const struct fuse_operations *op, struct fuse_args *opts) {
   fusech = NULL;
@@ -80,7 +85,7 @@
       set_one_signal_handler(SIGPIPE, SIG_IGN) == -1)
     return 0;
 
-  atexit(fusefs_ehandler);
+  atexit(wrap_fusefs_ehandler);
 
   /* We've initialized it! */
   mounted_at = strdup(mountpoint);
--- a/ext/fusefs_lib.c
+++ b/ext/fusefs_lib.c
@@ -1475,19 +1475,19 @@
   cFSException = rb_define_class_under(cFuseFS,"FuseFSException",rb_eStandardError);
 
   /* def Fuse.run */
-  rb_define_singleton_method(cFuseFS,"fuse_fd",     (rbfunc) rf_fd, 0);
-  rb_define_singleton_method(cFuseFS,"reader_uid",  (rbfunc) rf_uid, 0);
-  rb_define_singleton_method(cFuseFS,"uid",         (rbfunc) rf_uid, 0);
-  rb_define_singleton_method(cFuseFS,"reader_gid",  (rbfunc) rf_gid, 0);
-  rb_define_singleton_method(cFuseFS,"gid",         (rbfunc) rf_gid, 0);
-  rb_define_singleton_method(cFuseFS,"process",     (rbfunc) rf_process, 0);
-  rb_define_singleton_method(cFuseFS,"mount_to",    (rbfunc) rf_mount_to, -1);
-  rb_define_singleton_method(cFuseFS,"mount_under", (rbfunc) rf_mount_to, -1);
-  rb_define_singleton_method(cFuseFS,"mountpoint",  (rbfunc) rf_mount_to, -1);
-  rb_define_singleton_method(cFuseFS,"set_root",    (rbfunc) rf_set_root, 1);
-  rb_define_singleton_method(cFuseFS,"root=",       (rbfunc) rf_set_root, 1);
-  rb_define_singleton_method(cFuseFS,"handle_editor",   (rbfunc) rf_handle_editor, 1);
-  rb_define_singleton_method(cFuseFS,"handle_editor=",  (rbfunc) rf_handle_editor, 1);
+  rb_define_singleton_method(cFuseFS,"fuse_fd",     rf_fd, 0);
+  rb_define_singleton_method(cFuseFS,"reader_uid",  rf_uid, 0);
+  rb_define_singleton_method(cFuseFS,"uid",         rf_uid, 0);
+  rb_define_singleton_method(cFuseFS,"reader_gid",  rf_gid, 0);
+  rb_define_singleton_method(cFuseFS,"gid",         rf_gid, 0);
+  rb_define_singleton_method(cFuseFS,"process",     rf_process, 0);
+  rb_define_singleton_method(cFuseFS,"mount_to",    rf_mount_to, -1);
+  rb_define_singleton_method(cFuseFS,"mount_under", rf_mount_to, -1);
+  rb_define_singleton_method(cFuseFS,"mountpoint",  rf_mount_to, -1);
+  rb_define_singleton_method(cFuseFS,"set_root",    rf_set_root, 1);
+  rb_define_singleton_method(cFuseFS,"root=",       rf_set_root, 1);
+  rb_define_singleton_method(cFuseFS,"handle_editor",   rf_handle_editor, 1);
+  rb_define_singleton_method(cFuseFS,"handle_editor=",  rf_handle_editor, 1);
 
 #undef RMETHOD
 #define RMETHOD(name,cstr) \