Bug 17800 - Invalid artwork regex leads to scan failure
: Invalid artwork regex leads to scan failure
Status: RESOLVED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Scanner
: 7.7.0
: Other Fedora
: P3 critical with 2 votes (vote)
: 7.7.x
Assigned To: Michael Herger
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-12-04 09:27 UTC by Paul
Modified: 2011-12-05 20:42 UTC (History)
0 users

See Also:
Category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul 2011-12-04 09:27:02 UTC
Scanner crashes during both a full scan and a rescan for new files only. Problem occurs with 7.6, 7.7. and 7.7.1 rc1 running on a Vortexbox 2.0 (Fedora 16). Scan folder contains music files, cover.jpg, and folder.jpg only. No embedded art.

Results of scanner log below.

]
[11-12-03 16:42:36.1698] Slim::Utils::SQLiteHelper::updateProgress (422) Notify to server OK
[11-12-03 16:42:36.1720] Slim::Utils::Scanner::Local::new (773) Handling new audio track file:///storage/music/flac/10,000_Maniacs/Our_Time_in_Eden/01_Noah%27s_Dove.flac
[11-12-03 16:42:36.2316] Slim::Music::Artwork::findStandaloneArtwork (136) Warning: "cover|folder|album|thumb|*.jpg" at /usr/lib/perl5/vendor_perl/Slim/Music/Artwork.pm line 136.
[11-12-03 16:42:36.2334] main::main (340) Error: Failed when running main scan: [Quantifier follows nothing in regex; marked by <-- HERE in m/^(?:cover|folder|album|thumb|* <-- HERE .jpg)\./ at /usr/lib/perl5/vendor_perl/Slim/Music/Artwork.pm line 137.
]
Comment 1 Ron Olsen 2011-12-04 09:51:16 UTC
See http://forums.slimdevices.com/showthread.php?p=674550 for additional discussion of this issue.
Comment 2 Michael Herger 2011-12-04 23:00:07 UTC
"cover|folder|album|thumb|*.jpg" is an invalid regular expression. 

AFAIK you can remove the *.jpg in your artwork rule, as the scanner will do this anyway.

We must sanity check the expression before using it, in order to prevent failure here.
Comment 3 SVN Bot 2011-12-04 23:03:44 UTC
 == Auto-comment from SVN commit #33739 to the slim repo by mherger ==
 == http://svn.slimdevices.com/slim?view=revision&revision=33739 ==

Bug: 17800
Description: we need to handle "Windows-style" wildcards when adding file definitions to the artwork candidates list
Comment 4 Mikael Nyberg 2011-12-05 20:42:04 UTC
This change does it include a sanity check, or did it only fix this particular case ?
The main problem is if a user actually puts something bogus as an extra artwork extension.

If so would LMS scanner crash or just ignore the sugested extension ?