Removed check for wrong buffer size.

This commit is contained in:
Armin Novak 2019-10-04 11:46:14 +02:00
parent e09f739b90
commit 74f01aab15
2 changed files with 0 additions and 14 deletions

View File

@ -135,14 +135,6 @@ static BOOL nsc_encode_argb_to_aycocg(NSC_CONTEXT* context, const BYTE* data,
rw = (context->ChromaSubsamplingLevel ? tempWidth : context->width);
ccl = context->ColorLossLevel;
/* Internal buffer must conatin height * width pixels (aligned) */
if (context->priv->PlaneBuffersLength < context->height * rw)
return FALSE;
/* Input stride must contain enough data for width */
if (rw * GetBytesPerPixel(context->format) < scanline)
return FALSE;
for (y = 0; y < context->height; y++)
{
src = data + (context->height - 1 - y) * scanline;

View File

@ -63,12 +63,6 @@ static BOOL nsc_encode_argb_to_aycocg_sse2(NSC_CONTEXT* context,
rw = (context->ChromaSubsamplingLevel > 0 ? tempWidth : context->width);
ccl = context->ColorLossLevel;
if (context->priv->PlaneBuffersLength < rw * scanline)
return FALSE;
if (rw < scanline * 2)
return FALSE;
for (y = 0; y < context->height; y++)
{
src = data + (context->height - 1 - y) * scanline;