okra pushed a commit to branch master.

http://git.enlightenment.org/apps/ephoto.git/commit/?id=38c246b000641b690712fcb8b8341e5488ad86d0

commit 38c246b000641b690712fcb8b8341e5488ad86d0
Author: Stephen okra Houston <smhousto...@gmail.com>
Date:   Mon Nov 28 12:03:35 2016 -0600

    Ephoto: Fix coverity issues: CIDS 151514 151512
---
 src/bin/ephoto_directory_browser.c | 7 ++-----
 src/bin/ephoto_file.c              | 2 +-
 2 files changed, 3 insertions(+), 6 deletions(-)

diff --git a/src/bin/ephoto_directory_browser.c 
b/src/bin/ephoto_directory_browser.c
index 75c6c3d..d1b30e0 100644
--- a/src/bin/ephoto_directory_browser.c
+++ b/src/bin/ephoto_directory_browser.c
@@ -1160,11 +1160,8 @@ ephoto_directory_browser_initialize_structure(Ephoto 
*ephoto)
              dir = strdup(path);
              while (strcmp(dir, ephoto->config->open))
                {
-                  if (dir)
-                    {
-                       free(dir);
-                       dir = NULL;
-                    }
+                  free(dir);
+                  dir = NULL;
                   dir = ecore_file_dir_get(path);
                   dirs = eina_list_prepend(dirs, strdup(dir));
                   memset(path, 0x00, sizeof(path));
diff --git a/src/bin/ephoto_file.c b/src/bin/ephoto_file.c
index acf4238..6d89ea5 100644
--- a/src/bin/ephoto_file.c
+++ b/src/bin/ephoto_file.c
@@ -939,7 +939,7 @@ _prompt_upload_apply(void *data, Evas_Object *obj 
EINA_UNUSED,
    rewind(f);
    fdata = malloc(fsize);
    res = fread(fdata, fsize, 1, f);
-   if (res < 1) CRIT("fread() failed on file '%s': %s", entry->path, 
strerror(errno));
+   if (res < 1) CRIT("fread() failed on file '%s': %s", entry->path, 
strerror(errno)); 
    res = fclose(f);
    if (!res) CRIT("fclose() failed on file '%s': %s", entry->path, 
strerror(errno));
 

-- 


Reply via email to