diff --git a/cmd/format-fs.go b/cmd/format-fs.go index e5c195ae8..6cc7f2297 100644 --- a/cmd/format-fs.go +++ b/cmd/format-fs.go @@ -72,16 +72,6 @@ func newFormatFSV1() (format *formatFSV1) { return f } -// Returns the latest "fs" format V2 -func newFormatFSV2() (format *formatFSV2) { - f := &formatFSV2{} - f.Version = formatMetaVersionV1 - f.Format = formatBackendFS - f.ID = mustGetUUID() - f.FS.Version = formatFSVersionV2 - return f -} - // Returns the field formatMetaV1.Format i.e the string "fs" which is never likely to change. // We do not use this function in XL to get the format as the file is not fcntl-locked on XL. func formatMetaGetFormatBackendFS(r io.ReadSeeker) (string, error) { diff --git a/cmd/logger/logger.go b/cmd/logger/logger.go index 9971783d2..5768f3316 100644 --- a/cmd/logger/logger.go +++ b/cmd/logger/logger.go @@ -377,11 +377,10 @@ func (f fatalMsg) quiet(msg string, args ...interface{}) { } var ( - logTag = "ERROR" - logBanner = colorBgRed(colorFgWhite(colorBold(logTag))) + " " - emptyBanner = colorBgRed(strings.Repeat(" ", len(logTag))) + " " - minimumWidth = 80 - bannerWidth = len(logTag) + 1 + logTag = "ERROR" + logBanner = colorBgRed(colorFgWhite(colorBold(logTag))) + " " + emptyBanner = colorBgRed(strings.Repeat(" ", len(logTag))) + " " + bannerWidth = len(logTag) + 1 ) func (f fatalMsg) pretty(msg string, args ...interface{}) { diff --git a/cmd/ui-errors.go b/cmd/ui-errors.go index ae244b46e..3bb04b22e 100644 --- a/cmd/ui-errors.go +++ b/cmd/ui-errors.go @@ -120,12 +120,6 @@ Example 1: "", ) - uiErrUnableToReadFromBackend = newUIErrFn( - "Unable to read from the backend", - "Please ensure Minio binary has read permissions for the backend", - "", - ) - uiErrPortAlreadyInUse = newUIErrFn( "Port is already in use", "Please ensure no other program uses the same address/port", diff --git a/pkg/handlers/proxy.go b/pkg/handlers/proxy.go index 1d21cb185..b0f7d4b6e 100644 --- a/pkg/handlers/proxy.go +++ b/pkg/handlers/proxy.go @@ -30,7 +30,6 @@ var ( xForwardedPort = http.CanonicalHeaderKey("X-Forwarded-Port") xForwardedProto = http.CanonicalHeaderKey("X-Forwarded-Proto") xForwardedScheme = http.CanonicalHeaderKey("X-Forwarded-Scheme") - xForwardedServer = http.CanonicalHeaderKey("X-Forwarded-Server") xRealIP = http.CanonicalHeaderKey("X-Real-IP") ) diff --git a/pkg/madmin/constants.go b/pkg/madmin/constants.go deleted file mode 100644 index dc8f9c1b3..000000000 --- a/pkg/madmin/constants.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Minio Cloud Storage, (C) 2016 Minio, Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package madmin - -const ( - // Unsigned payload. - unsignedPayload = "UNSIGNED-PAYLOAD" -) diff --git a/pkg/madmin/utils.go b/pkg/madmin/utils.go index 83b2c59e2..95b08d1dc 100644 --- a/pkg/madmin/utils.go +++ b/pkg/madmin/utils.go @@ -17,7 +17,6 @@ package madmin import ( - "crypto/md5" "encoding/json" "io" "io/ioutil" @@ -38,13 +37,6 @@ func sum256(data []byte) []byte { return hash.Sum(nil) } -// sumMD5 calculate sumMD5 sum for an input byte array. -func sumMD5(data []byte) []byte { - hash := md5.New() - hash.Write(data) - return hash.Sum(nil) -} - // jsonDecoder decode json to go type. func jsonDecoder(body io.Reader, v interface{}) error { d := json.NewDecoder(body)