summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCedric Bail <cedric.bail@free.fr>2014-01-11 21:36:47 +0900
committerCedric Bail <cedric.bail@free.fr>2014-01-11 21:41:22 +0900
commitcad0db51630df45378213bfcc33a236e930e0776 (patch)
tree6bbce7b874fce2023dfe7e8a3bbf064af8366327
parentb63675a809b1b5bb8e740b433a9b8e4e174f424e (diff)
eina: fix memory leak of inserting the wrong value in the hash.
We where inserting the pointer data instead of the pointer, leading to unaligned access on Sparc (Thanks Lutin to report it and Debian tools/infra to help us catch it) and also a memory leak.
-rw-r--r--src/lib/eina/eina_file_common.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/eina/eina_file_common.c b/src/lib/eina/eina_file_common.c
index f6ae3bed5e..d12f6c976a 100644
--- a/src/lib/eina/eina_file_common.c
+++ b/src/lib/eina/eina_file_common.c
@@ -192,7 +192,7 @@ eina_file_virtual_map_new(Eina_File *file,
192 map->refcount = 0; 192 map->refcount = 0;
193 193
194 eina_hash_add(file->map, &key, map); 194 eina_hash_add(file->map, &key, map);
195 eina_hash_direct_add(file->rmap, map->map, map); 195 eina_hash_direct_add(file->rmap, &map->map, map);
196 } 196 }
197 197
198 map->refcount++; 198 map->refcount++;