diff options
author | antirez <antirez@gmail.com> | 2009-06-05 22:52:30 +0200 |
---|---|---|
committer | antirez <antirez@gmail.com> | 2009-06-05 22:52:30 +0200 |
commit | 9f3c422c72d4cede717b5f61bb7bde5823db53f2 (patch) | |
tree | e5e285e4de315f4769152b709a9695cca43c71de /benchmark.c | |
parent | 33c08b39164eb669313f4871ce1b16a8e4cb2e5c (diff) | |
download | redis-9f3c422c72d4cede717b5f61bb7bde5823db53f2.tar.gz |
Kill the background saving process before performing SHUTDOWN to avoid races
Diffstat (limited to 'benchmark.c')
-rw-r--r-- | benchmark.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/benchmark.c b/benchmark.c index 7d4c844d5..0d53c935a 100644 --- a/benchmark.c +++ b/benchmark.c @@ -428,15 +428,6 @@ int main(int argc, char **argv) { prepareForBenchmark(); c = createClient(); if (!c) exit(1); - c->obuf = sdscat(c->obuf,"PING\r\n"); - c->replytype = REPLY_RETCODE; - createMissingClients(c); - aeMain(config.el); - endBenchmark("PING"); - - prepareForBenchmark(); - c = createClient(); - if (!c) exit(1); c->obuf = sdscatprintf(c->obuf,"SET foo_rand000000000000 %d\r\n",config.datasize); { char *data = zmalloc(config.datasize+2); @@ -488,6 +479,15 @@ int main(int argc, char **argv) { aeMain(config.el); endBenchmark("LPOP"); + prepareForBenchmark(); + c = createClient(); + if (!c) exit(1); + c->obuf = sdscat(c->obuf,"PING\r\n"); + c->replytype = REPLY_RETCODE; + createMissingClients(c); + aeMain(config.el); + endBenchmark("PING"); + printf("\n"); } while(config.loop); |