MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / dictExpand

Function dictExpand

src/dict.cpp:335–339  ·  view source on GitHub ↗

return DICT_ERR if expand was not performed */

Source from the content-addressed store, hash-verified

333
334/* return DICT_ERR if expand was not performed */
335int dictExpand(dict *d, unsigned long size, bool fShrink) {
336 // External expand likely means mass insertion, and we don't want to shrink during that
337 d->noshrink = true;
338 return _dictExpand(d, size, fShrink, NULL);
339}
340
341/* return DICT_ERR if expand failed due to memory allocation failure */
342int dictTryExpand(dict *d, unsigned long size, bool fShrink) {

Callers 13

trackChangesMethod · 0.70
removeAllCachedValuesMethod · 0.70
expandMethod · 0.70
hashTypeDupFunction · 0.70
createSnapshotMethod · 0.70
expandMethod · 0.70
zsetDupFunction · 0.70
setTypeConvertFunction · 0.70
setTypeDupFunction · 0.70

Calls 1

_dictExpandFunction · 0.85

Tested by

no test coverage detected