Bugzilla – Bug 9223
Scanner logging tons of errors
Last modified: 2009-09-08 09:30:54 UTC
Every track is spitting out the following line: [08-08-20 09:55:00.7184] Slim::Player::ProtocolHandlers::handlerForURL (114) Warning: Use of uninitialized value in pattern match (m//) at D:/eclipse/Boom/server/Slim/Player/ProtocolHandlers.pm line 114. Might be a Windows only issue: "M:/something/..." is considere a url, using protocol "M", for which there's no protocol-handler. But as handlerForURL hasn't been changed in a good while, the question is why it's called with that value. Backtrace: [08-08-20 09:55:00.7192] Slim::Player::ProtocolHandlers::handlerForURL (108) Backtrace: frame 0: Slim::Utils::Log::logBacktrace (D:/eclipse/Boom/server/Slim/Player/ProtocolHandlers.pm line 108) frame 1: Slim::Player::ProtocolHandlers::handlerForURL (D:/eclipse/Boom/server/Slim/Music/Info.pm line 1019) frame 2: Slim::Music::Info::isRemoteURL (D:/eclipse/Boom/server/Slim/Music/Info.pm line 1525) frame 3: Slim::Music::Info::typeFromPath (D:/eclipse/Boom/server/Slim/Formats.pm line 153) frame 4: Slim::Formats::readTags (D:/eclipse/Boom/server/Slim/Schema.pm line 858) frame 5: Slim::Schema::newTrack (D:/eclipse/Boom/server/Slim/Utils/Scanner.pm line 335) frame 6: Slim::Utils::Scanner::scanDirectory (D:/eclipse/Boom/server/Slim/Music/MusicFolderScan.pm line 79) frame 7: Slim::Music::MusicFolderScan::startScan (D:/eclipse/Boom/server/Slim/Music/Import.pm line 491) frame 8: Slim::Music::Import::runImporter (D:/eclipse/Boom/server/Slim/Music/Import.pm line 335) frame 9: Slim::Music::Import::runScan (D:/eclipse/Boom/server/scanner.pl line 213) frame 10: (eval) (D:/eclipse/Boom/server/scanner.pl line 207) frame 11: main::main (D:/eclipse/Boom/server/scanner.pl line 353)
change 22424 removed the early call to isValidHandler(), passing to handlerForURL() without this check. Either we re-introduce the early check or we return undef from handlerForURL() if no handler can be found: Index: D:/eclipse/Boom/server/Slim/Player/ProtocolHandlers.pm =================================================================== --- D:/eclipse/Boom/server/Slim/Player/ProtocolHandlers.pm (revision 22786) +++ D:/eclipse/Boom/server/Slim/Player/ProtocolHandlers.pm (working copy) @@ -106,7 +106,7 @@ my $handler = $class->loadHandler($protocol); # Handler should be a class, not '1' for rtsp - return $handler =~ /::/ ? $handler : undef; + return $handler && $handler =~ /::/ ? $handler : undef; } sub iconHandlerForURL { Dean/Chris: I'd suggest we include this in 7.2 as the messages create huge scanner log files on Windows. And lack of log rotation this can be a problem.
I agree. Andy: you good with this patch?
Looks good to me.
change 22794 - suppress a warning for every file scanned on Windows systems
Verified fixed in SqueezeCenter 7.2.1-23555
This bug has been fixed in the 7.3.0 release version of SqueezeCenter! Please download the new version from http://www.slimdevices.com/su_downloads.html if you haven't already. If you are still experiencing this problem, feel free to reopen the bug with your new comments and we'll have another look.
Reduce number of active targets for SC