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

Function getsetCommand

src/t_string.cpp:421–430  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

419}
420
421void getsetCommand(client *c) {
422 if (getGenericCommand(c) == C_ERR) return;
423 c->argv[2] = tryObjectEncoding(c->argv[2]);
424 setKey(c,c->db,c->argv[1],c->argv[2]);
425 notifyKeyspaceEvent(NOTIFY_STRING,"set",c->argv[1],c->db->id);
426 g_pserver->dirty++;
427
428 /* Propagate as SET command */
429 rewriteClientCommandArgument(c,0,shared.set);
430}
431
432void setrangeCommand(client *c) {
433 robj *o;

Callers

nothing calls this directly

Calls 5

getGenericCommandFunction · 0.85
tryObjectEncodingFunction · 0.85
setKeyFunction · 0.85
notifyKeyspaceEventFunction · 0.85

Tested by

no test coverage detected