From 70af0ec24c795ef26e9d85813b9b8eecc22d73c5 Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Sat, 10 Oct 2020 16:02:10 -0700 Subject: [PATCH] filer: fix hanging on read --- weed/filer/stream.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/weed/filer/stream.go b/weed/filer/stream.go index f6e2a7643..a41aebe22 100644 --- a/weed/filer/stream.go +++ b/weed/filer/stream.go @@ -34,7 +34,7 @@ func StreamContent(masterClient *wdclient.MasterClient, w io.Writer, chunks []*f urlStrings := fileId2Url[chunkView.FileId] data, err := retriedFetchChunkData(urlStrings, chunkView.CipherKey, chunkView.IsGzipped, chunkView.IsFullChunk(), chunkView.Offset, int(chunkView.Size)) - if err == nil { + if err != nil { return err } w.Write(data)