Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1282)

Issue 13512045: code review 13512045: go.text/encoding: fix off-by-one error in some decoders... (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
10 years, 6 months ago by nigeltao
Modified:
10 years, 6 months ago
Reviewers:
r
CC:
r, golang-dev
Visibility:
Public.

Description

go.text/encoding: fix off-by-one error in some decoders returning ErrShortDst even when there is sufficient dst space. In theory, a transform.Transformer is allowed to return fewer dst bytes than maximal, but in practice, we shouldn't be wasteful.

Patch Set 1 #

Patch Set 2 : diff -r 3dcc127b5785 https://code.google.com/p/go.text #

Patch Set 3 : diff -r 3dcc127b5785 https://code.google.com/p/go.text #

Patch Set 4 : diff -r 3dcc127b5785 https://code.google.com/p/go.text #

Unified diffs Side-by-side diffs Delta from patch set Stats (+10 lines, -5 lines) Patch
M encoding/encoding_test.go View 1 1 chunk +7 lines, -2 lines 0 comments Download
M encoding/japanese/eucjp.go View 1 1 chunk +1 line, -1 line 0 comments Download
M encoding/japanese/shiftjis.go View 1 1 chunk +1 line, -1 line 0 comments Download
M encoding/simplifiedchinese/gbk.go View 1 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 3
nigeltao
Hello r@golang.org (cc: golang-dev@googlegroups.com), I'd like you to review this change to https://code.google.com/p/go.text
10 years, 6 months ago (2013-09-05 01:23:58 UTC) #1
r
LGTM
10 years, 6 months ago (2013-09-05 01:55:39 UTC) #2
nigeltao
10 years, 6 months ago (2013-09-05 02:42:28 UTC) #3
*** Submitted as
https://code.google.com/p/go/source/detail?r=2cad1b12da48&repo=text ***

go.text/encoding: fix off-by-one error in some decoders returning
ErrShortDst even when there is sufficient dst space.

In theory, a transform.Transformer is allowed to return fewer dst bytes
than maximal, but in practice, we shouldn't be wasteful.

R=r
CC=golang-dev
https://codereview.appspot.com/13512045
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b