make vacfs work; thanks to lucho

This commit is contained in:
rsc 2005-01-16 21:15:30 +00:00
parent 17465d1425
commit a20a146803
6 changed files with 154 additions and 145 deletions

View file

@ -25,7 +25,7 @@ readscore(int fd, uchar score[VtScoreSize])
int n;
n = readn(fd, buf, sizeof(buf)-1);
if(n < sizeof(buf)) {
if(n < sizeof(buf)-1) {
werrstr("short read");
return -1;
}
@ -92,7 +92,7 @@ vacfsopenscore(VtConn *z, u8int *score, int mode, int ncache)
memmove(fs->score, score, VtScoreSize);
fs->mode = mode;
memmove(e.score, score, VtScoreSize);
memmove(e.score, rt.score, VtScoreSize);
e.gen = 0;
e.psize = (rt.blocksize/VtEntrySize)*VtEntrySize;
e.dsize = rt.blocksize;