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

If editor doesn't create a file, just return false from sbbs_t::editfile()

... don't log any error message.

This fixes issue #914
parent 45743e3e
No related branches found
No related tags found
No related merge requests found
Pipeline #8880 failed
...@@ -1328,6 +1328,8 @@ bool sbbs_t::editfile(char *fname, uint maxlines, const char* to, const char* fr ...@@ -1328,6 +1328,8 @@ bool sbbs_t::editfile(char *fname, uint maxlines, const char* to, const char* fr
rioctl(IOCM | PAUSE | ABORT); rioctl(IOCM | PAUSE | ABORT);
if (external(cmdstr(cfg.xedit[useron_xedit - 1]->rcmd, msgtmp, nulstr, NULL, mode), mode, cfg.node_dir) != 0) if (external(cmdstr(cfg.xedit[useron_xedit - 1]->rcmd, msgtmp, nulstr, NULL, mode), mode, cfg.node_dir) != 0)
return false; return false;
if (!fexist(msgtmp))
return false;
l = process_edited_file(msgtmp, path, /* mode: */ WM_EDIT, &lines, maxlines); l = process_edited_file(msgtmp, path, /* mode: */ WM_EDIT, &lines, maxlines);
if (l > 0) { if (l > 0) {
SAFEPRINTF3(str, "created or edited file: %s (%ld bytes, %u lines)" SAFEPRINTF3(str, "created or edited file: %s (%ld bytes, %u lines)"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment