Browse Source
Merge pull request #2960 from guol-fnst/fix_errcode
fix http response error code
pull/2962/head
Chris Lu
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
1 additions and
1 deletions
-
weed/server/filer_server_handlers_read.go
|
@ -205,7 +205,7 @@ func (fs *FilerServer) GetOrHeadHandler(w http.ResponseWriter, r *http.Request) |
|
|
err := filer.ReadAll(data, fs.filer.MasterClient, entry.Chunks) |
|
|
err := filer.ReadAll(data, fs.filer.MasterClient, entry.Chunks) |
|
|
if err != nil { |
|
|
if err != nil { |
|
|
glog.Errorf("failed to read %s: %v", path, err) |
|
|
glog.Errorf("failed to read %s: %v", path, err) |
|
|
w.WriteHeader(http.StatusNotModified) |
|
|
|
|
|
|
|
|
w.WriteHeader(http.StatusInternalServerError) |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
rs, _, _ := images.Resized(ext, bytes.NewReader(data), width, height, mode) |
|
|
rs, _, _ := images.Resized(ext, bytes.NewReader(data), width, height, mode) |
|
|