netstar pushed a commit to branch master.

http://git.enlightenment.org/apps/evisum.git/commit/?id=b3d388ecbfcef103b39e276f9c9b91b027c799b5

commit b3d388ecbfcef103b39e276f9c9b91b027c799b5
Author: Alastair Poole <[email protected]>
Date:   Tue Oct 9 12:45:27 2018 +0100

    rel: 0.2.0
    
    Last release before redesign.
---
 NEWS         |  7 +++++++
 src/main.c   |  2 +-
 src/system.c | 11 ++++++++---
 src/ui.c     |  3 +++
 4 files changed, 19 insertions(+), 4 deletions(-)

diff --git a/NEWS b/NEWS
index 2a07d29..4f1ef14 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,10 @@
+============
+Evisum 0.2.0
+============
+
+   * Add variable unit display (K, M and G).
+   * Minor refactoring.
+
 ============
 Evisum 0.1.2
 ============
diff --git a/src/main.c b/src/main.c
index 8fade04..397ed06 100644
--- a/src/main.c
+++ b/src/main.c
@@ -2,7 +2,7 @@
    See LICENSE file for details.
  */
 
-#define VERSION "0.1.1"
+#define VERSION "0.2.0"
 
 #include "process.h"
 #include "system.h"
diff --git a/src/system.c b/src/system.c
index 6d4093a..7275db4 100644
--- a/src/system.c
+++ b/src/system.c
@@ -109,7 +109,7 @@ Fcontents(const char *path)
    int n = 1024;
 
    buf = malloc(n * sizeof(byte) + 1);
-   if (!buf) exit(0 << 1);
+   if (!buf) return NULL;
 
    while ((count = (fread(byte, sizeof(byte), 1, f))) > 0)
      {
@@ -118,13 +118,18 @@ Fcontents(const char *path)
           {
              n *= 2;
              char *tmp = realloc(buf, n * sizeof(byte) + 1);
-             if (!tmp) exit(1 << 1);
+             if (!tmp) return NULL;
              buf = tmp;
           }
         memcpy(&buf[bytes - sizeof(byte)], byte, sizeof(byte));
      }
 
-   if (!feof(f)) exit(2 << 1);
+   if (!feof(f))
+     {
+        free(buf);
+        fclose(f);
+        return NULL;
+     }
    fclose(f);
 
    buf[bytes] = 0;
diff --git a/src/ui.c b/src/ui.c
index a350086..a461c49 100644
--- a/src/ui.c
+++ b/src/ui.c
@@ -38,6 +38,9 @@ ui_shutdown(Ui *ui)
    if (ui->thread_process)
      ecore_thread_wait(ui->thread_process, 1.0);
 
+
+   eina_lock_free(&_lock);
+
    ecore_main_loop_quit();
 }
 

-- 


Reply via email to