1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-30 03:19:02 +00:00

Update libpcap to 1.7.3, partially addressing #34

This commit is contained in:
dmiller
2015-05-01 20:24:47 +00:00
parent d8c13c49e1
commit 4bbef7d69b
196 changed files with 9965 additions and 7133 deletions

View File

@@ -28,11 +28,6 @@
* dependent values so we can print the dump file on any architecture.
*/
#ifndef lint
static const char rcsid[] _U_ =
"@(#) $Header: /tcpdump/master/libpcap/savefile.c,v 1.183 2008-12-23 20:13:29 guy Exp $ (LBL)";
#endif
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
@@ -223,14 +218,14 @@ pcap_t* pcap_hopen_offline_with_tstamp_precision(intptr_t osfd, u_int precision,
FILE *file;
fd = _open_osfhandle(osfd, _O_RDONLY);
if ( fd < 0 )
if ( fd < 0 )
{
snprintf(errbuf, PCAP_ERRBUF_SIZE, pcap_strerror(errno));
return NULL;
}
file = _fdopen(fd, "rb");
if ( file == NULL )
if ( file == NULL )
{
snprintf(errbuf, PCAP_ERRBUF_SIZE, pcap_strerror(errno));
return NULL;
@@ -349,6 +344,11 @@ found:
*/
p->oneshot_callback = pcap_oneshot;
/*
* Savefiles never require special BPF code generation.
*/
p->bpf_codegen_flags = 0;
p->activated = 1;
return (p);