From: Moritz Hanke Date: Tue, 9 Sep 2014 14:25:12 +0000 (+0200) Subject: removes "int32_t xmin" from FLUSH X-Git-Tag: accepted/tizen/5.0/unified/20181102.025501~51 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=19f3f8e7c222a52bd6448f6d18ce91ecc3f05fb4;p=platform%2Fupstream%2Flibaec.git removes "int32_t xmin" from FLUSH --- diff --git a/src/decode.c b/src/decode.c index 526a643..099fc44 100644 --- a/src/decode.c +++ b/src/decode.c @@ -117,9 +117,8 @@ \ } else { \ \ - int32_t xmax, xmin, d; \ + int32_t xmax, d; \ data = state->last_out; \ - xmin = state->xmin; \ xmax = state->xmax; \ \ for (bp = state->flush_start; bp < flush_end; bp++) { \ @@ -127,10 +126,10 @@ half_d = ((uint32_t)d >> 1) + (d & 1); \ \ if (data < 0) { \ - if (half_d <= data - xmin) { \ + if (half_d <= xmax + data + 1) { \ data += ((uint32_t)d >> 1)^(~((d & 1) - 1)); \ } else { \ - data = xmin + d; \ + data = d - xmax - 1; \ } \ } else { \ if (half_d <= xmax - data) { \