Pārlūkot izejas kodu

Use an explicit index to add values to the multi-bulk reply array.

Daniele Alessandri 14 gadi atpakaļ
vecāks
revīzija
1e32f8aaa8
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1 1
      lib/Predis.php

+ 1 - 1
lib/Predis.php

@@ -617,7 +617,7 @@ class ResponseMultiBulkHandler implements IResponseHandler {
         if ($listLength > 0) {
             $reader = $connection->getResponseReader();
             for ($i = 0; $i < $listLength; $i++) {
-                $list[] = $reader->read($connection);
+                $list[$i] = $reader->read($connection);
             }
         }