]> granicus.if.org Git - neomutt/commitdiff
insert {}s
authorRichard Russon <rich@flatcap.org>
Sun, 3 Jun 2018 16:53:10 +0000 (17:53 +0100)
committerRichard Russon <rich@flatcap.org>
Wed, 6 Jun 2018 14:29:21 +0000 (15:29 +0100)
Insert {}s where the conditional or body take up more than one line.

55 files changed:
alias.c
attach.c
browser.c
buffy.c
commands.c
complete.c
compose.c
conn/sasl.c
conn/ssl_gnutls.c
copy.c
curs_main.c
envelope.c
handler.c
hcache/lmdb.c
hdrline.c
header.c
imap/auth_sasl.c
imap/command.c
imap/imap.c
imap/message.c
imap/util.c
init.c
mbox.c
menu.c
mh.c
mutt/rfc2047.c
mutt_notmuch.c
muttlib.c
mx.c
ncrypt/crypt.c
ncrypt/crypt_gpgme.c
ncrypt/gnupgparse.c
ncrypt/pgp.c
ncrypt/pgpinvoke.c
ncrypt/pgpkey.c
ncrypt/smime.c
newsrc.c
nntp.c
pager.c
parse.c
pattern.c
pop.c
postpone.c
progress.c
recvattach.c
recvcmd.c
rfc1524.c
score.c
send.c
sendlib.c
sidebar.c
smtp.c
state.c
status.c
thread.c

diff --git a/alias.c b/alias.c
index 1a73faf5edf786482b1055f330b34749f5ee58da..6ddbba65db5a073966984add5321bacc9dcb6104 100644 (file)
--- a/alias.c
+++ b/alias.c
@@ -589,8 +589,10 @@ int mutt_alias_complete(char *buf, size_t buflen)
       if (a->name && strncmp(a->name, buf, strlen(buf)) == 0)
       {
         if (!bestname[0]) /* init */
+        {
           mutt_str_strfcpy(bestname, a->name,
                            MIN(mutt_str_strlen(a->name) + 1, sizeof(bestname)));
+        }
         else
         {
           int i;
index 6892e9ec4b0b789e61f009129ad81133e465a5b8..df6e7474d96965720b86c26fbefe64477ee7c3a9 100644 (file)
--- a/attach.c
+++ b/attach.c
@@ -510,11 +510,15 @@ int mutt_view_attachment(FILE *fp, struct Body *a, int flag, struct Header *hdr,
       if (use_pager)
       {
         if (a->description)
+        {
           snprintf(descrip, sizeof(descrip),
                    _("---Command: %-20.20s Description: %s"), command, a->description);
+        }
         else
+        {
           snprintf(descrip, sizeof(descrip),
                    _("---Command: %-30.30s Attachment: %s"), command, type);
+        }
       }
 
       if ((mutt_wait_filter(thepid) || (entry->needsterminal && WaitKey)) && !use_pager)
index 38418f7b87b9ba67eb7f9c36f42a80dce04e3a28..9d27679550efb5cefbd2961dd64af4d03ea3167d 100644 (file)
--- a/browser.c
+++ b/browser.c
@@ -630,11 +630,15 @@ static const char *group_index_format_str(char *buf, size_t buflen, size_t col,
       if (flags & MUTT_FORMAT_OPTIONAL)
       {
         if (folder->ff->nd->unread != 0)
+        {
           mutt_expando_format(buf, buflen, col, cols, if_str,
                               group_index_format_str, data, flags);
+        }
         else
+        {
           mutt_expando_format(buf, buflen, col, cols, else_str,
                               group_index_format_str, data, flags);
+        }
       }
       else if (Context && Context->data == folder->ff->nd)
       {
@@ -732,7 +736,9 @@ static int examine_directory(struct Menu *menu, struct BrowserState *state,
         continue;
       if (Mask && Mask->regex &&
           !((regexec(Mask->regex, nntp_data->group, 0, NULL, 0) == 0) ^ Mask->not))
+      {
         continue;
+      }
       add_folder(menu, state, nntp_data->group, NULL, NULL, NULL, nntp_data);
     }
   }
@@ -791,7 +797,9 @@ static int examine_directory(struct Menu *menu, struct BrowserState *state,
       }
       if (Mask && Mask->regex &&
           !((regexec(Mask->regex, de->d_name, 0, NULL, 0) == 0) ^ Mask->not))
+      {
         continue;
+      }
 
       mutt_file_concat_path(buffer, d, de->d_name, sizeof(buffer));
       if (lstat(buffer, &s) == -1)
@@ -973,14 +981,18 @@ static void folder_entry(char *buf, size_t buflen, struct Menu *menu, int num)
 
 #ifdef USE_NNTP
   if (OptNews)
+  {
     mutt_expando_format(buf, buflen, 0, MuttIndexWindow->cols,
                         NONULL(GroupIndexFormat), group_index_format_str,
                         (unsigned long) &folder, MUTT_FORMAT_ARROWCURSOR);
+  }
   else
 #endif
+  {
     mutt_expando_format(buf, buflen, 0, MuttIndexWindow->cols,
                         NONULL(FolderFormat), folder_format_str,
                         (unsigned long) &folder, MUTT_FORMAT_ARROWCURSOR);
+  }
 }
 
 #ifdef USE_NOTMUCH
@@ -1048,8 +1060,10 @@ static void init_menu(struct BrowserState *state, struct Menu *menu,
     if (buffy)
       snprintf(title, titlelen, _("Subscribed newsgroups"));
     else
+    {
       snprintf(title, titlelen, _("Newsgroups on server [%s]"),
                CurrentNewsSrv->conn->account.host);
+    }
   }
   else
 #endif
@@ -1428,8 +1442,10 @@ void mutt_select_file(char *f, size_t flen, int flags, char ***files, int *numfi
           }
 #endif
           else
+          {
             mutt_file_concat_path(buf, LastDir, state.entry[menu->current].name,
                                   sizeof(buf));
+          }
 
           if ((mx_get_magic(buf) <= 0)
 #ifdef USE_IMAP
@@ -1677,8 +1693,10 @@ void mutt_select_file(char *f, size_t flen, int flags, char ***files, int *numfi
               FREE(&((state.entry)[nentry].desc));
               /* and move all other entries up */
               if (nentry + 1 < state.entrylen)
+              {
                 memmove(state.entry + nentry, state.entry + nentry + 1,
                         sizeof(struct FolderFile) * (state.entrylen - (nentry + 1)));
+              }
               memset(&state.entry[state.entrylen - 1], 0, sizeof(struct FolderFile));
               state.entrylen--;
               mutt_message(_("Mailbox deleted."));
diff --git a/buffy.c b/buffy.c
index 3b256748cdd2a603386618f808b55b52b2712480..91f5f009debb696bb819fd9d0b8931bd82322481 100644 (file)
--- a/buffy.c
+++ b/buffy.c
@@ -308,9 +308,11 @@ static int buffy_mbox_check(struct Buffy *mailbox, struct stat *sb, bool check_s
   if (CheckMboxSize)
     new_or_changed = sb->st_size > mailbox->size;
   else
+  {
     new_or_changed = sb->st_mtime > sb->st_atime ||
                      (mailbox->newly_created && sb->st_ctime == sb->st_mtime &&
                       sb->st_ctime == sb->st_atime);
+  }
 
   if (new_or_changed)
   {
index 5c1d5ef5bd2baf473237f1a1834a5e44d0d03c65..773d55c7e98d7a0b3a32121ef909d777616faa03 100644 (file)
@@ -549,8 +549,10 @@ void mutt_print_message(struct Header *h)
   if (pipe_message(h, PrintCommand, PrintDecode, 1, PrintSplit, "\f") == 0)
     mutt_message(ngettext("Message printed", "Messages printed", msgcount));
   else
+  {
     mutt_message(ngettext("Message could not be printed",
                           "Messages could not be printed", msgcount));
+  }
 }
 
 int mutt_select_sort(int reverse)
@@ -718,7 +720,9 @@ static void set_copy_flags(struct Header *hdr, int decode, int decrypt,
     }
     else if (((WithCrypto & APPLICATION_PGP) != 0) &&
              mutt_is_application_pgp(hdr->content) & ENCRYPT)
+    {
       decode = 1;
+    }
     else if (((WithCrypto & APPLICATION_SMIME) != 0) &&
              mutt_is_application_smime(hdr->content) & ENCRYPT)
     {
@@ -866,7 +870,9 @@ int mutt_save_message(struct Header *h, int delete, int decode, int decrypt)
 
   if ((WithCrypto != 0) && need_passphrase && (decode || decrypt) &&
       !crypt_valid_passphrase(app))
+  {
     return -1;
+  }
 
   mutt_message(_("Copying to %s..."), buf);
 
index 938d7d136db8009f72f5b79f2c88963b0c36603e..f084fd78e77cfed7cbd81041a0e34a0d4220e8b6 100644 (file)
@@ -261,8 +261,10 @@ int mutt_complete(char *buf, size_t buflen)
           tmp[0] = 0;
         mutt_str_strfcpy(tmp + strlen(tmp), filepart, sizeof(tmp) - strlen(tmp));
         if (stat(tmp, &st) != -1 && (st.st_mode & S_IFDIR))
+        {
           mutt_str_strfcpy(filepart + strlen(filepart), "/",
                            sizeof(filepart) - strlen(filepart));
+        }
         init = 1;
       }
     }
index 27ef0bc68d1b9e737300a675c985ec474810b827..ee138b95aa9b0f058d8257d1e83d9ec191087913 100644 (file)
--- a/compose.c
+++ b/compose.c
@@ -1279,12 +1279,16 @@ int mutt_compose_menu(struct Header *msg, char *fcc, size_t fcclen,
         if (mutt_enter_fname_full(prompt, fname, sizeof(fname), 0, 1, &files,
                                   &numfiles, MUTT_SEL_MULTI) == -1 ||
             *fname == '\0')
+        {
           break;
+        }
 
         int error = 0;
         if (numfiles > 1)
+        {
           mutt_message(ngettext("Attaching selected file...",
                                 "Attaching selected files...", numfiles));
+        }
         for (i = 0; i < numfiles; i++)
         {
           char *att = files[i];
index 9934e771ac44daacfff442d584f473f0b4f9638b..30aa0b74402694c0a43539d181d6717205db8098 100644 (file)
@@ -481,8 +481,10 @@ static int mutt_sasl_conn_write(struct Connection *conn, const char *buf, size_t
     } while (len > *sasldata->pbufsize);
   }
   else
+  {
     /* just write using the underlying socket function */
     rc = (sasldata->msasl_write)(conn, buf, len);
+  }
 
   conn->sockdata = sasldata;
 
index ce049edece2694f1c747bf9d91feadb203124d06..4c04380930e2c62fa49065b6b3c474e01fad6e47 100644 (file)
@@ -454,7 +454,9 @@ static int tls_check_preauth(const gnutls_datum_t *certdata,
   if (chainidx == 0 && SslVerifyHost != MUTT_NO &&
       !gnutls_x509_crt_check_hostname(cert, hostname) &&
       !tls_check_stored_hostname(certdata, hostname))
+  {
     *certerr |= CERTERR_HOSTNAME;
+  }
 
   /* see whether certificate is in our cache (certificates file) */
   if (tls_compare_certificates(certdata))
diff --git a/copy.c b/copy.c
index f6d9ef6b274f2cc871c3f08264e9d889785f88a2..ebe6c155e7414278d5b7ff7f9c6a2614a722fccc 100644 (file)
--- a/copy.c
+++ b/copy.c
@@ -128,11 +128,15 @@ int mutt_copy_hdr(FILE *in, FILE *out, LOFF_T off_start, LOFF_T off_end,
         if ((flags & (CH_UPDATE | CH_XMIT | CH_NOSTATUS)) &&
             ((mutt_str_strncasecmp("Status:", buf, 7) == 0) ||
              (mutt_str_strncasecmp("X-Status:", buf, 9) == 0)))
+        {
           continue;
+        }
         if ((flags & (CH_UPDATE_LEN | CH_XMIT | CH_NOLEN)) &&
             ((mutt_str_strncasecmp("Content-Length:", buf, 15) == 0) ||
              (mutt_str_strncasecmp("Lines:", buf, 6) == 0)))
+        {
           continue;
+        }
         if ((flags & CH_UPDATE_REFS) && (mutt_str_strncasecmp("References:", buf, 11) == 0))
           continue;
         if ((flags & CH_UPDATE_IRT) && (mutt_str_strncasecmp("In-Reply-To:", buf, 12) == 0))
@@ -400,8 +404,10 @@ int mutt_copy_hdr(FILE *in, FILE *out, LOFF_T off_start, LOFF_T off_end,
 int mutt_copy_header(FILE *in, struct Header *h, FILE *out, int flags, const char *prefix)
 {
   if (h->env)
+  {
     flags |= (h->env->irt_changed ? CH_UPDATE_IRT : 0) |
              (h->env->refs_changed ? CH_UPDATE_REFS : 0);
+  }
 
   if (mutt_copy_hdr(in, out, h->offset, h->content->offset, flags, prefix) == -1)
     return -1;
index 671ae275595309f41840c74c4ab4f6a059cb00a9..fced31ee3e793a226adfed7c0da1763c633b15cd 100644 (file)
@@ -917,8 +917,10 @@ int mutt_index_menu(void)
       {
         /* notify the user of new mail */
         if (check == MUTT_REOPENED)
+        {
           mutt_error(
               _("Mailbox was externally modified.  Flags may be wrong."));
+        }
         else if (check == MUTT_NEW_MAIL)
         {
           for (i = oldcount; i < Context->msgcount; i++)
@@ -1008,8 +1010,10 @@ int mutt_index_menu(void)
       else if (BrailleFriendly)
         mutt_window_move(MuttIndexWindow, menu->current - menu->top + menu->offset, 0);
       else
+      {
         mutt_window_move(MuttIndexWindow, menu->current - menu->top + menu->offset,
                          MuttIndexWindow->cols - 1);
+      }
       mutt_refresh();
 
       if (SigWinch)
@@ -2189,8 +2193,10 @@ int mutt_index_menu(void)
             menu->redraw |= REDRAW_INDEX;
         }
         else
+        {
           mutt_error(
               _("Thread cannot be broken, message is not part of a thread"));
+        }
 
         break;
 
@@ -2434,16 +2440,22 @@ int mutt_index_menu(void)
           if ((op == OP_MAIN_NEXT_NEW || op == OP_MAIN_PREV_NEW ||
                op == OP_MAIN_NEXT_NEW_THEN_UNREAD || op == OP_MAIN_PREV_NEW_THEN_UNREAD) &&
               first_new != -1)
+          {
             break;
+          }
         }
         if ((op == OP_MAIN_NEXT_NEW || op == OP_MAIN_PREV_NEW ||
              op == OP_MAIN_NEXT_NEW_THEN_UNREAD || op == OP_MAIN_PREV_NEW_THEN_UNREAD) &&
             first_new != -1)
+        {
           menu->current = first_new;
+        }
         else if ((op == OP_MAIN_NEXT_UNREAD || op == OP_MAIN_PREV_UNREAD ||
                   op == OP_MAIN_NEXT_NEW_THEN_UNREAD || op == OP_MAIN_PREV_NEW_THEN_UNREAD) &&
                  first_unread != -1)
+        {
           menu->current = first_unread;
+        }
 
         if (menu->current == -1)
         {
@@ -2499,8 +2511,10 @@ int mutt_index_menu(void)
           for (j = 0; j < Context->msgcount; j++)
           {
             if (message_is_tagged(Context, j))
+            {
               mutt_set_flag(Context, Context->hdrs[j], MUTT_FLAG,
                             !Context->hdrs[j]->flagged);
+            }
           }
 
           menu->redraw |= REDRAW_INDEX;
@@ -3087,9 +3101,11 @@ int mutt_index_menu(void)
           }
         }
         else
+        {
           /* L10N: This error is printed if <mark-message> cannot find a
              Message-ID for the currently selected message in the index. */
           mutt_error(_("No message ID to macro."));
+        }
         break;
 
       case OP_RECALL_MESSAGE:
@@ -3237,8 +3253,10 @@ int mutt_index_menu(void)
 
         rc = mutt_thread_set_flag(CURHDR, MUTT_DELETE, 0, op == OP_UNDELETE_THREAD ? 0 : 1);
         if (rc != -1)
+        {
           rc = mutt_thread_set_flag(CURHDR, MUTT_PURGE, 0,
                                     op == OP_UNDELETE_THREAD ? 0 : 1);
+        }
         if (rc != -1)
         {
           if (Resolve)
index 0218fae4501eb63fe9fff580563bb1156b559812..f2576c12b199d760b098715c45b74187f6584266 100644 (file)
@@ -174,7 +174,9 @@ bool mutt_env_cmp_strict(const struct Envelope *e1, const struct Envelope *e2)
         !mutt_addr_cmp_strict(e1->reply_to, e2->reply_to) ||
         !mutt_addr_cmp_strict(e1->to, e2->to) || !mutt_addr_cmp_strict(e1->cc, e2->cc) ||
         !mutt_addr_cmp_strict(e1->return_path, e2->return_path))
+    {
       return false;
+    }
     else
       return true;
   }
index 9490b53e894b299e9710985a83b4ab54bccdae0b..3d1114778979180cae72869bb7784485fa3bf557 100644 (file)
--- a/handler.c
+++ b/handler.c
@@ -719,7 +719,9 @@ static int message_handler(struct Body *a, struct State *s)
 
   if ((a->encoding == ENCBASE64) || (a->encoding == ENCQUOTEDPRINTABLE) ||
       (a->encoding == ENCUUENCODED))
+  {
     mutt_body_free(&b);
+  }
 
   return rc;
 }
@@ -1251,7 +1253,9 @@ static int multipart_handler(struct Body *a, struct State *s)
 
   if ((a->encoding == ENCBASE64) || (a->encoding == ENCQUOTEDPRINTABLE) ||
       (a->encoding == ENCUUENCODED))
+  {
     mutt_body_free(&b);
+  }
 
   /* make failure of a single part non-fatal */
   if (rc < 0)
@@ -1651,8 +1655,10 @@ int mutt_body_handler(struct Body *b, struct State *s)
       else
       {
         if (HonorDisposition && (b->disposition == DISPATTACH))
+        {
           str = _("[-- This is an attachment (need 'view-attachments' bound to "
                   "key!) --]\n");
+        }
         else
         {
           /* L10N: %s/%s is a MIME type, e.g. "text/plain". */
index a5c9fa3e710a20d32a964878b57a191de2d59e23..b968b4037d32e49c1ba568401374e278888a7216 100644 (file)
@@ -80,8 +80,10 @@ static int mdb_get_r_txn(struct HcacheLmdbCtx *ctx)
   if (rc == MDB_SUCCESS)
     ctx->txn_mode = TXN_READ;
   else
+  {
     mutt_debug(2, "%s: %s\n", ctx->txn ? "mdb_txn_renew" : "mdb_txn_begin",
                mdb_strerror(rc));
+  }
 
   return rc;
 }
index ea98c050ea633966e3358396b0f6866441914fb9..de4d3be47a41b0eb70fbcdac2bd56ae2b0f0a56e 100644 (file)
--- a/hdrline.c
+++ b/hdrline.c
@@ -523,8 +523,10 @@ static const char *index_format_str(char *buf, size_t buflen, size_t col, int co
     case 'a':
       colorlen = add_index_color(buf, buflen, flags, MT_COLOR_INDEX_AUTHOR);
       if (hdr->env->from && hdr->env->from->mailbox)
+      {
         mutt_format_s(buf + colorlen, buflen - colorlen, prec,
                       mutt_addr_for_display(hdr->env->from));
+      }
       else
         mutt_format_s(buf + colorlen, buflen - colorlen, prec, "");
       add_index_color(buf + colorlen, buflen - colorlen, flags, MT_COLOR_INDEX);
@@ -883,11 +885,15 @@ static const char *index_format_str(char *buf, size_t buflen, size_t col, int co
         {
           char *parent_tags = NULL;
           if (hdr->thread->prev && hdr->thread->prev->message)
+          {
             parent_tags =
                 driver_tags_get_transformed(&hdr->thread->prev->message->tags);
+          }
           if (!parent_tags && hdr->thread->parent && hdr->thread->parent->message)
+          {
             parent_tags =
                 driver_tags_get_transformed(&hdr->thread->parent->message->tags);
+          }
           if (parent_tags && mutt_str_strcasecmp(tags, parent_tags) == 0)
             i = 0;
           FREE(&parent_tags);
@@ -1140,8 +1146,10 @@ static const char *index_format_str(char *buf, size_t buflen, size_t col, int co
 
     case 'W':
       if (!optional)
+      {
         mutt_format_s(buf, buflen, prec,
                       hdr->env->organization ? hdr->env->organization : "");
+      }
       else if (!hdr->env->organization)
         optional = 0;
       break;
@@ -1149,8 +1157,10 @@ static const char *index_format_str(char *buf, size_t buflen, size_t col, int co
 #ifdef USE_NNTP
     case 'x':
       if (!optional)
+      {
         mutt_format_s(buf, buflen, prec,
                       hdr->env->x_comment_to ? hdr->env->x_comment_to : "");
+      }
       else if (!hdr->env->x_comment_to)
         optional = 0;
       break;
@@ -1342,11 +1352,15 @@ static const char *index_format_str(char *buf, size_t buflen, size_t col, int co
   }
 
   if (optional)
+  {
     mutt_expando_format(buf, buflen, col, cols, if_str, index_format_str,
                         (unsigned long) hfi, flags);
+  }
   else if (flags & MUTT_FORMAT_OPTIONAL)
+  {
     mutt_expando_format(buf, buflen, col, cols, else_str, index_format_str,
                         (unsigned long) hfi, flags);
+  }
 
   return src;
 }
index 1b3f2c42adee16b2b96b00af423971830b58ab7f..3d66f6e86109aa5f3469d0ac86abccc1e7fb48ee 100644 (file)
--- a/header.c
+++ b/header.c
@@ -128,11 +128,15 @@ void mutt_edit_headers(const char *editor, const char *body, struct Header *msg,
 #ifdef USE_NNTP
   if (!OptNewsSend)
 #endif
+  {
     if (!STAILQ_EMPTY(&msg->env->in_reply_to) &&
         (STAILQ_EMPTY(&n->in_reply_to) ||
          (mutt_str_strcmp(STAILQ_FIRST(&n->in_reply_to)->data,
                           STAILQ_FIRST(&msg->env->in_reply_to)->data) != 0)))
+    {
       mutt_list_free(&msg->env->references);
+    }
+  }
 
   /* restore old info. */
   mutt_list_free(&n->references);
index 458c232e6ad741b28dba8f2545e9148d21c4b68f..b300581bd29d08bc1653c4c14310c4b9b125cd1c 100644 (file)
@@ -112,9 +112,11 @@ enum ImapAuthRes imap_auth_sasl(struct ImapData *idata, const char *method)
     if (method)
       mutt_debug(2, "%s unavailable\n", method);
     else
+    {
       mutt_debug(
           1,
           "Failure starting authentication exchange. No shared mechanisms?\n");
+    }
     /* SASL doesn't support LOGIN, so fall back */
 
     return IMAP_AUTH_UNAVAIL;
index 9faf12bff14c813bc14d5f9b4b06553096419414..0322194f369a9ea0cffffeac091c0b32d0a72d44 100644 (file)
@@ -760,9 +760,11 @@ static void cmd_parse_status(struct ImapData *idata, char *s)
         inc->msg_unread = status->unseen;
 
         if (inc->new)
+        {
           /* force back to keep detecting new mail until the mailbox is
              opened */
           status->uidnext = oldun;
+        }
 
         FREE(&value);
         return;
@@ -976,7 +978,9 @@ int imap_cmd_step(struct ImapData *idata)
   if (((mutt_str_strncmp(idata->buf, "* ", 2) == 0) ||
        (mutt_str_strncmp(imap_next_word(idata->buf), "OK [", 4) == 0)) &&
       cmd_handle_untagged(idata))
+  {
     return IMAP_CMD_BAD;
+  }
 
   /* server demands a continuation response from us */
   if (idata->buf[0] == '+')
index 7d408d7b58eaa46dd45dbed67a1712c2a9df2d5e..14951a9486731c5c591e6418d27c14d3125f72b1 100644 (file)
@@ -1482,11 +1482,15 @@ int imap_buffy_check(int check_stats)
 
     imap_munge_mbox_name(idata, munged, sizeof(munged), name);
     if (check_stats)
+    {
       snprintf(command, sizeof(command),
                "STATUS %s (UIDNEXT UIDVALIDITY UNSEEN RECENT MESSAGES)", munged);
+    }
     else
+    {
       snprintf(command, sizeof(command),
                "STATUS %s (UIDNEXT UIDVALIDITY UNSEEN RECENT)", munged);
+    }
 
     if (imap_exec(idata, command, IMAP_CMD_QUEUE | IMAP_CMD_POLL) < 0)
     {
@@ -1547,9 +1551,11 @@ int imap_status(char *path, int queue)
     imap_unmunge_mbox_name(idata, mbox);
   }
   else
+  {
     /* Server does not support STATUS, and this is not the current mailbox.
      * There is no lightweight way to check recent arrivals */
     return -1;
+  }
 
   if (queue)
   {
@@ -2166,7 +2172,9 @@ static int imap_mbox_open(struct Context *ctx)
         mutt_bit_isset(idata->ctx->rights, MUTT_ACL_SEEN) ||
         mutt_bit_isset(idata->ctx->rights, MUTT_ACL_WRITE) ||
         mutt_bit_isset(idata->ctx->rights, MUTT_ACL_INSERT)))
+  {
     ctx->readonly = true;
+  }
 
   ctx->hdrmax = count;
   ctx->hdrs = mutt_mem_calloc(count, sizeof(struct Header *));
index 72d813828ff6058a12b0f8f5f3be793381c42dd4..b35dc4259b6b54d19df5827803cbec9d66b9f0f9 100644 (file)
@@ -942,8 +942,10 @@ int imap_read_headers(struct ImapData *idata, unsigned int msn_begin, unsigned i
     idata->uidnext = maxuid + 1;
   }
   if (idata->uidnext > 1)
+  {
     mutt_hcache_store_raw(idata->hcache, "/UIDNEXT", 8, &idata->uidnext,
                           sizeof(idata->uidnext));
+  }
 
   imap_hcache_close(idata);
 #endif /* USE_HCACHE */
@@ -1076,8 +1078,10 @@ int imap_msg_open(struct Context *ctx, struct Message *msg, int msgno)
           if (mutt_str_atoui(pc, &uid) < 0)
             goto bail;
           if (uid != HEADER_DATA(h)->uid)
+          {
             mutt_error(_(
                 "The message index is incorrect. Try reopening the mailbox."));
+          }
         }
         else if ((mutt_str_strncasecmp("RFC822", pc, 6) == 0) ||
                  (mutt_str_strncasecmp("BODY[]", pc, 6) == 0))
@@ -1447,8 +1451,10 @@ int imap_copy_messages(struct Context *ctx, struct Header *h, char *dest, int de
         goto out;
       }
       else
+      {
         mutt_message(ngettext("Copying %d message to %s...", "Copying %d messages to %s...", rc),
                      rc, mbox);
+      }
     }
     else
     {
index 2d88f511740567160dffb51df93ee49d958fba13..16cdc9623d718c6ced7903a7d194d9a23bb57556 100644 (file)
@@ -406,8 +406,10 @@ int imap_parse_path(const char *path, struct ImapMbox *mx)
     if (!c)
       return -1;
     else
+    {
       /* walk past closing '}' */
       mx->mbox = mutt_str_strdup(c + 1);
+    }
 
     c = strrchr(tmp, '@');
     if (c)
@@ -519,9 +521,11 @@ void imap_pretty_mailbox(char *path)
       if (hlen == 0)
         home_match = true;
       else if (ImapDelimChars)
+      {
         for (delim = ImapDelimChars; *delim != '\0'; delim++)
           if (target.mbox[hlen] == *delim)
             home_match = true;
+      }
     }
     FREE(&home.mbox);
   }
diff --git a/init.c b/init.c
index 2abbffb8f5016eb1c26225a0a0ebfde98b473749..955bf82ed4446409d69779644e035215ac2ab118 100644 (file)
--- a/init.c
+++ b/init.c
@@ -2109,9 +2109,11 @@ static int parse_set(struct Buffer *buf, struct Buffer *s, unsigned long data,
         else if (DTYPE(MuttVars[idx].type) == DT_MBTABLE)
           free_mbtable((struct MbTable **) MuttVars[idx].var);
         else
+        {
           /* MuttVars[idx].var is already 'char**' (or some 'void**') or...
            * so cast to 'void*' is okay */
           FREE((void *) MuttVars[idx].var);
+        }
       }
       else if (query || *s->dptr != '=')
       {
@@ -2416,8 +2418,10 @@ static int parse_set(struct Buffer *buf, struct Buffer *s, unsigned long data,
       else
       {
         if (inv)
+        {
           *(unsigned char *) MuttVars[idx].var =
               toggle_quadoption(*(unsigned char *) MuttVars[idx].var);
+        }
         else if (unset)
           *(unsigned char *) MuttVars[idx].var = MUTT_NO;
         else
@@ -3454,7 +3458,9 @@ int mutt_extract_token(struct Buffer *dest, struct Buffer *tok, int flags)
           (ch == '=' && (flags & MUTT_TOKEN_EQUAL)) ||
           (ch == ';' && !(flags & MUTT_TOKEN_SEMICOLON)) ||
           ((flags & MUTT_TOKEN_PATTERN) && strchr("~%=!|", ch)))
+      {
         break;
+      }
     }
 
     tok->dptr++;
diff --git a/mbox.c b/mbox.c
index 128ec2e79386916db9539ae3d6472ebd1da3c99c..b37fd7b8fa57e14de640e85ee998ccfcae7c5efa 100644 (file)
--- a/mbox.c
+++ b/mbox.c
@@ -306,8 +306,10 @@ static int mbox_parse_mailbox(struct Context *ctx)
       count++;
 
       if (!ctx->quiet)
+      {
         mutt_progress_update(&progress, count,
                              (int) (ftello(ctx->fp) / (ctx->size / 100 + 1)));
+      }
 
       if (ctx->msgcount == ctx->hdrmax)
         mx_alloc_memory(ctx);
@@ -393,8 +395,10 @@ static int mbox_parse_mailbox(struct Context *ctx)
       ctx->msgcount++;
 
       if (!curhdr->env->return_path && return_path[0])
+      {
         curhdr->env->return_path =
             mutt_addr_parse_list(curhdr->env->return_path, return_path);
+      }
 
       if (!curhdr->env->from)
         curhdr->env->from = mutt_addr_copy_list(curhdr->env->return_path, false);
@@ -588,7 +592,9 @@ static int strict_cmp_bodies(const struct Body *b1, const struct Body *b2)
       (mutt_str_strcmp(b1->subtype, b2->subtype) != 0) ||
       (mutt_str_strcmp(b1->description, b2->description) != 0) ||
       !mutt_param_cmp_strict(&b1->parameter, &b2->parameter) || b1->length != b2->length)
+  {
     return 0;
+  }
   return 1;
 }
 
@@ -606,7 +612,9 @@ int mbox_strict_cmp_headers(const struct Header *h1, const struct Header *h2)
         h1->zoccident != h2->zoccident || h1->mime != h2->mime ||
         !mutt_env_cmp_strict(h1->env, h2->env) ||
         !strict_cmp_bodies(h1->content, h2->content))
+    {
       return 0;
+    }
     else
       return 1;
   }
@@ -1321,9 +1329,11 @@ bail: /* Come here in case of disaster */
   }
 
   if (need_sort)
+  {
     /* if the mailbox was reopened, the thread tree will be invalid so make
      * sure to start threading from scratch.  */
     mutt_sort_headers(ctx, (need_sort == MUTT_REOPENED));
+  }
 
   return rc;
 }
diff --git a/menu.c b/menu.c
index 51ba7380906f73b9dabf4bae14672e9df5f7d9cf..0f521173380e1a19a44e1d4318547ff537a9b80a 100644 (file)
--- a/menu.c
+++ b/menu.c
@@ -513,12 +513,16 @@ void menu_check_recenter(struct Menu *menu)
     else
     {
       if (menu->current < menu->top + c)
+      {
         menu->top -= (menu->pagelen - c) * ((menu->top + menu->pagelen - 1 - menu->current) /
                                             (menu->pagelen - c)) -
                      c;
+      }
       else if ((menu->current >= menu->top + menu->pagelen - c))
+      {
         menu->top +=
             (menu->pagelen - c) * ((menu->current - menu->top) / (menu->pagelen - c)) - c;
+      }
     }
   }
 
@@ -937,7 +941,9 @@ static int menu_search(struct Menu *menu, int op)
                            _("Reverse search for: "),
                        buf, sizeof(buf), MUTT_CLEAR) != 0 ||
         !buf[0])
+    {
       return -1;
+    }
     if (menu->menu >= 0 && menu->menu < MENU_MAX)
     {
       mutt_str_replace(&SearchBuffers[menu->menu], buf);
@@ -1120,8 +1126,10 @@ int mutt_menu_loop(struct Menu *menu)
     else if (BrailleFriendly)
       mutt_window_move(menu->indexwin, menu->current - menu->top + menu->offset, 0);
     else
+    {
       mutt_window_move(menu->indexwin, menu->current - menu->top + menu->offset,
                        menu->indexwin->cols - 1);
+    }
 
     mutt_refresh();
 
diff --git a/mh.c b/mh.c
index b6be89bdb5c12cf4e05a74a35115526348afbe3f..c56fff418ef09a7577d9ed6991dbb94eeacaf800 100644 (file)
--- a/mh.c
+++ b/mh.c
@@ -1755,8 +1755,10 @@ static int mh_commit_msg(struct Context *ctx, struct Message *msg,
     }
   }
   if (updseq)
+  {
     mh_sequences_add_one(ctx, hi, !msg->flags.read, msg->flags.flagged,
                          msg->flags.replied);
+  }
   return 0;
 }
 
