aboutsummaryrefslogtreecommitdiff
path: root/internal/fusefrontend
diff options
context:
space:
mode:
Diffstat (limited to 'internal/fusefrontend')
-rw-r--r--internal/fusefrontend/ctlsock_interface.go19
-rw-r--r--internal/fusefrontend/write_lock.go2
2 files changed, 20 insertions, 1 deletions
diff --git a/internal/fusefrontend/ctlsock_interface.go b/internal/fusefrontend/ctlsock_interface.go
new file mode 100644
index 0000000..c22dce6
--- /dev/null
+++ b/internal/fusefrontend/ctlsock_interface.go
@@ -0,0 +1,19 @@
+package fusefrontend
+
+import (
+ "errors"
+
+ "github.com/rfjakob/gocryptfs/internal/ctlsock"
+)
+
+var _ ctlsock.Interface = &FS{} // Verify that interface is implemented.
+
+// EncryptPath implements ctlsock.Backend
+func (fs *FS) EncryptPath(plainPath string) (string, error) {
+ return fs.encryptPath(plainPath)
+}
+
+// DecryptPath implements ctlsock.Backend
+func (fs *FS) DecryptPath(plainPath string) (string, error) {
+ return "", errors.New("Not implemented")
+}
diff --git a/internal/fusefrontend/write_lock.go b/internal/fusefrontend/write_lock.go
index 7394994..3addfd6 100644
--- a/internal/fusefrontend/write_lock.go
+++ b/internal/fusefrontend/write_lock.go
@@ -21,7 +21,7 @@ var wlock wlockMap
// 2) lock ... unlock ...
// 3) unregister
type wlockMap struct {
- // Counts lock() calls. As every operation that modifies a file should
+ // opCount counts lock() calls. As every operation that modifies a file should
// call it, this effectively serves as a write-operation counter.
// The variable is accessed without holding any locks so atomic operations
// must be used. It must be the first element of the struct to guarantee