Skip to content
Snippets Groups Projects
Commit 6b956410 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Fix error removing INPUT.MSG introduced in Commit d02fc1a2

remove() is expected to fail in this scenario sometimes depending
on how writemsg() is used - in the error case, the user was trying
to edit his .plan file with the ;plan command:
term Node 10 <Deuce> !ERROR 11 (Resource temporarily unavailable) in writemsg.cpp line 1232 (editfile) removing "/sbbs/node10/temp/INPUT.MSG" access=0

Thanks for the bug report!
parent 9eb7ea86
No related branches found
No related tags found
No related merge requests found
......@@ -1228,8 +1228,7 @@ bool sbbs_t::editfile(char *fname, bool msg)
msg_tmp_fname(useron_xedit, msgtmp, sizeof(msgtmp));
if(stricmp(msgtmp,path)) {
if(removecase(msgtmp) != 0)
errormsg(WHERE, ERR_REMOVE, msgtmp, 0);
(void)removecase(msgtmp);
if(fexistcase(path))
CopyFile(path, msgtmp, /* failIfExists: */FALSE);
}
......
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