Skip to content
Snippets Groups Projects
Commit f497189a authored by rswindell's avatar rswindell
Browse files

Always delete the quotes file (e.g. QUOTES.TXT) before deciding if we are

going to recover a draft message or quote a source message or whatever.
Lingering QUOTES.TXT files interferred with recovering draft messages.
parent 656b326a
No related branches found
No related tags found
No related merge requests found
......@@ -251,6 +251,8 @@ bool sbbs_t::writemsg(const char *fname, const char *top, char *subj, long mode,
removecase(tagfile);
SAFEPRINTF(draft_desc, "draft.%s.msg", subnum >= cfg.total_subs ? "mail" : cfg.sub[subnum]->code);
SAFEPRINTF3(draft, "%suser/%04u.%s", cfg.data_dir, useron.number, draft_desc);
quotes_fname(useron_xedit, str, sizeof(str));
removecase(str);
bool draft_restored = false;
if(flength(draft) > 0 && (time(NULL) - fdate(draft)) < 48L*60L*60L && yesno("Unsaved draft message found. Use it")) {
......@@ -400,10 +402,6 @@ bool sbbs_t::writemsg(const char *fname, const char *top, char *subj, long mode,
close(file);
}
}
else {
quotes_fname(useron_xedit, str, sizeof(str));
removecase(str);
}
if(!online || sys_status&SS_ABORT) {
free(buf);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment