aboutsummaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorTobias Kortkamp <tobik@FreeBSD.org>2020-07-05 09:46:37 +0000
committerTobias Kortkamp <tobik@FreeBSD.org>2020-07-05 09:46:37 +0000
commit88b1f4328d007c13d2f039bc7cb1952c40a00611 (patch)
tree588296204026c77ec1b59259879d8588b9d4f69d /net
parent64b09ee5e190f1e19a590e789e552c1e18649f9a (diff)
downloadports-88b1f4328d007c13d2f039bc7cb1952c40a00611.tar.gz
ports-88b1f4328d007c13d2f039bc7cb1952c40a00611.zip
Notes
Diffstat (limited to 'net')
-rw-r--r--net/l2tpd/Makefile1
-rw-r--r--net/l2tpd/files/patch-control.c51
2 files changed, 49 insertions, 3 deletions
diff --git a/net/l2tpd/Makefile b/net/l2tpd/Makefile
index fef0858100cf..58c68b893e01 100644
--- a/net/l2tpd/Makefile
+++ b/net/l2tpd/Makefile
@@ -14,6 +14,7 @@ BROKEN_armv6= fails to link: undefined reference to check_control
BROKEN_armv7= fails to link: undefined reference to check_control
USES= compiler:nestedfct
+CFLAGS+= -fcommon
PORTDOCS= README
ETCDIR= ${PREFIX}/etc/l2tp
diff --git a/net/l2tpd/files/patch-control.c b/net/l2tpd/files/patch-control.c
index 6e0b458d9baa..28921bd4dae2 100644
--- a/net/l2tpd/files/patch-control.c
+++ b/net/l2tpd/files/patch-control.c
@@ -1,5 +1,5 @@
---- control.c.orig.o Thu Apr 11 00:09:33 2002
-+++ control.c Tue Aug 9 13:20:07 2005
+--- control.c.orig 2002-04-10 20:09:33 UTC
++++ control.c
@@ -16,8 +16,6 @@
#include <errno.h>
#include <string.h>
@@ -9,7 +9,43 @@
#include <unistd.h>
#include <stdlib.h>
#include "l2tp.h"
-@@ -1582,6 +1580,12 @@
+@@ -1076,7 +1074,7 @@ int control_finish (struct tunnel *t, struct call *c)
+ return 0;
+ }
+
+-inline int check_control (const struct buffer *buf, struct tunnel *t,
++static inline int check_control (const struct buffer *buf, struct tunnel *t,
+ struct call *c)
+ {
+ /*
+@@ -1212,7 +1210,7 @@ inline int check_control (const struct buffer *buf, st
+ return 0;
+ }
+
+-inline int check_payload (struct buffer *buf, struct tunnel *t,
++static inline int check_payload (struct buffer *buf, struct tunnel *t,
+ struct call *c)
+ {
+ /*
+@@ -1318,7 +1316,7 @@ inline int check_payload (struct buffer *buf, struct t
+ #endif
+ return 0;
+ }
+-inline int expand_payload (struct buffer *buf, struct tunnel *t,
++static inline int expand_payload (struct buffer *buf, struct tunnel *t,
+ struct call *c)
+ {
+ /*
+@@ -1498,7 +1496,7 @@ void send_zlb (void *data)
+ toss (buf);
+ }
+
+-inline int write_packet (struct buffer *buf, struct tunnel *t, struct call *c,
++static inline int write_packet (struct buffer *buf, struct tunnel *t, struct call *c,
+ int convert)
+ {
+ /*
+@@ -1582,6 +1580,12 @@ inline int write_packet (struct buffer *buf, struct tu
wbuf[pos++] = e;
for (x = 0; x < buf->len; x++)
{
@@ -22,3 +58,12 @@
e = *((char *) buf->start + x);
if ((e < 0x20) || (e == PPP_ESCAPE) || (e == PPP_FLAG))
{
+@@ -1657,7 +1661,7 @@ void handle_special (struct buffer *buf, struct call *
+ }
+ }
+
+-inline int handle_packet (struct buffer *buf, struct tunnel *t,
++int handle_packet (struct buffer *buf, struct tunnel *t,
+ struct call *c)
+ {
+ int res;