]> Cypherpunks repositories - gostls13.git/commit
mime/multipart: Allow ReadForm to process large non-file parts
authorSteven Hartland <steven.hartland@multiplay.co.uk>
Thu, 16 Mar 2017 12:08:35 +0000 (12:08 +0000)
committerBrad Fitzpatrick <bradfitz@golang.org>
Mon, 22 May 2017 14:54:00 +0000 (14:54 +0000)
commitd79ec64fe107c0566ac38ad62dcae45c3fbe07fb
tree46fff8c07a4ce3df592198dc89565887c30a619f
parent6a6c792eef55eded7fb3165a330ec2b239b83960
mime/multipart: Allow ReadForm to process large non-file parts

Allow the memory limit passed into ReadForm to be used as the
memory limit for processing non-file form data as well as file
form data, rather than the existing behaviour of the memory limit
only applying to the file parts and the non-file parts being
arbitrarily limited to 10MB.

This ensures backwards compatibility while still providing the
user with control over the amount of non-file data that can be
processed instead of enforcing an arbitrary 10MB limit.

Change-Id: I53c09eae00147d3ff2d6bdfd4e50949267932c3d
Reviewed-on: https://go-review.googlesource.com/38195
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/mime/multipart/formdata.go
src/mime/multipart/formdata_test.go