mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-06-19 23:02:21 +08:00
直接打印SockException类
This commit is contained in:
@@ -266,7 +266,7 @@ void MultiMediaSourceMuxer::startSendRtp(MediaSource &sender, const MediaSourceE
|
||||
if (auto strong_self = weak_self.lock()) {
|
||||
// 可能归属线程发生变更
|
||||
strong_self->getOwnerPoller(MediaSource::NullMediaSource())->async([=]() {
|
||||
WarnL << "stream:" << strong_self->shortUrl() << " stop send rtp:" << ssrc << ", reason:" << ex.what();
|
||||
WarnL << "stream:" << strong_self->shortUrl() << " stop send rtp:" << ssrc << ", reason:" << ex;
|
||||
strong_self->_rtp_sender.erase(ssrc);
|
||||
NoticeCenter::Instance().emitEvent(Broadcast::kBroadcastSendRtpStopped, *strong_self, ssrc, ex);
|
||||
});
|
||||
|
||||
@@ -118,7 +118,7 @@ void HlsPlayer::fetchSegment() {
|
||||
return;
|
||||
}
|
||||
if (err) {
|
||||
WarnL << "Download ts segment " << url << " failed:" << err.what();
|
||||
WarnL << "Download ts segment " << url << " failed:" << err;
|
||||
if (err.getErrCode() == Err_timeout) {
|
||||
strong_self->_timeout_multiple = MAX(strong_self->_timeout_multiple + 1, MAX_TIMEOUT_MULTIPLE);
|
||||
}else{
|
||||
|
||||
@@ -101,7 +101,7 @@ void HttpSession::onError(const SockException& err) {
|
||||
uint64_t duration = _ticker.createdTime() / 1000;
|
||||
WarnP(this) << "FLV/TS/FMP4播放器("
|
||||
<< _mediaInfo.shortUrl()
|
||||
<< ")断开:" << err.what()
|
||||
<< ")断开:" << err
|
||||
<< ",耗时(s):" << duration;
|
||||
|
||||
GET_CONFIG(uint32_t, iFlowThreshold, General::kFlowThreshold);
|
||||
@@ -111,9 +111,6 @@ void HttpSession::onError(const SockException& err) {
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
//http客户端
|
||||
TraceP(this) << err.what();
|
||||
}
|
||||
|
||||
void HttpSession::onManager() {
|
||||
|
||||
@@ -101,7 +101,7 @@ void RtmpPlayer::onPlayResult_l(const SockException &ex, bool handshake_done) {
|
||||
return;
|
||||
}
|
||||
|
||||
WarnL << ex.getErrCode() << " " << ex.what();
|
||||
WarnL << ex.getErrCode() << " " << ex;
|
||||
if (!handshake_done) {
|
||||
//开始播放阶段
|
||||
_play_timer.reset();
|
||||
|
||||
@@ -336,7 +336,7 @@ void RtpSender::onFlushRtpList(shared_ptr<List<Buffer::Ptr> > rtp_list) {
|
||||
|
||||
void RtpSender::onErr(const SockException &ex) {
|
||||
_is_connect = false;
|
||||
WarnL << "send rtp connection lost: " << ex.what();
|
||||
WarnL << "send rtp connection lost: " << ex;
|
||||
onClose(ex);
|
||||
}
|
||||
|
||||
|
||||
@@ -260,7 +260,7 @@ void RtpServer::connectToServer(const std::string &url, uint16_t port, const fun
|
||||
return;
|
||||
}
|
||||
if (err) {
|
||||
WarnL << "连接到服务器 " << url << ":" << port << " 失败 " << err.what();
|
||||
WarnL << "连接到服务器 " << url << ":" << port << " 失败 " << err;
|
||||
} else {
|
||||
InfoL << "连接到服务器 " << url << ":" << port << " 成功";
|
||||
strong_self->onConnect();
|
||||
|
||||
@@ -60,7 +60,7 @@ void RtpSession::onRecv(const Buffer::Ptr &data) {
|
||||
}
|
||||
|
||||
void RtpSession::onError(const SockException &err) {
|
||||
WarnP(this) << _stream_id << " " << err.what();
|
||||
WarnP(this) << _stream_id << " " << err;
|
||||
}
|
||||
|
||||
void RtpSession::onManager() {
|
||||
|
||||
@@ -57,7 +57,7 @@ void ShellSession::onRecv(const Buffer::Ptr&buf) {
|
||||
}
|
||||
|
||||
void ShellSession::onError(const SockException &err){
|
||||
WarnP(this) << err.what();
|
||||
WarnP(this) << err;
|
||||
}
|
||||
|
||||
void ShellSession::onManager() {
|
||||
|
||||
Reference in New Issue
Block a user