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

Method trackkey

src/db.cpp:3178–3188  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3176}
3177
3178void redisDbPersistentData::trackkey(const char *key, bool fUpdate)
3179{
3180 if (m_fTrackingChanges && !m_fAllChanged && m_spstorage) {
3181 dictEntry *de = dictFind(m_dictChanged, key);
3182 if (de == nullptr) {
3183 dictAdd(m_dictChanged, (void*)sdsdupshared(key), (void*)fUpdate);
3184 if (!fUpdate)
3185 ++m_cnewKeysPending;
3186 }
3187 }
3188}
3189
3190sds serializeExpire(const expireEntry *pexpire)
3191{

Callers 1

lookupKeyFunction · 0.45

Calls 3

sdsdupsharedFunction · 0.85
dictFindFunction · 0.70
dictAddFunction · 0.70

Tested by

no test coverage detected