From 35219d0022a6225a4a412844f1cf00747a04e41e Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Sun, 16 Oct 2016 13:43:19 +0200 Subject: [PATCH] fusefrontend: log missing gocryptfs.diriv This can happen during normal operation when the directory has been deleted concurrently. But it can also mean that the gocryptfs.diriv is missing due to an error, so log the event at "info" level. --- internal/fusefrontend/fs_dir.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/internal/fusefrontend/fs_dir.go b/internal/fusefrontend/fs_dir.go index b7a0251..6b581b1 100644 --- a/internal/fusefrontend/fs_dir.go +++ b/internal/fusefrontend/fs_dir.go @@ -255,6 +255,11 @@ func (fs *FS) OpenDir(dirName string, context *fuse.Context) ([]fuse.DirEntry, f cDirAbsPath = filepath.Join(fs.args.Cipherdir, cDirName) cachedIV, err = nametransform.ReadDirIV(cDirAbsPath) if err != nil { + // This can happen during normal operation when the directory has + // been deleted concurrently. But it can also mean that the + // gocryptfs.diriv is missing due to an error, so log the event + // at "info" level. + tlog.Info.Printf("OpenDir: %v", err) return nil, fuse.ToStatus(err) } }