*/
static char *get_flags(struct ListHead *hflags, char *s)
{
- char *flag_word = NULL;
- char ctmp;
-
/* sanity-check string */
if (mutt_str_strncasecmp("FLAGS", s, 5) != 0)
{
{
s++;
SKIPWS(s);
- flag_word = s;
+ const char* flag_word = s;
while (*s && (*s != ')') && !ISSPACE(*s))
s++;
- ctmp = *s;
+ const char ctmp = *s;
*s = '\0';
if (*flag_word)
mutt_list_insert_tail(hflags, mutt_str_strdup(flag_word));
bool changed, bool invert, int *pos)
{
int count = 0; /* number of messages in message set */
- bool match = false; /* whether current message matches flag condition */
unsigned int setstart = 0; /* start of current message range */
int n;
bool started = false;
for (n = *pos; n < idata->ctx->msgcount && buf->dptr - buf->data < IMAP_MAX_CMDLEN; n++)
{
- match = false;
+ bool match = false; /* whether current message matches flag condition */
/* don't include pending expunged messages */
if (hdrs[n]->active)
{