From b9084821372f987dbc1eccec360e2f3eadb270aa Mon Sep 17 00:00:00 2001 From: guy Date: Tue, 23 Dec 2008 20:13:29 +0000 Subject: Update CHANGES for USB fixes. Update CREDITS to give Jon Smirl credit for some of the USB fixes. Rename DLT_USB_LINUX_MMAP to DLT_USB_LINUX_MMAPPED, and declare a structure for the header of packets in DLT_USB_LINUX_MMAPPED captures. --- pcap-usb-linux.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'pcap-usb-linux.c') diff --git a/pcap-usb-linux.c b/pcap-usb-linux.c index e8c3972..d399c75 100644 --- a/pcap-usb-linux.c +++ b/pcap-usb-linux.c @@ -34,7 +34,7 @@ */ #ifndef lint static const char rcsid[] _U_ = - "@(#) $Header: /tcpdump/master/libpcap/pcap-usb-linux.c,v 1.29 2008-12-23 19:05:26 guy Exp $ (LBL)"; + "@(#) $Header: /tcpdump/master/libpcap/pcap-usb-linux.c,v 1.30 2008-12-23 20:13:29 guy Exp $ (LBL)"; #endif #ifdef HAVE_CONFIG_H @@ -255,7 +255,7 @@ usb_activate(pcap_t* handle) /* binary api is available, try to use fast mmap access */ if (usb_mmap(handle)) { - handle->linktype = DLT_USB_LINUX_MMAP; + handle->linktype = DLT_USB_LINUX_MMAPPED; handle->stats_op = usb_stats_linux_bin; handle->read_op = usb_read_linux_mmap; handle->cleanup_op = usb_cleanup_linux_mmap; @@ -733,8 +733,8 @@ usb_read_linux_mmap(pcap_t *handle, int max_packets, pcap_handler callback, u_ch clen = hdr->data_len; /* get packet info from header*/ - pkth.caplen = clen + MMAPPED_USB_HEADER_SIZE; - pkth.len = hdr->data_len + MMAPPED_USB_HEADER_SIZE; + pkth.caplen = clen + sizeof(pcap_usb_header_mmapped); + pkth.len = hdr->data_len + sizeof(pcap_usb_header_mmapped); pkth.ts.tv_sec = hdr->ts_sec; pkth.ts.tv_usec = hdr->ts_usec; -- cgit v1.2.3