From 20cba9e89f80d788a1cc65473865f52de94ea451 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 21 Oct 2013 23:19:15 +0200 Subject: Song: pass reference to song_equals() --- src/DecoderControl.cxx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/DecoderControl.cxx') diff --git a/src/DecoderControl.cxx b/src/DecoderControl.cxx index 26751855d..ff6d1ad2d 100644 --- a/src/DecoderControl.cxx +++ b/src/DecoderControl.cxx @@ -47,10 +47,8 @@ decoder_control::~decoder_control() } bool -decoder_control::IsCurrentSong(const Song *_song) const +decoder_control::IsCurrentSong(const Song &_song) const { - assert(_song != nullptr); - switch (state) { case DecoderState::STOP: case DecoderState::ERROR: @@ -58,7 +56,7 @@ decoder_control::IsCurrentSong(const Song *_song) const case DecoderState::START: case DecoderState::DECODE: - return song_equals(song, _song); + return SongEquals(*song, _song); } assert(false); -- cgit v1.2.3