mirror of
https://gitee.com/xia-chu/ZLMediaKit.git
synced 2026-05-06 10:57:50 +08:00
确保断连续推功能开启后流能正常强制关闭 (#4287)
Some checks are pending
Android / build (push) Waiting to run
CodeQL / Analyze (cpp) (push) Waiting to run
CodeQL / Analyze (javascript) (push) Waiting to run
Docker / build (push) Waiting to run
Linux / build (push) Waiting to run
macOS / build (push) Waiting to run
Windows / build (push) Waiting to run
Some checks are pending
Android / build (push) Waiting to run
CodeQL / Analyze (cpp) (push) Waiting to run
CodeQL / Analyze (javascript) (push) Waiting to run
Docker / build (push) Waiting to run
Linux / build (push) Waiting to run
macOS / build (push) Waiting to run
Windows / build (push) Waiting to run
This commit is contained in:
parent
a35444f27e
commit
f0bc7a75aa
@ -513,6 +513,18 @@ EventPoller::Ptr MultiMediaSourceMuxer::getOwnerPoller(MediaSource &sender) {
|
||||
}
|
||||
}
|
||||
|
||||
bool MultiMediaSourceMuxer::close(MediaSource &sender) {
|
||||
_rtmp = nullptr;
|
||||
_rtsp = nullptr;
|
||||
_fmp4 = nullptr;
|
||||
_ts = nullptr;
|
||||
_mp4 = nullptr;
|
||||
_hls = nullptr;
|
||||
_hls_fmp4 = nullptr;
|
||||
_rtp_sender.clear();
|
||||
return true;
|
||||
}
|
||||
|
||||
std::shared_ptr<MultiMediaSourceMuxer> MultiMediaSourceMuxer::getMuxer(MediaSource &sender) const {
|
||||
return const_cast<MultiMediaSourceMuxer*>(this)->shared_from_this();
|
||||
}
|
||||
|
||||
@ -182,6 +182,12 @@ public:
|
||||
*/
|
||||
toolkit::EventPoller::Ptr getOwnerPoller(MediaSource &sender) override;
|
||||
|
||||
/**
|
||||
* 关闭流
|
||||
* @return 是否成功
|
||||
*/
|
||||
bool close(MediaSource &sender) override;
|
||||
|
||||
/**
|
||||
* 获取本对象
|
||||
* Get this object
|
||||
|
||||
Loading…
Reference in New Issue
Block a user