[FFmpeg-cvslog] avcodec/utvideoenc: Remove always-false pixel format check
Andreas Rheinhardt
git at videolan.org
Wed May 21 13:47:39 EEST 2025
ffmpeg | branch: master | Andreas Rheinhardt <andreas.rheinhardt at outlook.com> | Sun Oct 3 15:32:18 2021 +0200| [22e6e4e914d2416d76a1d1b8b45775a307c7743e] | committer: Andreas Rheinhardt
avcodec/utvideoenc: Remove always-false pixel format check
Mark it as unreachable instead.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=22e6e4e914d2416d76a1d1b8b45775a307c7743e
---
libavcodec/utvideoenc.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/libavcodec/utvideoenc.c b/libavcodec/utvideoenc.c
index c2b5a8abb7..7cefca79bc 100644
--- a/libavcodec/utvideoenc.c
+++ b/libavcodec/utvideoenc.c
@@ -24,6 +24,7 @@
* Ut Video encoder
*/
+#include "libavutil/avassert.h"
#include "libavutil/imgutils.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/mem.h"
@@ -143,9 +144,7 @@ static av_cold int utvideo_encode_init(AVCodecContext *avctx)
original_format = UTVIDEO_444;
break;
default:
- av_log(avctx, AV_LOG_ERROR, "Unknown pixel format: %d\n",
- avctx->pix_fmt);
- return AVERROR_INVALIDDATA;
+ av_unreachable("Already checked via CODEC_PIXFMTS");
}
ff_bswapdsp_init(&c->bdsp);
More information about the ffmpeg-cvslog
mailing list