Fix return code in RequestEntityTooLargeError

Change-Id: Ic7fb562ba58e6807b4c2561d2a506ca02afa8c2b
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Julien Danjou 2011-06-23 17:36:42 +02:00
parent 12cdf34ea3
commit d6aaafa9c3
1 changed files with 2 additions and 3 deletions

View File

@ -42,9 +42,8 @@ func ForbiddenError(conn http.ResponseWriter, errorMessage string, args ...inter
fmt.Fprintf(conn, "<h1>Forbidden</h1>")
}
func RequestEntityTooLargeError(conn http.ResponseWriter, errorMessage string, args ...interface{}) {
conn.WriteHeader(http.StatusForbidden)
log.Printf("Request entity is too large: %s", fmt.Sprintf(errorMessage, args...))
func RequestEntityTooLargeError(conn http.ResponseWriter) {
conn.WriteHeader(http.StatusRequestEntityTooLarge)
fmt.Fprintf(conn, "<h1>Request entity is too large</h1>")
}