status: fix assertion failure on window resize without active mpd connection
This commit is contained in:
@@ -557,7 +557,7 @@ void Status::Changes::elapsedTime(bool update_elapsed)
|
||||
m_kbps = st.kbps();
|
||||
}
|
||||
|
||||
if (m_player_state == MPD::psStop)
|
||||
if (m_player_state == MPD::psUnknown || m_player_state == MPD::psStop)
|
||||
{
|
||||
if (Statusbar::isUnlocked() && Config.statusbar_visibility)
|
||||
*wFooter << NC::XY(0, 1) << wclrtoeol;
|
||||
@@ -565,6 +565,7 @@ void Status::Changes::elapsedTime(bool update_elapsed)
|
||||
}
|
||||
|
||||
std::string ps = playerStateToString(m_player_state);
|
||||
|
||||
MPD::Song np = myPlaylist->nowPlayingSong();
|
||||
drawTitle(np);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user