dect
/
libpcap
Archived
1
0
Fork 0

Added the definition of SET_BINMODE under WIN32.

master
test2 13 years ago
parent 5377f7340b
commit b3eca60b5c
  1. 13
      sf-pcap.c

@ -67,6 +67,19 @@ static const char rcsid[] _U_ =
#include "sf-pcap.h"
/*
* Setting O_BINARY on DOS/Windows is a bit tricky
*/
#if defined(WIN32)
#define SET_BINMODE(f) _setmode(_fileno(f), _O_BINARY)
#elif defined(MSDOS)
#if defined(__HIGHC__)
#define SET_BINMODE(f) setmode(f, O_BINARY)
#else
#define SET_BINMODE(f) setmode(fileno(f), O_BINARY)
#endif
#endif
/*
* Standard libpcap format.
*/