index 6a6893c380b6754347a79382862713c5c3d34117..e9478cc9a5cd9e068b9d600685b92fef374f4d04 100644 (file)
@@ -239,7 +239,9 @@ static size_t try_block(const char *d, size_t dlen, const char *fromcode,
     assert(strchr(MimeSpecials, '?'));
     if ((c >= 0x7f) || (c < 0x20) || (*p == '_') ||
         ((c != ' ') && strchr(MimeSpecials, *p)))
+    {
       count++;
+    }
   }
 
   len = ENCWORD_LEN_MIN - 2 + strlen(tocode);
index 21e13d9cd1d37b20e0818a61515fd351df9c34cc..d71e7cfe3cbb5dbee8adfea39fe24c1e8a3f91fc 100644 (file)
@@ -318,7 +318,9 @@ static bool query_window_check_timebase(const char *timebase)
   if ((strcmp(timebase, "hour") == 0) || (strcmp(timebase, "day") == 0) ||
       (strcmp(timebase, "week") == 0) || (strcmp(timebase, "month") == 0) ||
       (strcmp(timebase, "year") == 0))
+  {
     return true;
+  }
   return false;
 }
 
@@ -402,11 +404,15 @@ static bool windowed_query_from_query(const char *query, char *buf, size_t bufle
   }
 
   if (end == 0)
