Mercurial > libavformat.hg
diff file.c @ 2205:28eb72f5208a libavformat
Check for O_BINARY instead of a list of systems that need it
author | ramiro |
---|---|
date | Mon, 25 Jun 2007 20:34:20 +0000 |
parents | 5ce5fad0dfac |
children | 3dfa90f47d53 |
line wrap: on
line diff
--- a/file.c Mon Jun 25 16:18:28 2007 +0000 +++ b/file.c Mon Jun 25 20:34:20 2007 +0000 @@ -41,7 +41,7 @@ } else { access = O_RDONLY; } -#if defined(__MINGW32__) || defined(CONFIG_OS2) || defined(__CYGWIN__) +#ifdef O_BINARY access |= O_BINARY; #endif fd = open(filename, access, 0666); @@ -96,7 +96,7 @@ } else { fd = 0; } -#if defined(__MINGW32__) || defined(CONFIG_OS2) || defined(__CYGWIN__) +#ifdef O_BINARY setmode(fd, O_BINARY); #endif h->priv_data = (void *)(size_t)fd;