commit | 747486a9656da913e578fad6f24f897f95e66bf6 | [log] [tgz] |
---|---|---|
author | Ondrej Kusnirik <Ondrej.Kusnirik@cesnet.cz> | Mon Aug 19 10:52:44 2024 +0200 |
committer | Michal Vasko <mvasko@cesnet.cz> | Mon Aug 19 13:23:22 2024 +0200 |
tree | 6cd858f346038928e25ec39bdfe7e8a5414d5431 | |
parent | 79e721c6416afc5ca95a04cab69d4ef3060123dc [diff] [blame] |
tree data OPTIMIZE duplication of a hash table Allocate the exact amount of memory for a new hash table as was allocated for the old one at once.
diff --git a/src/tree_data_hash.c b/src/tree_data_hash.c index ce237b1..9be655c 100644 --- a/src/tree_data_hash.c +++ b/src/tree_data_hash.c
@@ -84,7 +84,7 @@ * * Implementation of ::lyht_value_equal_cb. */ -static ly_bool +ly_bool lyd_hash_table_val_equal(void *val1_p, void *val2_p, ly_bool mod, void *UNUSED(cb_data)) { struct lyd_node *val1, *val2;