Fix a couple of bugs

This commit is contained in:
Andrew Pamment 2018-10-12 11:11:44 +10:00
parent 37bcd31ff2
commit 40c52836f9
2 changed files with 11 additions and 1 deletions

View File

@ -477,6 +477,12 @@ char *external_editor(struct user_record *user, char *to, char *from, char *quot
sprintf(buffer, "%s/node%d/MSGTMP", conf.bbs_path, mynode);
body = file2str(buffer);
if (body == NULL) {
return NULL;
}
totlen = strlen(body);
if (email == 1) {
tagline = conf.default_tagline;
} else {

View File

@ -431,7 +431,11 @@ char *www_msgs_messageview(struct user_record *user, int conference, int area, i
stralloc_cats(&page, "\" />\n");
stralloc_cats(&page, "<input type=\"hidden\" name=\"replyid\" value=\"");
stralloc_cats(&page, msgid);
if (msgid == NULL) {
stralloc_cats(&page, "NULL");
} else {
stralloc_cats(&page, msgid);
}
stralloc_cats(&page, "\" />\n");
stralloc_cats(&page, "To : <input type=\"text\" name=\"recipient\" value=\"");