From 41778490e3f44c3cbe491959dc591dd8e8269ba2 Mon Sep 17 00:00:00 2001 From: Alexander Butenko Date: Tue, 4 Aug 2015 07:15:55 +0000 Subject: [PATCH] Fix for MysqliDb usage with HHVM --- MysqliDb.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/MysqliDb.php b/MysqliDb.php index 74c124e1..c6e0f3a7 100644 --- a/MysqliDb.php +++ b/MysqliDb.php @@ -1105,9 +1105,11 @@ public function __destruct() * * @return array */ - protected function refValues($arr) + protected function refValues(Array &$arr) { - //Reference is required for PHP 5.3+ + //Reference in the function arguments are required for HHVM to work + //https://github.com/facebook/hhvm/issues/5155 + //Referenced data array is required by mysqli since PHP 5.3+ if (strnatcmp(phpversion(), '5.3') >= 0) { $refs = array(); foreach ($arr as $key => $value) {