History

sws-test: check W/H

Fixes CID733834 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>

Michael Niedermayer committed 14 years ago

Commit c0f0bec1 parent 2c857271 file · +2 −1Browse files

Unified · Split

libswscale/swscale-test.c+2−1
@@ -316,7 +316,8 @@ static int fileTest(uint8_t *ref[4], int refStride[4], int w, int h, FILE *fp, · 315 unmodified lines
316316 srcFormat = av_get_pix_fmt(srcStr);
317317 dstFormat = av_get_pix_fmt(dstStr);
318318
319− if (srcFormat == AV_PIX_FMT_NONE || dstFormat == AV_PIX_FMT_NONE) {
319+ if (srcFormat == AV_PIX_FMT_NONE || dstFormat == AV_PIX_FMT_NONE ||
320+ srcW > 1024U || srcH > 1024U || dstW > 1024U || dstH > 1024U) {
320321 fprintf(stderr, "malformed input file\n");
321322 return -1;
322323 }

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t