multiple fixes

* adjust isOpen count
* move ContinuousDirtyPages lock to filehandle
* fix problem with MergeIntoVisibles, avoid reusing slices
* let filer delete the garbage
This commit is contained in:
Chris Lu
2020-08-23 15:48:02 -07:00
parent c19245886c
commit aee27ccbe1
10 changed files with 81 additions and 61 deletions

View File

@@ -15,7 +15,7 @@ type Node struct {
type BoundedTree struct {
root *Node
sync.Mutex
sync.RWMutex
}
func NewBoundedTree() *BoundedTree {
@@ -131,6 +131,9 @@ func (n *Node) getChild(childName string) *Node {
func (t *BoundedTree) HasVisited(p util.FullPath) bool {
t.RLock()
defer t.RUnlock()
if t.root == nil {
return true
}