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

Function zuiSdsFromValue

app/redis-6.2.6/src/t_zset.c:2243–2253  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2241}
2242
2243sds zuiSdsFromValue(zsetopval *val) {
2244 if (val->ele == NULL) {
2245 if (val->estr != NULL) {
2246 val->ele = sdsnewlen((char*)val->estr,val->elen);
2247 } else {
2248 val->ele = sdsfromlonglong(val->ell);
2249 }
2250 val->flags |= OPVAL_DIRTY_SDS;
2251 }
2252 return val->ele;
2253}
2254
2255/* This is different from zuiSdsFromValue since returns a new SDS string
2256 * which is up to the caller to free. */

Callers 3

zuiFindFunction · 0.85
zdiffAlgorithm2Function · 0.85

Calls 2

sdsnewlenFunction · 0.85
sdsfromlonglongFunction · 0.85

Tested by

no test coverage detected