History

avcodec/vc2enc: Remove superfluous error message

ff_get_encode_buffer() already emits an error message of its own. While just at it, also check for ret < 0 instead of just ret != 0.

Andreas Rheinhardt committed 2 years ago

Commit eac8dcb1 parent b1702af1 file · +1 −3Browse files

Unified · Split

libavcodec/vc2enc.c+1−3
@@ -918,10 +918,8 @@ static int encode_frame(VC2EncContext *s, AVPacket *avpkt, const AVFrame *frame, · 917 unmodified lines
918918 if (field < 2) {
919919 ret = ff_get_encode_buffer(s->avctx, avpkt,
920920 max_frame_bytes << s->interlaced, 0);
921− if (ret) {
922− av_log(s->avctx, AV_LOG_ERROR, "Error getting output packet.\n");
921+ if (ret < 0)
923922 return ret;
924− }
925923 init_put_bits(&s->pb, avpkt->data, avpkt->size);
926924 }
927925

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t