Mercurial > hg > toybox
changeset 1078:7b6fbc0475d8 draft
It's not a problem to exactly fill up the buffer with a run if the next symbol is the terminating symbol. Fixes https://jira.cyanogenmod.org/browse/CYAN-1896
author | Rob Landley <rob@landley.net> |
---|---|
date | Sun, 06 Oct 2013 17:35:57 -0500 |
parents | f2e8247a4fd0 |
children | f4f543ff8490 |
files | lib/bunzip.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/lib/bunzip.c Fri Oct 04 14:32:39 2013 -0500 +++ b/lib/bunzip.c Sun Oct 06 17:35:57 2013 -0500 @@ -378,7 +378,7 @@ literal used is the one at the head of the mtfSymbol array.) */ if (runPos) { runPos = 0; - if (dbufCount+hh >= bd->dbufSize) return RETVAL_DATA_ERROR; + if (dbufCount+hh > bd->dbufSize) return RETVAL_DATA_ERROR; uc = bd->symToByte[bd->mtfSymbol[0]]; byteCount[uc] += hh;