Commit 18c54e21 authored by benoit's avatar benoit

Make sure strides have positive values before converting.

Patch by Peter Schlaile: peter schlaile de


git-svn-id: file:///var/local/repositories/mplayer/trunk/libswscale@25467 b3059339-0415-0410-9bf9-f77b7e298cf2
parent cd0f28d5
...@@ -1681,7 +1681,7 @@ static int rgb2rgbWrapper(SwsContext *c, uint8_t* src[], int srcStride[], int sr ...@@ -1681,7 +1681,7 @@ static int rgb2rgbWrapper(SwsContext *c, uint8_t* src[], int srcStride[], int sr
if(conv) if(conv)
{ {
if (dstStride[0]*srcBpp == srcStride[0]*dstBpp) if (dstStride[0]*srcBpp == srcStride[0]*dstBpp && srcStride[0] > 0)
conv(src[0], dst[0] + dstStride[0]*srcSliceY, srcSliceH*srcStride[0]); conv(src[0], dst[0] + dstStride[0]*srcSliceY, srcSliceH*srcStride[0]);
else else
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment