Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.0.0b4

Bug #8656 getFiles() generate error if one of uploaded files haven't been selected
Submitted: 2006-09-07 15:55 UTC
From: s dot kornev at gmail dot com Assigned: wenz
Status: Closed Package: HTTP_Upload (version CVS)
PHP Version: 4.3.0 OS: WinXP
Roadmaps: (Not assigned)    
Subscription  


 [2006-09-07 15:55 UTC] s dot kornev at gmail dot com (Sergei)
Description: ------------ Getting error if one of submitted files haven't been selected Upload error: You haven't selected any file for uploading. Test script: --------------- <?php /** * strings 443 - 450 should be patched with this code */ // In 4.1 $_FILES isn't initialized when no uploads // XXX (cox) afaik, in >= 4.1 and <= 4.3 only if (function_exists('version_compare') && version_compare(phpversion(), '4.1', 'ge') && version_compare(phpversion(), '4.3', 'le')) { $error = $this->isMissing(); if (PEAR::isError($error)) { return $error; } } ?> Expected result: ---------------- no errors Actual result: -------------- Upload error: You haven't selected any file for uploading.

Comments

 [2006-09-07 16:29 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2006-09-07 17:55 UTC] s dot kornev at gmail dot com
It doesnt' work for. Cause on NT 5.1(XP) and PHP 4.30 $_FILES is initialized. so patch should be something like if (function_exists('version_compare') && version_compare(phpversion(), '4.1', 'ge') && version_compare(phpversion(), '4.3', 'le')) as I ve written before. thanks.
 [2006-09-07 18:03 UTC] s dot kornev at gmail dot com
changes to bug state open
 [2006-09-08 05:56 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!