diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2009-12-08 10:00:57 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2009-12-08 10:05:02 +0000 |
commit | bee68ae8e6633b07ccb82ce6d60eab687c3ddc70 (patch) | |
tree | 3aa43d1f63fc5d899f2d3ac0cf15d531fe65772c /main/iptraf/iptraf-3.0.0-vlan.patch | |
parent | d14ba6107e7837d93c1141cdcfd5ee8a3a6a8590 (diff) | |
download | aports-bee68ae8e6633b07ccb82ce6d60eab687c3ddc70.tar.bz2 aports-bee68ae8e6633b07ccb82ce6d60eab687c3ddc70.tar.xz |
main/iptraf: fix for vlan traffic
from http://linux.mantech.ro/IPTraf-fix.html
Diffstat (limited to 'main/iptraf/iptraf-3.0.0-vlan.patch')
-rw-r--r-- | main/iptraf/iptraf-3.0.0-vlan.patch | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/main/iptraf/iptraf-3.0.0-vlan.patch b/main/iptraf/iptraf-3.0.0-vlan.patch new file mode 100644 index 000000000..f0087bf39 --- /dev/null +++ b/main/iptraf/iptraf-3.0.0-vlan.patch @@ -0,0 +1,28 @@ +--- src/packet.c.orig 2008-03-07 17:56:48.000000000 +0200 ++++ src/packet.c 2008-03-07 18:05:41.000000000 +0200 +@@ -101,8 +101,8 @@ + result = LINK_ETHERNET; + else if (strncmp(ifname, "tun", 3) == 0) + result = LINK_ETHERNET; +- else if (strncmp(ifname, "vlan", 3) == 0) +- result = LINK_VLAN; ++ else if (strncmp(ifname, "vlan", 4) == 0) ++ result = LINK_ETHERNET; + else if (strncmp(ifname, "brg", 3) == 0) + result = LINK_ETHERNET; + else if (strncmp(ifname, "tap", 3) == 0) +@@ -231,14 +231,6 @@ + case LINK_IPIP: + *packet = tpacket; + break; +- case LINK_VLAN: +- *packet = tpacket + VLAN_ETH_HLEN; +- readlen -= VLAN_ETH_HLEN; +- /* +- * Move IP datagram into an aligned buffer. +- */ +- memmove(aligned_buf, *packet, min(SNAPSHOT_LEN, *readlen)); +- *packet = aligned_buf; + default: + *packet = (char *) NULL; /* return a NULL packet to signal */ + break; /* an unrecognized link protocol */ |