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

Side by Side Diff: webrtc/p2p/base/port.cc

Issue 1363573002: Wire up transport sequence number / send time callbacks to webrtc via libjingle. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Cleanups. Created 5 years, 2 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 294 matching lines...) Expand 10 before | Expand all | Expand 10 after
305 // because we then get back responses for them, which this code correctly 305 // because we then get back responses for them, which this code correctly
306 // does not handle. 306 // does not handle.
307 if (msg->type() != STUN_BINDING_RESPONSE) { 307 if (msg->type() != STUN_BINDING_RESPONSE) {
308 LOG_J(LS_ERROR, this) << "Received unexpected STUN message type (" 308 LOG_J(LS_ERROR, this) << "Received unexpected STUN message type ("
309 << msg->type() << ") from unknown address (" 309 << msg->type() << ") from unknown address ("
310 << addr.ToSensitiveString() << ")"; 310 << addr.ToSensitiveString() << ")";
311 } 311 }
312 } 312 }
313 } 313 }
314 314
315 void Port::OnSentPacket(const rtc::SentPacket& sent_packet) {
316 PortInterface::SignalSentPacket(this, sent_packet);
317 }
318
315 void Port::OnReadyToSend() { 319 void Port::OnReadyToSend() {
316 AddressMap::iterator iter = connections_.begin(); 320 AddressMap::iterator iter = connections_.begin();
317 for (; iter != connections_.end(); ++iter) { 321 for (; iter != connections_.end(); ++iter) {
318 iter->second->OnReadyToSend(); 322 iter->second->OnReadyToSend();
319 } 323 }
320 } 324 }
321 325
322 size_t Port::AddPrflxCandidate(const Candidate& local) { 326 size_t Port::AddPrflxCandidate(const Candidate& local) {
323 candidates_.push_back(local); 327 candidates_.push_back(local);
324 return (candidates_.size() - 1); 328 return (candidates_.size() - 1);
(...skipping 1086 matching lines...) Expand 10 before | Expand all | Expand 10 after
1411 ASSERT(sent < 0); 1415 ASSERT(sent < 0);
1412 error_ = port_->GetError(); 1416 error_ = port_->GetError();
1413 sent_packets_discarded_++; 1417 sent_packets_discarded_++;
1414 } else { 1418 } else {
1415 send_rate_tracker_.AddSamples(sent); 1419 send_rate_tracker_.AddSamples(sent);
1416 } 1420 }
1417 return sent; 1421 return sent;
1418 } 1422 }
1419 1423
1420 } // namespace cricket 1424 } // namespace cricket
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698