diff options
Diffstat (limited to 'main.go')
-rw-r--r-- | main.go | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -122,8 +122,11 @@ func loadConfig(args *argContainer) (masterkey []byte, confFile *configfile.Conf pw := readpassword.Once(args.extpass) tlog.Info.Println("Decrypting master key") masterkey, confFile, err = configfile.LoadConfFile(args.config, pw) - if err != nil { - tlog.Fatal.Println(err.Error()) + if _, ok := err.(configfile.DeprecatedFsError); ok { + // Force read-only mode + args.ro = true + } else if err != nil { + tlog.Fatal.Println(err) os.Exit(ERREXIT_LOADCONF) } |