| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/renderer/media/rtc_peer_connection_handler.h" | 5 #include "content/renderer/media/rtc_peer_connection_handler.h" |
| 6 | 6 |
| 7 #include <string.h> | 7 #include <string.h> |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 992 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1003 } | 1003 } |
| 1004 | 1004 |
| 1005 RTCPeerConnectionHandler::~RTCPeerConnectionHandler() { | 1005 RTCPeerConnectionHandler::~RTCPeerConnectionHandler() { |
| 1006 DCHECK(thread_checker_.CalledOnValidThread()); | 1006 DCHECK(thread_checker_.CalledOnValidThread()); |
| 1007 | 1007 |
| 1008 stop(); | 1008 stop(); |
| 1009 | 1009 |
| 1010 g_peer_connection_handlers.Get().erase(this); | 1010 g_peer_connection_handlers.Get().erase(this); |
| 1011 if (peer_connection_tracker_) | 1011 if (peer_connection_tracker_) |
| 1012 peer_connection_tracker_->UnregisterPeerConnection(this); | 1012 peer_connection_tracker_->UnregisterPeerConnection(this); |
| 1013 STLDeleteValues(&remote_streams_); | 1013 base::STLDeleteValues(&remote_streams_); |
| 1014 | 1014 |
| 1015 UMA_HISTOGRAM_COUNTS_10000( | 1015 UMA_HISTOGRAM_COUNTS_10000( |
| 1016 "WebRTC.NumDataChannelsPerPeerConnection", num_data_channels_created_); | 1016 "WebRTC.NumDataChannelsPerPeerConnection", num_data_channels_created_); |
| 1017 } | 1017 } |
| 1018 | 1018 |
| 1019 // static | 1019 // static |
| 1020 void RTCPeerConnectionHandler::DestructAllHandlers() { | 1020 void RTCPeerConnectionHandler::DestructAllHandlers() { |
| 1021 // Copy g_peer_connection_handlers since releasePeerConnectionHandler will | 1021 // Copy g_peer_connection_handlers since releasePeerConnectionHandler will |
| 1022 // remove an item. | 1022 // remove an item. |
| 1023 std::set<RTCPeerConnectionHandler*> handlers( | 1023 std::set<RTCPeerConnectionHandler*> handlers( |
| (...skipping 870 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1894 } | 1894 } |
| 1895 | 1895 |
| 1896 void RTCPeerConnectionHandler::ResetUMAStats() { | 1896 void RTCPeerConnectionHandler::ResetUMAStats() { |
| 1897 DCHECK(thread_checker_.CalledOnValidThread()); | 1897 DCHECK(thread_checker_.CalledOnValidThread()); |
| 1898 num_local_candidates_ipv6_ = 0; | 1898 num_local_candidates_ipv6_ = 0; |
| 1899 num_local_candidates_ipv4_ = 0; | 1899 num_local_candidates_ipv4_ = 0; |
| 1900 ice_connection_checking_start_ = base::TimeTicks(); | 1900 ice_connection_checking_start_ = base::TimeTicks(); |
| 1901 memset(ice_state_seen_, 0, sizeof(ice_state_seen_)); | 1901 memset(ice_state_seen_, 0, sizeof(ice_state_seen_)); |
| 1902 } | 1902 } |
| 1903 } // namespace content | 1903 } // namespace content |
| OLD | NEW |