diff options
| author | Joe Tsai <joetsai@digital-static.net> | 2016-10-31 17:34:42 -0700 |
|---|---|---|
| committer | Joe Tsai <thebrokentoaster@gmail.com> | 2016-11-01 05:42:33 +0000 |
| commit | 032d150bd4a812eee9c3ea017f0d3acc8c484325 (patch) | |
| tree | 0b0fe38fb69f32ea68d6de185417ec585b4ae58e /src/net/http/httputil/reverseproxy_test.go | |
| parent | 7a26d9fcedd94a1ba0d95833b0cdbbdcc776fe19 (diff) | |
| download | go-032d150bd4a812eee9c3ea017f0d3acc8c484325.tar.xz | |
encoding/json: marshal with null when RawMessage is nil
This CL expands upon a change made in (http://golang.org/cl/21811)
to ensure that a nil RawMessage gets serialized as "null" instead of
being a nil slice.
The added check only triggers when the RawMessage is nil. We do not
handle the case when the RawMessage is non-nil, but empty.
Fixes #17704
Updates #14493
Change-Id: I0fbebcdd81f7466c5b78c94953afc897f162ceb4
Reviewed-on: https://go-review.googlesource.com/32472
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/net/http/httputil/reverseproxy_test.go')
0 files changed, 0 insertions, 0 deletions
