diff options
author | Max Kellermann <max@duempel.org> | 2014-12-04 21:52:31 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2014-12-04 21:53:45 +0100 |
commit | 406bda9b952e74f5ba028e66ca40b72af1e7bf17 (patch) | |
tree | d2bdd44c68f00e3b120809cc431cf2c82950e8a0 /src/decoder | |
parent | 405f1dd02715b142f582eb1eab41b7055da36f99 (diff) | |
download | mpd-406bda9b952e74f5ba028e66ca40b72af1e7bf17.tar.gz mpd-406bda9b952e74f5ba028e66ca40b72af1e7bf17.tar.xz mpd-406bda9b952e74f5ba028e66ca40b72af1e7bf17.zip |
decoder/sidplay: simplify the SidDatabase::length() call
Diffstat (limited to 'src/decoder')
-rw-r--r-- | src/decoder/plugins/SidplayDecoderPlugin.cxx | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/decoder/plugins/SidplayDecoderPlugin.cxx b/src/decoder/plugins/SidplayDecoderPlugin.cxx index 9bbff7ae1..7bd355086 100644 --- a/src/decoder/plugins/SidplayDecoderPlugin.cxx +++ b/src/decoder/plugins/SidplayDecoderPlugin.cxx @@ -141,12 +141,10 @@ get_song_length(const SidplayContainerPath &container) "failed to load file for calculating md5 sum"); return SignedSongTime::Negative(); } - char md5sum[SIDTUNE_MD5_LENGTH+1]; - tune.createMD5(md5sum); - const unsigned song_num = container.track; + tune.selectSong(container.track); - const auto length = songlength_database->length(md5sum, song_num); + const auto length = songlength_database->length(tune); if (length < 0) return SignedSongTime::Negative(); |