Skip to content

Commit

Permalink
Fixed upload failure on files that contain semicolons in their names.
Browse files Browse the repository at this point in the history
  • Loading branch information
lstein committed Feb 24, 2006
1 parent 606fdf3 commit 53651f2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
6 changes: 3 additions & 3 deletions CGI.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ use Carp 'croak';
# The most recent version and complete docs are available at:
# http://stein.cshl.org/WWW/software/CGI/

$CGI::revision = '$Id: CGI.pm,v 1.200 2006-02-08 18:28:54 lstein Exp $';
$CGI::revision = '$Id: CGI.pm,v 1.201 2006-02-24 19:02:24 lstein Exp $';
$CGI::VERSION='3.16';

# HARD-CODED LOCATION FOR FILE UPLOAD TEMPORARY FILES.
Expand Down Expand Up @@ -3310,11 +3310,11 @@ sub read_multipart {
return;
}
my($param)= $header{'Content-Disposition'}=~/ name="([^;]*)"/;
my($param)= $header{'Content-Disposition'}=~/ name="([^"]*)"/;
$param .= $TAINTED;
# Bug: Netscape doesn't escape quotation marks in file names!!!
my($filename) = $header{'Content-Disposition'}=~/ filename="([^;]*)"/;
my($filename) = $header{'Content-Disposition'}=~/ filename="([^"]*)"/;
# Test for Opera's multiple upload feature
my($multipart) = ( defined( $header{'Content-Type'} ) &&
$header{'Content-Type'} =~ /multipart\/mixed/ ) ?
Expand Down
3 changes: 2 additions & 1 deletion CGI/Fast.pm
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ package CGI::Fast;
# wish, but if you redistribute a modified version, please attach a note
# listing the modifications you have made.

$CGI::Fast::VERSION='1.06';
$CGI::Fast::VERSION='1.07';

use CGI;
use FCGI;
Expand Down Expand Up @@ -54,6 +54,7 @@ sub new {
return undef unless FCGI::accept() >= 0;
}
}
CGI->_reset_globals;
return $CGI::Q = $self->SUPER::new($initializer, @param);
}

Expand Down
5 changes: 4 additions & 1 deletion Changes
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
Version 3.17 ??
Version 3.17 Fri Feb 24 14:01:27 EST 2006
1. Added patch from Mike Hanafey which caused 0 arguments to CGI::Cookie->new() to
be treated as empty.
2. Patch to CGI::Carp from Peter Whaite to fix the unfixable problem of CGI::Carp
not behaving correctly in an eval() context.
3. CGI::Fast->new() calls CGI->_reset_globals to avoid contamination of one session
with another's variables.
4. Fixed upload failure on files that contain semicolons in their names.

Version 3.16 Wed Feb 8 13:29:11 EST 2006
1. header() -charset option now works even when the MIME type is not "text".
Expand Down

0 comments on commit 53651f2

Please sign in to comment.