mirror of
https://github.com/golang/go
synced 2024-11-25 12:27:57 -07:00
image/jpeg: fix typos
Fixes #665. R=nigeltao, nigeltao_golang CC=golang-dev https://golang.org/cl/570041
This commit is contained in:
parent
72a3f5329d
commit
926f59ba14
@ -375,7 +375,7 @@ func Decode(r io.Reader) (image.Image, os.Error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Check for the Start Of Image marker.
|
// Check for the Start Of Image marker.
|
||||||
_, err := io.ReadFull(r, d.tmp[0:2])
|
_, err := io.ReadFull(d.r, d.tmp[0:2])
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -385,7 +385,7 @@ func Decode(r io.Reader) (image.Image, os.Error) {
|
|||||||
|
|
||||||
// Process the remaining segments until the End Of Image marker.
|
// Process the remaining segments until the End Of Image marker.
|
||||||
for {
|
for {
|
||||||
_, err := io.ReadFull(r, d.tmp[0:2])
|
_, err := io.ReadFull(d.r, d.tmp[0:2])
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -399,7 +399,7 @@ func Decode(r io.Reader) (image.Image, os.Error) {
|
|||||||
|
|
||||||
// Read the 16-bit length of the segment. The value includes the 2 bytes for the
|
// Read the 16-bit length of the segment. The value includes the 2 bytes for the
|
||||||
// length itself, so we subtract 2 to get the number of remaining bytes.
|
// length itself, so we subtract 2 to get the number of remaining bytes.
|
||||||
_, err = io.ReadFull(r, d.tmp[0:2])
|
_, err = io.ReadFull(d.r, d.tmp[0:2])
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user