source: trunk/lib/pcap_dump_flush.c @ 1070

Last change on this file since 1070 was 1070, checked in by dlawson, 7 years ago
  • wrapping lib/pcap*c with #ifdef HAVE_PCAP so they don't build if we don't have pcap
  • changed some types and defines in linktypes.c to use libtrace internal representations rather than libpcap's, in case we don't have pcap.
  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 315 bytes
Line 
1#ifdef HAVE_PCAP
2#include "config.h"
3
4#ifndef HAVE_PCAP_DUMP_FLUSH
5#include <stdio.h>
6#include <pcap.h>
7#ifdef HAVE_PCAP_INT_H
8# include <pcap-int.h>
9#endif
10#include <string.h>
11
12int pcap_dump_flush(pcap_dumper_t *p) {
13        if (fflush((FILE *)p) == EOF)
14                return (-1);
15        else
16                return (0);
17}
18
19#endif
20
21#endif // HAVE_PCAP
Note: See TracBrowser for help on using the repository browser.