From ce42a6f23d9fd50ddf2e66a68e6ec57cad80c018 Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Sun, 29 Nov 2015 21:55:20 +0100 Subject: [PATCH] Run go fmt --- cryptfs/names_diriv.go | 8 ++++---- integration_tests/example_filesystems_test.go | 2 +- main.go | 8 ++++---- pathfs_frontend/args.go | 8 ++++---- pathfs_frontend/fs.go | 6 +++--- 5 files changed, 16 insertions(+), 16 deletions(-) diff --git a/cryptfs/names_diriv.go b/cryptfs/names_diriv.go index 9012e48..3e24a73 100644 --- a/cryptfs/names_diriv.go +++ b/cryptfs/names_diriv.go @@ -11,15 +11,15 @@ import ( // A simple one-entry DirIV cache type DirIVCache struct { // Invalidated? - cleared bool + cleared bool // The DirIV - iv []byte + iv []byte // Directory the DirIV belongs to - dir string + dir string // Ecrypted version of "dir" translatedDir string // Synchronisation - lock sync.RWMutex + lock sync.RWMutex } func (c *DirIVCache) lookup(dir string) (bool, []byte, string) { diff --git a/integration_tests/example_filesystems_test.go b/integration_tests/example_filesystems_test.go index 6f1574a..c74e383 100644 --- a/integration_tests/example_filesystems_test.go +++ b/integration_tests/example_filesystems_test.go @@ -3,9 +3,9 @@ package integration_tests // Mount example filesystems and check that the file "status.txt" is there import ( - "path/filepath" "io/ioutil" "os" + "path/filepath" "testing" ) diff --git a/main.go b/main.go index e602ed2..c5c7f64 100644 --- a/main.go +++ b/main.go @@ -283,11 +283,11 @@ func pathfsFrontend(key []byte, args argContainer, confFile *cryptfs.ConfFile) * // Reconciliate CLI and config file arguments into a Args struct that is passed to the // filesystem implementation frontendArgs := pathfs_frontend.Args{ - Cipherdir: args.cipherdir, - Masterkey: key, - OpenSSL: args.openssl, + Cipherdir: args.cipherdir, + Masterkey: key, + OpenSSL: args.openssl, PlaintextNames: args.plaintextnames, - DirIV: args.diriv, + DirIV: args.diriv, } // confFile is nil when "-zerokey" or "-masterkey" was used if confFile != nil { diff --git a/pathfs_frontend/args.go b/pathfs_frontend/args.go index 7971b79..86a907d 100644 --- a/pathfs_frontend/args.go +++ b/pathfs_frontend/args.go @@ -2,9 +2,9 @@ package pathfs_frontend // Container for arguments that are passed from main() to pathfs_frontend type Args struct { - Masterkey []byte - Cipherdir string - OpenSSL bool + Masterkey []byte + Cipherdir string + OpenSSL bool PlaintextNames bool - DirIV bool + DirIV bool } diff --git a/pathfs_frontend/fs.go b/pathfs_frontend/fs.go index 736e5dc..54525b9 100644 --- a/pathfs_frontend/fs.go +++ b/pathfs_frontend/fs.go @@ -17,8 +17,8 @@ import ( type FS struct { *cryptfs.CryptFS - pathfs.FileSystem // loopbackFileSystem, see go-fuse/fuse/pathfs/loopback.go - args Args // Stores configuration arguments + pathfs.FileSystem // loopbackFileSystem, see go-fuse/fuse/pathfs/loopback.go + args Args // Stores configuration arguments // dirIVLock: Lock()ed if any "gocryptfs.diriv" file is modified // Readers must RLock() it to prevent them from seeing intermediate // states @@ -30,7 +30,7 @@ func NewFS(args Args) *FS { return &FS{ CryptFS: cryptfs.NewCryptFS(args.Masterkey, args.OpenSSL, args.PlaintextNames), FileSystem: pathfs.NewLoopbackFileSystem(args.Cipherdir), - args: args, + args: args, } }