Refactor checks to use a copy of the new logging backend.

As a bonus, this shrinks the android release version of libjingle_peerconnection_so.so by ~25k in local tests.

We could try to unify the backend with the logging one, but that turns out to be surprisingly tricky due to dependency loops and chromium overrides.

Bug: webrtc:8982
Change-Id: I66854dd333f568d9b2a5f46bbead14b2e31179be
Reviewed-on: https://webrtc-review.googlesource.com/79623
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Jonas Olsson <jonasolsson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23634}
This commit is contained in:
Jonas Olsson
2018-06-14 13:14:22 +02:00
committed by Commit Bot
parent 6a9bd74481
commit f8e5c110ee
5 changed files with 292 additions and 108 deletions

View File

@ -305,8 +305,7 @@ void PeerConnectionObserverJni::OnRemoveStream(
rtc::scoped_refptr<MediaStreamInterface> stream) {
JNIEnv* env = AttachCurrentThreadIfNeeded();
NativeToJavaStreamsMap::iterator it = remote_streams_.find(stream);
RTC_CHECK(it != remote_streams_.end())
<< "unexpected stream: " << std::hex << stream;
RTC_CHECK(it != remote_streams_.end()) << "unexpected stream: " << stream;
Java_Observer_onRemoveStream(env, j_observer_global_,
it->second.j_media_stream());
remote_streams_.erase(it);