* a rc file.
*/
{
- mutt_str_strfcpy(err->data, _("default colors not supported"), err->dsize);
+ mutt_buffer_strcpy(err, _("default colors not supported"));
return -1;
}
#endif /* HAVE_USE_DEFAULT_COLORS */
(type != DT_QUAD) && !(flags & CS_DUMP_NO_ESCAPING))
{
mutt_buffer_reset(tmp);
- size_t len = pretty_var(value->data, tmp);
- mutt_str_strfcpy(value->data, tmp->data, len + 1);
+ pretty_var(value->data, tmp);
+ mutt_buffer_strcpy(value, tmp->data);
}
}
(type != DT_QUAD) && !(flags & CS_DUMP_NO_ESCAPING))
{
mutt_buffer_reset(tmp);
- size_t len = pretty_var(initial->data, tmp);
- mutt_str_strfcpy(initial->data, tmp->data, len + 1);
+ pretty_var(initial->data, tmp);
+ mutt_buffer_strcpy(initial, tmp->data);
}
}
}
* common mistake */
if ((*pattern.data == '^') && (!CurrentFolder))
{
- mutt_str_strfcpy(err->data, _("current mailbox shortcut '^' is unset"), err->dsize);
+ mutt_buffer_strcpy(err, _("current mailbox shortcut '^' is unset"));
goto error;
}
* This is likely a mistake too */
if (!*path && *pattern.data)
{
- mutt_str_strfcpy(err->data, _("mailbox shortcut expanded to empty regex"), err->dsize);
+ mutt_buffer_strcpy(err, _("mailbox shortcut expanded to empty regex"));
goto error;
}
{
if (mutt_comp_valid_command(command.data) == 0)
{
- mutt_str_strfcpy(err->data, _("badly formatted command string"), err->dsize);
+ mutt_buffer_strcpy(err, _("badly formatted command string"));
return -1;
}
}
{
if (!MoreArgs(s))
{
- mutt_str_strfcpy(err->data, _("-group: no group name"), err->dsize);
+ mutt_buffer_strcpy(err, _("-group: no group name"));
goto bail;
}
if (!MoreArgs(s))
{
- mutt_str_strfcpy(err->data, _("out of arguments"), err->dsize);
+ mutt_buffer_strcpy(err, _("out of arguments"));
goto bail;
}
if (!MoreArgs(s))
{
- mutt_str_strfcpy(err->data, _("alias: no address"), err->dsize);
+ mutt_buffer_strcpy(err, _("alias: no address"));
return -1;
}
mutt_extract_token(buf, s, 0);
if (!buf->data || *buf->data == '\0')
{
- mutt_str_strfcpy(err->data, _("attachments: no disposition"), err->dsize);
+ mutt_buffer_strcpy(err, _("attachments: no disposition"));
return -1;
}
}
else
{
- mutt_str_strfcpy(err->data, _("attachments: invalid disposition"), err->dsize);
+ mutt_buffer_strcpy(err, _("attachments: invalid disposition"));
return -1;
}
char *p = strpbrk(buf->data, ": \t");
if (!p || (*p != ':'))
{
- mutt_str_strfcpy(err->data, _("invalid header field"), err->dsize);
+ mutt_buffer_strcpy(err, _("invalid header field"));
return -1;
}
keylen = p - buf->data + 1;
if (!MoreArgs(s))
{
if (data == MUTT_SPAM)
- mutt_str_strfcpy(err->data, _("spam: no matching pattern"), err->dsize);
+ mutt_buffer_strcpy(err, _("spam: no matching pattern"));
else
- mutt_str_strfcpy(err->data, _("nospam: no matching pattern"), err->dsize);
+ mutt_buffer_strcpy(err, _("nospam: no matching pattern"));
return -1;
}
}
/* This should not happen. */
- mutt_str_strfcpy(err->data, "This is no good at all.", err->dsize);
+ mutt_buffer_strcpy(err, "This is no good at all.");
return -1;
}
mutt_extract_token(buf, s, 0);
if (!buf->data || *buf->data == '\0')
{
- mutt_str_strfcpy(err->data, _("unattachments: no disposition"), err->dsize);
+ mutt_buffer_strcpy(err, _("unattachments: no disposition"));
return -1;
}
}
else
{
- mutt_str_strfcpy(err->data, _("unattachments: invalid disposition"), err->dsize);
+ mutt_buffer_strcpy(err, _("unattachments: invalid disposition"));
return -1;
}
if ((type != DT_BOOL) && (type != DT_NUMBER) && (type != DT_LONG) && (type != DT_QUAD))
{
mutt_buffer_reset(tmp);
- size_t len = pretty_var(value->data, tmp);
- mutt_str_strfcpy(value->data, tmp->data, len + 1);
+ pretty_var(value->data, tmp);
+ mutt_buffer_strcpy(value, tmp->data);
}
dump_config_neo(Config, he, value, NULL, 0);
/* make sure the macro sequence is not an empty string */
if (!*buf->data)
{
- mutt_str_strfcpy(err->data, _("macro: empty key sequence"), err->dsize);
+ mutt_buffer_strcpy(err, _("macro: empty key sequence"));
}
else
{
if (!MoreArgs(s))
{
- mutt_str_strfcpy(err->data, _("exec: no arguments"), err->dsize);
+ mutt_buffer_strcpy(err, _("exec: no arguments"));
return -1;
}
return true;
/* Nope. */
- mutt_str_strfcpy(err->data, _("No current message"), err->dsize);
+ mutt_buffer_strcpy(err, _("No current message"));
return false;
}
{
if (!Context->menu)
{
- mutt_str_strfcpy(err->data, _("No current message"), err->dsize);
+ mutt_buffer_strcpy(err, _("No current message"));
return RANGE_E_CTX;
}
pat->max = CTX_MSGNO(Context);
/* We need a Context for pretty much anything. */
if (!Context)
{
- mutt_str_strfcpy(err->data, _("No Context"), err->dsize);
+ mutt_buffer_strcpy(err, _("No Context"));
return false;
}
}
if (!curlist)
{
- mutt_str_strfcpy(err->data, _("empty pattern"), err->dsize);
+ mutt_buffer_strcpy(err, _("empty pattern"));
return NULL;
}
if (curlist->next)
if (mutt_str_atoi(pc, &ptr->val) < 0)
{
FREE(&pattern);
- mutt_str_strfcpy(err->data, _("Error: score: invalid number"), err->dsize);
+ mutt_buffer_strcpy(err, _("Error: score: invalid number"));
return -1;
}
OptNeedRescore = true;