summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/tcp-wrappers/tcp-wrappers-7.6/0001-Fix-implicit-function-declaration-warnings.patch
blob: 85031779261606494c4362995358a56bc6bdfb78 (plain)
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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
From 9c97b5db237a793e0d1b6b0241570bdc6e35ee24 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Sun, 7 Aug 2022 17:42:24 -0700
Subject: [PATCH] Fix implicit-function-declaration warnings

These are seen with clang-15+

Upstream-Status: Inactive-Upstream [current release is from 1997; no vcs anywhere]
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 hosts_access.c | 3 +++
 safe_finger.c  | 1 +
 shell_cmd.c    | 3 +++
 tcpd.c         | 2 +-
 tcpdchk.c      | 1 +
 workarounds.c  | 1 +
 6 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/hosts_access.c b/hosts_access.c
index 0133e5e..58697ea 100644
--- a/hosts_access.c
+++ b/hosts_access.c
@@ -33,6 +33,12 @@ static char sccsid[] = "@(#) hosts_access.c 1.21 97/02/12 02:13:22";
 #endif
 #include <netinet/in.h>
 #include <arpa/inet.h>
+#ifdef USE_GETDOMAIN
+/* defined in workarounds.c */
+extern int     yp_get_default_domain(char **ptr);
+#else
+#  include <rpcsvc/ypclnt.h>
+#endif	/* USE_GETDOMAIN */
 #include <stdio.h>
 #include <stdlib.h>
 #include <syslog.h>
@@ -45,6 +46,8 @@ static char sccsid[] = "@(#) hosts_access.c 1.21 97/02/12 02:13:22";
 #endif
 
 extern int errno;
+extern int match_pattern_ylo(const char *s, const char *pattern);
+extern unsigned long cidr_mask_addr(char* str);
 
 #ifndef	INADDR_NONE
 #define	INADDR_NONE	(-1)		/* XXX should be 0xffffffff */
diff --git a/safe_finger.c b/safe_finger.c
index 23afab1..a6458fb 100644
--- a/safe_finger.c
+++ b/safe_finger.c
@@ -34,6 +34,7 @@ static char sccsid[] = "@(#) safe_finger.c 1.4 94/12/28 17:42:41";
 #include <syslog.h>
 
 extern void exit();
+extern int pipe_stdin(char  **argv);
 
 /* Local stuff */
 
diff --git a/shell_cmd.c b/shell_cmd.c
index 62d31bc..a566092 100644
--- a/shell_cmd.c
+++ b/shell_cmd.c
@@ -16,10 +16,13 @@ static char sccsid[] = "@(#) shell_cmd.c 1.5 94/12/28 17:42:44";
 
 #include <sys/types.h>
 #include <sys/param.h>
+#include <sys/wait.h>
+#include <fcntl.h>
 #include <signal.h>
 #include <stdio.h>
 #include <syslog.h>
 #include <string.h>
+#include <unistd.h>
 
 extern void exit();
 
diff --git a/tcpd.c b/tcpd.c
index dc9ff17..4353caa 100644
--- a/tcpd.c
+++ b/tcpd.c
@@ -46,7 +46,7 @@ void fix_options(struct request_info *);
 int     allow_severity = SEVERITY;	/* run-time adjustable */
 int     deny_severity = LOG_WARNING;	/* ditto */
 
-main(argc, argv)
+void main(argc, argv)
 int     argc;
 char  **argv;
 {
diff --git a/tcpdchk.c b/tcpdchk.c
index 5dca8bd..67c12ce 100644
--- a/tcpdchk.c
+++ b/tcpdchk.c
@@ -38,6 +38,7 @@ static char sccsid[] = "@(#) tcpdchk.c 1.8 97/02/12 02:13:25";
 
 extern int errno;
 extern void exit();
+extern unsigned long cidr_mask_addr(char* str);
 extern int optind;
 extern char *optarg;
 
diff --git a/workarounds.c b/workarounds.c
index b22b378..6335049 100644
--- a/workarounds.c
+++ b/workarounds.c
@@ -21,6 +21,7 @@ char    sccsid[] = "@(#) workarounds.c 1.6 96/03/19 16:22:25";
 #include <stdio.h>
 #include <syslog.h>
 #include <string.h>
+#include <unistd.h>
 
 extern int errno;
 
-- 
2.37.1