From cf9329cf0070b2692664222ee80d18ff1334575f Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Sat, 7 Nov 2009 16:59:06 +0100 Subject: [PATCH] screen_outputs: set list_window length to 0 if not connected The "length" wasn't set properly because we commented out the according line from clear_outputs_list(). --- src/screen_outputs.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/screen_outputs.c b/src/screen_outputs.c index 43a9eaa..b0acf71 100644 --- a/src/screen_outputs.c +++ b/src/screen_outputs.c @@ -120,8 +120,10 @@ fill_outputs_list(struct mpdclient *c) assert(mpd_outputs != NULL); connection = mpdclient_get_connection(c); - if (connection == NULL) + if (connection == NULL) { + list_window_set_length(lw, 0); return; + } mpd_send_outputs(connection); while ((output = mpd_recv_output(connection)) != NULL) { -- 2.30.2