Skip to content

Commit

Permalink
Update status.go (#1093)
Browse files Browse the repository at this point in the history
  • Loading branch information
moredure authored Sep 6, 2021
1 parent 3f70d78 commit 5d73da3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions status.go
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,10 @@ func invalidStatusLine(statusCode int) []byte {
statusText := StatusMessage(statusCode)
// xxx placeholder of status code
var line = make([]byte, 0, len("HTTP/1.1 xxx \r\n")+len(statusText))
line = append(line, []byte("HTTP/1.1 ")...)
line = append(line, "HTTP/1.1 "...)
line = strconv.AppendInt(line, int64(statusCode), 10)
line = append(line, []byte(" ")...)
line = append(line, []byte(statusText)...)
line = append(line, []byte("\r\n")...)
line = append(line, ' ')
line = append(line, statusText...)
line = append(line, "\r\n"...)
return line
}

0 comments on commit 5d73da3

Please sign in to comment.