From 223108c6aeb214e838f28acf75257569fd33b7bf Mon Sep 17 00:00:00 2001 From: Alexander Neumann Date: Sat, 28 Mar 2015 15:24:53 +0100 Subject: [PATCH] Remove unused vars and const --- backend/generic.go | 1 - backend/local/local.go | 7 +++---- cmd/dirdiff/main.go | 2 -- cmd/restic/cmd_find.go | 6 ------ key.go | 1 - server.go | 1 - 6 files changed, 3 insertions(+), 15 deletions(-) diff --git a/backend/generic.go b/backend/generic.go index 2da7fb11e..42d4258de 100644 --- a/backend/generic.go +++ b/backend/generic.go @@ -15,7 +15,6 @@ var ( ) var ( - newHash = sha256.New hashData = sha256.Sum256 ) diff --git a/backend/local/local.go b/backend/local/local.go index 598474fa2..bc9cf3b7f 100644 --- a/backend/local/local.go +++ b/backend/local/local.go @@ -19,10 +19,9 @@ import ( var ErrWrongData = errors.New("wrong data returned by backend, checksum does not match") type Local struct { - p string - ver uint - name string - id string + p string + ver uint + id string } // Open opens the local backend at dir. diff --git a/cmd/dirdiff/main.go b/cmd/dirdiff/main.go index 4b9f8c8ad..94ffe47a5 100644 --- a/cmd/dirdiff/main.go +++ b/cmd/dirdiff/main.go @@ -7,8 +7,6 @@ import ( "syscall" ) -const backlog = 100 - type entry struct { path string fi os.FileInfo diff --git a/cmd/restic/cmd_find.go b/cmd/restic/cmd_find.go index 5ddb10da4..ae18955dd 100644 --- a/cmd/restic/cmd_find.go +++ b/cmd/restic/cmd_find.go @@ -10,12 +10,6 @@ import ( "github.com/restic/restic/debug" ) -type findQuery struct { - name string - minModTime time.Time - maxModTime time.Time -} - type findResult struct { node *restic.Node path string diff --git a/key.go b/key.go index 02b801a14..a3c298a6f 100644 --- a/key.go +++ b/key.go @@ -46,7 +46,6 @@ type Key struct { Created time.Time `json:"created"` Username string `json:"username"` Hostname string `json:"hostname"` - Comment string `json:"comment,omitempty"` KDF string `json:"kdf"` N int `json:"N"` diff --git a/server.go b/server.go index da7fc5456..209cde546 100644 --- a/server.go +++ b/server.go @@ -316,7 +316,6 @@ func (s Server) Key() *Key { type ServerStats struct { Blobs, Trees uint - Bytes uint64 } // Stats returns statistics for this backend and the server.