cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=4096a185232ce685db92b391d8a8cc241a090b2c

commit 4096a185232ce685db92b391d8a8cc241a090b2c
Author: Cedric Bail <cedric.b...@samsung.com>
Date:   Wed Nov 20 20:04:58 2013 +0900

    edje: fix use of eina_hash_pointer_new to actually look at the right value.
---
 ChangeLog                 |  1 +
 NEWS                      |  3 ++-
 src/lib/edje/edje_cache.c | 10 +++++-----
 3 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 6c3dea3..b9c4c28 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,7 @@
 2013-11-20  Cedric Bail
 
        * Eina: Fix a possible race condition during eina_file_close.
+       * Edje: Fix use of eina_hash_pointer to actually look at the pointer.
 
 2013-11-19  Tom Hacohen
 
diff --git a/NEWS b/NEWS
index 5ce9bcf..01803f8 100644
--- a/NEWS
+++ b/NEWS
@@ -435,7 +435,8 @@ Fixes:
      - Fix size calculation of flags of signal callbacks
      - Check for both Lua 5.1 and 5.2.
      - Fixed memory leak in the edje map color transition.
-        - Add null checking for name of anchor and item in geometry get 
functions.
+     - Add null checking for name of anchor and item in geometry get functions.
+     - Fix use of eina_hash_pointer to actually look at the pointer value.
 
     * Efreet:
      - Fix desktop command parsing of https.
diff --git a/src/lib/edje/edje_cache.c b/src/lib/edje/edje_cache.c
index f2e9b20..607eff5 100644
--- a/src/lib/edje/edje_cache.c
+++ b/src/lib/edje/edje_cache.c
@@ -388,7 +388,7 @@ _edje_file_dangling(Edje_File *edf)
    if (edf->dangling) return;
    edf->dangling = EINA_TRUE;
 
-   eina_hash_del(_edje_file_hash, edf->f, edf);
+   eina_hash_del(_edje_file_hash, &edf->f, edf);
    if (!eina_hash_population(_edje_file_hash))
      {
        eina_hash_free(_edje_file_hash);
@@ -411,7 +411,7 @@ _edje_cache_file_coll_open(const Eina_File *file, const 
char *coll, int *error_r
        goto find_list;
      }
 
-   edf = eina_hash_find(_edje_file_hash, file);
+   edf = eina_hash_find(_edje_file_hash, &file);
    if (edf)
      {
        edf->references++;
@@ -425,7 +425,7 @@ find_list:
          {
             edf->references = 1;
             _edje_file_cache = eina_list_remove_list(_edje_file_cache, l);
-            eina_hash_direct_add(_edje_file_hash, file, edf);
+            eina_hash_direct_add(_edje_file_hash, &edf->f, edf);
             goto open;
          }
      }
@@ -439,7 +439,7 @@ find_list:
    (void) ed;
 #endif
 
-   eina_hash_direct_add(_edje_file_hash, file, edf);
+   eina_hash_direct_add(_edje_file_hash, &edf->f, edf);
    /* return edf; */
 
 open:
@@ -654,7 +654,7 @@ _edje_cache_file_unref(Edje_File *edf)
        return;
      }
 
-   eina_hash_del(_edje_file_hash, edf->f, edf);
+   eina_hash_del(_edje_file_hash, &edf->f, edf);
    if (!eina_hash_population(_edje_file_hash))
      {
        eina_hash_free(_edje_file_hash);

-- 


Reply via email to