From 6113e36f93e24c4c945674772ba784a6582cda78 Mon Sep 17 00:00:00 2001 From: jcorporation Date: Wed, 6 Feb 2019 22:00:16 +0000 Subject: [PATCH] Fix: reset tag_types array to 0 values --- src/mpd_client.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mpd_client.c b/src/mpd_client.c index 6b85fa2..623c001 100644 --- a/src/mpd_client.c +++ b/src/mpd_client.c @@ -198,6 +198,7 @@ void *mpd_client_loop(void *arg_config) { list_init(&mpd_state.mympd_searchtags); list_init(&mpd_state.mympd_browsetags); mpd_state.tag_types_len = 0; + memset(mpd_state.tag_types, 0, sizeof(mpd_state.tag_types)); char testdirname[400]; snprintf(testdirname, 400, "%s/library", DOC_ROOT); @@ -1009,6 +1010,7 @@ static void mpd_client_mpd_features(t_config *config, t_mpd_state *mpd_state) { mpd_state->feat_advsearch = false; mpd_state->feat_smartpls = config->smartpls; mpd_state->tag_types_len = 0; + memset(mpd_state->tag_types, 0, sizeof(mpd_state->tag_types)); if (mpd_send_allowed_commands(mpd_state->conn)) { while ((pair = mpd_recv_command_pair(mpd_state->conn)) != NULL) {