ID:               50196
 Updated by:       j...@php.net
 Reported By:      stas at zend dot com
-Status:           Open
+Status:           Feedback
 Bug Type:         Streams related
 Operating System: Windows
 PHP Version:      5.2SVN-2009-11-16 (SVN)
 New Comment:

Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc. If the script requires a 
database to demonstrate the issue, please make sure it creates 
all necessary tables, stored procedures etc.

Please avoid embedding huge scripts into the report.




Previous Comments:
------------------------------------------------------------------------

[2009-11-16 22:08:27] stas at zend dot com

Description:
------------
If I use stream_copy_to_stream with source stream being not file (say,
HTTP socket) then I get this warning:

Warning: Invalid CRT parameters detected

This is because in _php_stream_copy_to_stream_ex() php_stream_stat() is
applied to source stream, which goes to php_sockop_stat which calls
fstat, which produces "invalid parameter" pseudo-exception. 

Reproduce code:
---------------
$socket = open_http_socket();
$fp = fopen("data", "w");
stream_copy_to_stream($socket, $fp);

Actual result:
--------------
Warning: Invalid CRT parameters detected


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=50196&edit=1

Reply via email to