Browse Source

rgb24toyv12: break out in the middle before out of array reads.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tags/n0.8
Michael Niedermayer 14 years ago
parent
commit
9a5624a0f1
1 changed files with 3 additions and 0 deletions
  1. +3
    -0
      libswscale/rgb2rgb_template.c

+ 3
- 0
libswscale/rgb2rgb_template.c View File

@@ -2264,6 +2264,9 @@ static inline void RENAME(rgb24toyv12)(const uint8_t *src, uint8_t *ydst, uint8_
ydst += lumStride;
src += srcStride;

if(y+1 == height)
break;

for (i=0; i<chromWidth; i++) {
unsigned int b = src[6*i+0];
unsigned int g = src[6*i+1];


Loading…
Cancel
Save