summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mbbsd/bbs.c2
-rw-r--r--mbbsd/read.c17
2 files changed, 15 insertions, 4 deletions
diff --git a/mbbsd/bbs.c b/mbbsd/bbs.c
index 2fe205e2..e9a1ca6d 100644
--- a/mbbsd/bbs.c
+++ b/mbbsd/bbs.c
@@ -2355,7 +2355,7 @@ push_bottom(int ent, fileheader_t * fhdr, char *direct)
delete_record(buf, sizeof(fileheader_t), i+1);
}
}
- //setbottomtotal(currbid);
+ setbottomtotal(currbid);
touchdircache(currbid);
return DIRCHANGED;
}
diff --git a/mbbsd/read.c b/mbbsd/read.c
index e96a9449..eb6c69db 100644
--- a/mbbsd/read.c
+++ b/mbbsd/read.c
@@ -873,8 +873,8 @@ i_read(int cmdmode, char *direct, void (*dotitle) (), void (*doentry) (), onekey
if (last_line < locmem->top_ln + p_lines) {
if (bidcache > 0 && !(currmode & (MODE_SELECT | MODE_DIGEST)))
{
- bottom_line = getbtotal(currbid);
- num = bottom_line+getbottomtotal(currbid);
+ bottom_line = getbtotal(currbid);
+ num = bottom_line+getbottomtotal(currbid);
}
else
num = get_num_records(currdirect, FHSZ);
@@ -902,13 +902,19 @@ i_read(int cmdmode, char *direct, void (*dotitle) (), void (*doentry) (), onekey
entries = get_fileheader_cache(currbid, currdirect,
headers, recbase, p_lines);
else
- entries = get_records(currdirect, headers, FHSZ,
+ entries += get_records(currdirect, headers, FHSZ,
recbase, p_lines);
}
else
#endif
+ {
entries = get_records(currdirect, headers, FHSZ, recbase,
p_lines);
+ if( entries>=0 && entries<p_lines && n_bottom)
+ entries +=get_records(directbottom,&headers[entries],FHSZ,
+ 1, p_lines-entries);
+ }
+
}
@@ -997,8 +1003,13 @@ i_read(int cmdmode, char *direct, void (*dotitle) (), void (*doentry) (), onekey
headers, recbase, p_lines);
else
#endif
+ {
entries = get_records(currdirect, headers, FHSZ, recbase,
p_lines);
+ if( entries>=0 && entries<p_lines && n_bottom)
+ entries+=get_records(directbottom,&headers[entries],FHSZ,
+ 1, p_lines-entries);
+ }
}
num = locmem->crs_ln - locmem->top_ln;