MCPcopy Create free account
hub / github.com/F-Stack/f-stack / zrealloc

Function zrealloc

app/redis-6.2.6/src/zmalloc.c:249–253  ·  view source on GitHub ↗

Reallocate memory and zero it or panic */

Source from the content-addressed store, hash-verified

247
248/* Reallocate memory and zero it or panic */
249void *zrealloc(void *ptr, size_t size) {
250 ptr = ztryrealloc_usable(ptr, size, NULL);
251 if (!ptr && size != 0) zmalloc_oom_handler(size);
252 return ptr;
253}
254
255/* Try Reallocating memory, and return NULL if failed. */
256void *ztryrealloc(void *ptr, size_t size) {

Callers 15

appendServerSaveParamsFunction · 0.85
rewriteConfigAppendLineFunction · 0.85
cliIntegrateHelpFunction · 0.85
findBigKeysFunction · 0.85
findHotKeysFunction · 0.85
luaRedisGenericCommandFunction · 0.85
aeApiResizeFunction · 0.85
ziplistResizeFunction · 0.85
ziplistMergeFunction · 0.85
aeResizeSetSizeFunction · 0.85

Calls 1

ztryrealloc_usableFunction · 0.85

Tested by

no test coverage detected