diff options
| author | Khem Raj <raj.khem@gmail.com> | 2022-08-07 17:45:25 -0700 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-08-28 07:51:30 +0100 |
| commit | 81eb70494a845211b32ef50529d44f9c1220bbdf (patch) | |
| tree | 4310d278ca817c04316c30e38affb2d6699e89d8 | |
| parent | b331a3324160df103a33fcfaad6e7e97ac450c1a (diff) | |
| download | poky-81eb70494a845211b32ef50529d44f9c1220bbdf.tar.gz | |
tcp-wrappers: Fix implicit-function-declaration warnings
This is seen with clang-15+
(From OE-Core rev: a5555a2d38521ef1c8d93676fbc2f6fec3558160)
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 4b882afd6c1a67b48cf4e7ace95d46ca2ff12aa0)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/recipes-extended/tcp-wrappers/tcp-wrappers-7.6/0001-Fix-implicit-function-declaration-warnings.patch | 109 | ||||
| -rw-r--r-- | meta/recipes-extended/tcp-wrappers/tcp-wrappers_7.6.bb | 1 |
2 files changed, 110 insertions, 0 deletions
diff --git a/meta/recipes-extended/tcp-wrappers/tcp-wrappers-7.6/0001-Fix-implicit-function-declaration-warnings.patch b/meta/recipes-extended/tcp-wrappers/tcp-wrappers-7.6/0001-Fix-implicit-function-declaration-warnings.patch new file mode 100644 index 0000000000..ec793ac8ff --- /dev/null +++ b/meta/recipes-extended/tcp-wrappers/tcp-wrappers-7.6/0001-Fix-implicit-function-declaration-warnings.patch | |||
| @@ -0,0 +1,109 @@ | |||
| 1 | From 9c97b5db237a793e0d1b6b0241570bdc6e35ee24 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Khem Raj <raj.khem@gmail.com> | ||
| 3 | Date: Sun, 7 Aug 2022 17:42:24 -0700 | ||
| 4 | Subject: [PATCH] Fix implicit-function-declaration warnings | ||
| 5 | |||
| 6 | These are seen with clang-15+ | ||
| 7 | |||
| 8 | Upstream-Status: Inappropriate [upstream is dead] | ||
| 9 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
| 10 | --- | ||
| 11 | hosts_access.c | 3 +++ | ||
| 12 | safe_finger.c | 1 + | ||
| 13 | shell_cmd.c | 3 +++ | ||
| 14 | tcpd.c | 2 +- | ||
| 15 | tcpdchk.c | 1 + | ||
| 16 | workarounds.c | 1 + | ||
| 17 | 6 files changed, 10 insertions(+), 1 deletion(-) | ||
| 18 | |||
| 19 | diff --git a/hosts_access.c b/hosts_access.c | ||
| 20 | index 0133e5e..58697ea 100644 | ||
| 21 | --- a/hosts_access.c | ||
| 22 | +++ b/hosts_access.c | ||
| 23 | @@ -33,6 +33,7 @@ static char sccsid[] = "@(#) hosts_access.c 1.21 97/02/12 02:13:22"; | ||
| 24 | #endif | ||
| 25 | #include <netinet/in.h> | ||
| 26 | #include <arpa/inet.h> | ||
| 27 | +#include <rpcsvc/ypclnt.h> | ||
| 28 | #include <stdio.h> | ||
| 29 | #include <stdlib.h> | ||
| 30 | #include <syslog.h> | ||
| 31 | @@ -45,6 +46,8 @@ static char sccsid[] = "@(#) hosts_access.c 1.21 97/02/12 02:13:22"; | ||
| 32 | #endif | ||
| 33 | |||
| 34 | extern int errno; | ||
| 35 | +extern int match_pattern_ylo(const char *s, const char *pattern); | ||
| 36 | +extern unsigned long cidr_mask_addr(char* str); | ||
| 37 | |||
| 38 | #ifndef INADDR_NONE | ||
| 39 | #define INADDR_NONE (-1) /* XXX should be 0xffffffff */ | ||
| 40 | diff --git a/safe_finger.c b/safe_finger.c | ||
| 41 | index 23afab1..a6458fb 100644 | ||
| 42 | --- a/safe_finger.c | ||
| 43 | +++ b/safe_finger.c | ||
| 44 | @@ -34,6 +34,7 @@ static char sccsid[] = "@(#) safe_finger.c 1.4 94/12/28 17:42:41"; | ||
| 45 | #include <syslog.h> | ||
| 46 | |||
| 47 | extern void exit(); | ||
| 48 | +extern int pipe_stdin(char **argv); | ||
| 49 | |||
| 50 | /* Local stuff */ | ||
| 51 | |||
| 52 | diff --git a/shell_cmd.c b/shell_cmd.c | ||
| 53 | index 62d31bc..a566092 100644 | ||
| 54 | --- a/shell_cmd.c | ||
| 55 | +++ b/shell_cmd.c | ||
| 56 | @@ -16,10 +16,13 @@ static char sccsid[] = "@(#) shell_cmd.c 1.5 94/12/28 17:42:44"; | ||
| 57 | |||
| 58 | #include <sys/types.h> | ||
| 59 | #include <sys/param.h> | ||
| 60 | +#include <sys/wait.h> | ||
| 61 | +#include <fcntl.h> | ||
| 62 | #include <signal.h> | ||
| 63 | #include <stdio.h> | ||
| 64 | #include <syslog.h> | ||
| 65 | #include <string.h> | ||
| 66 | +#include <unistd.h> | ||
| 67 | |||
| 68 | extern void exit(); | ||
| 69 | |||
| 70 | diff --git a/tcpd.c b/tcpd.c | ||
| 71 | index dc9ff17..4353caa 100644 | ||
| 72 | --- a/tcpd.c | ||
| 73 | +++ b/tcpd.c | ||
| 74 | @@ -46,7 +46,7 @@ void fix_options(struct request_info *); | ||
| 75 | int allow_severity = SEVERITY; /* run-time adjustable */ | ||
| 76 | int deny_severity = LOG_WARNING; /* ditto */ | ||
| 77 | |||
| 78 | -main(argc, argv) | ||
| 79 | +void main(argc, argv) | ||
| 80 | int argc; | ||
| 81 | char **argv; | ||
| 82 | { | ||
| 83 | diff --git a/tcpdchk.c b/tcpdchk.c | ||
| 84 | index 5dca8bd..67c12ce 100644 | ||
| 85 | --- a/tcpdchk.c | ||
| 86 | +++ b/tcpdchk.c | ||
| 87 | @@ -38,6 +38,7 @@ static char sccsid[] = "@(#) tcpdchk.c 1.8 97/02/12 02:13:25"; | ||
| 88 | |||
| 89 | extern int errno; | ||
| 90 | extern void exit(); | ||
| 91 | +extern unsigned long cidr_mask_addr(char* str); | ||
| 92 | extern int optind; | ||
| 93 | extern char *optarg; | ||
| 94 | |||
| 95 | diff --git a/workarounds.c b/workarounds.c | ||
| 96 | index b22b378..6335049 100644 | ||
| 97 | --- a/workarounds.c | ||
| 98 | +++ b/workarounds.c | ||
| 99 | @@ -21,6 +21,7 @@ char sccsid[] = "@(#) workarounds.c 1.6 96/03/19 16:22:25"; | ||
| 100 | #include <stdio.h> | ||
| 101 | #include <syslog.h> | ||
| 102 | #include <string.h> | ||
| 103 | +#include <unistd.h> | ||
| 104 | |||
| 105 | extern int errno; | ||
| 106 | |||
| 107 | -- | ||
| 108 | 2.37.1 | ||
| 109 | |||
diff --git a/meta/recipes-extended/tcp-wrappers/tcp-wrappers_7.6.bb b/meta/recipes-extended/tcp-wrappers/tcp-wrappers_7.6.bb index 814d7fd913..8137d257c8 100644 --- a/meta/recipes-extended/tcp-wrappers/tcp-wrappers_7.6.bb +++ b/meta/recipes-extended/tcp-wrappers/tcp-wrappers_7.6.bb | |||
| @@ -50,6 +50,7 @@ SRC_URI = "http://ftp.porcupine.org/pub/security/tcp_wrappers_${PV}.tar.gz \ | |||
| 50 | file://fix_warnings.patch \ | 50 | file://fix_warnings.patch \ |
| 51 | file://fix_warnings2.patch \ | 51 | file://fix_warnings2.patch \ |
| 52 | file://0001-Remove-fgets-extern-declaration.patch \ | 52 | file://0001-Remove-fgets-extern-declaration.patch \ |
| 53 | file://0001-Fix-implicit-function-declaration-warnings.patch \ | ||
| 53 | " | 54 | " |
| 54 | 55 | ||
| 55 | SRC_URI[md5sum] = "e6fa25f71226d090f34de3f6b122fb5a" | 56 | SRC_URI[md5sum] = "e6fa25f71226d090f34de3f6b122fb5a" |
