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
c9da078c
Commit
c9da078c
authored
Apr 28, 2011
by
Han-Wen Nienhuys
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reinstate file name printing in debug mode.
parent
88ab347f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
4 deletions
+24
-4
fuse/fuse.go
fuse/fuse.go
+9
-4
fuse/opcode.go
fuse/opcode.go
+15
-0
No files found.
fuse/fuse.go
View file @
c9da078c
...
@@ -292,10 +292,15 @@ func (me *MountState) handle(req *request) {
...
@@ -292,10 +292,15 @@ func (me *MountState) handle(req *request) {
func
(
me
*
MountState
)
dispatch
(
req
*
request
,
handler
*
operationHandler
)
{
func
(
me
*
MountState
)
dispatch
(
req
*
request
,
handler
*
operationHandler
)
{
if
me
.
Debug
{
if
me
.
Debug
{
nm
:=
""
handler
:=
getHandler
(
req
.
inHeader
.
Opcode
)
// TODO - reinstate filename printing.
var
names
interface
{}
log
.
Printf
(
"Dispatch: %v, NodeId: %v %s
\n
"
,
if
handler
.
FileNames
>
0
{
operationName
(
req
.
inHeader
.
Opcode
),
req
.
inHeader
.
NodeId
,
nm
)
names
=
req
.
filenames
(
handler
.
FileNames
)
}
else
{
names
=
""
}
log
.
Printf
(
"Dispatch: %v, NodeId: %v %v
\n
"
,
operationName
(
req
.
inHeader
.
Opcode
),
req
.
inHeader
.
NodeId
,
names
)
}
}
handler
.
Func
(
me
,
req
)
handler
.
Func
(
me
,
req
)
}
}
...
...
fuse/opcode.go
View file @
c9da078c
...
@@ -260,6 +260,7 @@ type operationHandler struct {
...
@@ -260,6 +260,7 @@ type operationHandler struct {
OutputSize
int
OutputSize
int
DecodeIn
castPointerFunc
DecodeIn
castPointerFunc
DecodeOut
castPointerFunc
DecodeOut
castPointerFunc
FileNames
int
}
}
var
operationHandlers
[]
*
operationHandler
var
operationHandlers
[]
*
operationHandler
...
@@ -425,4 +426,18 @@ func init() {
...
@@ -425,4 +426,18 @@ func init() {
operationHandlers
[
op
]
.
DecodeOut
=
f
operationHandlers
[
op
]
.
DecodeOut
=
f
}
}
for
op
,
count
:=
range
map
[
Opcode
]
int
{
FUSE_LOOKUP
:
1
,
FUSE_RENAME
:
2
,
FUSE_SYMLINK
:
2
,
FUSE_GETXATTR
:
1
,
FUSE_CREATE
:
1
,
FUSE_MKNOD
:
1
,
FUSE_MKDIR
:
1
,
FUSE_UNLINK
:
1
,
FUSE_RMDIR
:
1
,
FUSE_REMOVEXATTR
:
1
,
}
{
operationHandlers
[
op
]
.
FileNames
=
count
}
}
}
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