SVN: toys/rsget.pl/RSGet/Curl.pm

sparky sparky at pld-linux.org
Sat Jun 26 17:06:00 CEST 2010


Author: sparky
Date: Sat Jun 26 17:05:59 2010
New Revision: 11590

Modified:
   toys/rsget.pl/RSGet/Curl.pm
Log:
- avoid warning id content-type is missing (happens in case of ftp://)


Modified: toys/rsget.pl/RSGet/Curl.pm
==============================================================================
--- toys/rsget.pl/RSGet/Curl.pm	(original)
+++ toys/rsget.pl/RSGet/Curl.pm	Sat Jun 26 17:05:59 2010
@@ -282,7 +282,7 @@
 		size_got => 0;
 
 	{
-		my $mime = $curl->getinfo( CURLINFO_CONTENT_TYPE );
+		my $mime = $curl->getinfo( CURLINFO_CONTENT_TYPE ) || "unknown";
 		if ( $mime =~ m#^text/html# ) {
 			$get_obj->{is_html} = 1;
 			$supercurl->{size_total} = 0;


More information about the pld-cvs-commit mailing list