[Slim-Checkins] r10204 - /trunk/server/Slim/Utils/Scanner.pm

andy at svn.slimdevices.com andy at svn.slimdevices.com
Wed Oct 4 19:27:07 PDT 2006


Author: andy
Date: Wed Oct  4 19:27:06 2006
New Revision: 10204

URL: http://svn.slimdevices.com?rev=10204&view=rev
Log:
Fix bug in scanWMA, invalid check should come after we convert mms to http

Modified:
    trunk/server/Slim/Utils/Scanner.pm

Modified: trunk/server/Slim/Utils/Scanner.pm
URL: http://svn.slimdevices.com/trunk/server/Slim/Utils/Scanner.pm?rev=10204&r1=10203&r2=10204&view=diff
==============================================================================
--- trunk/server/Slim/Utils/Scanner.pm (original)
+++ trunk/server/Slim/Utils/Scanner.pm Wed Oct  4 19:27:06 2006
@@ -920,16 +920,16 @@
 sub scanWMAStream {
 	my $args = shift;
 	
+	my $request = HTTP::Request->new( GET => $args->{'url'} );
+	
+	addWMAHeaders( $request );
+	
 	# Make sure we don't send any bad URLs through
-	if ( $args->{'url'} !~ /^http:/ ) {
+	if ( $request->uri->as_string !~ /^http:/ ) {
 		my $error = 'Invalid URL: ' . $args->{'url'};
 		scanWMAStreamError( undef, $error, $args );
 		return;
 	}
-	
-	my $request = HTTP::Request->new( GET => $args->{'url'} );
-	
-	addWMAHeaders( $request );
 	
 	my $http = Slim::Networking::Async::HTTP->new();
 	$http->send_request( {



More information about the checkins mailing list