diff --git a/tests/unit/protocol.tcl b/tests/unit/protocol.tcl index b0faf5dd74ed0dfe33f7620203560d5b52983fb8..516a834a858c14138503d6c447139ce0e0cd89d6 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 + } +}