summaryrefslogtreecommitdiffstats
path: root/meta-networking/recipes-support/iftop/iftop/0001-cfgfile-fix-build-with-gcc-15.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-networking/recipes-support/iftop/iftop/0001-cfgfile-fix-build-with-gcc-15.patch')
-rw-r--r--meta-networking/recipes-support/iftop/iftop/0001-cfgfile-fix-build-with-gcc-15.patch46
1 files changed, 46 insertions, 0 deletions
diff --git a/meta-networking/recipes-support/iftop/iftop/0001-cfgfile-fix-build-with-gcc-15.patch b/meta-networking/recipes-support/iftop/iftop/0001-cfgfile-fix-build-with-gcc-15.patch
new file mode 100644
index 0000000000..73540e18c6
--- /dev/null
+++ b/meta-networking/recipes-support/iftop/iftop/0001-cfgfile-fix-build-with-gcc-15.patch
@@ -0,0 +1,46 @@
1From e579fbe1f73dc89e2bf81a5b6c949f8ae24f93b2 Mon Sep 17 00:00:00 2001
2From: Martin Jansa <martin.jansa@gmail.com>
3Date: Fri, 21 Mar 2025 09:31:05 +0000
4Subject: [PATCH] cfgfile: fix build with gcc-15
5
6* fix read_config declaration to match
7
8cfgfile.c:247:5: error: conflicting types for 'read_config'; have 'int(char *, int)'
9 247 | int read_config(char *file, int whinge_on_error) {
10 | ^~~~~~~~~~~
11In file included from cfgfile.c:16:
12cfgfile.h:16:5: note: previous declaration of 'read_config' with type 'int(void)'
13 16 | int read_config();
14 | ^~~~~~~~~~~
15make[2]: *** [Makefile:566: cfgfile.o] Error 1
16make[2]: *** Waiting for unfinished jobs....
17iftop.c: In function 'main':
18iftop.c:803:5: error: too many arguments to function 'read_config'; expected 0, have 2
19 803 | read_config(options.config_file, options.config_file_specified);
20 | ^~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~
21In file included from iftop.c:50:
22cfgfile.h:16:5: note: declared here
23 16 | int read_config();
24 | ^~~~~~~~~~~
25
26Upstream-Status: Pending [last pre release was over 10 years ago and https://code.blinkace.com/pdw/iftop has last commit from 4 years ago]
27
28Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
29---
30
31 cfgfile.h | 2 +-
32 1 file changed, 1 insertion(+), 1 deletion(-)
33
34diff --git a/cfgfile.h b/cfgfile.h
35index 11ba475..a331b75 100644
36--- a/cfgfile.h
37+++ b/cfgfile.h
38@@ -13,7 +13,7 @@ typedef struct {
39 int value;
40 } config_enumeration_type;
41
42-int read_config();
43+int read_config(char *file, int whinge_on_error);
44
45 char *config_get_string(const char *directive);
46 int config_get_bool(const char *directive);