forked from enlightenment/efl
[win32] use the correct value for an invalid handle and check results. Remove trailing spaces
SVN revision: 33579
This commit is contained in:
parent
ebdbf7c6ec
commit
0f79f11a02
|
@ -749,10 +749,11 @@ eet_open(const char *file, Eet_File_Mode mode)
|
|||
fcntl(fileno(ef->fp), F_SETFD, FD_CLOEXEC);
|
||||
#else
|
||||
/* FIXME: check if that code is needed / correct */
|
||||
h = (HANDLE) _get_osfhandle (fileno(ef->fp));
|
||||
if (h == (HANDLE) -1)
|
||||
h = (HANDLE) _get_osfhandle(fileno(ef->fp));
|
||||
if (h == INVALID_HANDLE_VALUE)
|
||||
return NULL;
|
||||
if (!SetHandleInformation(h, HANDLE_FLAG_INHERIT, 0))
|
||||
return NULL;
|
||||
SetHandleInformation (h, HANDLE_FLAG_INHERIT, 0);
|
||||
#endif
|
||||
/* if we opened for read or read-write */
|
||||
if ((mode == EET_FILE_MODE_READ) || (mode == EET_FILE_MODE_READ_WRITE))
|
||||
|
|
Loading…
Reference in New Issue