mirror of
https://github.com/golang/go
synced 2024-11-22 04:14:42 -07:00
netchan: zero out request to ensure correct gob decoding.
Gob decoding does not overwrite fields which are zero in the encoder. Fixes #1174. R=r, r2 CC=golang-dev https://golang.org/cl/2337044
This commit is contained in:
parent
3d0726b04d
commit
17c9c01912
@ -107,6 +107,7 @@ func (client *expClient) run() {
|
||||
}
|
||||
switch hdr.payloadType {
|
||||
case payRequest:
|
||||
*req = request{}
|
||||
if err := client.decode(reqValue); err != nil {
|
||||
expLog("error decoding client request:", err)
|
||||
break
|
||||
|
Loading…
Reference in New Issue
Block a user