Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(254)

Unified Diff: webrtc/api/peerconnection.cc

Issue 2019423006: Adding more detail to MessageQueue::Dispatch logging. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/api/peerconnection.cc
diff --git a/webrtc/api/peerconnection.cc b/webrtc/api/peerconnection.cc
index 5284db37fd7675bb65c01af4417f8a20b66783e3..048f26b1e1dc2d5c3138ab0ea7416d54c2632da3 100644
--- a/webrtc/api/peerconnection.cc
+++ b/webrtc/api/peerconnection.cc
@@ -560,7 +560,8 @@ PeerConnection::~PeerConnection() {
// which will trigger some final actions in PeerConnection...
session_.reset(nullptr);
// port_allocator_ lives on the worker thread and should be destroyed there.
- worker_thread()->Invoke<void>([this] { port_allocator_.reset(nullptr); });
+ worker_thread()->Invoke<void>(FROM_HERE,
+ [this] { port_allocator_.reset(nullptr); });
}
bool PeerConnection::Initialize(
@@ -579,8 +580,9 @@ bool PeerConnection::Initialize(
// The port allocator lives on the worker thread and should be initialized
// there.
- if (!worker_thread()->Invoke<bool>(rtc::Bind(
- &PeerConnection::InitializePortAllocator_w, this, configuration))) {
+ if (!worker_thread()->Invoke<bool>(
+ FROM_HERE, rtc::Bind(&PeerConnection::InitializePortAllocator_w, this,
+ configuration))) {
return false;
}
@@ -821,7 +823,7 @@ bool PeerConnection::GetStats(StatsObserver* observer,
}
stats_->UpdateStats(level);
- signaling_thread()->Post(this, MSG_GETSTATS,
+ signaling_thread()->Post(FROM_HERE, this, MSG_GETSTATS,
new GetStatsMsg(observer, track));
return true;
}
@@ -1050,7 +1052,8 @@ void PeerConnection::SetLocalDescription(
}
SetSessionDescriptionMsg* msg = new SetSessionDescriptionMsg(observer);
- signaling_thread()->Post(this, MSG_SET_SESSIONDESCRIPTION_SUCCESS, msg);
+ signaling_thread()->Post(FROM_HERE, this, MSG_SET_SESSIONDESCRIPTION_SUCCESS,
+ msg);
// MaybeStartGathering needs to be called after posting
// MSG_SET_SESSIONDESCRIPTION_SUCCESS, so that we don't signal any candidates
@@ -1157,15 +1160,16 @@ void PeerConnection::SetRemoteDescription(
UpdateEndedRemoteMediaStreams();
SetSessionDescriptionMsg* msg = new SetSessionDescriptionMsg(observer);
- signaling_thread()->Post(this, MSG_SET_SESSIONDESCRIPTION_SUCCESS, msg);
+ signaling_thread()->Post(FROM_HERE, this, MSG_SET_SESSIONDESCRIPTION_SUCCESS,
+ msg);
}
bool PeerConnection::SetConfiguration(const RTCConfiguration& configuration) {
TRACE_EVENT0("webrtc", "PeerConnection::SetConfiguration");
if (port_allocator_) {
if (!worker_thread()->Invoke<bool>(
- rtc::Bind(&PeerConnection::ReconfigurePortAllocator_w, this,
- configuration))) {
+ FROM_HERE, rtc::Bind(&PeerConnection::ReconfigurePortAllocator_w,
+ this, configuration))) {
return false;
}
}
@@ -1472,7 +1476,8 @@ void PeerConnection::PostSetSessionDescriptionFailure(
const std::string& error) {
SetSessionDescriptionMsg* msg = new SetSessionDescriptionMsg(observer);
msg->error = error;
- signaling_thread()->Post(this, MSG_SET_SESSIONDESCRIPTION_FAILED, msg);
+ signaling_thread()->Post(FROM_HERE, this, MSG_SET_SESSIONDESCRIPTION_FAILED,
+ msg);
}
void PeerConnection::PostCreateSessionDescriptionFailure(
@@ -1480,7 +1485,8 @@ void PeerConnection::PostCreateSessionDescriptionFailure(
const std::string& error) {
CreateSessionDescriptionMsg* msg = new CreateSessionDescriptionMsg(observer);
msg->error = error;
- signaling_thread()->Post(this, MSG_CREATE_SESSIONDESCRIPTION_FAILED, msg);
+ signaling_thread()->Post(FROM_HERE, this,
+ MSG_CREATE_SESSIONDESCRIPTION_FAILED, msg);
}
bool PeerConnection::GetOptionsForOffer(
@@ -1972,7 +1978,7 @@ void PeerConnection::OnSctpDataChannelClosed(DataChannel* channel) {
// we can't free it directly here; we need to free it asynchronously.
sctp_data_channels_to_free_.push_back(*it);
sctp_data_channels_.erase(it);
- signaling_thread()->Post(this, MSG_FREE_DATACHANNELS, nullptr);
+ signaling_thread()->Post(FROM_HERE, this, MSG_FREE_DATACHANNELS, nullptr);
return;
}
}

Powered by Google App Engine
This is Rietveld 408576698