summaryrefslogtreecommitdiff
path: root/sys/src/cmd/hjfs/fs1.c
diff options
context:
space:
mode:
authoraiju <aiju@phicode.de>2012-08-08 10:14:20 +0200
committeraiju <aiju@phicode.de>2012-08-08 10:14:20 +0200
commit9e608833e922c318b431aead7874a8f8f1539ae7 (patch)
tree25f41f5a4ac655eb2b0e2214d4bd0a450d762505 /sys/src/cmd/hjfs/fs1.c
parentf2c70fe2f708446794af299b1130b7aaf8dc73e5 (diff)
hjfs: various fixes
Diffstat (limited to 'sys/src/cmd/hjfs/fs1.c')
-rw-r--r--sys/src/cmd/hjfs/fs1.c20
1 files changed, 2 insertions, 18 deletions
diff --git a/sys/src/cmd/hjfs/fs1.c b/sys/src/cmd/hjfs/fs1.c
index 784593245..7052b749a 100644
--- a/sys/src/cmd/hjfs/fs1.c
+++ b/sys/src/cmd/hjfs/fs1.c
@@ -270,6 +270,7 @@ initfs(Dev *d, int doream, int flags)
if(doream)
writeusers(fs);
readusers(fs);
+ dprint("hjfs: fs is %s\n", d->name);
return fs;
error:
@@ -418,22 +419,7 @@ freeit:
}
static int
-isopen(Fs *fs, FLoc *p, uvlong blk, int deind)
-{
- Loc *l;
-
- qlock(&fs->loctree);
- for(l = fs->rootloc->gnext; l != fs->rootloc; l = l->gnext)
- if(l->blk == blk && l->deind == deind && l->next->blk == p->blk && l->next->deind == p->deind){
- qunlock(&fs->loctree);
- return 1;
- }
- qunlock(&fs->loctree);
- return 0;
-}
-
-static int
-dumpblk(Fs *fs, FLoc *p, uvlong *l)
+dumpblk(Fs *fs, FLoc *, uvlong *l)
{
uvlong n;
int i;
@@ -466,8 +452,6 @@ dumpblk(Fs *fs, FLoc *p, uvlong *l)
case TDENTRY:
memcpy(c->de, b->de, sizeof(b->de));
for(d = b->de; d < &b->de[DEPERBLK]; d++){
- if((d->mode & DGONE) != 0 && !isopen(fs, p, *l, d - b->de))
- memset(d, 0, sizeof(Dentry));
if((d->mode & DALLOC) == 0)
continue;
if((d->type & QTTMP) != 0)