From d3660ffce8ec38f8017216bca2e77c0362328c72 Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Thu, 27 Dec 2018 12:17:05 -0800 Subject: [PATCH] avoid gzipping files without file extensions fix https://github.com/chrislusf/seaweedfs/issues/804 --- weed/operation/compress.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/weed/operation/compress.go b/weed/operation/compress.go index 50958fd50..65979d529 100644 --- a/weed/operation/compress.go +++ b/weed/operation/compress.go @@ -38,8 +38,8 @@ func IsGzippable(ext, mtype string, data []byte) bool { return true case ".php", ".java", ".go", ".rb", ".c", ".cpp", ".h", ".hpp": return true - case ".png", ".jpg", ".jpeg", "": - return true + case ".png", ".jpg", ".jpeg": + return false } // by mime type