From: antirez <antirez@gmail.com>
Date: Thu, 11 Oct 2012 16:36:18 +0000 (+0200)
Subject: Merge remote-tracking branch 'origin/2.6' into 2.6
X-Git-Url: https://git.saurik.com/redis.git/commitdiff_plain/c3ff470889c2bcf4d9521cf547d32760ef5bbc6c?hp=-c

Merge remote-tracking branch 'origin/2.6' into 2.6
---

c3ff470889c2bcf4d9521cf547d32760ef5bbc6c
diff --combined src/redis.c
index 8dc6b9a9,aa5a73f2..f26bdab0
--- a/src/redis.c
+++ b/src/redis.c
@@@ -1623,7 -1623,6 +1623,7 @@@ int processCommand(redisClient *c) 
  
      /* Lua script too slow? Only allow commands with REDIS_CMD_STALE flag. */
      if (server.lua_timedout &&
 +          c->cmd->proc != authCommand &&
          !(c->cmd->proc == shutdownCommand &&
            c->argc == 2 &&
            tolower(((char*)c->argv[1]->ptr)[0]) == 'n') &&
@@@ -2579,6 -2578,11 +2579,11 @@@ int main(int argc, char **argv) 
              redisLog(REDIS_NOTICE,"The server is now ready to accept connections at %s", server.unixsocket);
      }
  
+     /* Warning the user about suspicious maxmemory setting. */
+     if (server.maxmemory > 0 && server.maxmemory < 1024*1024) {
+         redisLog(REDIS_WARNING,"WARNING: You specified a maxmemory value that is less than 1MB (current value is %llu bytes). Are you sure this is what you really want?", server.maxmemory);
+     }
+ 
      aeSetBeforeSleepProc(server.el,beforeSleep);
      aeMain(server.el);
      aeDeleteEventLoop(server.el);