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
29c89791
Commit
29c89791
authored
Dec 11, 2019
by
Han-Wen Nienhuys
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fs: fix lint errors
Change-Id: I3bce0eee02e0f8d1a2d02c4a4f065bb023179ab1
parent
c8185a54
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
fs/loopback.go
fs/loopback.go
+6
-6
No files found.
fs/loopback.go
View file @
29c89791
...
@@ -55,9 +55,9 @@ func (n *loopbackNode) Statfs(ctx context.Context, out *fuse.StatfsOut) syscall.
...
@@ -55,9 +55,9 @@ func (n *loopbackNode) Statfs(ctx context.Context, out *fuse.StatfsOut) syscall.
return
OK
return
OK
}
}
func
(
n
*
loopbackRoot
)
Getattr
(
ctx
context
.
Context
,
f
FileHandle
,
out
*
fuse
.
AttrOut
)
syscall
.
Errno
{
func
(
r
*
loopbackRoot
)
Getattr
(
ctx
context
.
Context
,
f
FileHandle
,
out
*
fuse
.
AttrOut
)
syscall
.
Errno
{
st
:=
syscall
.
Stat_t
{}
st
:=
syscall
.
Stat_t
{}
err
:=
syscall
.
Stat
(
n
.
rootPath
,
&
st
)
err
:=
syscall
.
Stat
(
r
.
rootPath
,
&
st
)
if
err
!=
nil
{
if
err
!=
nil
{
return
ToErrno
(
err
)
return
ToErrno
(
err
)
}
}
...
@@ -211,7 +211,7 @@ func (n *loopbackNode) Symlink(ctx context.Context, target, name string, out *fu
...
@@ -211,7 +211,7 @@ func (n *loopbackNode) Symlink(ctx context.Context, target, name string, out *fu
return
nil
,
ToErrno
(
err
)
return
nil
,
ToErrno
(
err
)
}
}
st
:=
syscall
.
Stat_t
{}
st
:=
syscall
.
Stat_t
{}
if
syscall
.
Lstat
(
p
,
&
st
);
err
!=
nil
{
if
err
:=
syscall
.
Lstat
(
p
,
&
st
);
err
!=
nil
{
syscall
.
Unlink
(
p
)
syscall
.
Unlink
(
p
)
return
nil
,
ToErrno
(
err
)
return
nil
,
ToErrno
(
err
)
}
}
...
@@ -231,7 +231,7 @@ func (n *loopbackNode) Link(ctx context.Context, target InodeEmbedder, name stri
...
@@ -231,7 +231,7 @@ func (n *loopbackNode) Link(ctx context.Context, target InodeEmbedder, name stri
return
nil
,
ToErrno
(
err
)
return
nil
,
ToErrno
(
err
)
}
}
st
:=
syscall
.
Stat_t
{}
st
:=
syscall
.
Stat_t
{}
if
syscall
.
Lstat
(
p
,
&
st
);
err
!=
nil
{
if
err
:=
syscall
.
Lstat
(
p
,
&
st
);
err
!=
nil
{
syscall
.
Unlink
(
p
)
syscall
.
Unlink
(
p
)
return
nil
,
ToErrno
(
err
)
return
nil
,
ToErrno
(
err
)
}
}
...
@@ -288,7 +288,7 @@ func (n *loopbackNode) Getattr(ctx context.Context, f FileHandle, out *fuse.Attr
...
@@ -288,7 +288,7 @@ func (n *loopbackNode) Getattr(ctx context.Context, f FileHandle, out *fuse.Attr
}
}
p
:=
n
.
path
()
p
:=
n
.
path
()
var
err
error
=
nil
var
err
error
st
:=
syscall
.
Stat_t
{}
st
:=
syscall
.
Stat_t
{}
err
=
syscall
.
Lstat
(
p
,
&
st
)
err
=
syscall
.
Lstat
(
p
,
&
st
)
if
err
!=
nil
{
if
err
!=
nil
{
...
@@ -371,7 +371,7 @@ func (n *loopbackNode) Setattr(ctx context.Context, f FileHandle, in *fuse.SetAt
...
@@ -371,7 +371,7 @@ func (n *loopbackNode) Setattr(ctx context.Context, f FileHandle, in *fuse.SetAt
return
OK
return
OK
}
}
// NewLoopback returns a root node for a loopback file system whose
// NewLoopback
Root
returns a root node for a loopback file system whose
// root is at the given root. This node implements all NodeXxxxer
// root is at the given root. This node implements all NodeXxxxer
// operations available.
// operations available.
func
NewLoopbackRoot
(
root
string
)
(
InodeEmbedder
,
error
)
{
func
NewLoopbackRoot
(
root
string
)
(
InodeEmbedder
,
error
)
{
...
...
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