Skip to content

Commit a40e9a8

Browse files
committed
mount: set DirectMount: true
Attempt to directly call mount(2) before trying fusermount. This means we can do without fusermount if running as root. #697
1 parent 8d3b992 commit a40e9a8

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

README.md

+5
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,11 @@ RM: 2,367
195195
Changelog
196196
---------
197197

198+
#### vNEXT, in progress
199+
* Attempt to directly call mount(2) before trying fusermount. This means we
200+
can do without fusermount if running as root or in a root-like namespace
201+
([#697](https://github.com/rfjakob/gocryptfs/issues/697)).
202+
198203
#### v2.3.2, 2023-04-29
199204
* Fix incorrect file size reported after hard link creation
200205
([#724](https://github.com/rfjakob/gocryptfs/issues/724))

mount.go

+3
Original file line numberDiff line numberDiff line change
@@ -396,6 +396,9 @@ func initGoFuse(rootNode fs.InodeEmbedder, args *argContainer) *fuse.Server {
396396
// Setting SyncRead disables FUSE_CAP_ASYNC_READ. This makes the kernel
397397
// do everything in-order without parallelism.
398398
SyncRead: args.serialize_reads,
399+
// Attempt to directly call mount(2) before trying fusermount. This means we
400+
// can do without fusermount if running as root.
401+
DirectMount: true,
399402
}
400403

401404
mOpts := &fuseOpts.MountOptions

0 commit comments

Comments
 (0)