efl_io_file: unbreak windows build (missing O_CLOEXEC).

To avoid many ifdef, define the flag to 0 so we "| 0" or "& ~0", that
have no effect.

Fixes T4612.
This commit is contained in:
Gustavo Sverzut Barbieri 2016-09-16 07:26:54 -03:00
parent 60f84b733a
commit 6e12d4f86c
1 changed files with 9 additions and 0 deletions

View File

@ -16,6 +16,15 @@
#include <sys/stat.h>
#include <fcntl.h>
#ifndef O_CLOEXEC
/* If a platform doesn't define O_CLOEXEC, then use 0 as we'll "| 0"
* and "& ~0", which have no effect.
*
* This should be the case on _WIN32.
*/
#define O_CLOEXEC (0)
#endif
#define MY_CLASS EFL_IO_FILE_CLASS
typedef struct _Efl_Io_File_Data