From 291969aee6a262dfa542b76ebdbdfebef3bb3ed1 Mon Sep 17 00:00:00 2001 From: xiongziliang <771730766@qq.com> Date: Fri, 27 Dec 2019 15:36:54 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=96=87=E4=BB=B6=E5=86=99?= =?UTF-8?q?=E7=BC=93=E5=AD=98=E6=8F=90=E5=89=8D=E9=94=80=E6=AF=81=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98:#196?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Record/HlsMakerImp.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Record/HlsMakerImp.cpp b/src/Record/HlsMakerImp.cpp index cfb76e17..cfb42ed6 100644 --- a/src/Record/HlsMakerImp.cpp +++ b/src/Record/HlsMakerImp.cpp @@ -103,7 +103,8 @@ void HlsMakerImp::onWriteHls(const char *data, int len) { std::shared_ptr HlsMakerImp::makeFile(const string &file,bool setbuf) { - auto ret= shared_ptr(File::createfile_file(file.data(), "wb"), [](FILE *fp) { + auto file_buf = _file_buf; + auto ret= shared_ptr(File::createfile_file(file.data(), "wb"), [file_buf](FILE *fp) { if (fp) { fclose(fp); }