Commit 46db10ed authored by Stefano Sabatini's avatar Stefano Sabatini
Browse files

Optimize / simplify avcodec_get_pix_fmt_name() check.

Originally committed as revision 25689 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent a5f27f6d
......@@ -419,7 +419,7 @@ void avcodec_get_chroma_sub_sample(enum PixelFormat pix_fmt, int *h_shift, int *
const char *avcodec_get_pix_fmt_name(enum PixelFormat pix_fmt)
{
if (pix_fmt < 0 || pix_fmt >= PIX_FMT_NB)
if ((unsigned)pix_fmt >= PIX_FMT_NB)
return NULL;
else
return av_pix_fmt_descriptors[pix_fmt].name;
......
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