1
0
mirror of https://github.com/labstack/echo.git synced 2025-07-05 00:58:47 +02:00

Using int64 instead of uint64 for response size

Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
Vishal Rana
2015-05-15 15:24:47 -07:00
parent 1ee3bc23e3
commit d90395cf2b
3 changed files with 8 additions and 8 deletions

View File

@ -10,8 +10,8 @@ import (
type (
Response struct {
Writer http.ResponseWriter
status int
size uint64
status int
size int64
committed bool
}
)
@ -33,7 +33,7 @@ func (r *Response) WriteHeader(code int) {
func (r *Response) Write(b []byte) (n int, err error) {
n, err = r.Writer.Write(b)
r.size += uint64(n)
r.size += int64(n)
return n, err
}
@ -41,7 +41,7 @@ func (r *Response) Status() int {
return r.status
}
func (r *Response) Size() uint64 {
func (r *Response) Size() int64 {
return r.size
}