Redis Benchmark: use atomic var for liveclients in 'createClient'

This commit is contained in:
artix 2019-02-05 19:18:25 +01:00
parent 834809cbb3
commit daaff484a6

View File

@ -658,7 +658,7 @@ static client createClient(char *cmd, size_t len, client from, int thread_id) {
if (config.idlemode == 0)
aeCreateFileEvent(el,c->context->fd,AE_WRITABLE,writeHandler,c);
listAddNodeTail(config.clients,c);
config.liveclients++;
atomicIncr(config.liveclients, 1);
return c;
}