From:             faraco dot phpbugs at mailnull dot com
Operating system: Windows NT4 SP6
PHP version:      4.3.4
PHP Bug Type:     HTTP related
Bug description:  Intermittent upload crash in FastCGI mode

Description:
------------
When running PHP 4.3.4 (also 4.3.2) in FastCGI mode, the http upload of
files occasionally results on "Page Cannot Be Displayed".

Some comments:

1. The SAME file sometimes is uploaded successfully and sometimes is not.
So, no problems with MAX_FILE_SIZE (HTML script) or UPLOAD_MAX_FILESIZE,
POST_MAX_SIZE (PHP.INI) settings.

2. No problems with plain/text files uploads. These intermittent problems
seem to occur only with binary files.

3. On a manual test, in 60 seconds, the same requisition failed 8 times
and succeeded other 4.


Reproduce code:
---------------
up.html
-----------
<html><body>
<form action="upload.php" method="post" enctype="multipart/form-data">
<input type="hidden" name="MAX_FILE_SIZE" value="20971520">
<input name="userfile" type="file"><br>
<input type="submit" value="Send files">
</form>
</body></html>


upload.php
----------
<?
if(move_uploaded_file($_FILES['userfile']['tmp_name'],
"uploaded/".$_FILES['userfile']['name'])) {
    echo "SUCCESSFULL";
} else {
    echo "ERROR<br>";
    print_r($_FILES);
}
?>


-- 
Edit bug report at http://bugs.php.net/?id=26647&edit=1
-- 
Try a CVS snapshot (php4):  http://bugs.php.net/fix.php?id=26647&r=trysnapshot4
Try a CVS snapshot (php5):  http://bugs.php.net/fix.php?id=26647&r=trysnapshot5
Fixed in CVS:               http://bugs.php.net/fix.php?id=26647&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=26647&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=26647&r=needtrace
Need Reproduce Script:      http://bugs.php.net/fix.php?id=26647&r=needscript
Try newer version:          http://bugs.php.net/fix.php?id=26647&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=26647&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=26647&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=26647&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=26647&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=26647&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=26647&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=26647&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=26647&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=26647&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=26647&r=float

Reply via email to