summaryrefslogtreecommitdiff
path: root/fsck.go
diff options
context:
space:
mode:
authorJakob Unterwurzacher2021-06-02 19:32:20 +0200
committerJakob Unterwurzacher2021-06-02 19:32:20 +0200
commit8f2be5d93cda2696fce7bc1a3f8a888a19321f09 (patch)
treefda2f89077dce75d7112cd8f2fed1ec4941f7e3c /fsck.go
parent307dfd7f71ee1d72113e2194e9b26a53b9a36c46 (diff)
fsck: mark temporary mount read-only
We don't write during fsck, but somebody else might try to.
Diffstat (limited to 'fsck.go')
-rw-r--r--fsck.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/fsck.go b/fsck.go
index c0db576..1f40514 100644
--- a/fsck.go
+++ b/fsck.go
@@ -260,6 +260,7 @@ func fsck(args *argContainer) (exitcode int) {
os.Exit(exitcodes.Usage)
}
args.allow_other = false
+ args.ro = true
var err error
args.mountpoint, err = ioutil.TempDir("", "gocryptfs.fsck.")
if err != nil {