Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go-fuse
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Levin Zimmermann
go-fuse
Commits
d339218a
Commit
d339218a
authored
Apr 22, 2011
by
Han-Wen Nienhuys
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move GetPath to pathfilesystem.go, so all locking is within one file.
parent
85a39adf
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
11 deletions
+11
-11
fuse/pathfilesystem.go
fuse/pathfilesystem.go
+11
-0
fuse/pathops.go
fuse/pathops.go
+0
-11
No files found.
fuse/pathfilesystem.go
View file @
d339218a
...
@@ -468,3 +468,14 @@ func (me *FileSystemConnector) Unmount(path string) Status {
...
@@ -468,3 +468,14 @@ func (me *FileSystemConnector) Unmount(path string) Status {
}
}
return
unmountError
return
unmountError
}
}
func
(
me
*
FileSystemConnector
)
GetPath
(
nodeid
uint64
)
(
path
string
,
mount
*
mountData
,
node
*
inode
)
{
n
:=
me
.
getInodeData
(
nodeid
)
// Need to lock because renames create invalid states.
me
.
treeLock
.
RLock
()
defer
me
.
treeLock
.
RUnlock
()
p
,
m
:=
n
.
GetPath
()
return
p
,
m
,
n
}
fuse/pathops.go
View file @
d339218a
...
@@ -23,17 +23,6 @@ func (me *FileSystemConnector) SetOptions(opts FileSystemConnectorOptions) {
...
@@ -23,17 +23,6 @@ func (me *FileSystemConnector) SetOptions(opts FileSystemConnectorOptions) {
me
.
options
=
opts
me
.
options
=
opts
}
}
func
(
me
*
FileSystemConnector
)
GetPath
(
nodeid
uint64
)
(
path
string
,
mount
*
mountData
,
node
*
inode
)
{
n
:=
me
.
getInodeData
(
nodeid
)
// Need to lock because renames create invalid states.
me
.
treeLock
.
RLock
()
defer
me
.
treeLock
.
RUnlock
()
p
,
m
:=
n
.
GetPath
()
return
p
,
m
,
n
}
func
(
me
*
FileSystemConnector
)
Init
(
h
*
InHeader
,
input
*
InitIn
)
(
*
InitOut
,
Status
)
{
func
(
me
*
FileSystemConnector
)
Init
(
h
*
InHeader
,
input
*
InitIn
)
(
*
InitOut
,
Status
)
{
// TODO ?
// TODO ?
return
&
InitOut
{},
OK
return
&
InitOut
{},
OK
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment