summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@samsung.com>2019-03-06 08:37:25 -0500
committerMike Blumenkrantz <zmike@samsung.com>2019-03-06 08:37:25 -0500
commit9acd9a16f858cfe4d1aa4e60e9517f0d7200b032 (patch)
treebb00cd1228705643c67432902c3c077f3c9299ca
parent8f9cbdc09e14de7785429f9bfcb557a27310aa1f (diff)
efl.file: use ENOENT as default error if file opening fails and errno isn't set
Summary: ensure that a nonzero return happens here so that failure cases can be correctly detected Reviewers: vtorri, bu5hm4n Reviewed By: bu5hm4n Subscribers: bu5hm4n, raster, cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D8103
-rw-r--r--src/lib/efl/interfaces/efl_file.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/efl/interfaces/efl_file.c b/src/lib/efl/interfaces/efl_file.c
index 3acdc17ce8..67619039c9 100644
--- a/src/lib/efl/interfaces/efl_file.c
+++ b/src/lib/efl/interfaces/efl_file.c
@@ -40,7 +40,7 @@ _efl_file_load(Eo *obj, Efl_File_Data *pd)
40 { 40 {
41 Eina_File *f; 41 Eina_File *f;
42 f = eina_file_open(pd->vpath, EINA_FALSE); 42 f = eina_file_open(pd->vpath, EINA_FALSE);
43 if (!f) return errno; 43 if (!f) return errno ?: ENOENT;
44 pd->file_opened = EINA_TRUE; 44 pd->file_opened = EINA_TRUE;
45 pd->setting = 1; 45 pd->setting = 1;
46 ret = efl_file_mmap_set(obj, f); 46 ret = efl_file_mmap_set(obj, f);