From 21e5d7edc4f28157254ef29a8ac247f3a572f6a6 Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Thu, 17 Dec 2015 16:28:38 +0000 Subject: [PATCH] [util] Use O_BINARY instead of _O_BINARY The latter doesn't seem to be available in Cygwin. I'm surprised it compiled before... --- util/options.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util/options.cc b/util/options.cc index 882e06072..bc699c1d1 100644 --- a/util/options.cc +++ b/util/options.cc @@ -490,7 +490,7 @@ font_options_t::get_font (void) const GString *gs = g_string_new (NULL); char buf[BUFSIZ]; #if defined(_WIN32) || defined(__CYGWIN__) - setmode (fileno (stdin), _O_BINARY); + setmode (fileno (stdin), O_BINARY); #endif while (!feof (stdin)) { size_t ret = fread (buf, 1, sizeof (buf), stdin); @@ -672,7 +672,7 @@ output_options_t::get_file_handle (void) fp = fopen (output_file, "wb"); else { #if defined(_WIN32) || defined(__CYGWIN__) - setmode (fileno (stdout), _O_BINARY); + setmode (fileno (stdout), O_BINARY); #endif fp = stdout; }