blob: 9d1e05d7f4e604d709c6b03dfccbd9cf1a9bdd53 [file] [log] [blame]
Brad Bishop316dfdd2018-06-25 12:45:53 -04001From 7f8878ac1aaf4a19992d39379797c151301bedb1 Mon Sep 17 00:00:00 2001
2From: Oleksiy Obitotskyy <oobitots@cisco.com>
3Date: Mon, 5 Feb 2018 08:29:10 -0800
4Subject: [PATCH] Fix build with clang
5
6Fix "error: non-void function 'fix_options' should return a value".
7Add function prototype to tcpd.c and miscd.c.
8
9Upstream-Status: Pending
10
11Signed-off-by: Oleksiy Obitotskyy <oobitots@cisco.com>
12---
13 v2 - add function prototypes
14
15 fix_options.c | 2 +-
16 miscd.c | 4 ++++
17 tcpd.c | 4 ++++
18 3 files changed, 9 insertions(+), 1 deletion(-)
19
20diff --git a/fix_options.c b/fix_options.c
21index b5e81b8..9958ff4 100644
22--- a/fix_options.c
23+++ b/fix_options.c
24@@ -29,7 +29,7 @@ static char sccsid[] = "@(#) fix_options.c 1.6 97/04/08 02:29:19";
25
26 /* fix_options - get rid of IP-level socket options */
27
28-fix_options(request)
29+void fix_options(request)
30 struct request_info *request;
31 {
32 #ifdef IP_OPTIONS
33diff --git a/miscd.c b/miscd.c
34index 1ab835c..723b83a 100644
35--- a/miscd.c
36+++ b/miscd.c
37@@ -40,6 +40,10 @@ static char sccsid[] = "@(#) miscd.c 1.10 96/02/11 17:01:30";
38 #include "patchlevel.h"
39 #include "tcpd.h"
40
41+#ifdef KILL_IP_OPTIONS
42+void fix_options(struct request_info *);
43+#endif
44+
45 int allow_severity = SEVERITY; /* run-time adjustable */
46 int deny_severity = LOG_WARNING; /* ditto */
47
48diff --git a/tcpd.c b/tcpd.c
49index d865b9c..a179891 100644
50--- a/tcpd.c
51+++ b/tcpd.c
52@@ -38,6 +38,10 @@ static char sccsid[] = "@(#) tcpd.c 1.10 96/02/11 17:01:32";
53 #include "patchlevel.h"
54 #include "tcpd.h"
55
56+#ifdef KILL_IP_OPTIONS
57+void fix_options(struct request_info *);
58+#endif
59+
60 int allow_severity = SEVERITY; /* run-time adjustable */
61 int deny_severity = LOG_WARNING; /* ditto */
62
63--
642.10.3.dirty
65