ZF-10570: Zend_Service_Amazon_S3 serial request bug with Content-Encoding header set


Zend_Service_Amazon_S3::_makeRequest() does not reset the 'Content-Encoding' header. This creates a problem when content with gzip content-encoding is uploaded to S3, then subsequent, non compressed, data is uploaded. I have included a patch below to address the issue.

==== Dif File ===

This patch file was generated by NetBeans IDE

It uses platform neutral UTF-8 encoding and \n newlines.

--- Base (BASE) +++ Locally Modified (Based On LOCAL) @@ -559,7 +559,8 @@ $client->setHeaders(array('Content-MD5' => null, 'Expect' => null, 'Range' => null, - 'x-amz-acl' => null)); + 'x-amz-acl' => null, + 'Content-Encoding' => null));



Patch applied. In the future, please create your diff file from the top-level ZF directory (the one that contains library, tests, documentation, etc), and/or specify the file that needs to be patched. Also, please include unit tests in the future.

Hi Matthew,

I'll make sure to do that for any subsequent bugs.

Thanks, Nick