]> Cypherpunks repositories - gostls13.git/commitdiff
typos
authorRuss Cox <rsc@golang.org>
Sat, 14 Nov 2009 18:28:53 +0000 (10:28 -0800)
committerRuss Cox <rsc@golang.org>
Sat, 14 Nov 2009 18:28:53 +0000 (10:28 -0800)
Fixes #171.
Fixes #172.

R=agl1
https://golang.org/cl/154136

src/pkg/crypto/subtle/constant_time.go
src/pkg/encoding/binary/binary_test.go

index edbfa84fb2bb5c3dd06fd3a2e844f95c675c82ae..79a96ec9636f4457480c206cc168fdbd05e88d5a 100644 (file)
@@ -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;
index 078a13a5305be2191bbf94624fe6b89bad0d8ab6..71c6875cc96bf26306a630ba4e808a75e5747cbb 100644 (file)
@@ -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)
        }
 }