+  {
     snprintf(buf, buflen, "date:%d%s..now and %s", beg, NmQueryWindowTimebase,
              NmQueryWindowCurrentSearch);
+  }
   else
+  {
     snprintf(buf, buflen, "date:%d%s..%d%s and %s", beg, NmQueryWindowTimebase,
              end, NmQueryWindowTimebase, NmQueryWindowCurrentSearch);
+  }
 
   mutt_debug(2, "nm: %s -> %s\n", query, buf);
 
@@ -1048,8 +1054,10 @@ static void progress_update(struct Context *ctx, notmuch_query_t *q)
   }
 
   if (data->progress_ready)
+  {
     mutt_progress_update(&data->progress,
                          ctx->msgcount + data->ignmsgcount - data->oldmsgcount, -1);
+  }
 }
 
 /**
@@ -1888,11 +1896,15 @@ char *nm_uri_from_query(struct Context *ctx, char *buf, size_t buflen)
     }
   }
   else if (NmDefaultUri)
+  {
     added = snprintf(uri, sizeof(uri), "%s?type=%s&query=", NmDefaultUri,
                      query_type_to_string(string_to_query_type(NmQueryType)));
+  }
   else if (Folder)
+  {
     added = snprintf(uri, sizeof(uri), "notmuch://%s?type=%s&query=", Folder,
                      query_type_to_string(string_to_query_type(NmQueryType)));
+  }
   else
     return NULL;
 
index fe6847ac141065b2688869e6df215d577a9e6118..e557548fad0872db28c28aa4367206213d11da4f 100644 (file)
--- a/muttlib.c
+++ b/muttlib.c
@@ -319,8 +319,10 @@ char *mutt_gecos_name(char *dest, size_t destlen, struct passwd *pw)
   if (GecosMask && GecosMask->regex)
   {
     if (regexec(GecosMask->regex, pw->pw_gecos, 1, pat_match, 0) == 0)
+    {
       mutt_str_strfcpy(dest, pw->pw_gecos + pat_match[0].rm_so,
                        MIN(pat_match[0].rm_eo - pat_match[0].rm_so + 1, destlen));
+    }
   }
   else if ((p = strchr(pw->pw_gecos, ',')))
     mutt_str_strfcpy(dest, pw->pw_gecos, MIN(destlen, p - pw->pw_gecos + 1));
@@ -475,14 +477,18 @@ void mutt_mktemp_full(char *s, size_t slen, const char *prefix,
                       NONULL(prefix), NONULL(ShortHostname), (int) getuid(),
                       (int) getpid(), mutt_rand64(), suffix ? "." : "", NONULL(suffix));
   if (n >= slen)
+  {
     mutt_debug(1,
                "%s:%d: ERROR: insufficient buffer space to hold temporary "
                "filename! slen=%zu but need %zu\n",
                src, line, slen, n);
+  }
   mutt_debug(3, "%s:%d: mutt_mktemp returns \"%s\".\n", src, line, s);
   if (unlink(s) && errno != ENOENT)
+  {
     mutt_debug(1, "%s:%d: ERROR: unlink(\"%s\"): %s (errno %d)\n", src, line, s,
                strerror(errno), errno);
+  }
 }
 
 /**
@@ -675,7 +681,9 @@ int mutt_check_overwrite(const char *attname, const char *path, char *fname,
     if (mutt_get_field(_("File under directory: "), tmp, sizeof(tmp),
                        MUTT_FILE | MUTT_CLEAR) != 0 ||
         !tmp[0])
+    {
       return -1;
+    }
     mutt_file_concat_path(fname, path, tmp, flen);
   }
 
@@ -803,11 +811,13 @@ void mutt_expando_format(char *buf, size_t buflen, size_t col, int cols, const c
         for (char *p = tmp; p && *p; p++)
         {
           if (*p == '\'')
+          {
             /* shell quoting doesn't permit escaping a single quote within
              * single-quoted material.  double-quoting instead will lead
              * shell variable expansions, so break out of the single-quoted
              * span, insert a double-quoted single quote, and resume. */
             mutt_buffer_addstr(command, "'\"'\"'");
+          }
           else
             mutt_buffer_addch(command, *p);
         }
@@ -1537,9 +1547,11 @@ int mutt_inbox_cmp(const char *a, const char *b)
 {
   /* fast-track in case the paths have been mutt_pretty_mailbox'ified */
   if (a[0] == '=' && b[0] == '=')
+  {
     return (mutt_str_strcasecmp(a + 1, "inbox") == 0) ?
                -1 :
                (mutt_str_strcasecmp(b + 1, "inbox") == 0) ? 1 : 0;
+  }
 
   const char *a_end = strrchr(a, '/');
   const char *b_end = strrchr(b, '/');
diff --git a/mx.c b/mx.c
index b25d61c4328d127f244a6d56abfb962f09342432..1dd4072729911037977fbf66378458962744c98e 100644 (file)
--- a/mx.c
+++ b/mx.c
@@ -920,8 +920,10 @@ int mx_mbox_close(struct Context *ctx, int *index_hint)
   if (!ctx->quiet)
   {
     if (move_messages)
+    {
       mutt_message(_("%d kept, %d moved, %d deleted."),
                    ctx->msgcount - ctx->deleted, read_msgs, ctx->deleted);
+    }
     else
       mutt_message(_("%d kept, %d deleted."), ctx->msgcount - ctx->deleted, ctx->deleted);
   }
@@ -1020,8 +1022,10 @@ void mx_update_tables(struct Context *ctx, bool committing)
     else
     {
       if (ctx->magic == MUTT_MH || ctx->magic == MUTT_MAILDIR)
+      {
         ctx->size -= (ctx->hdrs[i]->content->length + ctx->hdrs[i]->content->offset -
                       ctx->hdrs[i]->content->hdr_offset);
+      }
       /* remove message from the hash tables */
       if (ctx->subj_hash && ctx->hdrs[i]->env->real_subj)
         mutt_hash_delete(ctx->subj_hash, ctx->hdrs[i]->env->real_subj, ctx->hdrs[i]);
index 57bae2c97e874be66a3a9e057f755c1dfdc2d9cb..55f5a6377363fbb663eeb78f84db1d52941dd08c 100644 (file)
@@ -369,7 +369,9 @@ int mutt_is_multipart_encrypted(struct Body *b)
       (mutt_str_strcasecmp(b->subtype, "encrypted") != 0) ||
       !(p = mutt_param_get(&b->parameter, "protocol")) ||
       (mutt_str_strcasecmp(p, "application/pgp-encrypted") != 0))
+  {
     return 0;
+  }
 
   return PGPENCRYPT;
 }
@@ -487,7 +489,9 @@ int mutt_is_application_pgp(struct Body *m)
          (p = mutt_param_get(&m->parameter, "x-action")) ||
          (p = mutt_param_get(&m->parameter, "action"))) &&
         (mutt_str_strncasecmp("pgp-sign", p, 8) == 0))
+    {
       t |= PGPSIGN;
+    }
     else if (p && (mutt_str_strncasecmp("pgp-encrypt", p, 11) == 0))
       t |= PGPENCRYPT;
     else if (p && (mutt_str_strncasecmp("pgp-keys", p, 7) == 0))
@@ -543,8 +547,10 @@ int mutt_is_application_smime(struct Body *m)
   if (!t)
   {
     if (complain)
+    {
       mutt_message(
           _("S/MIME messages with no hints on content are unsupported."));
+    }
     return 0;
   }
 
@@ -555,9 +561,11 @@ int mutt_is_application_smime(struct Body *m)
   {
     len++;
     if (mutt_str_strcasecmp((t + len), "p7m") == 0)
+    {
       /* Not sure if this is the correct thing to do, but
         it's required for compatibility with Outlook */
       return (SMIMESIGN | SMIMEOPAQUE);
+    }
     else if (mutt_str_strcasecmp((t + len), "p7s") == 0)
       return (SMIMESIGN | SMIMEOPAQUE);
   }
