Skip to content

Commit

Permalink
Fix initial hash table capacity in celix_properties.
Browse files Browse the repository at this point in the history
  • Loading branch information
PengZheng authored Nov 18, 2023
1 parent 74f9550 commit 3ff7046
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libs/utils/src/properties.c
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,7 @@ celix_properties_t* celix_properties_create() {
if (props != NULL) {
celix_string_hash_map_create_options_t opts = CELIX_EMPTY_STRING_HASH_MAP_CREATE_OPTIONS;
opts.storeKeysWeakly = true;
opts.initialCapacity = (unsigned int)ceil(CELIX_PROPERTIES_OPTIMIZATION_ENTRIES_BUFFER_SIZE / 0.75);
opts.initialCapacity = CELIX_PROPERTIES_OPTIMIZATION_ENTRIES_BUFFER_SIZE;
opts.removedCallbackData = props;
opts.removedCallback = celix_properties_removeEntryCallback;
opts.removedKeyCallback = celix_properties_removeKeyCallback;
Expand Down

0 comments on commit 3ff7046

Please sign in to comment.