From 3d377e8bca827121882d52af5badcbb4140fba5b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B5=AE=E7=94=9F=E8=8B=A5=E6=A2=A6?= <1070753498@qq.com> Date: Mon, 4 Sep 2023 20:08:41 +0800 Subject: [PATCH] =?UTF-8?q?truncate=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ffmpeg/audioframeconverter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ffmpeg/audioframeconverter.cpp b/ffmpeg/audioframeconverter.cpp index 5421696..034684b 100644 --- a/ffmpeg/audioframeconverter.cpp +++ b/ffmpeg/audioframeconverter.cpp @@ -172,7 +172,7 @@ auto AudioFrameConverter::convert(Frame *frame) -> QByteArray qWarning() << "audio buffer is probably too small"; } size = len * d_ptr->format.channelCount() * av_get_bytes_per_sample(d_ptr->avSampleFormat); - data.resize(size); + data.truncate(size); return data; }