MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / rdbSaveAuxFieldStrInt

Function rdbSaveAuxFieldStrInt

src/rdb.cpp:1114–1118  ·  view source on GitHub ↗

Wrapper for strlen(key) + integer type (up to long long range). */

Source from the content-addressed store, hash-verified

1112
1113/* Wrapper for strlen(key) + integer type (up to long long range). */
1114ssize_t rdbSaveAuxFieldStrInt(rio *rdb, const char *key, long long val) {
1115 char buf[LONG_STR_SIZE];
1116 int vlen = ll2string(buf,sizeof(buf),val);
1117 return rdbSaveAuxField(rdb,key,strlen(key),buf,vlen);
1118}
1119
1120/* Return the length the object will have on disk if saved with
1121 * the rdbSaveObject() function. Currently we use a trick to get

Callers 1

rdbSaveInfoAuxFieldsFunction · 0.85

Calls 2

ll2stringFunction · 0.85
rdbSaveAuxFieldFunction · 0.85

Tested by

no test coverage detected