diff options
author | Ewald Snel <esnel@users.sourceforge.net> | 2002-04-29 10:31:45 +0000 |
---|---|---|
committer | Ewald Snel <esnel@users.sourceforge.net> | 2002-04-29 10:31:45 +0000 |
commit | 95106bbf0c22cc6d4aa0cbbc5ddc313fd15fd5bc (patch) | |
tree | 8d3be53aa44b09d89dcbfeb19563e884d8f2adb3 | |
parent | c38f39733dc1082cadf12f4296933adbcf2b7931 (diff) | |
download | xine-lib-95106bbf0c22cc6d4aa0cbbc5ddc313fd15fd5bc.tar.gz xine-lib-95106bbf0c22cc6d4aa0cbbc5ddc313fd15fd5bc.tar.bz2 |
Small cinepak fixes
CVS patchset: 1806
CVS date: 2002/04/29 10:31:45
-rw-r--r-- | src/libcinepak/xine_decoder.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/libcinepak/xine_decoder.c b/src/libcinepak/xine_decoder.c index 0bf774f73..78147ca22 100644 --- a/src/libcinepak/xine_decoder.c +++ b/src/libcinepak/xine_decoder.c @@ -136,7 +136,7 @@ static void cinepak_decode_vectors (cvid_frame_t *frame, cvid_strip_t *strip, for (x=strip->x1; x < strip->x2; x+=4) { if ((chunk_id & 0x0100) && !(mask >>= 1)) { if ((data + 4) > eod) - break; + return; flag = (data[0] << 24) | (data[1] << 16) | (data[2] << 8) | data[3]; data += 4; @@ -146,7 +146,7 @@ static void cinepak_decode_vectors (cvid_frame_t *frame, cvid_strip_t *strip, if (!(chunk_id & 0x0100) || (flag & mask)) { if (!(chunk_id & 0x0200) && !(mask >>= 1)) { if ((data + 4) > eod) - break; + return; flag = (data[0] << 24) | (data[1] << 16) | (data[2] << 8) | data[3]; data += 4; @@ -155,7 +155,7 @@ static void cinepak_decode_vectors (cvid_frame_t *frame, cvid_strip_t *strip, if ((chunk_id & 0x0200) || (~flag & mask)) { if (data >= eod) - break; + return; codebook = &strip->v1_codebook[*data++]; iy[0][0] = codebook->y0; iy[0][1] = codebook->y0; @@ -176,7 +176,7 @@ static void cinepak_decode_vectors (cvid_frame_t *frame, cvid_strip_t *strip, } else if (flag & mask) { if ((data + 4) > eod) - break; + return; codebook = &strip->v4_codebook[*data++]; iy[0][0] = codebook->y0; iy[0][1] = codebook->y1; @@ -442,8 +442,6 @@ static void cvid_reset (video_decoder_t *this_gen) { cvid_decoder_t *this = (cvid_decoder_t *) this_gen; - cinepak_reset (&this->frame); - this->size = 0; } |