Browse Source

Fix: `http: multiple response.WriteHeader calls` (#2038)

We can't change the http status code here, because the response has been written.
tags/v1.2.0-rc1
Shuanglei Tao 7 years ago
parent
commit
d389ed25a5
1 changed files with 0 additions and 1 deletions
  1. 0
    1
      routers/repo/http.go

+ 0
- 1
routers/repo/http.go View File

@@ -381,7 +381,6 @@ func serviceRPC(h serviceHandler, service string) {
cmd.Stderr = &stderr
if err := cmd.Run(); err != nil {
log.GitLogger.Error(2, "fail to serve RPC(%s): %v - %v", service, err, stderr)
h.w.WriteHeader(http.StatusInternalServerError)
return
}
}

Loading…
Cancel
Save