You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
114 lines
3.4 KiB
114 lines
3.4 KiB
11 years ago
|
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
|
||
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
|
||
|
#
|
||
|
# Filename: package/.../musl/pkg/ebtables/ebtables-struct-ethhdr.patch
|
||
|
# Copyright (C) 2014 The OpenSDE Project
|
||
|
#
|
||
|
# More information can be found in the files COPYING and README.
|
||
|
#
|
||
|
# This patch file is dual-licensed. It is available under the license the
|
||
|
# patched project is licensed under, as long as it is an OpenSource license
|
||
|
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
|
||
|
# of the GNU General Public License as published by the Free Software
|
||
|
# Foundation; either version 2 of the License, or (at your option) any later
|
||
|
# version.
|
||
|
# --- SDE-COPYRIGHT-NOTE-END ---
|
||
|
|
||
|
From 94df0e94a42bf2c92c0fa62b9429e2e833eef952 Mon Sep 17 00:00:00 2001
|
||
|
From: Christian Wiese <chris@opensde.org>
|
||
|
Date: Mon, 28 Apr 2014 02:32:37 +0200
|
||
|
Subject: fix redefinition of struct ethhdr
|
||
|
|
||
|
Resort headers so <netinet/if_ether.h> gets before <linux/if_ether.h> to
|
||
|
avoid redefinition of struct ethhdr.
|
||
|
---
|
||
|
extensions/ebt_among.c | 5 +++--
|
||
|
extensions/ebt_arpreply.c | 3 ++-
|
||
|
extensions/ebt_nat.c | 3 ++-
|
||
|
useful_functions.c | 5 +++--
|
||
|
4 files changed, 10 insertions(+), 6 deletions(-)
|
||
|
|
||
|
diff --git a/extensions/ebt_among.c b/extensions/ebt_among.c
|
||
|
index f97d07e..b57b2ad 100644
|
||
|
--- a/extensions/ebt_among.c
|
||
|
+++ b/extensions/ebt_among.c
|
||
|
@@ -12,15 +12,16 @@
|
||
|
#include <getopt.h>
|
||
|
#include <ctype.h>
|
||
|
#include <unistd.h>
|
||
|
-#include "../include/ebtables_u.h"
|
||
|
#include <netinet/ether.h>
|
||
|
-#include "../include/ethernetdb.h"
|
||
|
#include <linux/if_ether.h>
|
||
|
#include <linux/netfilter_bridge/ebt_among.h>
|
||
|
#include <sys/mman.h>
|
||
|
#include <sys/stat.h>
|
||
|
#include <fcntl.h>
|
||
|
|
||
|
+#include "../include/ebtables_u.h"
|
||
|
+#include "../include/ethernetdb.h"
|
||
|
+
|
||
|
#define AMONG_DST '1'
|
||
|
#define AMONG_SRC '2'
|
||
|
#define AMONG_DST_F '3'
|
||
|
diff --git a/extensions/ebt_arpreply.c b/extensions/ebt_arpreply.c
|
||
|
index c3757f3..a1b3503 100644
|
||
|
--- a/extensions/ebt_arpreply.c
|
||
|
+++ b/extensions/ebt_arpreply.c
|
||
|
@@ -11,10 +11,11 @@
|
||
|
#include <stdlib.h>
|
||
|
#include <string.h>
|
||
|
#include <getopt.h>
|
||
|
-#include "../include/ebtables_u.h"
|
||
|
#include <netinet/ether.h>
|
||
|
#include <linux/netfilter_bridge/ebt_arpreply.h>
|
||
|
|
||
|
+#include "../include/ebtables_u.h"
|
||
|
+
|
||
|
static int mac_supplied;
|
||
|
|
||
|
#define REPLY_MAC '1'
|
||
|
diff --git a/extensions/ebt_nat.c b/extensions/ebt_nat.c
|
||
|
index e6afbf8..ae9c9bb 100644
|
||
|
--- a/extensions/ebt_nat.c
|
||
|
+++ b/extensions/ebt_nat.c
|
||
|
@@ -10,10 +10,11 @@
|
||
|
#include <stdlib.h>
|
||
|
#include <string.h>
|
||
|
#include <getopt.h>
|
||
|
-#include "../include/ebtables_u.h"
|
||
|
#include <netinet/ether.h>
|
||
|
#include <linux/netfilter_bridge/ebt_nat.h>
|
||
|
|
||
|
+#include "../include/ebtables_u.h"
|
||
|
+
|
||
|
static int to_source_supplied, to_dest_supplied;
|
||
|
|
||
|
#define NAT_S '1'
|
||
|
diff --git a/useful_functions.c b/useful_functions.c
|
||
|
index d20b68e..b305ff5 100644
|
||
|
--- a/useful_functions.c
|
||
|
+++ b/useful_functions.c
|
||
|
@@ -22,8 +22,6 @@
|
||
|
* along with this program; if not, write to the Free Software
|
||
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||
|
*/
|
||
|
-#include "include/ebtables_u.h"
|
||
|
-#include "include/ethernetdb.h"
|
||
|
#include <stdio.h>
|
||
|
#include <netinet/ether.h>
|
||
|
#include <string.h>
|
||
|
@@ -34,6 +32,9 @@
|
||
|
#include <sys/socket.h>
|
||
|
#include <arpa/inet.h>
|
||
|
|
||
|
+#include "include/ebtables_u.h"
|
||
|
+#include "include/ethernetdb.h"
|
||
|
+
|
||
|
const unsigned char mac_type_unicast[ETH_ALEN] = {0,0,0,0,0,0};
|
||
|
const unsigned char msk_type_unicast[ETH_ALEN] = {1,0,0,0,0,0};
|
||
|
const unsigned char mac_type_multicast[ETH_ALEN] = {1,0,0,0,0,0};
|
||
|
--
|
||
|
1.7.2.3
|
||
|
|