ipsend.c (153881) | ipsend.c (161357) |
---|---|
1/* $FreeBSD: head/contrib/ipfilter/ipsend/ipsend.c 153881 2005-12-30 11:52:26Z guido $ */ | 1/* $FreeBSD: head/contrib/ipfilter/ipsend/ipsend.c 161357 2006-08-16 12:23:02Z guido $ */ |
2/* 3 * ipsend.c (C) 1995-1998 Darren Reed 4 * 5 * See the IPFILTER.LICENCE file for details on licencing. 6 */ 7#if !defined(lint) 8static const char sccsid[] = "@(#)ipsend.c 1.5 12/10/95 (C)1995 Darren Reed"; | 2/* 3 * ipsend.c (C) 1995-1998 Darren Reed 4 * 5 * See the IPFILTER.LICENCE file for details on licencing. 6 */ 7#if !defined(lint) 8static const char sccsid[] = "@(#)ipsend.c 1.5 12/10/95 (C)1995 Darren Reed"; |
9static const char rcsid[] = "@(#)$Id: ipsend.c,v 2.8.2.2 2004/11/13 16:50:10 darrenr Exp $"; | 9static const char rcsid[] = "@(#)$Id: ipsend.c,v 2.8.2.3 2006/03/17 13:45:34 darrenr Exp $"; |
10#endif 11#include <sys/param.h> 12#include <sys/types.h> 13#include <sys/time.h> 14#include <sys/socket.h> 15#include <netinet/in.h> 16#include <arpa/inet.h> 17#include <netinet/in_systm.h> --- 132 unchanged lines hidden (view full) --- 150char *dev; 151int mtu; 152ip_t *ip; 153struct in_addr gwip; 154{ 155 int wfd; 156 157 wfd = initdevice(dev, 5); | 10#endif 11#include <sys/param.h> 12#include <sys/types.h> 13#include <sys/time.h> 14#include <sys/socket.h> 15#include <netinet/in.h> 16#include <arpa/inet.h> 17#include <netinet/in_systm.h> --- 132 unchanged lines hidden (view full) --- 150char *dev; 151int mtu; 152ip_t *ip; 153struct in_addr gwip; 154{ 155 int wfd; 156 157 wfd = initdevice(dev, 5); |
158 if (wfd == -1) 159 return -1; |
|
158 return send_packet(wfd, mtu, ip, gwip); 159} 160 161void 162udpcksum(ip_t *ip, struct udphdr *udp, int len) 163{ 164 union pseudoh { 165 struct hdr { --- 273 unchanged lines hidden --- | 160 return send_packet(wfd, mtu, ip, gwip); 161} 162 163void 164udpcksum(ip_t *ip, struct udphdr *udp, int len) 165{ 166 union pseudoh { 167 struct hdr { --- 273 unchanged lines hidden --- |