projects
/
apps
/
native
/
position-finder-server.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cad28e5
)
remove hash table if there is nothing in the hash table to minimize memory
94/159294/1
author
Jeonghoon Park
<jh1979.park@samsung.com>
Wed, 8 Nov 2017 05:24:23 +0000
(14:24 +0900)
committer
Jeonghoon Park
<jh1979.park@samsung.com>
Wed, 8 Nov 2017 05:24:23 +0000
(14:24 +0900)
Change-Id: I86140d7bbec589f5753022a2a7d979ed7ad5dd76
src/connectivity.c
patch
|
blob
|
history
diff --git
a/src/connectivity.c
b/src/connectivity.c
index
a9c695b
..
d1ef473
100644
(file)
--- a/
src/connectivity.c
+++ b/
src/connectivity.c
@@
-913,6
+913,11
@@
int connectivity_attributes_remove_value_by_key(connectivity_resource_s *resourc
if (resource_info->value_hash)
g_hash_table_remove(resource_info->value_hash, key);
+ if (g_hash_table_size(resource_info->value_hash) == 0) {
+ g_hash_table_unref(resource_info->value_hash);
+ resource_info->value_hash = NULL;
+ }
+
return 0;
}