From: Federico Kircheis Date: Mon, 5 Mar 2018 17:58:53 +0000 (+0100) Subject: Reduce variable scope - mx.c X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=85e58844068f72f0e5b678b9e77152e4ac3e8f89;p=neomutt Reduce variable scope - mx.c --- diff --git a/mx.c b/mx.c index c81d1a9c8..17a20c925 100644 --- a/mx.c +++ b/mx.c @@ -643,7 +643,6 @@ int mx_close_mailbox(struct Context *ctx, int *index_hint) { int i, move_messages = 0, purge = 1, read_msgs = 0; int check; - int is_spool = 0; struct Context f; char mbox[_POSIX_PATH_MAX]; char buf[SHORT_STRING]; @@ -694,9 +693,8 @@ int mx_close_mailbox(struct Context *ctx, int *index_hint) if (read_msgs && Move != MUTT_NO) { - char *p = NULL; - - p = mutt_find_hook(MUTT_MBOXHOOK, ctx->path); + int is_spool; + char *p = mutt_find_hook(MUTT_MBOXHOOK, ctx->path); if (p) { is_spool = 1;