Author: sparky
Date: Thu Sep 17 23:46:25 2009
New Revision: 10619

Modified:
   toys/rsget.pl/RSGet/Curl.pm
Log:
- allow attachment; filename*=UTF-8


Modified: toys/rsget.pl/RSGet/Curl.pm
==============================================================================
--- toys/rsget.pl/RSGet/Curl.pm (original)
+++ toys/rsget.pl/RSGet/Curl.pm Thu Sep 17 23:46:25 2009
@@ -155,7 +155,11 @@
        }
 
        my $fname;
-       if ( $supercurl->{head} =~ 
/^Content-Disposition:\s*attachment;\s*filename\s*=\s*"?(.+?)"?;?\s*$/mi ) {
+       if ( $supercurl->{head} =~
+                       
/^Content-Disposition:\s*attachment;\s*filename\*=UTF-8''(.+?);?\s*$/mi ) {
+               $fname = de_ml( uri_unescape( $1 ) );
+       } elsif ( $supercurl->{head} =~
+                       
/^Content-Disposition:\s*attachment;\s*filename\s*=\s*"?(.+?)"?;?\s*$/mi ) {
                $fname = de_ml( uri_unescape( $1 ) );
        } else {
                my $eurl = $curl->getinfo( CURLINFO_EFFECTIVE_URL );
_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to