Revision b0121db...

Go back to digest for 10th November 2013

Bug Fixes in Multimedia

Matěj Laitl committed changes in [amarok] /:

SqlRegistry: fix assert fail in SqlScanResultProcessor by always returning the correct track

What happened:
1. User has 1.mp3, copies it as and edits some tags of Both files do *not* have AFT tag embedded.
2. Amarok registers the new file.
3. Users restarts Amarok (needed to reproduce because of internal state)
4. User renames back to 1.mp3 by overwriting it, Amarok catches it
5. Amarok does not associate new 1.mp3 with the old 1.mp3 because it finds
previous entry by uid (file hash) instead.
6. Amarok tries to remove entry for the old 1.mp3, but
SqlRegistry::getTrack( int urlId ) erroneously returns the new entry
7. SqlScanResultProcessor correctly asserts out, refusing to delete the
incorrect entry.

The fix is to enhance SqlRegistry::getTrack( int urlId ) to double-check
that it indeed returns the correct entry.



File Changes

Modified 2 files
  •   ChangeLog
  •   src/core-impl/collections/db/sql/SqlRegistry.cpp
2 files changed in total