silly cache hack, also fix vtfilewritebefore not to be so aggressive.

This commit is contained in:
rsc 2004-06-17 19:17:04 +00:00
parent 7cb748941e
commit a1882dc1d0
2 changed files with 25 additions and 6 deletions

View file

@ -1222,10 +1222,13 @@ vtfileflushbefore(VtFile *r, u64int offset)
* if the rest of the block is already flushed,
* we can flush the whole block.
*/
ok = 1;
for(; j<ppb; j++)
if(vtglobaltolocal(b->data+j*VtScoreSize) != NilBlock)
ok = 0;
ok = 0;
if(index[i] != index1[i]){
ok = 1;
for(; j<ppb; j++)
if(vtglobaltolocal(b->data+j*VtScoreSize) != NilBlock)
ok = 0;
}
}
if(ok){
if(i == depth)