Commit 330c80da authored by Han-Wen Nienhuys's avatar Han-Wen Nienhuys

Run gofmt.

parent d822ee41
...@@ -16,7 +16,7 @@ func main() { ...@@ -16,7 +16,7 @@ func main() {
entry_ttl := flag.Float64("entry_ttl", 1.0, "fuse entry cache TTL.") entry_ttl := flag.Float64("entry_ttl", 1.0, "fuse entry cache TTL.")
negative_ttl := flag.Float64("negative_ttl", 1.0, "fuse negative entry cache TTL.") negative_ttl := flag.Float64("negative_ttl", 1.0, "fuse negative entry cache TTL.")
delcache_ttl := flag.Float64("deletion_cache_ttl", 5.0, "Deletion cache TTL in seconds.") delcache_ttl := flag.Float64("deletion_cache_ttl", 5.0, "Deletion cache TTL in seconds.")
branchcache_ttl := flag.Float64("branchcache_ttl", 5.0, "Branch cache TTL in seconds.") branchcache_ttl := flag.Float64("branchcache_ttl", 5.0, "Branch cache TTL in seconds.")
deldirname := flag.String( deldirname := flag.String(
......
...@@ -172,7 +172,7 @@ func (me *FileSystemConnector) SetAttr(header *InHeader, input *SetAttrIn) (out ...@@ -172,7 +172,7 @@ func (me *FileSystemConnector) SetAttr(header *InHeader, input *SetAttrIn) (out
// Must call GetAttr(); the filesystem may override some of // Must call GetAttr(); the filesystem may override some of
// the changes we effect here. // the changes we effect here.
fi, code := node.fsInode.GetAttr(f, &header.Context) fi, code := node.fsInode.GetAttr(f, &header.Context)
if code.Ok() { if code.Ok() {
out = node.mount.fileInfoToAttr(fi, header.NodeId) out = node.mount.fileInfoToAttr(fi, header.NodeId)
} }
......
...@@ -6,6 +6,7 @@ import ( ...@@ -6,6 +6,7 @@ import (
"testing" "testing"
"unsafe" "unsafe"
) )
var _ = log.Println var _ = log.Println
func markSeen(t *testing.T, substr string) { func markSeen(t *testing.T, substr string) {
......
...@@ -161,6 +161,7 @@ func VerboseTest() bool { ...@@ -161,6 +161,7 @@ func VerboseTest() bool {
} }
const AT_FDCWD = -100 const AT_FDCWD = -100
func Linkat(fd1 int, n1 string, fd2 int, n2 string) int { func Linkat(fd1 int, n1 string, fd2 int, n2 string) int {
b1 := syscall.StringBytePtr(n1) b1 := syscall.StringBytePtr(n1)
b2 := syscall.StringBytePtr(n2) b2 := syscall.StringBytePtr(n2)
......
...@@ -28,7 +28,7 @@ func TestOsErrorToErrno(t *testing.T) { ...@@ -28,7 +28,7 @@ func TestOsErrorToErrno(t *testing.T) {
func TestLinkAt(t *testing.T) { func TestLinkAt(t *testing.T) {
dir, _ := ioutil.TempDir("", "go-fuse") dir, _ := ioutil.TempDir("", "go-fuse")
ioutil.WriteFile(dir + "/a", []byte{42}, 0644) ioutil.WriteFile(dir+"/a", []byte{42}, 0644)
f, _ := os.Open(dir) f, _ := os.Open(dir)
e := Linkat(f.Fd(), "a", f.Fd(), "b") e := Linkat(f.Fd(), "a", f.Fd(), "b")
if e != 0 { if e != 0 {
......
...@@ -621,7 +621,7 @@ func (me *pathInode) Truncate(file File, size uint64, context *Context) (code St ...@@ -621,7 +621,7 @@ func (me *pathInode) Truncate(file File, size uint64, context *Context) (code St
return code return code
} }
} }
if len(files) == 0 || code == ENOSYS || code == EBADF { if len(files) == 0 || code == ENOSYS || code == EBADF {
code = me.fs.Truncate(me.GetPath(), size, context) code = me.fs.Truncate(me.GetPath(), size, context)
} }
return code return code
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment