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

Function freeZsetObject

app/redis-6.2.6/src/object.c:323–338  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

321}
322
323void freeZsetObject(robj *o) {
324 zset *zs;
325 switch (o->encoding) {
326 case OBJ_ENCODING_SKIPLIST:
327 zs = o->ptr;
328 dictRelease(zs->dict);
329 zslFree(zs->zsl);
330 zfree(zs);
331 break;
332 case OBJ_ENCODING_ZIPLIST:
333 zfree(o->ptr);
334 break;
335 default:
336 serverPanic("Unknown sorted set encoding");
337 }
338}
339
340void freeHashObject(robj *o) {
341 switch (o->encoding) {

Callers 1

decrRefCountFunction · 0.85

Calls 3

zslFreeFunction · 0.85
dictReleaseFunction · 0.70
zfreeFunction · 0.70

Tested by

no test coverage detected