From the BeBook:

Node Locking

Another feature provided by the BNode class is "node locking": Through BNode's
Lock() function you can restrict access to the node. The lock is removed when
Unlock() is called, or when the BNode object is deleted.

There is still something wrong with locking though. For example, it looks like
WriteAttr() fails on the node when we lock it (File Busy) but it should not.
The lock acquirer should be able to call WriteAttr() on it.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25158 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Bruno G. Albuquerque 2008-04-25 14:50:57 +00:00
parent 2bea381578
commit 8ce1d51721
1 changed files with 2 additions and 1 deletions

View File

@ -168,10 +168,11 @@ BNode::BNode(const BNode &node)
}
/*! \brief Frees all resources associated with this BNode.
/*! \brief Unlocks the BNode and frees all resources associated with it.
*/
BNode::~BNode()
{
Unlock();
Unset();
}