diff --git a/src/t_zset.c b/src/t_zset.c index a2150201..cc6e440e 100644 --- a/src/t_zset.c +++ b/src/t_zset.c @@ -3041,7 +3041,7 @@ void zrankGenericCommand(client *c, int reverse) { robj *key = c->argv[1]; robj *ele = c->argv[2]; robj *zobj; - PORT_ULONG rank; + PORT_LONG rank; if ((zobj = lookupKeyReadOrReply(c,key,shared.nullbulk)) == NULL || checkType(c,zobj,OBJ_ZSET)) return; diff --git a/tests/support/server.tcl b/tests/support/server.tcl index 68eb40bd..834d6093 100644 --- a/tests/support/server.tcl +++ b/tests/support/server.tcl @@ -305,7 +305,7 @@ proc start_server {options {code undefined}} { # Wait for actual startup while {![info exists _pid]} { - regexp {PID:\s(\d+)} [exec cat $stdout] _ _pid + regexp -nocase {PID[:=]\s*(\d+)} [exec cat $stdout] _ _pid after 100 } @@ -334,7 +334,7 @@ proc start_server {options {code undefined}} { while 1 { # check that the server actually started and is ready for connections - if {[exec grep "ready to accept" | wc -l < $stdout] > 0} { + if {[exec grep -i "ready to accept" | wc -l < $stdout] > 0} { break } after 10