Skip to content

Commit

Permalink
Merge pull request #110 from arnehormann/legacy-fix
Browse files Browse the repository at this point in the history
backport of fix in PR 109
  • Loading branch information
arnehormann committed Jul 11, 2013
2 parents 75bb76e + 1fcee9a commit fdeb568
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions buffer.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@ func (b *buffer) readNext(need int) (p []byte, err error) {
if b.length < need {
// refill
err = b.fill(need) // err deferred
if err == io.EOF && b.length >= need {
err = nil
}
}

p = b.buf[b.idx : b.idx+need]
Expand Down

0 comments on commit fdeb568

Please sign in to comment.