No one is going to find this inode.

There is only one ref to it -- the caller --
and no links to it.
This commit is contained in:
rsc 2007-08-28 03:31:11 +00:00
parent 1b25f3b057
commit 8970df0c1b

2
fs.c
View file

@ -243,12 +243,12 @@ iput(struct inode *ip)
panic("iput busy"); panic("iput busy");
ip->flags |= I_BUSY; ip->flags |= I_BUSY;
release(&icache.lock); release(&icache.lock);
// XXX convince rsc that no one will come find this inode.
itrunc(ip); itrunc(ip);
ip->type = 0; ip->type = 0;
iupdate(ip); iupdate(ip);
acquire(&icache.lock); acquire(&icache.lock);
ip->flags &= ~I_BUSY; ip->flags &= ~I_BUSY;
wakeup(ip);
} }
ip->ref--; ip->ref--;
release(&icache.lock); release(&icache.lock);