ZF-9206: Zend_Http_Client throws a warning, when using 'php://output' as destination stream.

Issue Type: Bug Created: 2010-02-18T06:41:54.000+0000 Last Updated: 2011-08-01T13:05:26.000+0000 Status: Resolved Fix version(s): - 1.11.10 (04/Aug/11)

Reporter: François-Xavier MAURICARD (fxmauricard) Assignee: Enrico Zimuel (zimuel) Tags: - Zend_Http_Client

Related issues: Attachments: - zend_http_client_fix_stream_not_seekable.patch


When using setStream() method of Zend_Http_Client for redirecting the output to 'php://output', a warning is thrown : {quote} Warning: rewind() [function.rewind]: stream does not support seeking in __...\library\Zend\Http\Client.php on line 998 {quote}

Here is the sample code : {quote} $httpClient = new Zend_Http_Client(); $httpClient->setUri($myUri); $httpClient->setMethod(Zend_Http_Client::GET); $httpClient->setStream('php://output')->request(); {quote}


Posted by François-Xavier MAURICARD (fxmauricard) on 2010-02-18T06:50:10.000+0000

Here is a patch for fixing this issue.

We simply test if the stream is seekable before doing the call to rewind().

Posted by François-Xavier MAURICARD (fxmauricard) on 2010-12-21T01:27:55.000+0000

As I've attached a patch fixing the issue and nothing was done, is this issue will be fixed or not?

Posted by Enrico Zimuel (zimuel) on 2011-08-01T13:03:13.000+0000

Solved in trunk + unit test (commit 24336)

Posted by Enrico Zimuel (zimuel) on 2011-08-01T13:05:26.000+0000

Solved in branches/release-1.11 (commit 24337)

Have you found an issue?

See the Overview section for more details.


© 2006-2018 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.