summaryrefslogtreecommitdiff
path: root/src/modules/ecore_evas/engines/extn
diff options
context:
space:
mode:
authorVincent Torri <vincent dot torri at gmail dot com>2015-12-03 11:42:08 +0100
committerCedric BAIL <cedric@osg.samsung.com>2015-12-05 21:06:04 +0100
commit0497b9685c782c24fba84a1d5391edaa8d5ce10a (patch)
tree7a9547ea7ab407cfa555598646302bbc0b21b8c4 /src/modules/ecore_evas/engines/extn
parent4f242fb48a5cf18b6e5ea6598681486abf791771 (diff)
efl: add binary mode to open() calls
This allows better compatibility with Windows Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
Diffstat (limited to 'src/modules/ecore_evas/engines/extn')
-rw-r--r--src/modules/ecore_evas/engines/extn/ecore_evas_extn_buf.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/modules/ecore_evas/engines/extn/ecore_evas_extn_buf.c b/src/modules/ecore_evas/engines/extn/ecore_evas_extn_buf.c
index 245534fba3..28ffcc31f9 100644
--- a/src/modules/ecore_evas/engines/extn/ecore_evas_extn_buf.c
+++ b/src/modules/ecore_evas/engines/extn/ecore_evas_extn_buf.c
@@ -1,5 +1,9 @@
1#include "ecore_evas_extn_engine.h" 1#include "ecore_evas_extn_engine.h"
2 2
3#ifndef O_BINARY
4# define O_BINARY 0
5#endif
6
3struct _Extnbuf 7struct _Extnbuf
4{ 8{
5 const char *file, *lock; 9 const char *file, *lock;
@@ -165,7 +169,7 @@ _extnbuf_lock_file_set(Extnbuf *b, const char *file)
165 } 169 }
166 b->lock = eina_stringshare_add(file); 170 b->lock = eina_stringshare_add(file);
167 if (!b->lock) goto err; 171 if (!b->lock) goto err;
168 b->lockfd = open(b->lock, O_RDWR); 172 b->lockfd = open(b->lock, O_RDWR | O_BINARY);
169 if (b->lockfd >= 0) return EINA_TRUE; 173 if (b->lockfd >= 0) return EINA_TRUE;
170err: 174err:
171 if (b->lock) eina_stringshare_del(b->lock); 175 if (b->lock) eina_stringshare_del(b->lock);