Do not call multiple response.WriteHeader calls (#6733)

Execute method in s3Select package makes a response.WriteHeader call.

Not calling it again in SelectObjectContentHandler function in case of
error in s3Select.Execute call.
master
kannappanr 6 years ago committed by GitHub
parent 4280e68de3
commit 9ed7fb4916
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      cmd/object-handlers.go

@ -269,10 +269,7 @@ func (api objectAPIHandlers) SelectObjectContentHandler(w http.ResponseWriter, r
}
// Executes the query on data-set
if err = s3select.Execute(w, s3s); err != nil {
writeErrorResponse(w, toAPIErrorCode(err), r.URL)
return
}
s3select.Execute(w, s3s)
for k, v := range objInfo.UserDefined {
logger.GetReqInfo(ctx).SetTags(k, v)

Loading…
Cancel
Save