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
3c64a018
Commit
3c64a018
authored
Aug 15, 2010
by
Ivan Krasin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed the problem: filename has 0x00 symbol at the end
parent
7e853ab4
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
3 deletions
+4
-3
fuse/fuse.go
fuse/fuse.go
+2
-1
fuse/fuse_test.go
fuse/fuse_test.go
+2
-2
No files found.
fuse/fuse.go
View file @
3c64a018
...
@@ -6,6 +6,7 @@ import (
...
@@ -6,6 +6,7 @@ import (
"fmt"
"fmt"
"os"
"os"
"path"
"path"
"strings"
)
)
const
(
const
(
...
@@ -254,7 +255,7 @@ func readDir(fs FileSystem, h *InHeader, ing interface{}, c *managerClient) (int
...
@@ -254,7 +255,7 @@ func readDir(fs FileSystem, h *InHeader, ing interface{}, c *managerClient) (int
}
}
func
lookup
(
h
*
InHeader
,
r
*
bytes
.
Buffer
,
c
*
managerClient
)
(
interface
{},
Status
)
{
func
lookup
(
h
*
InHeader
,
r
*
bytes
.
Buffer
,
c
*
managerClient
)
(
interface
{},
Status
)
{
filename
:=
string
(
r
.
Bytes
()
)
filename
:=
string
s
.
TrimRight
(
string
(
r
.
Bytes
()),
"
\x00
"
)
fmt
.
Printf
(
"filename: %s
\n
"
,
filename
)
fmt
.
Printf
(
"filename: %s
\n
"
,
filename
)
resp
:=
c
.
lookup
(
h
.
NodeId
,
filename
)
resp
:=
c
.
lookup
(
h
.
NodeId
,
filename
)
if
resp
.
status
!=
OK
{
if
resp
.
status
!=
OK
{
...
...
fuse/fuse_test.go
View file @
3c64a018
...
@@ -9,11 +9,11 @@ import (
...
@@ -9,11 +9,11 @@ import (
)
)
const
(
const
(
tempMountDir
=
"testMountDir"
tempMountDir
=
"testMountDir
2
"
)
)
var
(
var
(
testFileNames
=
[]
string
{
"one"
,
"two"
,
"three
3
"
}
testFileNames
=
[]
string
{
"one"
,
"two"
,
"three
.txt
"
}
)
)
type
testFuse
struct
{}
type
testFuse
struct
{}
...
...
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