diff options
Diffstat (limited to 'mbbsd')
-rw-r--r-- | mbbsd/read.c | 6 | ||||
-rw-r--r-- | mbbsd/record.c | 2 |
2 files changed, 2 insertions, 6 deletions
diff --git a/mbbsd/read.c b/mbbsd/read.c index 47c63c3c..c05daae7 100644 --- a/mbbsd/read.c +++ b/mbbsd/read.c @@ -899,11 +899,6 @@ i_read(int cmdmode, char *direct, void (*dotitle) (), void (*doentry) (), onekey else entries = get_records(currdirect, headers, FHSZ, recbase, p_lines); - if (entries < 0) - { - setbtotal(currbid); - last_line = getbtotal(currbid); - } } else #endif @@ -993,6 +988,7 @@ i_read(int cmdmode, char *direct, void (*dotitle) (), void (*doentry) (), onekey p_lines); if (entries <= 0) { + setbtotal(currbid); last_line = -1; break; } diff --git a/mbbsd/record.c b/mbbsd/record.c index 01b9fb15..17f8b482 100644 --- a/mbbsd/record.c +++ b/mbbsd/record.c @@ -567,7 +567,7 @@ do_append(char *fpath, fileheader_t * record, int size) if(fstat(fd, &st)!=-1) fsize = st.st_size; - lseek(fd, (fsize / size) * size, SEEK_CUR); // avoid offset + lseek(fd, (fsize / size) * size, SEEK_SET); // avoid offset safewrite(fd, record, size); |