summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpiaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2005-06-12 16:06:14 +0800
committerpiaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2005-06-12 16:06:14 +0800
commitce01a30cfa781622a2954942032bf3d129943f7a (patch)
treeb07ccebccdce6c1739939b0fb379d5059b46365b
parent0d4166c24d046abb9fe3961b5144c87a09631f98 (diff)
downloadpttbbs-ce01a30cfa781622a2954942032bf3d129943f7a.tar
pttbbs-ce01a30cfa781622a2954942032bf3d129943f7a.tar.gz
pttbbs-ce01a30cfa781622a2954942032bf3d129943f7a.tar.bz2
pttbbs-ce01a30cfa781622a2954942032bf3d129943f7a.tar.lz
pttbbs-ce01a30cfa781622a2954942032bf3d129943f7a.tar.xz
pttbbs-ce01a30cfa781622a2954942032bf3d129943f7a.tar.zst
pttbbs-ce01a30cfa781622a2954942032bf3d129943f7a.zip
when some files were corrupted (disappeared on disk)
the read mark was not updated so 'unread' flag couldn't be removed. git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2832 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--mbbsd/bbs.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/mbbsd/bbs.c b/mbbsd/bbs.c
index 99b3d82a..d4a4194b 100644
--- a/mbbsd/bbs.c
+++ b/mbbsd/bbs.c
@@ -1133,8 +1133,7 @@ read_post(int ent, fileheader_t * fhdr, const char *direct)
STATINC(STAT_READPOST);
setdirpath(genbuf, direct, fhdr->filename);
- if ((more_result = more(genbuf, YEA)) == -1)
- return READ_SKIP;
+ more_result = more(genbuf, YEA);
{
int posttime=atoi(fhdr->filename+2);
@@ -1153,6 +1152,8 @@ read_post(int ent, fileheader_t * fhdr, const char *direct)
strncpy(currtitle, subject(fhdr->title), TTLEN);
if (more_result) {
+ if(more_result == -1)
+ return READ_SKIP;
if(more_result == 999) {
return do_reply(fhdr);
}