1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-02-05 11:35:01 +00:00

- Fix not real world communications via gen_eth (FreeBSD's libpcap) issue [1]

- Add LICENSE [2]
- Remove MD5 from distinfo

PR:		ports/154521
Submitted by:	Alexander V. Chernikov <melifaro@ipfw.ru> [1]
		Pavel Volkov <pavelivolkov@googlemail.com> [2] (maintainer)
Approved by:	maintainer
This commit is contained in:
Andrej Zverev 2011-02-10 20:35:33 +00:00
parent b8344202c1
commit 65296b5804
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=268896
3 changed files with 28 additions and 2 deletions

View File

@ -7,7 +7,7 @@
PORTNAME= dynamips
DISTVERSION= 0.2.8-RC2
PORTREVISION= 2
PORTREVISION= 3
CATEGORIES= emulators
MASTER_SITES= http://www.ipflow.utc.fr/dynamips/
PKGNAMESUFFIX= -devel
@ -18,6 +18,7 @@ COMMENT= Cisco 1700/2600/3600/3700/7200 Simulator
LIB_DEPENDS= elf.0:${PORTSDIR}/devel/libelf
CONFLICTS= dynamips-[0-9]*
LICENSE= GPLv2
USE_GMAKE= yes
ALL_TARGET= ${PORTNAME} nvram_export

View File

@ -1,3 +1,2 @@
MD5 (dynamips-0.2.8-RC2.tar.gz) = 8d12d28684d164fe3312a3fe43c84d2e
SHA256 (dynamips-0.2.8-RC2.tar.gz) = a8b377ce631119e285c401fdb7cb4d0bcc600a15508bdffcf337546957e252de
SIZE (dynamips-0.2.8-RC2.tar.gz) = 578935

View File

@ -0,0 +1,26 @@
--- gen_eth.c.orig 2007-05-26 18:52:33.000000000 +0900
+++ gen_eth.c 2009-07-21 03:18:35.194759073 +0900
@@ -22,6 +22,7 @@
#include <sys/types.h>
#include <sys/socket.h>
#include <sys/wait.h>
+#include <sys/ioctl.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <pthread.h>
@@ -45,8 +46,13 @@
if (!(p = pcap_open_live(device,2048,TRUE,10,pcap_errbuf)))
goto pcap_error;
- /* Accept only incoming packets */
- pcap_setdirection(p,PCAP_D_IN);
+ pcap_setdirection(p,PCAP_D_INOUT);
+#ifdef BIOCFEEDBACK
+ {
+ int on = 1;
+ ioctl(pcap_fileno(p), BIOCFEEDBACK, &on);
+ }
+#endif
#else
p = pcap_open(device,2048,
PCAP_OPENFLAG_PROMISCUOUS |