From: Max Kellermann Date: Sun, 19 Mar 2017 09:42:00 +0000 (+0100) Subject: main: merge exit_and_cleanup() into main() X-Git-Tag: v0.26~43 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=88187e4e0364c9c38008df05fff43428cdc41887;p=ncmpc.git main: merge exit_and_cleanup() into main() There's no point in having this function that is called only once. --- diff --git a/src/main.c b/src/main.c index 12bee3d..af67327 100644 --- a/src/main.c +++ b/src/main.c @@ -90,18 +90,6 @@ update_xterm_title(void) } #endif -static void -exit_and_cleanup(void) -{ - screen_exit(); -#ifndef NCMPC_MINI - set_xterm_title(""); -#endif - printf("\n"); - - mpdclient_free(mpd); -} - #ifndef WIN32 static void catch_sigint(gcc_unused int sig) @@ -626,7 +614,13 @@ main(int argc, const char *argv[]) ncmpc_lirc_close(); #endif - exit_and_cleanup(); + screen_exit(); +#ifndef NCMPC_MINI + set_xterm_title(""); +#endif + printf("\n"); + + mpdclient_free(mpd); #ifdef ENABLE_LYRICS_SCREEN lyrics_deinit();