From f8fddff7694b2cb9487fd4b5cbe9f97a136600b0 Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Thu, 3 Sep 2015 18:57:28 +0200 Subject: Split into FS and File --- cryptfs/log.go | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 cryptfs/log.go (limited to 'cryptfs/log.go') diff --git a/cryptfs/log.go b/cryptfs/log.go new file mode 100644 index 0000000..947b1c3 --- /dev/null +++ b/cryptfs/log.go @@ -0,0 +1,19 @@ +package cryptfs + +import ( + "fmt" +) + +type logChannel struct { + enabled bool +} + +func (l logChannel) Printf(format string, args ...interface{}) { + if l.enabled == true { + fmt.Printf(format, args...) + } +} + + +var debug = logChannel{true} +var warn = logChannel{true} -- cgit v1.2.3