diff options
author | in2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2002-08-15 17:46:30 +0800 |
---|---|---|
committer | in2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2002-08-15 17:46:30 +0800 |
commit | 0ea122a155d13aa84a5cd376a705bd7f540e45b0 (patch) | |
tree | 2e93d47d5bef6fcca53f3a60216de9a977e879bc /mbbsd/read.c | |
parent | 4eaaaf8838d50e22bdf0217e350fa8e92a9c14a2 (diff) | |
download | pttbbs-0ea122a155d13aa84a5cd376a705bd7f540e45b0.tar pttbbs-0ea122a155d13aa84a5cd376a705bd7f540e45b0.tar.gz pttbbs-0ea122a155d13aa84a5cd376a705bd7f540e45b0.tar.bz2 pttbbs-0ea122a155d13aa84a5cd376a705bd7f540e45b0.tar.lz pttbbs-0ea122a155d13aa84a5cd376a705bd7f540e45b0.tar.xz pttbbs-0ea122a155d13aa84a5cd376a705bd7f540e45b0.tar.zst pttbbs-0ea122a155d13aa84a5cd376a705bd7f540e45b0.zip |
load cache at first time
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@472 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/read.c')
-rw-r--r-- | mbbsd/read.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/mbbsd/read.c b/mbbsd/read.c index 33ea06b5..ec7efeb4 100644 --- a/mbbsd/read.c +++ b/mbbsd/read.c @@ -1,4 +1,4 @@ -/* $Id: read.c,v 1.13 2002/07/27 15:06:39 kcwu Exp $ */ +/* $Id: read.c,v 1.14 2002/08/15 09:46:30 in2 Exp $ */ #include "bbs.h" #define MAXPATHLEN 256 @@ -759,8 +759,12 @@ i_read(int cmdmode, char *direct, void (*dotitle) (), void (*doentry) (), onekey switch (mode) { case NEWDIRECT: /* 第一次載入此目錄 */ case DIRCHANGED: - if (bidcache > 0 && !(currmode & (MODE_SELECT | MODE_DIGEST))) - last_line = getbtotal(currbid); + if (bidcache > 0 && !(currmode & (MODE_SELECT | MODE_DIGEST))){ + if( (last_line = getbtotal(currbid)) == 0 ){ + setbtotal(currbid); + last_line = get_num_records(currdirect, FHSZ); + } + } else last_line = get_num_records(currdirect, FHSZ); |