Opened 18 years ago
Closed 18 years ago
#1733 closed patch (fixed)
Fix 3 small metadata related bugs in MythMusic
Reported by: | Owned by: | Isaac Richards | |
---|---|---|---|
Priority: | minor | Milestone: | 0.20 |
Component: | mythmusic | Version: | head |
Severity: | medium | Keywords: | |
Cc: | Ticket locked: | no |
Description
While explaining something to Joggi on the ML today, I noticed that when Mythmusic was doing it's scan for new music, it did not correctly remove the stale DB entries for files that no longer exist.
The removeFromDB method diligently strips of the directory name from the filename before the query, but then just binds the original filename to the query before executing it...
The attached patch fixes this.
One patch you don't need to review Isaac, can I have write access now ;) Just kidding :p
Attachments (2)
Change History (4)
Changed 18 years ago by
Attachment: | remove_stale_metadata.diff added |
---|
Changed 18 years ago by
Attachment: | mythmusic_triple_fix.diff added |
---|
Fix three bugs relating to metadata (full comment to follow)
comment:1 Changed 18 years ago by
Milestone: | → 0.20 |
---|---|
Summary: | Fix removal of stale metadata in mythmusic's scan → Fix 3 small metadata related bugs in MythMusic |
Version: | → head |
Please now ignore the first patch "remove_stale_metadata.diff".
While the new diff addresses three kinda separate issues, the patch is combined as the issues are very simple to analyse in diff format and are all related to metadata handling.
Description:
The fixes in mythmusic/metadata.cpp address the incorrect usage of the method QString::remove which will actually edit the original data which is not what is intended. This corrects this thinko.
The fixes in mythmusic/editmetadata.cpp are a cosmetic change which will prevent certain options relating to saving metadata appearing when the filename contains : (somewhat odd considering MM on it's own does not allow this to happen but I presume MFD does as there is special consideration for : in other areas of the code).
The fixes in mythmusic/main.cpp is the same fix as originally posted but uses the same variable name as used in two places in metadata.cpp for consistency. Fixes the removal of stale metadata from the DB during scan.
If someone feels like it's worth it, this can probably go into fixes without conflict (tho' not tested).
Patch to fix the issue