From: antirez Date: Thu, 28 Jul 2011 12:40:06 +0000 (+0200) Subject: Regression for a crash with blocking ops and pipelining X-Git-Url: https://git.saurik.com/redis.git/commitdiff_plain/4bb1ccc6ebaa5944f8283500d69cae505f9d04d8?ds=sidebyside;hp=--cc Regression for a crash with blocking ops and pipelining --- 4bb1ccc6ebaa5944f8283500d69cae505f9d04d8 diff --git a/tests/unit/protocol.tcl b/tests/unit/protocol.tcl index b0faf5dd..516a834a 100644 --- a/tests/unit/protocol.tcl +++ b/tests/unit/protocol.tcl @@ -60,3 +60,19 @@ start_server {tags {"protocol"}} { assert_error "*wrong*arguments*ping*" {r ping x y z} } } + +start_server {tags {"regression"}} { + test "Regression for a crash with blocking ops and pipelining" { + set rd [redis_deferring_client] + set fd [r channel] + set proto "*3\r\n\$5\r\nBLPOP\r\n\$6\r\nnolist\r\n\$1\r\n0\r\n" + puts -nonewline $fd $proto$proto + flush $fd + set res {} + + $rd rpush nolist a + $rd read + $rd rpush nolist a + $rd read + } +}