for (int i = 0; i < (int) n; i++)
{
char ch[8];
- snprintf(ch, 8, "%02X%s", md[i], (i % 2 ? " " : ""));
+ snprintf(ch, 8, "%02X%s", md[i], ((i % 2) ? " " : ""));
mutt_str_strcat(s, l, ch);
}
s[2 * n + n / 2 - 1] = '\0'; /* don't want trailing space */
if (flags & (CH_DECODE | CH_PREFIX))
{
- if (mutt_write_one_header(out, 0, headers[x], flags & CH_PREFIX ? prefix : 0,
+ if (mutt_write_one_header(out, 0, headers[x], (flags & CH_PREFIX) ? prefix : 0,
mutt_window_wrap_cols(MuttIndexWindow, Wrap), flags) == -1)
{
error = true;
buf_size = ntohl(*((long *) send_token.value));
gss_release_buffer(&min_stat, &send_token);
mutt_debug(2, "Unwrapped security level flags: %c%c%c\n",
- server_conf_flags & GSS_AUTH_P_NONE ? 'N' : '-',
- server_conf_flags & GSS_AUTH_P_INTEGRITY ? 'I' : '-',
- server_conf_flags & GSS_AUTH_P_PRIVACY ? 'P' : '-');
+ (server_conf_flags & GSS_AUTH_P_NONE) ? 'N' : '-',
+ (server_conf_flags & GSS_AUTH_P_INTEGRITY) ? 'I' : '-',
+ (server_conf_flags & GSS_AUTH_P_PRIVACY) ? 'P' : '-');
mutt_debug(2, "Maximum GSS token size is %ld\n", buf_size);
/* agree to terms (hack!) */
return IMAP_CMD_BAD;
rc = mutt_socket_write_d(idata->conn, idata->cmdbuf->data, -1,
- flags & IMAP_CMD_PASS ? IMAP_LOG_PASS : IMAP_LOG_CMD);
+ (flags & IMAP_CMD_PASS) ? IMAP_LOG_PASS : IMAP_LOG_CMD);
idata->cmdbuf->dptr = idata->cmdbuf->data;
/* unidle when command queue is flushed */
static int mbox_open_mailbox_append(struct Context *ctx, int flags)
{
- ctx->fp = mutt_file_fopen(ctx->path, flags & MUTT_NEWFOLDER ? "w" : "a");
+ ctx->fp = mutt_file_fopen(ctx->path, (flags & MUTT_NEWFOLDER) ? "w" : "a");
if (!ctx->fp)
{
mutt_perror(ctx->path);
else
{
snprintf(prompt, sizeof(prompt), _("Password for %s@%s: "),
- account->flags & MUTT_ACCT_LOGIN ? account->login : account->user,
+ (account->flags & MUTT_ACCT_LOGIN) ? account->login : account->user,
account->host);
account->pass[0] = '\0';
if (mutt_get_password(prompt, account->pass, sizeof(account->pass)))
b->type = TYPETEXT;
b->subtype = mutt_str_strdup("plain");
- mutt_param_set(&b->parameter, "x-action", flags & ENCRYPT ? "pgp-encrypted" : "pgp-signed");
+ mutt_param_set(&b->parameter, "x-action", (flags & ENCRYPT) ? "pgp-encrypted" : "pgp-signed");
mutt_param_set(&b->parameter, "charset", send_charset);
b->filename = mutt_str_strdup(pgpoutfile);
{
if (flags & ENCRYPT)
return pgp_invoke(pgpin, pgpout, pgperr, pgpinfd, pgpoutfd, pgperrfd,
- flags & SIGN ? 1 : 0, fname, NULL, uids,
- flags & SIGN ? PgpEncryptSignCommand : PgpEncryptOnlyCommand);
+ (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);
fcc_error = false; /* reset value since we may have failed before */
mutt_pretty_mailbox(fcc, sizeof(fcc));
i = mutt_compose_menu(msg, fcc, sizeof(fcc), cur,
- (flags & SENDNOFREEHEADER ? MUTT_COMPOSE_NOFREEHEADER : 0));
+ ((flags & SENDNOFREEHEADER) ? MUTT_COMPOSE_NOFREEHEADER : 0));
if (i == -1)
{
/* abort */
static void linearize_tree(struct Context *ctx)
{
struct MuttThread *tree = ctx->tree;
- struct Header **array = ctx->hdrs + (Sort & SORT_REVERSE ? ctx->msgcount - 1 : 0);
+ struct Header **array = ctx->hdrs + ((Sort & SORT_REVERSE) ? ctx->msgcount - 1 : 0);
while (tree)
{
tree = tree->child;
*array = tree->message;
- array += Sort & SORT_REVERSE ? -1 : 1;
+ array += (Sort & SORT_REVERSE) ? -1 : 1;
if (tree->child)
tree = tree->child;