Commit e56b7970 authored by Han-Wen Nienhuys's avatar Han-Wen Nienhuys

Fix unionfs.

parent ed37744c
......@@ -4,6 +4,7 @@ import (
"crypto/md5"
"fmt"
"github.com/hanwen/go-fuse/fuse"
"github.com/hanwen/go-fuse/raw"
"log"
"os"
"path"
......@@ -559,7 +560,7 @@ func (me *UnionFs) Chmod(name string, mode uint32, context *fuse.Context) (code
func (me *UnionFs) Access(name string, mode uint32, context *fuse.Context) (code fuse.Status) {
// We always allow writing.
mode = mode &^ fuse.W_OK
mode = mode &^ raw.W_OK
if name == "" {
return fuse.OK
}
......
......@@ -2,7 +2,6 @@ package unionfs
import (
"fmt"
"github.com/hanwen/go-fuse/fuse"
"io/ioutil"
"log"
"os"
......@@ -12,6 +11,9 @@ import (
"syscall"
"testing"
"time"
"github.com/hanwen/go-fuse/fuse"
"github.com/hanwen/go-fuse/raw"
)
var _ = fmt.Print
......@@ -607,7 +609,7 @@ func TestUnionFsWriteAccess(t *testing.T) {
CheckSuccess(err)
freezeRo(wd + "/ro")
err = syscall.Access(wd+"/mnt/file", fuse.W_OK)
err = syscall.Access(wd+"/mnt/file", raw.W_OK)
if err != nil {
CheckSuccess(err)
}
......
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