From b10a6917f456125491411f0fc13dd3efae455df8 Mon Sep 17 00:00:00 2001 From: komh Date: Thu, 4 Mar 2010 14:46:44 +0000 Subject: Define HAVE_SETMODE conditionally, and use it in stream/stream_file.c instead of platform specific predefined macros. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@30829 b3059339-0415-0410-9bf9-f77b7e298cf2 --- stream/stream_file.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'stream/stream_file.c') diff --git a/stream/stream_file.c b/stream/stream_file.c index dceea84db0..9fda32b185 100644 --- a/stream/stream_file.c +++ b/stream/stream_file.c @@ -145,14 +145,14 @@ static int open_f(stream_t *stream,int mode, void* opts, int* file_format) { // read from stdin mp_msg(MSGT_OPEN,MSGL_INFO,MSGTR_ReadSTDIN); f=0; // 0=stdin -#if defined(__MINGW32__) || defined(__OS2__) - setmode(fileno(stdin),O_BINARY); +#if HAVE_SETMODE + setmode(fileno(stdin),O_BINARY); #endif } else { mp_msg(MSGT_OPEN,MSGL_INFO,"Writing to stdout\n"); f=1; -#if defined(__MINGW32__) || defined(__OS2__) - setmode(fileno(stdout),O_BINARY); +#if HAVE_SETMODE + setmode(fileno(stdout),O_BINARY); #endif } } else { -- cgit v1.2.3