Commit 933d1850 authored by Russ Cox's avatar Russ Cox

typos

Fixes #171.
Fixes #172.

R=agl1
https://golang.org/cl/154136
parent aebae257
......@@ -23,7 +23,7 @@ func ConstantTimeCompare(x, y []byte) int {
// Its behavior is undefined if v takes any other value.
func ConstantTimeSelect(v, x, y int) int { return ^(v-1)&x | (v-1)&y }
// ConstantTimeByteEq returns 1 if x == x and 0 otherwise.
// ConstantTimeByteEq returns 1 if x == y and 0 otherwise.
func ConstantTimeByteEq(x, y uint8) int {
z := ^(x ^ y);
z &= z >> 4;
......
......@@ -81,6 +81,6 @@ little:
t.Errorf("Read little-endian: %v", err)
}
if !reflect.DeepEqual(sl, s) {
t.Errorf("Read big-endian:\n\thave %+v\n\twant %+v", sl, s)
t.Errorf("Read little-endian:\n\thave %+v\n\twant %+v", sl, s)
}
}
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