diff options
author | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2013-09-10 17:44:32 +0300 |
---|---|---|
committer | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2013-09-10 17:53:07 +0300 |
commit | f04ab838abd90fb70f7d6ef77fdacdf07f09ba4d (patch) | |
tree | 00d3d7834953f6ca2b7a804fe02bfd95f795c6e6 /tests/common | |
parent | e681dd0d75a4b6a7974cc898477f3a138f7872c2 (diff) |
Build fixes for Windows/Visual C++
Diffstat (limited to 'tests/common')
-rw-r--r-- | tests/common/test_helpers.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/common/test_helpers.h b/tests/common/test_helpers.h new file mode 100644 index 00000000..f77760a5 --- /dev/null +++ b/tests/common/test_helpers.h @@ -0,0 +1,17 @@ +/* Compatibility helpers for the test programs. */ + +#ifndef _TEST_HELPERS_H_ +#define _TEST_HELPERS_H_ + +#ifdef _WIN32 +#include <io.h> +#include <fcntl.h> +#define SET_BINARY_MODE(file) setmode(fileno(file), O_BINARY) + +#else +#define SET_BINARY_MODE(file) + +#endif + + +#endif |