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

Function sdsjoinsds

app/redis-6.2.6/src/sds.c:1148–1157  ·  view source on GitHub ↗

Like sdsjoin, but joins an array of SDS strings. */

Source from the content-addressed store, hash-verified

1146
1147/* Like sdsjoin, but joins an array of SDS strings. */
1148sds sdsjoinsds(sds *argv, int argc, const char *sep, size_t seplen) {
1149 sds join = sdsempty();
1150 int j;
1151
1152 for (j = 0; j < argc; j++) {
1153 join = sdscatsds(join, argv[j]);
1154 if (j != argc-1) join = sdscatlen(join,sep,seplen);
1155 }
1156 return join;
1157}
1158
1159/* Wrappers to the allocators used by SDS. Note that SDS will actually
1160 * just use the macros defined into sdsalloc.h in order to avoid to pay

Callers 1

ldbEvalFunction · 0.85

Calls 3

sdsemptyFunction · 0.85
sdscatsdsFunction · 0.85
sdscatlenFunction · 0.85

Tested by

no test coverage detected