Message ID | 71cb00a8-ffea-fe3d-211b-bae983fea4ed@gmail.com |
---|---|
State | New |
Headers | show |
On Wed, 30 Oct 2019, Alfred E. Heggestad wrote: > This does not change the programs behaviour. > The purpose of this patch is to make the code more > robust against future changes, in case someone > starts using the AV_PIX_FMT_NONE entry. PIX_FMT_NONE signals the end of the array, whatever it maps to is irrelevent. I'd rather keep code as is. Regards, Marton
diff --git a/libavdevice/sdl2.c b/libavdevice/sdl2.c index d6fc74a66c..4eafde10de 100644 --- a/libavdevice/sdl2.c +++ b/libavdevice/sdl2.c @@ -91,7 +91,7 @@ static const struct sdl_texture_format_entry { { AV_PIX_FMT_YUV420P, SDL_PIXELFORMAT_IYUV }, { AV_PIX_FMT_YUYV422, SDL_PIXELFORMAT_YUY2 }, { AV_PIX_FMT_UYVY422, SDL_PIXELFORMAT_UYVY }, - { AV_PIX_FMT_NONE, 0 }, + { AV_PIX_FMT_NONE, SDL_PIXELFORMAT_UNKNOWN }, }; static void compute_texture_rect(AVFormatContext *s)