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
Kirill Smelkov
go-fuse
Commits
ca4265a2
Commit
ca4265a2
authored
Sep 23, 2011
by
Han-Wen Nienhuys
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Provide a DefaultFsNode.GetAttr()
parent
16ee6060
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
fuse/defaultnode.go
fuse/defaultnode.go
+5
-1
No files found.
fuse/defaultnode.go
View file @
ca4265a2
...
...
@@ -20,6 +20,7 @@ func (me *DefaultNodeFileSystem) OnMount(conn *FileSystemConnector) {
func
(
me
*
DefaultNodeFileSystem
)
StatFs
()
*
StatfsOut
{
return
nil
}
func
(
me
*
DefaultNodeFileSystem
)
Root
()
FsNode
{
return
new
(
DefaultFsNode
)
}
...
...
@@ -124,7 +125,10 @@ func (me *DefaultFsNode) ListXAttr(context *Context) (attrs []string, code Statu
}
func
(
me
*
DefaultFsNode
)
GetAttr
(
file
File
,
context
*
Context
)
(
fi
*
os
.
FileInfo
,
code
Status
)
{
return
nil
,
ENOSYS
if
me
.
Inode
()
.
IsDir
()
{
return
&
os
.
FileInfo
{
Mode
:
S_IFDIR
|
0755
},
OK
}
return
&
os
.
FileInfo
{
Mode
:
S_IFREG
|
0644
},
OK
}
func
(
me
*
DefaultFsNode
)
Chmod
(
file
File
,
perms
uint32
,
context
*
Context
)
(
code
Status
)
{
...
...
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