From d257c58e62caa93f662162ad73728305be566412 Mon Sep 17 00:00:00 2001 From: Richard Russon Date: Thu, 4 Jul 2019 19:41:57 +0100 Subject: [PATCH] rename locals for consistency --- init.c | 12 ++++++------ main.c | 6 +++--- ncrypt/crypt_gpgme.c | 9 ++++----- 3 files changed, 13 insertions(+), 14 deletions(-) diff --git a/init.c b/init.c index 7b1ad3aa9..495b65b12 100644 --- a/init.c +++ b/init.c @@ -1355,15 +1355,15 @@ static enum CommandResult parse_mailboxes(struct Buffer *buf, struct Buffer *s, if (!new_account) { - struct Mailbox *old_m = mx_mbox_find(a, m->realpath); - if (old_m) + struct Mailbox *m_old = mx_mbox_find(a, m->realpath); + if (m_old) { - if (old_m->flags == MB_HIDDEN) + if (m_old->flags == MB_HIDDEN) { - old_m->flags = MB_NORMAL; - mutt_sb_notify_mailbox(old_m, true); + m_old->flags = MB_NORMAL; + mutt_sb_notify_mailbox(m_old, true); struct MailboxNode *mn = mutt_mem_calloc(1, sizeof(*mn)); - mn->mailbox = old_m; + mn->mailbox = m_old; STAILQ_INSERT_TAIL(&AllMailboxes, mn, entries); } mailbox_free(&m); diff --git a/main.c b/main.c index 7dad20f6b..95f096620 100644 --- a/main.c +++ b/main.c @@ -1172,9 +1172,9 @@ int main(int argc, char *argv[], char *envp[]) if (C_Spoolfile) { // Check if C_Spoolfile corresponds a mailboxes' description. - struct Mailbox *desc_m = mutt_mailbox_find_desc(C_Spoolfile); - if (desc_m) - mutt_buffer_strcpy(folder, desc_m->realpath); + struct Mailbox *m_desc = mutt_mailbox_find_desc(C_Spoolfile); + if (m_desc) + mutt_buffer_strcpy(folder, m_desc->realpath); else mutt_buffer_strcpy(folder, C_Spoolfile); } diff --git a/ncrypt/crypt_gpgme.c b/ncrypt/crypt_gpgme.c index 4dc3b445f..44d52500b 100644 --- a/ncrypt/crypt_gpgme.c +++ b/ncrypt/crypt_gpgme.c @@ -2436,7 +2436,6 @@ int smime_gpgme_decrypt_mime(FILE *fp_in, FILE **fp_out, struct Body *b, struct * part can then point into this file and there won't ever be a need to * decrypt again. This needs a partial rewrite of the MIME engine. */ struct Body *bb = *cur; - struct Body *tmp_b = NULL; saved_b_type = bb->type; saved_b_offset = bb->offset; @@ -2469,16 +2468,16 @@ int smime_gpgme_decrypt_mime(FILE *fp_in, FILE **fp_out, struct Body *b, struct return -1; } - tmp_b = decrypt_part(bb, &s, *fp_out, true, &is_signed); - if (tmp_b) - tmp_b->goodsig = is_signed > 0; + struct Body *b_tmp = decrypt_part(bb, &s, *fp_out, true, &is_signed); + if (b_tmp) + b_tmp->goodsig = is_signed > 0; bb->type = saved_b_type; bb->length = saved_b_length; bb->offset = saved_b_offset; mutt_file_fclose(&fp_tmp2); rewind(*fp_out); mutt_body_free(cur); - *cur = tmp_b; + *cur = b_tmp; } return *cur ? 0 : -1; } -- 2.40.0