mirror of
https://github.com/mollyim/webrtc.git
synced 2025-05-12 21:30:45 +01:00
Log more info when select fails
This commit is contained in:
parent
8ee5fc9619
commit
84db3b7d55
2 changed files with 10 additions and 2 deletions
|
@ -1448,6 +1448,8 @@ bool PhysicalSocketServer::WaitSelect(int cmsWait, bool process_io) {
|
|||
if (n < 0) {
|
||||
if (errno != EINTR) {
|
||||
RTC_LOG_E(LS_ERROR, EN, errno) << "select";
|
||||
// RingRTC change to log more information around select failures.
|
||||
RTC_LOG(LS_ERROR) << "select failed: fdmax=" << fdmax << ", cmsWait=" << cmsWait;
|
||||
return false;
|
||||
}
|
||||
// Else ignore the error and keep going. If this EINTR was for one of the
|
||||
|
|
|
@ -846,8 +846,14 @@ bool Thread::ProcessMessages(int cmsLoop) {
|
|||
ScopedAutoReleasePool pool;
|
||||
#endif
|
||||
absl::AnyInvocable<void()&&> task = Get(cmsNext);
|
||||
if (!task)
|
||||
return !IsQuitting();
|
||||
// RingRTC change to log more information around select failures.
|
||||
if (!task) {
|
||||
bool isQuitting = IsQuitting();
|
||||
if (!isQuitting) {
|
||||
RTC_LOG(LS_ERROR) << name_ << " will stop processing messages. cmsNext=" << cmsNext;
|
||||
}
|
||||
return !isQuitting;
|
||||
}
|
||||
Dispatch(std::move(task));
|
||||
|
||||
if (cmsLoop != kForever) {
|
||||
|
|
Loading…
Reference in a new issue