@@ -765,9 +773,11 @@ void crypt_extract_keys_from_messages(struct Header *h)
       if (((WithCrypto & APPLICATION_SMIME) != 0) && (hi->security & APPLICATION_SMIME))
       {
         if (hi->security & ENCRYPT)
+        {
           mutt_copy_message_ctx(fpout, Context, hi,
                                 MUTT_CM_NOHEADER | MUTT_CM_DECODE_CRYPT | MUTT_CM_DECODE_SMIME,
                                 0);
+        }
         else
           mutt_copy_message_ctx(fpout, Context, hi, 0, 0);
         fflush(fpout);
@@ -806,9 +816,11 @@ void crypt_extract_keys_from_messages(struct Header *h)
       if (((WithCrypto & APPLICATION_SMIME) != 0) && (h->security & APPLICATION_SMIME))
       {
         if (h->security & ENCRYPT)
+        {
           mutt_copy_message_ctx(fpout, Context, h,
                                 MUTT_CM_NOHEADER | MUTT_CM_DECODE_CRYPT | MUTT_CM_DECODE_SMIME,
                                 0);
+        }
         else
           mutt_copy_message_ctx(fpout, Context, h, 0, 0);
 
index b86530835a3453be9f0770422c5cb48b9520a90c..61131c7b33b5ec98ad764e4126d7ce20f49abd0b 100644 (file)
@@ -1253,9 +1253,11 @@ static int show_sig_summary(unsigned long sum, gpgme_ctx_t ctx, gpgme_key_t key,
       state_puts("\n", s);
     }
     else
+    {
       state_puts(_("Warning: At least one certification key "
                    "has expired\n"),
                  s);
+    }
   }
 
   if ((sum & GPGME_SIGSUM_SIG_EXPIRED))
@@ -1275,9 +1277,11 @@ static int show_sig_summary(unsigned long sum, gpgme_ctx_t ctx, gpgme_key_t key,
   }
 
   if ((sum & GPGME_SIGSUM_KEY_MISSING))
+  {
     state_puts(_("Can't verify due to a missing "
                  "key or certificate\n"),
                s);
+  }
 
   if ((sum & GPGME_SIGSUM_CRL_MISSING))
   {
@@ -1870,9 +1874,11 @@ restart:
       *r_is_signed = -1; /* A signature exists. */
 
     if ((s->flags & MUTT_DISPLAY))
+    {
       state_attach_puts(_("[-- Begin signature "
                           "information --]\n"),
                         s);
+    }
     for (idx = 0; (res = show_one_sig_status(ctx, idx, s)) != -1; idx++)
     {
       if (res == 1)
@@ -1884,9 +1890,11 @@ restart:
       *r_is_signed = anywarn ? 2 : 1; /* Good signature. */
 
     if ((s->flags & MUTT_DISPLAY))
+    {
       state_attach_puts(_("[-- End signature "
                           "information --]\n\n"),
                         s);
+    }
   }
   gpgme_release(ctx);
   ctx = NULL;
@@ -2224,11 +2232,15 @@ static int pgp_gpgme_extract_keys(gpgme_data_t keydata, FILE **fp, int dryrun)
       strftime(date, sizeof(date), "%Y-%m-%d", localtime(&tt));
 
       if (!more)
+      {
         fprintf(*fp, "pub %5.5s %d/%8s %s %s\n", gpgme_pubkey_algo_name(subkey->pubkey_algo),
                 subkey->length, shortid, date, uid->uid);
+      }
       else
+      {
         fprintf(*fp, "sub %5.5s %d/%8s %s\n", gpgme_pubkey_algo_name(subkey->pubkey_algo),
                 subkey->length, shortid, date);
+      }
       subkey = subkey->next;
       more = 1;
     }
@@ -2724,9 +2736,11 @@ int pgp_gpgme_encrypted_handler(struct Body *a, struct State *s)
   if (!fpout)
   {
     if (s->flags & MUTT_DISPLAY)
+    {
       state_attach_puts(_("[-- Error: could not create temporary file! "
                           "--]\n"),
                         s);
+    }
     return -1;
   }
 
@@ -2736,11 +2750,13 @@ int pgp_gpgme_encrypted_handler(struct Body *a, struct State *s)
     tattach->goodsig = is_signed > 0;
 
     if (s->flags & MUTT_DISPLAY)
+    {
       state_attach_puts(
           is_signed ? _("[-- The following data is PGP/MIME signed and "
                         "encrypted --]\n\n") :
                       _("[-- The following data is PGP/MIME encrypted --]\n\n"),
           s);
+    }
 
     {
       FILE *savefp = s->fpin;
@@ -2749,11 +2765,10 @@ int pgp_gpgme_encrypted_handler(struct Body *a, struct State *s)
       s->fpin = savefp;
     }
 
-    /*
-       * if a multipart/signed is the _only_ sub-part of a
-       * multipart/encrypted, cache signature verification
-       * status.
-       */
+    /* if a multipart/signed is the _only_ sub-part of a
+     * multipart/encrypted, cache signature verification
+     * status.
+     */
     if (mutt_is_multipart_signed(tattach) && !tattach->next)
       a->goodsig |= tattach->goodsig;
 
@@ -2799,9 +2814,11 @@ int smime_gpgme_application_handler(struct Body *a, struct State *s)
   if (!fpout)
   {
     if (s->flags & MUTT_DISPLAY)
+    {
       state_attach_puts(_("[-- Error: could not create temporary file! "
                           "--]\n"),
                         s);
+    }
     return -1;
   }
 
@@ -2811,10 +2828,12 @@ int smime_gpgme_application_handler(struct Body *a, struct State *s)
     tattach->goodsig = is_signed > 0;
 
     if (s->flags & MUTT_DISPLAY)
+    {
       state_attach_puts(
           is_signed ? _("[-- The following data is S/MIME signed --]\n\n") :
                       _("[-- The following data is S/MIME encrypted --]\n\n"),
           s);
+    }
 
     {
       FILE *savefp = s->fpin;
@@ -3727,8 +3746,10 @@ static void print_key_info(gpgme_key_t key, FILE *fp)
   {
     s = key->issuer_serial;
     if (s)
+    {
       fprintf(fp, "%*s0x%s\n", KeyInfoPadding[KIP_SERIAL_NO],
               _(KeyInfoPrompts[KIP_SERIAL_NO]), s);
+    }
   }
 
   if (key->issuer_name)
@@ -4242,15 +4263,19 @@ static struct CryptKeyInfo *crypt_select_key(struct CryptKeyInfo *keys,
       ts = _("keys matching");
 
     if (p)
+    {
       /* L10N:
          %1$s is one of the previous four entries.
          %2$s is an address.
          e.g. "S/MIME keys matching <me@mutt.org>." */
       snprintf(buf, sizeof(buf), _("%s <%s>."), ts, p->mailbox);
+    }
     else
+    {
       /* L10N:
          e.g. 'S/MIME keys matching "Michael Elkins".' */
       snprintf(buf, sizeof(buf), _("%s \"%s\"."), ts, s);
+    }
     menu->title = buf;
   }
 
@@ -4290,8 +4315,10 @@ static struct CryptKeyInfo *crypt_select_key(struct CryptKeyInfo *keys,
           char buf2[LONG_STRING];
 
           if (key_table[menu->current]->flags & KEYFLAG_CANTUSE)
+          {
             warn_s = _("ID is expired/disabled/revoked. Do you really want to "
                        "use the key?");
+          }
           else
           {
             warn_s = "??";
index 43d0fd7f99b452479a3b5e6bee6f7570e72d0f90..885baed6a6eff039709f0207f48c23525f3b0804 100644 (file)
@@ -352,7 +352,9 @@ static struct PgpKeyInfo *parse_pub_line(char *buf, int *is_subkey, struct PgpKe
         if (!is_uid && (!*is_subkey || !PgpIgnoreSubkeys ||
                         !((flags & KEYFLAG_DISABLED) || (flags & KEYFLAG_REVOKED) ||
                           (flags & KEYFLAG_EXPIRED))))
+        {
           tmp.flags |= flags;
+        }
 
         break;
 
index 0d051e13effbcdf7ab764cae05d27b50f00a6a6f..dce95ab03e63fb3fd49e3ea69063cd1b7bed5cf1 100644 (file)
@@ -405,7 +405,9 @@ int pgp_application_pgp_handler(struct Body *m, struct State *s)
             (!needpass &&
              ((mutt_str_strcmp("-----END PGP SIGNATURE-----\n", buf) == 0) ||
               (mutt_str_strcmp("-----END PGP PUBLIC KEY BLOCK-----\n", buf) == 0))))
+        {
           break;
+        }
         /* remember optional Charset: armor header as defined by RFC4880 */
         if (mutt_str_strncmp("Charset: ", buf, 9) == 0)
         {
@@ -859,8 +861,10 @@ static struct Body *pgp_decrypt_part(struct Body *a, struct State *s,
     mutt_file_fclose(&pgperr);
     unlink(pgptmpfile);
     if (s->flags & MUTT_DISPLAY)
+    {
       state_attach_puts(
           _("[-- Error: could not create a PGP subprocess! --]\n\n"), s);
+    }
     return NULL;
   }
 
@@ -1049,8 +1053,10 @@ int pgp_encrypted_handler(struct Body *a, struct State *s)
   if (tattach)
   {
     if (s->flags & MUTT_DISPLAY)
+    {
       state_attach_puts(
           _("[-- The following data is PGP/MIME encrypted --]\n\n"), s);
+    }
 
     fpin = s->fpin;
     s->fpin = fpout;
index 521fd0c1807184942f4c3a137d7868f2774ffb46..01c98940709cec64c0d1021024cb54b7510c75a2 100644 (file)
@@ -217,11 +217,15 @@ pid_t pgp_invoke_encrypt(FILE **pgpin, FILE **pgpout, FILE **pgperr,
                          const char *fname, const char *uids, int sign)
 {
   if (sign)
+  {
     return pgp_invoke(pgpin, pgpout, pgperr, pgpinfd, pgpoutfd, pgperrfd, 1,
                       fname, NULL, uids, PgpEncryptSignCommand);
+  }
   else
+  {
     return pgp_invoke(pgpin, pgpout, pgperr, pgpinfd, pgpoutfd, pgperrfd, 0,
                       fname, NULL, uids, PgpEncryptOnlyCommand);
+  }
 }
 
 pid_t pgp_invoke_traditional(FILE **pgpin, FILE **pgpout, FILE **pgperr,
@@ -229,12 +233,16 @@ pid_t pgp_invoke_traditional(FILE **pgpin, FILE **pgpout, FILE **pgperr,
                              const char *fname, const char *uids, int flags)
 {
   if (flags & ENCRYPT)
+  {
     return pgp_invoke(pgpin, pgpout, pgperr, pgpinfd, pgpoutfd, pgperrfd,
                       (flags & SIGN) ? 1 : 0, fname, NULL, uids,
                       (flags & SIGN) ? PgpEncryptSignCommand : PgpEncryptOnlyCommand);
+  }
   else
+  {
     return pgp_invoke(pgpin, pgpout, pgperr, pgpinfd, pgpoutfd, pgperrfd, 1,
                       fname, NULL, NULL, PgpClearsignCommand);
+  }
 }
 
 void pgp_invoke_import(const char *fname)
index abb00c40de83526d8b92bc18fe1a1a046f6d0add..e577fb33a73b34dfed5edd851848579da85e9399 100644 (file)
@@ -327,8 +327,10 @@ static int compare_key_address(const void *a, const void *b)
   if (r != 0)
     return r > 0;
   else
+  {
     return (mutt_str_strcasecmp(pgp_fpr_or_lkeyid((*s)->parent),
                                 pgp_fpr_or_lkeyid((*t)->parent)) > 0);
+  }
 }
 
 static int pgp_compare_address(const void *a, const void *b)
@@ -637,9 +639,12 @@ static struct PgpKeyInfo *pgp_select_key(struct PgpKeyInfo *keys,
           char buf2[LONG_STRING];
 
           if (KeyTable[menu->current]->flags & KEYFLAG_CANTUSE)
+          {
             str = _("ID is expired/disabled/revoked. Do you really want to use "
                     "the key?");
+          }
           else
+          {
             switch (KeyTable[menu->current]->trust & 0x03)
             {
               case 0:
@@ -654,6 +659,7 @@ static struct PgpKeyInfo *pgp_select_key(struct PgpKeyInfo *keys,
                         "use the key?");
                 break;
             }
+          }
 
           snprintf(buf2, sizeof(buf2), "%s", str);
 
index f056d5f32c1ddd525e6cd310f63651e0652a5af1..d9af6715cbe725f342021cea157ea2f4ea750585 100644 (file)
@@ -1309,8 +1309,10 @@ int smime_verify_sender(struct Header *h)
   }
 
   if (h->security & ENCRYPT)
+  {
     mutt_copy_message_ctx(fpout, Context, h, MUTT_CM_DECODE_CRYPT & MUTT_CM_DECODE_SMIME,
                           CH_MIME | CH_WEED | CH_NONEWLINE);
+  }
   else
     mutt_copy_message_ctx(fpout, Context, h, 0, 0);
 
@@ -1847,8 +1849,10 @@ static struct Body *smime_handle_entity(struct Body *m, struct State *s, FILE *o
     mutt_file_fclose(&smimeout);
     mutt_file_unlink(tmpfname);
     if (s->flags & MUTT_DISPLAY)
+    {
       state_attach_puts(
           _("[-- Error: unable to create OpenSSL subprocess! --]\n"), s);
+    }
     mutt_file_fclose(&smimeerr);
     return NULL;
   }
@@ -1859,8 +1863,10 @@ static struct Body *smime_handle_entity(struct Body *m, struct State *s, FILE *o
     mutt_file_fclose(&smimeout);
     mutt_file_unlink(tmpfname);
     if (s->flags & MUTT_DISPLAY)
+    {
       state_attach_puts(
           _("[-- Error: unable to create OpenSSL subprocess! --]\n"), s);
+    }
     mutt_file_fclose(&smimeerr);
     return NULL;
   }
@@ -1894,9 +1900,11 @@ static struct Body *smime_handle_entity(struct Body *m, struct State *s, FILE *o
     }
 
     if (type & ENCRYPT)
+    {
       state_attach_puts(_("[-- The following data is S/MIME"
                           " encrypted --]\n"),
                         s);
+    }
     else
       state_attach_puts(_("[-- The following data is S/MIME signed --]\n"), s);
   }
index 08e6a39b929459c9c55f1bfae9e19f2d5de9ef6d..5558ab13694871f18f11b96f81f4d5caf518874f 100644 (file)
--- a/newsrc.c
+++ b/newsrc.c
@@ -501,8 +501,10 @@ int nntp_newsrc_update(struct NntpServer *nserv)
       if (nntp_data->newsrc_ent[j].first == nntp_data->newsrc_ent[j].last)
         snprintf(buf + off, buflen - off, "%u", nntp_data->newsrc_ent[j].first);
       else if (nntp_data->newsrc_ent[j].first < nntp_data->newsrc_ent[j].last)
+      {
         snprintf(buf + off, buflen - off, "%u-%u",
                  nntp_data->newsrc_ent[j].first, nntp_data->newsrc_ent[j].last);
+      }
       off += strlen(buf + off);
     }
     buf[off++] = '\n';
@@ -726,7 +728,9 @@ header_cache_t *nntp_hcache_open(struct NntpData *nntp_data)
   if (!nntp_data->nserv || !nntp_data->nserv->cacheable ||
       !nntp_data->nserv->conn || !nntp_data->group ||
       !(nntp_data->newsrc_ent || nntp_data->subscribed || SaveUnsubscribed))
+  {
     return NULL;
+  }
 
   mutt_account_tourl(&nntp_data->nserv->conn->account, &url);
   url.path = nntp_data->group;
@@ -834,8 +838,10 @@ void nntp_delete_group_cache(struct NntpData *nntp_data)
 #endif
 
   if (!nntp_data->bcache)
+  {
     nntp_data->bcache =
         mutt_bcache_open(&nntp_data->nserv->conn->account, nntp_data->group);
+  }
   if (nntp_data->bcache)
   {
     mutt_debug(2, "%s/*\n", nntp_data->group);
diff --git a/nntp.c b/nntp.c
index 2713d6561d0ba0112413b902fa95b77feb9e0b84..e379d858627b63f390e4c6a2766e40ce377efe41 100644 (file)
--- a/nntp.c
+++ b/nntp.c
@@ -513,8 +513,10 @@ static int nntp_auth(struct NntpServer *nserv)
           if (DebugLevel < MUTT_SOCK_LOG_FULL)
           {
             if (strchr(buf, ' '))
+            {
               mutt_debug(MUTT_SOCK_LOG_CMD, "%d> AUTHINFO SASL %s%s\n",
                          conn->fd, method, client_len ? " sasl_data" : "");
+            }
             else
               mutt_debug(MUTT_SOCK_LOG_CMD, "%d> sasl_data\n", conn->fd);
           }
@@ -695,11 +697,13 @@ int nntp_open_connection(struct NntpServer *nserv)
   if (nserv->use_tls != 1 && (nserv->hasSTARTTLS || SslForceTls))
   {
     if (nserv->use_tls == 0)
+    {
       nserv->use_tls =
           SslForceTls || query_quadoption(SslStarttls,
                                           _("Secure connection with TLS?")) == MUTT_YES ?
               2 :
               1;
+    }
     if (nserv->use_tls == 2)
     {
       if (mutt_socket_send(conn, "STARTTLS\r\n") < 0 ||
@@ -1325,13 +1329,17 @@ static int nntp_fetch_headers(struct Context *ctx, void *hc, anum_t first,
     }
   }
   else
+  {
     for (current = first; current <= last; current++)
       fc.messages[current - first] = 1;
+  }
 
   /* fetching header from cache or server, or fallback to fetch overview */
   if (!ctx->quiet)
+  {
     mutt_progress_init(&fc.progress, _("Fetching message headers..."),
                        MUTT_PROGRESS_MSG, ReadInc, last - first + 1);
+  }
   for (current = first; current <= last && rc == 0; current++)
   {
     if (!ctx->quiet)
@@ -1383,10 +1391,12 @@ static int nntp_fetch_headers(struct Context *ctx, void *hc, anum_t first,
 
     /* fallback to fetch overview */
     else if (nntp_data->nserv->hasOVER || nntp_data->nserv->hasXOVER)
+    {
       if (NntpListgroup && nntp_data->nserv->hasLISTGROUP)
         break;
       else
         continue;
+    }
 
     /* fetch header from server */
     else
@@ -1686,8 +1696,10 @@ static int nntp_msg_open(struct Context *ctx, struct Message *msg, int msgno)
       if (rc > 0)
       {
         if (mutt_str_strncmp(NHDR(hdr)->article_num ? "423" : "430", buf, 3) == 0)
+        {
           mutt_error(_("Article %d not found on the server."),
                      NHDR(hdr)->article_num ? article : hdr->env->message_id);
+        }
         else
           mutt_error("ARTICLE: %s", buf);
       }
@@ -1813,7 +1825,9 @@ int nntp_post(const char *msg)
        mutt_socket_send_d(nntp_data->nserv->conn, "\r\n", MUTT_SOCK_LOG_HDR) < 0) ||
       mutt_socket_send_d(nntp_data->nserv->conn, ".\r\n", MUTT_SOCK_LOG_HDR) < 0 ||
       mutt_socket_readln(buf, sizeof(buf), nntp_data->nserv->conn) < 0)
+  {
     return nntp_connect_error(nntp_data->nserv);
+  }
   if (buf[0] != '2')
   {
     mutt_error(_("Can't post article: %s"), buf);
@@ -2550,8 +2564,10 @@ int nntp_check_children(struct Context *ctx, const char *msgid)
       if (mutt_str_strncmp("500", buf, 3) != 0)
         mutt_error("XPAT: %s", buf);
       else
+      {
         mutt_error(_("Unable to find child articles because server does not "
                      "support XPAT command."));
+      }
     }
     return -1;
   }
diff --git a/pager.c b/pager.c
index 373e47588503b5409afb3457f6df40a9d2e4cf1f..b4af3f786b747047a3a2a8887f64a32c25fe2df0 100644 (file)
--- a/pager.c
+++ b/pager.c
@@ -859,9 +859,11 @@ static void resolve_types(char *buf, char *raw, struct Line *line_info, int n,
         if (regexec(QuoteRegex->regex, buf, 1, pmatch, 0) == 0)
         {
           if (q_classify && line_info[n].quote == NULL)
+          {
             line_info[n].quote = classify_quote(quote_list, buf + pmatch[0].rm_so,
                                                 pmatch[0].rm_eo - pmatch[0].rm_so,
                                                 force_redraw, q_level);
+          }
           line_info[n].type = MT_COLOR_QUOTED;
         }
         else
@@ -875,9 +877,11 @@ static void resolve_types(char *buf, char *raw, struct Line *line_info, int n,
     else
     {
       if (q_classify && line_info[n].quote == NULL)
+      {
         line_info[n].quote = classify_quote(quote_list, buf + pmatch[0].rm_so,
                                             pmatch[0].rm_eo - pmatch[0].rm_so,
                                             force_redraw, q_level);
+      }
       line_info[n].type = MT_COLOR_QUOTED;
     }
   }
@@ -928,8 +932,10 @@ static void resolve_types(char *buf, char *raw, struct Line *line_info, int n,
                 break;
               }
               if (++(line_info[n].chunks) > 1)
+              {
                 mutt_mem_realloc(&(line_info[n].syntax),
                                  (line_info[n].chunks) * sizeof(struct Syntax));
+              }
             }
             i = line_info[n].chunks - 1;
             pmatch[0].rm_so += offset;
@@ -989,8 +995,10 @@ static void resolve_types(char *buf, char *raw, struct Line *line_info, int n,
             if (!found)
             {
               if (++(line_info[n].chunks) > 1)
+              {
                 mutt_mem_realloc(&(line_info[n].syntax),
                                  (line_info[n].chunks) * sizeof(struct Syntax));
+              }
             }
             i = line_info[n].chunks - 1;
             pmatch[0].rm_so += offset;
@@ -1539,8 +1547,10 @@ static int display_line(FILE *f, LOFF_T *last_pos, struct Line **line_info,
                    (offset ? REG_NOTBOL : 0)) == 0)
     {
       if (++((*line_info)[n].search_cnt) > 1)
+      {
         mutt_mem_realloc(&((*line_info)[n].search),
                          ((*line_info)[n].search_cnt) * sizeof(struct Syntax));
+      }
       else
         (*line_info)[n].search = mutt_mem_malloc(sizeof(struct Syntax));
       pmatch[0].rm_so += offset;
@@ -2394,8 +2404,10 @@ int mutt_pager(const char *banner, const char *fname, int flags, struct Pager *e
 
       case OP_HALF_UP:
         if (rd.topline)
+        {
           rd.topline = up_n_lines(rd.pager_window->rows / 2, rd.line_info,
                                   rd.topline, rd.hide_quoted);
+        }
         else
           mutt_error(_("Top of message is shown."));
         break;
@@ -2499,7 +2511,9 @@ int mutt_pager(const char *banner, const char *fname, int flags, struct Pager *e
                                _("Search for: ") :
                                _("Reverse search for: "),
                            buffer, sizeof(buffer), MUTT_CLEAR) != 0)
+        {
           break;
+        }
 
         if (strcmp(buffer, searchbuf) == 0)
         {
@@ -2983,8 +2997,10 @@ int mutt_pager(const char *banner, const char *fname, int flags, struct Pager *e
             break;
           }
           if (IsMsgAttach(extra))
+          {
             mutt_attach_reply(extra->fp, extra->hdr, extra->actx, extra->bdy,
                               SENDNEWS | SENDREPLY);
+          }
           else
             ci_send_message(SENDNEWS | SENDREPLY, NULL, NULL, extra->ctx, extra->hdr);
           pager_menu->redraw = REDRAW_FULL;
@@ -3013,11 +3029,15 @@ int mutt_pager(const char *banner, const char *fname, int flags, struct Pager *e
         CHECK_MODE(IsHeader(extra) || IsMsgAttach(extra));
         CHECK_ATTACH;
         if (IsMsgAttach(extra))
+        {
           mutt_attach_reply(extra->fp, extra->hdr, extra->actx, extra->bdy,
                             SENDREPLY | SENDGROUPREPLY);
+        }
         else
+        {
           ci_send_message(SENDREPLY | SENDGROUPREPLY, NULL, NULL, extra->ctx,
                           extra->hdr);
+        }
         pager_menu->redraw = REDRAW_FULL;
         break;
 
@@ -3025,11 +3045,15 @@ int mutt_pager(const char *banner, const char *fname, int flags, struct Pager *e
         CHECK_MODE(IsHeader(extra) || IsMsgAttach(extra));
         CHECK_ATTACH;
         if (IsMsgAttach(extra))
+        {
           mutt_attach_reply(extra->fp, extra->hdr, extra->actx, extra->bdy,
                             SENDREPLY | SENDLISTREPLY);
+        }
         else
+        {
           ci_send_message(SENDREPLY | SENDLISTREPLY, NULL, NULL, extra->ctx,
                           extra->hdr);
+        }
         pager_menu->redraw = REDRAW_FULL;
         break;
 
@@ -3160,8 +3184,10 @@ int mutt_pager(const char *banner, const char *fname, int flags, struct Pager *e
         r = mutt_thread_set_flag(extra->hdr, MUTT_DELETE, 0,
                                  ch == OP_UNDELETE_THREAD ? 0 : 1);
         if (r != -1)
+        {
           r = mutt_thread_set_flag(extra->hdr, MUTT_PURGE, 0,
                                    ch == OP_UNDELETE_THREAD ? 0 : 1);
+        }
         if (r != -1)
         {
           if (Resolve)
diff --git a/parse.c b/parse.c
index f6710c4557278deb63b9a6f089c3ef2d315e6818..359bf77ac29dc7b3a295a95fc32265aafb5de031 100644 (file)
--- a/parse.c
+++ b/parse.c
@@ -75,8 +75,10 @@ char *mutt_rfc822_read_line(FILE *f, char *line, size_t *linelen)
     {
       /* we did get a full line. remove trailing space */
       while (ISSPACE(*buf))
+      {
         *buf-- = 0; /* we cannot come beyond line's beginning because
-                         * it begins with a non-space */
+                     * it begins with a non-space */
+      }
 
       /* check to see if the next line is a continuation line */
       ch = fgetc(f);
@@ -376,10 +378,12 @@ void mutt_parse_content_type(char *s, struct Body *ct)
   {
     pc = mutt_param_get(&ct->parameter, "charset");
     if (!pc)
+    {
       mutt_param_set(&ct->parameter, "charset",
                      (AssumedCharset && *AssumedCharset) ?
                          (const char *) mutt_ch_get_default_charset() :
                          "us-ascii");
+    }
   }
 }
 
@@ -1301,7 +1305,9 @@ struct Envelope *mutt_rfc822_read_header(FILE *f, struct Header *hdr,
 
       if (ReplyRegex && ReplyRegex->regex &&
           (regexec(ReplyRegex->regex, e->subject, 1, pmatch, 0) == 0))
+      {
         e->real_subj = e->subject + pmatch[0].rm_eo;
+      }
       else
         e->real_subj = e->subject;
     }
index 86f3f5f4d060caf7f43959909429ddc593478c86..90f584cc0882d5d7801594a8252aa8581295d180 100644 (file)
--- a/pattern.c
+++ b/pattern.c
@@ -1668,8 +1668,10 @@ int mutt_pattern_exec(struct Pattern *pat, enum PatternExecFlag flags,
       {
         cache_entry = pat->alladdr ? &cache->list_all : &cache->list_one;
         if (!is_pattern_cache_set(*cache_entry))
+        {
           set_pattern_cache_value(
               cache_entry, mutt_is_list_cc(pat->alladdr, h->env->to, h->env->cc));
+        }
         result = get_pattern_cache_value(*cache_entry);
       }
       else
@@ -1682,9 +1684,11 @@ int mutt_pattern_exec(struct Pattern *pat, enum PatternExecFlag flags,
       {
         cache_entry = pat->alladdr ? &cache->sub_all : &cache->sub_one;
         if (!is_pattern_cache_set(*cache_entry))
+        {
           set_pattern_cache_value(
               cache_entry,
               mutt_is_list_recipient(pat->alladdr, h->env->to, h->env->cc));
+        }
         result = get_pattern_cache_value(*cache_entry);
       }
       else
@@ -1697,8 +1701,10 @@ int mutt_pattern_exec(struct Pattern *pat, enum PatternExecFlag flags,
       {
         cache_entry = pat->alladdr ? &cache->pers_recip_all : &cache->pers_recip_one;
         if (!is_pattern_cache_set(*cache_entry))
+        {
           set_pattern_cache_value(cache_entry,
                                   match_user(pat->alladdr, h->env->to, h->env->cc));
+        }
         result = get_pattern_cache_value(*cache_entry);
       }
       else
@@ -2046,7 +2052,9 @@ int mutt_search_command(int cur, int op)
                            _("Reverse search for: "),
                        buf, sizeof(buf), MUTT_CLEAR | MUTT_PATTERN) != 0 ||
         !buf[0])
+    {
       return -1;
+    }
 
     if (op == OP_SEARCH || op == OP_SEARCH_NEXT)
       OptSearchReverse = false;
diff --git a/pop.c b/pop.c
index a88f1783bef301294b1c8e31574f2fc97734fc9f..1cc1243568ebd5e5793a40080a9d0dbac433f971 100644 (file)
--- a/pop.c
+++ b/pop.c
@@ -327,8 +327,10 @@ static int pop_fetch_headers(struct Context *ctx)
   }
 
   if (!ctx->quiet)
+  {
     mutt_progress_init(&progress, _("Fetching message headers..."),
                        MUTT_PROGRESS_MSG, ReadInc, new_count - old_count);
+  }
 
   if (ret == 0)
   {
index 21891af2f0c6e75268479250058d1763b30a3d6a..93f442e18cdaa7826f1ea385309106f140b8aa9a 100644 (file)
@@ -627,7 +627,9 @@ int mutt_prepare_template(FILE *fp, struct Context *ctx, struct Header *newhdr,
         (mutt_str_strcasecmp(
              mutt_param_get(&newhdr->content->parameter, "protocol"),
              "application/pgp-signature") == 0))
+    {
       newhdr->security |= APPLICATION_PGP;
+    }
     else if (WithCrypto & APPLICATION_SMIME)
       newhdr->security |= APPLICATION_SMIME;
 
@@ -678,7 +680,9 @@ int mutt_prepare_template(FILE *fp, struct Context *ctx, struct Header *newhdr,
     {
       if (mutt_str_strcasecmp("yes",
                               mutt_param_get(&b->parameter, "x-mutt-noconv")) == 0)
+      {
         b->noconv = true;
+      }
       else
       {
         s.flags |= MUTT_CHARCONV;
index a791113051a723cfd659c157f45328a38c922aa8..34a4710507396c5151def67e28d2eb4fd44a9869 100644 (file)
@@ -126,8 +126,10 @@ void mutt_progress_init(struct Progress *progress, const char *msg,
   if (progress->size != 0)
   {
     if (progress->flags & MUTT_PROGRESS_SIZE)
+    {
       mutt_str_pretty_size(progress->sizestr, sizeof(progress->sizestr),
                            progress->size);
+    }
     else
       snprintf(progress->sizestr, sizeof(progress->sizestr), "%zu", progress->size);
   }
@@ -143,8 +145,10 @@ void mutt_progress_init(struct Progress *progress, const char *msg,
     mutt_debug(1, "gettimeofday failed: %d\n", errno);
   /* if timestamp is 0 no time-based suppression is done */
   if (TimeInc != 0)
+  {
     progress->timestamp =
         ((unsigned int) tv.tv_sec * 1000) + (unsigned int) (tv.tv_usec / 1000);
+  }
   mutt_progress_update(progress, 0, 0);
 }
 
@@ -173,7 +177,9 @@ void mutt_progress_update(struct Progress *progress, long pos, int percent)
   /* refresh if size > inc */
   if ((progress->flags & MUTT_PROGRESS_SIZE) &&
       (pos >= (progress->pos + (progress->inc << 10))))
+  {
     update = true;
+  }
   else if (pos >= (progress->pos + progress->inc))
     update = true;
 
index 018b71afab41021f1956aa1174b8685f8032eb87..2e065e5fb6dbd05435eeabee39b6abaed61940cf 100644 (file)
@@ -440,7 +440,9 @@ static void prepend_curdir(char *dst, size_t dstlen)
   if (!dst || !*dst || *dst == '/' || dstlen < 3 ||
       /* XXX bad modularization, these are special to mutt_expand_path() */
       !strchr("~=+@<>!-^", *dst))
+  {
     return;
+  }
 
   dstlen -= 3;
   l = strlen(dst) + 2;
@@ -462,8 +464,10 @@ static int query_save_attachment(FILE *fp, struct Body *body,
   if (body->filename)
   {
     if (directory && *directory)
+    {
       mutt_file_concat_path(buf, *directory, mutt_file_basename(body->filename),
                             sizeof(buf));
+    }
     else
       mutt_str_strfcpy(buf, body->filename, sizeof(buf));
   }
@@ -725,7 +729,9 @@ void mutt_pipe_attachment_list(struct AttachCtx *actx, FILE *fp, bool tag,
   if (mutt_get_field((filter ? _("Filter through: ") : _("Pipe to: ")), buf,
                      sizeof(buf), MUTT_CMD) != 0 ||
       !buf[0])
+  {
     return;
+  }
 
   mutt_expand_path(buf, sizeof(buf));
 
@@ -1319,8 +1325,10 @@ void mutt_view_attachments(struct Header *hdr)
               menu->redraw = REDRAW_CURRENT;
           }
           else
+          {
             mutt_message(
                 _("Only deletion of multipart attachments is supported."));
+          }
         }
         else
         {
@@ -1334,8 +1342,10 @@ void mutt_view_attachments(struct Header *hdr)
                 menu->redraw = REDRAW_INDEX;
               }
               else
+              {
                 mutt_message(
                     _("Only deletion of multipart attachments is supported."));
+              }
             }
           }
         }
index 45cfc6d7a047dac8f5fc4c23574b805a3b425fc4..8918023b9f9a3fd0dffd2884300dd9d167afafda 100644 (file)
--- a/recvcmd.c
+++ b/recvcmd.c
@@ -314,7 +314,9 @@ static struct AttachPtr *find_parent(struct AttachCtx *actx, struct Body *cur, s
       if (mutt_is_message_type(actx->idx[i]->content->type,
                                actx->idx[i]->content->subtype) &&
           is_parent(i, actx, cur))
+      {
         parent = actx->idx[i];
+      }
       if (actx->idx[i]->content == cur)
         break;
     }
@@ -338,8 +340,10 @@ static void include_header(int quote, FILE *ifp, struct Header *hdr, FILE *ofp,
     if (prefix)
       mutt_str_strfcpy(prefix2, prefix, sizeof(prefix2));
     else if (!TextFlowed)
+    {
       mutt_make_string_flags(prefix2, sizeof(prefix2), NONULL(IndentString),
                              Context, hdr, 0);
+    }
     else
       mutt_str_strfcpy(prefix2, ">", sizeof(prefix2));
 
@@ -424,8 +428,10 @@ static void attach_forward_bodies(FILE *fp, struct Header *hdr, struct AttachCtx
   if (ForwardQuote)
   {
     if (!TextFlowed)
+    {
       mutt_make_string_flags(prefix, sizeof(prefix), NONULL(IndentString),
                              Context, parent_hdr, 0);
+    }
     else
       mutt_str_strfcpy(prefix, ">", sizeof(prefix));
   }
@@ -882,8 +888,10 @@ void mutt_attach_reply(FILE *fp, struct Header *hdr, struct AttachCtx *actx,
     st.fpout = tmpfp;
 
     if (!TextFlowed)
+    {
       mutt_make_string_flags(prefix, sizeof(prefix), NONULL(IndentString),
                              Context, parent_hdr, 0);
+    }
     else
       mutt_str_strfcpy(prefix, ">", sizeof(prefix));
 
index c9871e6978beb1be1b64984c0d6bf8c9794cee62..92b8b8e0f20c0833046f220dce96e83f66b8b7a4 100644 (file)
--- a/rfc1524.c
+++ b/rfc1524.c
@@ -239,7 +239,9 @@ static int rfc1524_mailcap_parse(struct Body *a, char *filename, char *type,
           ((mutt_str_strncasecmp(buf, type, btlen) != 0) ||
            (buf[btlen] != 0 &&                           /* implicit wild */
             (mutt_str_strcmp(buf + btlen, "/*") != 0)))) /* wildsubtype */
+      {
         continue;
+      }
 
       /* next field is the viewcommand */
       char *field = ch;
diff --git a/score.c b/score.c
index 44d81ff2374984107757dd502309b0ecdb63ba3f..3dab481673a39fab45ced8fd0878da9888b3099a 100644 (file)
--- a/score.c
+++ b/score.c
@@ -128,11 +128,13 @@ int mutt_parse_score(struct Buffer *buf, struct Buffer *s, unsigned long data,
     ptr->str = pattern;
   }
   else
+  {
     /* 'buf' arg was cleared and 'pattern' holds the only reference;
      * as here 'ptr' != NULL -> update the value only in which case
      * ptr->str already has the string, so pattern should be freed.
      */
     FREE(&pattern);
+  }
   pc = buf->data;
   if (*pc == '=')
   {
diff --git a/send.c b/send.c
index 965b35cb46195c8bbd47ec9aab13c77c703786b6..b1a759e9f80b1200b727d59bda76f544e37aac60 100644 (file)
--- a/send.c
+++ b/send.c
@@ -920,7 +920,9 @@ static int generate_body(FILE *tempfp, struct Header *msg, int flags,
 
     if (((WithCrypto & APPLICATION_PGP) != 0) &&
         (b = crypt_pgp_make_key_attachment(NULL)) == NULL)
+    {
       return -1;
+    }
 
     b->next = msg->content;
     msg->content = b;
@@ -1121,8 +1123,10 @@ static int send_message(struct Header *msg)
   if (!OptNewsSend)
 #endif
     if (SmtpUrl)
+    {
       return mutt_smtp_send(msg->env->from, msg->env->to, msg->env->cc, msg->env->bcc,
                             tempfile, (msg->content->encoding == ENC8BIT));
+    }
 #endif /* USE_SMTP */
 
   i = mutt_invoke_sendmail(msg->env->from, msg->env->to, msg->env->cc, msg->env->bcc,
@@ -1242,7 +1246,9 @@ static bool search_attach_keyword(char *filename)
   /* Search for the regex in AbortNoattachRegex within a file */
   if (!AbortNoattachRegex || !AbortNoattachRegex->regex || !QuoteRegex ||
       !QuoteRegex->regex)
+  {
     return false;
+  }
 
   FILE *attf = mutt_file_fopen(filename, "r");
   if (!attf)
@@ -1442,8 +1448,10 @@ int ci_send_message(int flags, struct Header *msg, char *tempfile,
      */
 
     if (msg->env->from)
+    {
       mutt_debug(5, "msg->env->from before set_reverse_name: %s\n",
                  msg->env->from->mailbox);
+    }
     msg->env->from = set_reverse_name(cur->env);
   }
   if (cur && ReplyWithXorig && !(flags & (SENDPOSTPONED | SENDRESEND | SENDFORWARD)))
index 6f3ebdd7f3091338a8f23465ba88f3130907ba30..17bc47b9c8b6b00198de33c2f7894c2cabf136c9 100644 (file)
--- a/sendlib.c
+++ b/sendlib.c
@@ -333,7 +333,9 @@ int mutt_write_mime_header(struct Body *a, FILE *f)
 
       if ((mutt_str_strcasecmp(np->attribute, "boundary") == 0) &&
           (strcmp(buffer, tmp) == 0))
+      {
         snprintf(buffer, sizeof(buffer), "\"%s\"", tmp);
+      }
 
       FREE(&tmp);
 
@@ -961,9 +963,11 @@ struct Content *mutt_get_content_info(const char *fname, struct Body *b)
   mutt_file_fclose(&fp);
 
   if (b != NULL && b->type == TYPETEXT && (!b->noconv && !b->force_charset))
+  {
     mutt_param_set(&b->parameter, "charset",
                    (!info->hibin ? "us-ascii" :
                                    Charset && !mutt_ch_is_us_ascii(Charset) ? Charset : "unknown-8bit"));
+  }
 
   return info;
 }
index 0af05c68b77a1f8de58e2a77b371d89e9021eea5..9ff44f9516ac69aa94fc95670d516db257673943 100644 (file)
--- a/sidebar.c
+++ b/sidebar.c
@@ -237,11 +237,15 @@ static const char *sidebar_format_str(char *buf, size_t buflen, size_t col, int
   }
 
   if (optional)
+  {
     mutt_expando_format(buf, buflen, col, SidebarWidth, if_str,
                         sidebar_format_str, (unsigned long) sbe, flags);
+  }
   else if (flags & MUTT_FORMAT_OPTIONAL)
+  {
     mutt_expando_format(buf, buflen, col, SidebarWidth, else_str,
                         sidebar_format_str, (unsigned long) sbe, flags);
+  }
 
   /* We return the format string, unchanged */
   return src;
@@ -883,7 +887,9 @@ static void draw_sidebar(int num_rows, int num_cols, int div_width)
     if ((mutt_str_strlen(b->path) > maildirlen) &&
         (mutt_str_strncmp(Folder, b->path, maildirlen) == 0) &&
         SidebarDelimChars && strchr(SidebarDelimChars, b->path[maildirlen]))
+    {
       maildir_is_prefix = true;
+    }
 
     /* calculate depth of current folder and generate its display name with indented spaces */
     int sidebar_folder_depth = 0;
diff --git a/smtp.c b/smtp.c
index 459bb40b985844740ebcc9838f762bc9d52bc795..b4e6ca084da44c92d6457444dfbea5f427ad6fff 100644 (file)
--- a/smtp.c
+++ b/smtp.c
@@ -588,7 +588,9 @@ static int smtp_open(struct Connection *conn)
   else if (mutt_bit_isset(Capabilities, STARTTLS) &&
            (rc = query_quadoption(SslStarttls,
                                   _("Secure connection with TLS?"))) == MUTT_ABORT)
+  {
     return rc;
+  }
 
   if (rc == MUTT_YES)
   {
diff --git a/state.c b/state.c
index 3e837baf104c6103b81ea4463559e2360bd78a51..c942ad49e248099a1320e47c6a5c282cc1c63395 100644 (file)
--- a/state.c
+++ b/state.c
@@ -108,8 +108,10 @@ int state_printf(struct State *s, const char *fmt, ...)
 void state_prefix_put(const char *d, size_t dlen, struct State *s)
 {
   if (s->prefix)
+  {
     while (dlen--)
       state_prefix_putc(*d++, s);
+  }
   else
     fwrite(d, dlen, 1, s->fpout);
 }
index 07d029c27b73779005ba72d2407d9569b2d986eb..515cb0d81a513c33d71bfafe8687a48c0a57fdbd 100644 (file)
--- a/status.c
+++ b/status.c
@@ -256,11 +256,13 @@ static const char *status_format_str(char *buf, size_t buflen, size_t col, int c
       if (!menu)
         break;
       if (menu->top + menu->pagelen >= menu->max)
+      {
         cp = menu->top ?
           /* L10N: Status bar message: the end of the list emails is visible in the index */
           _("end") :
           /* L10N: Status bar message: all the emails are visible in the index */
           _("all");
+      }
       else
       {
         count = (100 * (menu->top + menu->pagelen)) / menu->max;
index ecfbd68f35991234475b60ed0805530ba53c7715..83053b323ab9f127347e9461df275e6950e5577c 100644 (file)
--- a/thread.c
+++ b/thread.c
@@ -286,8 +286,10 @@ void mutt_draw_tree(struct Context *ctx)
       else
         myarrow[0] = vtee;
       if (width == 2)
+      {
         myarrow[1] = pseudo ? MUTT_TREE_STAR :
                               (tree->duplicate_thread ? MUTT_TREE_EQUALS : MUTT_TREE_HLINE);
+      }
       if (tree->visible)
       {
         myarrow[width] = MUTT_TREE_RARROW;
@@ -612,8 +614,10 @@ static int compare_threads(const void *a, const void *b)
   static sort_t *sort_func = NULL;
 
   if (a && b)
+  {
     return ((*sort_func)(&(*((struct MuttThread **) a))->sort_key,
                          &(*((struct MuttThread **) b))->sort_key));
+  }
   /* a hack to let us reset sort_func even though we can't
    * have extra arguments because of qsort
    */
@@ -725,7 +729,9 @@ struct MuttThread *mutt_sort_subthreads(struct MuttThread *thread, int init)
             if (!thread->sort_key ||
                 ((((Sort & SORT_REVERSE) ? 1 : -1) *
                   compare_threads((void *) &thread, (void *) &sort_key)) > 0))
+            {
               thread->sort_key = sort_key->sort_key;
+            }
           }
           else if (!thread->sort_key)
             thread->sort_key = sort_key->sort_key;
@@ -774,11 +780,15 @@ static void check_subjects(struct Context *ctx, int init)
     if (!tmp)
       cur->subject_changed = true;
     else if (cur->env->real_subj && tmp->message->env->real_subj)
+    {
       cur->subject_changed =
           (mutt_str_strcmp(cur->env->real_subj, tmp->message->env->real_subj) != 0) ? true : false;
+    }
     else
+    {
       cur->subject_changed =
           (cur->env->real_subj || tmp->message->env->real_subj) ? true : false;
+    }
   }
 }
 
@@ -1381,8 +1391,10 @@ int mutt_messages_in_thread(struct Context *ctx, struct Header *hdr, int flag)
   if (Sort & SORT_REVERSE)
     rc = threads[0]->message->msgno - (threads[1] ? threads[1]->message->msgno : -1);
   else
+  {
     rc = (threads[1] ? threads[1]->message->msgno : ctx->msgcount) -
          threads[0]->message->msgno;
+  }
 
   if (flag)
     rc += 1;