1
0
mirror of https://github.com/astaxie/beego.git synced 2025-06-12 07:40:39 +00:00

Merge branch 'develop' of https://github.com/astaxie/beego into develop

This commit is contained in:
astaxie
2015-12-21 22:54:22 +08:00
6 changed files with 94 additions and 123 deletions

View File

@ -315,7 +315,7 @@ func (input *BeegoInput) Session(key interface{}) interface{} {
// CopyBody returns the raw request body data as bytes.
func (input *BeegoInput) CopyBody(MaxMemory int64) []byte {
safe := &io.LimitedReader{R:input.Context.Request.Body, N:MaxMemory}
safe := &io.LimitedReader{R: input.Context.Request.Body, N: MaxMemory}
requestbody, _ := ioutil.ReadAll(safe)
input.Context.Request.Body.Close()
bf := bytes.NewBuffer(requestbody)