summaryrefslogtreecommitdiffstats
path: root/mbbsd
diff options
context:
space:
mode:
Diffstat (limited to 'mbbsd')
-rw-r--r--mbbsd/bbs.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/mbbsd/bbs.c b/mbbsd/bbs.c
index 21088996..1f03f831 100644
--- a/mbbsd/bbs.c
+++ b/mbbsd/bbs.c
@@ -2332,6 +2332,16 @@ edit_title(int ent, fileheader_t * fhdr, const char *direct)
{
getdata(b_lines - 1, 0, "確定(Y/N)?[n] ", genbuf, 3, DOECHO);
if ((genbuf[0] == 'y' || genbuf[0] == 'Y') && dirty) {
+ // TODO verify if record is still valid
+ fileheader_t curr;
+ memset(&curr, 0, sizeof(curr));
+ if (get_record(direct, &curr, sizeof(curr), ent) < 0 ||
+ strcmp(curr.filename, fhdr->filename) != 0)
+ {
+ // modified...
+ vmsg("抱歉,系統忙碌中,請稍後再試。");
+ return FULLUPDATE;
+ }
*fhdr = tmpfhdr;
substitute_ref_record(direct, fhdr, ent);
}