tcpdump mailing list archives
[Patch] pcap-dos.c
From: Gisle Vanem <gvanem () broadpark no>
Date: Thu, 28 Mar 2013 13:53:37 +0100
This file has fallen behind since pcap_create() was put in pcap.c long time ago (a more generic create-function). Hence: --- Git-Latest\pcap-dos.c Wed Nov 28 23:41:44 2012 +++ pcap-dos.c Thu Nov 29 00:00:12 2012 @@ -143,7 +143,7 @@ return handle_to_device [fd-1]; } -pcap_t *pcap_create (const char *device, char *ebuf) +pcap_t *pcap_create_interface (const char *device, char *ebuf) { pcap_t *p; @@ -211,7 +211,7 @@ pcap_read_one (pcap_t *p, pcap_handler callback, u_char *data) { struct pcap_pkthdr pcap; - struct timeval now, expiry; + struct timeval now, expiry = { 0,0 }; BYTE *rx_buf; int rx_len = 0; @@ -287,7 +287,7 @@ return (1); } - /* If not to wait for a packet or pcap_close() called from + /* If not to wait for a packet or pcap_cleanup_dos() called from * e.g. SIGINT handler, exit loop now. */ if (p->md.timeout <= 0 || (volatile int)p->fd <= 0) ------------------ The change in the comment is just to make it clear it's not pcap_close() that's called directly. --gv _______________________________________________ tcpdump-workers mailing list tcpdump-workers () lists tcpdump org https://lists.sandelman.ca/mailman/listinfo/tcpdump-workers
Current thread:
- [Patch] pcap-dos.c Gisle Vanem (Mar 28)
- Re: [Patch] pcap-dos.c Guy Harris (Mar 28)