diff --git a/libraries/Redis.php b/libraries/Redis.php index 1e4c389..6bc12b2 100644 --- a/libraries/Redis.php +++ b/libraries/Redis.php @@ -322,7 +322,12 @@ private function _bulk_reply() // fully return from redis and enter into socket. $value_length = (int) fgets($this->_connection); - if ($value_length <= 0) return NULL; + if ($value_length <= 0) { + if ($value_length == 0) { + fgets($this->_connection); + } + return NULL; + } $response = ''; @@ -511,4 +516,4 @@ function __destruct() { if ($this->_connection) fclose($this->_connection); } -} \ No newline at end of file +}