* which may make the line look like fixed although it wasn't
* so keep this in mind for later processing */
fixed = buf_len == 0 || buf[buf_len - 1] != ' ' ||
- (strcmp(buf + buf_off, "-- ") == 0);
+ (m_strcmp(buf + buf_off, "-- ") == 0);
if (delsp && buf_len >= 1 && buf[buf_len-1] == ' ')
buf[--buf_len] = '\0';
}
/* signature separator also flushes the previous paragraph */
- if (strcmp(buf + buf_off, "-- ") == 0 && curline && *curline) {
+ if (m_strcmp(buf + buf_off, "-- ") == 0 && curline && *curline) {
print_flowed_line (curline, s, quotelevel);
*curline = '\0';
curline_len = 1;
}
p_realloc(&curline, curline_len + buf_len - buf_off);
- strcpy (curline + curline_len - 1, buf + buf_off);
+ m_strcpy(curline + curline_len - 1, buf_len - buf_off + 1, buf + buf_off);
curline_len += buf_len - buf_off;
/* if this was a fixed line the paragraph is finished */
if ((in = safe_fopen (hdr->content->filename, "r")) == NULL)
return;
- out = m_tempfile(tmpf, sizeof(tmpf), NONULL(Tempdir), NULL);
+ out = m_tempfile(tmpf, sizeof(tmpf), NONULL(mod_core.tmpdir), NULL);
if (!out) {
- fclose(in);
+ m_fclose(&in);
return;
}
}
fputs (buf, out);
}
- fclose (in);
- fclose (out);
+ m_fclose(&in);
+ m_fclose(&out);
mutt_set_mtime (hdr->content->filename, tmpf);
unlink (hdr->content->filename);
m_strreplace(&hdr->content->filename, tmpf);