Commit 4f8a000e authored by Timo Savola's avatar Timo Savola Committed by Russ Cox

websocket: fix binary frame size decoding

R=ukai, rsc
CC=golang-dev
https://golang.org/cl/166074
parent 0e2e066c
......@@ -64,9 +64,8 @@ func (ws *Conn) Read(msg []byte) (n int, err os.Error) {
if err != nil {
return n, err
}
if (c & 0x80) == 0x80 {
length = length*128 + int(c&0x7f)
} else {
if (c & 0x80) == 0 {
break
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment