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

Bug #7499 Error in HTTP_Upload::isMissing() on determining uploaded files
Submitted: 2006-04-27 08:27 UTC
From: alpaxo at aiken dot com dot ua Assigned: wenz
Status: Closed Package: HTTP_Upload (version CVS)
PHP Version: Irrelevant OS: any
Roadmaps: (Not assigned)    
Subscription  


 [2006-04-27 08:27 UTC] alpaxo at aiken dot com dot ua (Alexey)
Description: ------------ Description: ------------ // $Id: Upload.php,v 1.54 2006/04/06 08:43:58 wenz Exp $ Error in HTTP_Upload::isMissing() on determining uploaded files on l.526-529: } else { //one file $size = $value['size'];dump($value); $error = $value['error']; } If we have 2 file in $this->post_files, for example: array(11) { ["p58i0"]=> array(5) { ["name"]=> string(23) "test.jpg" ["type"]=> string(10) "image/jpeg" ["tmp_name"]=> string(15) "/tmp\php21A.tmp" ["error"]=> int(0) ["size"]=> int(29867) } ["p58i1"]=> array(5) { ["name"]=> string(0) "" ["type"]=> string(0) "" ["tmp_name"]=> string(0) "" ["error"]=> int(4) ["size"]=> int(0) } } then values of p58i0 will be overwritten by p58i1, as result - having $this->raiseError('NO_USER_FILE'); Possible solution: 1. l.526: }else{ replace with }elseif(!empty($value['name'])){ 2. l.527 $size = $value['size']; replace with $size += $value['size'];

Comments

 [2006-12-01 11: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!