mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-09-18 20:29:22 +08:00
working
This commit is contained in:
@@ -59,3 +59,13 @@ func (i *InodeToPath) HasPath(path util.FullPath) bool {
|
||||
_, found := i.path2inode[path]
|
||||
return found
|
||||
}
|
||||
|
||||
func (i *InodeToPath) HasInode(inode uint64) bool {
|
||||
if inode == 1 {
|
||||
return true
|
||||
}
|
||||
i.RLock()
|
||||
defer i.RUnlock()
|
||||
_, found := i.inode2path[inode]
|
||||
return found
|
||||
}
|
||||
|
Reference in New Issue
Block a user