[TagLibExtractor] Fix crash on invalid Speex files
ClosedPublic

Authored by bruns on Apr 30 2019, 2:15 AM.

Details

Summary

TagLib::Ogg::Speex::File::isValid() returns true even for invalid files,
but tag() only returns a valid XiphComment when the file is valid.

Other TagLib::Ogg::* classes properly clear the valid flag when
encountering files.

See https://github.com/taglib/taglib/issues/902

BUG: 403902

Diff Detail

Repository
R286 KFileMetaData
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
bruns created this revision.Apr 30 2019, 2:15 AM
Restricted Application added projects: Frameworks, Baloo. · View Herald TranscriptApr 30 2019, 2:15 AM
Restricted Application added a subscriber: kde-frameworks-devel. · View Herald Transcript
bruns requested review of this revision.Apr 30 2019, 2:15 AM
ngraham accepted this revision.Apr 30 2019, 12:35 PM

Gross! Confirmed the fix.

This revision is now accepted and ready to land.Apr 30 2019, 12:35 PM
astippich accepted this revision.Apr 30 2019, 3:38 PM

Given the outcome, I wish I never added support for speex files to the extractor because it was "easy to add".

This revision was automatically updated to reflect the committed changes.