From b92df8065d777b9ea4556702e6adddeec0306711 Mon Sep 17 00:00:00 2001 From: aarzilli Date: Mon, 24 Nov 2014 18:41:50 +0100 Subject: [PATCH] DirReader.Readdir incorrectly logs the contents of err where it should really log the contents of res.err Change-Id: Ic607d823af4b6147a54f896ffabaabf67b7b1c02 --- pkg/schema/dirreader.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/schema/dirreader.go b/pkg/schema/dirreader.go index 2c9d2834d..a6da856e2 100644 --- a/pkg/schema/dirreader.go +++ b/pkg/schema/dirreader.go @@ -156,7 +156,7 @@ func (dr *DirReader) Readdir(n int) (entries []DirectoryEntry, err error) { for _, c := range cs { res := <-c if res.err != nil { - return nil, fmt.Errorf("schema/dirreader: can't create dirEntry: %v", err) + return nil, fmt.Errorf("schema/dirreader: can't create dirEntry: %v", res.err) } entries = append(entries, res.ent) }