master branch merged into scripting.

This commit is contained in:
antirez
2011-07-12 12:39:16 +02:00
34 changed files with 875 additions and 454 deletions

View File

@ -36,6 +36,7 @@ redisClient *createClient(int fd) {
c->reqtype = 0;
c->argc = 0;
c->argv = NULL;
c->cmd = NULL;
c->multibulklen = 0;
c->bulklen = -1;
c->sentlen = 0;
@ -461,6 +462,7 @@ static void freeClientArgv(redisClient *c) {
for (j = 0; j < c->argc; j++)
decrRefCount(c->argv[j]);
c->argc = 0;
c->cmd = NULL;
}
void freeClient(redisClient *c) {
@ -961,5 +963,7 @@ void rewriteClientCommandVector(redisClient *c, int argc, ...) {
/* Replace argv and argc with our new versions. */
c->argv = argv;
c->argc = argc;
c->cmd = lookupCommand(c->argv[0]->ptr);
redisAssert(c->cmd != NULL);
va_end(ap);
}