24 lines
760 B
Text
24 lines
760 B
Text
$NetBSD: patch-ab,v 1.2 2006/03/14 02:38:16 joerg Exp $
|
|
|
|
--- interfaces-bpf.cc.orig 2003-03-17 09:32:30.000000000 +0000
|
|
+++ interfaces-bpf.cc
|
|
@@ -15,6 +15,7 @@
|
|
GNU General Public License for more details.
|
|
******************************************************************************/
|
|
|
|
+#include <assert.h>
|
|
#include <unistd.h>
|
|
#include <stdio.h>
|
|
#include <fcntl.h>
|
|
@@ -383,7 +384,11 @@ int BPFInterfaces::send_packet(int ifn,
|
|
/* write this packet: */
|
|
iov[0].iov_base = (char* )ðer_packet;
|
|
iov[0].iov_len = sizeof(ether_packet);
|
|
+#if defined(__DragonFly__)
|
|
+ iov[1].iov_base = (char *)data;
|
|
+#else
|
|
iov[1].iov_base = data;
|
|
+#endif
|
|
iov[1].iov_len = len;
|
|
if (writev(_latd_bpf_fd, iov, 2) < 0) {
|
|
syslog(LOG_ERR, "writev: %m");
|