diff --git a/libavcodec/vorbisenc.c b/libavcodec/vorbisenc.c index 0f78d95ffd..c06093ea99 100644 --- a/libavcodec/vorbisenc.c +++ b/libavcodec/vorbisenc.c @@ -1094,8 +1094,9 @@ static int vorbis_encode_frame(AVCodecContext *avctx, AVPacket *avpkt, if (frame) { if (frame->pts != AV_NOPTS_VALUE) avpkt->pts = ff_samples_to_time_base(avctx, frame->pts); - } else + } else { avpkt->pts = venc->next_pts; + } if (avpkt->pts != AV_NOPTS_VALUE) venc->next_pts = avpkt->pts + avpkt->duration;