diff options
author | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2022-08-23 21:16:00 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2022-08-27 02:23:43 +0200 |
commit | 52dcf0e0f56b4a696ba134221c03facdc166c7fc (patch) | |
tree | 7e6bc860d7d6ecdf01b666afa581acd407d68812 /libavcodec/encode.c | |
parent | 1e6307f46c486d17f670043672d49335ea1bae97 (diff) | |
download | ffmpeg-52dcf0e0f56b4a696ba134221c03facdc166c7fc.tar.gz |
avcodec/encode: Remove redundant check
frame is always set at this point for no-delay encoders.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavcodec/encode.c')
-rw-r--r-- | libavcodec/encode.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/encode.c b/libavcodec/encode.c index f7b13c8ba1..f66e2f9ba8 100644 --- a/libavcodec/encode.c +++ b/libavcodec/encode.c @@ -194,7 +194,7 @@ int ff_encode_encode_cb(AVCodecContext *avctx, AVPacket *avpkt, if (avctx->codec->type == AVMEDIA_TYPE_VIDEO && !(avctx->codec->capabilities & AV_CODEC_CAP_DELAY)) avpkt->pts = avpkt->dts = frame->pts; - if (frame && !(avctx->codec->capabilities & AV_CODEC_CAP_DELAY)) { + if (!(avctx->codec->capabilities & AV_CODEC_CAP_DELAY)) { if (avctx->codec->type == AVMEDIA_TYPE_AUDIO) { if (avpkt->pts == AV_NOPTS_VALUE) avpkt->pts = frame->pts; |