From 1a33bb8089a2b8d65579d15e86501aa842ad01b7 Mon Sep 17 00:00:00 2001 From: Paul Tarjan Date: Wed, 14 May 2014 17:27:58 -0700 Subject: [PATCH 1/2] Don't take curl callback by ref Changing these does nothing to the caller, why would you take them by ref? HHVM doesn't promote this to refs if they can't be modified: https://github.com/facebook/hhvm/issues/2587 --- S3.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/S3.php b/S3.php index 2078f929..55603bbb 100644 --- a/S3.php +++ b/S3.php @@ -2307,7 +2307,7 @@ private function __dnsBucketName($bucket) * @param string &$data Data * @return integer */ - private function __responseHeaderCallback(&$curl, &$data) + private function __responseHeaderCallback($curl, $data) { if (($strlen = strlen($data)) <= 2) return $strlen; if (substr($data, 0, 4) == 'HTTP') From 42a9aa2b1893e7c82d05ed1f73af2b2c8aa413fa Mon Sep 17 00:00:00 2001 From: Paul Tarjan Date: Wed, 14 May 2014 23:00:27 -0700 Subject: [PATCH 2/2] fix docblock gotta love duplication --- S3.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/S3.php b/S3.php index 55603bbb..0b1564b2 100644 --- a/S3.php +++ b/S3.php @@ -2303,8 +2303,8 @@ private function __dnsBucketName($bucket) /** * CURL header callback * - * @param resource &$curl CURL resource - * @param string &$data Data + * @param resource $curl CURL resource + * @param string $data Data * @return integer */ private function __responseHeaderCallback($curl, $data)