Permalink
Browse files

Fixes next token after a filename may include a dash or other character

Signed-off-by: Joshua Peek <josh@joshpeek.com>
  • Loading branch information...
1 parent 18eb0d3 commit a180673170c736a709842f5cc73d4fc33d36a325 @rubys rubys committed with josh Jan 21, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/rack/utils.rb
View
@@ -483,7 +483,7 @@ def self.parse_multipart(env)
dispparm = /;\s*(#{token})=("(?:\\"|[^"])*"|#{token})*/
rfc2183 = /^#{condisp}(#{dispparm})+$/i
- broken_quoted = /^#{condisp}.*;\sfilename="(.*?)"(?:\s*$|\s*;\s*\w+=)/i
+ broken_quoted = /^#{condisp}.*;\sfilename="(.*?)"(?:\s*$|\s*;\s*#{token}=)/i
broken_unquoted = /^#{condisp}.*;\sfilename=(#{token})/i
if head =~ rfc2183

1 comment on commit a180673

@josh
josh commented on a180673 Jan 21, 2010

Sorry, tests were added in 4b6bc86

Please sign in to comment.