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

Function quicklistCreateNode

app/redis-6.2.6/src/quicklist.c:144–155  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

142}
143
144REDIS_STATIC quicklistNode *quicklistCreateNode(void) {
145 quicklistNode *node;
146 node = zmalloc(sizeof(*node));
147 node->zl = NULL;
148 node->count = 0;
149 node->sz = 0;
150 node->next = node->prev = NULL;
151 node->encoding = QUICKLIST_NODE_ENCODING_RAW;
152 node->container = QUICKLIST_NODE_CONTAINER_ZIPLIST;
153 node->recompress = 0;
154 return node;
155}
156
157/* Return cached quicklist count */
158unsigned long quicklistCount(const quicklist *ql) { return ql->count; }

Callers 6

quicklistPushHeadFunction · 0.85
quicklistPushTailFunction · 0.85
quicklistAppendZiplistFunction · 0.85
_quicklistSplitNodeFunction · 0.85
_quicklistInsertFunction · 0.85
quicklistDupFunction · 0.85

Calls 1

zmallocFunction · 0.85

Tested by

no test coverage detected