mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-21 10:55:51 +02:00
avoid strcmp NULL, fix segv on mingw
Originally committed as revision 18502 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
1894e741f5
commit
de481d7fed
@ -494,7 +494,7 @@ static enum PixelFormat avcodec_get_pix_fmt_internal(const char *name)
|
||||
int i;
|
||||
|
||||
for (i=0; i < PIX_FMT_NB; i++)
|
||||
if (!strcmp(pix_fmt_info[i].name, name))
|
||||
if (pix_fmt_info[i].name && !strcmp(pix_fmt_info[i].name, name))
|
||||
return i;
|
||||
return PIX_FMT_NONE;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user