使用临时变量和std::move减少智能指针的拷贝构造

This commit is contained in:
xiongziliang
2020-10-10 18:23:25 +08:00
parent 83a24a5863
commit dfaa8b540c
12 changed files with 31 additions and 30 deletions

View File

@@ -113,7 +113,7 @@ void PSRtpSender::onRtp(const RtpPacket::Ptr &rtp, bool) {
}
//此函数在其他线程执行
void PSRtpSender::onFlush(shared_ptr<List<RtpPacket::Ptr>> &rtp_list, bool) {
void PSRtpSender::onFlush(shared_ptr<List<RtpPacket::Ptr> > rtp_list, bool) {
if(!_is_connect){
//连接成功后才能发送数据
return;