aboutsummaryrefslogtreecommitdiff
path: root/webrtc/p2p/base/port.cc
diff options
context:
space:
mode:
authorpkasting@chromium.org <pkasting@chromium.org>2014-11-06 20:19:22 +0000
committerpkasting@chromium.org <pkasting@chromium.org>2014-11-06 20:19:22 +0000
commit332331fb01f8a316ac6d61cf4572478610fb3472 (patch)
treef80ca6afdf7b7a750d70819f56bb099614653c46 /webrtc/p2p/base/port.cc
parentd89b69aadeb9db67b7cc2de3300109d866c2a937 (diff)
downloadwebrtc-332331fb01f8a316ac6d61cf4572478610fb3472.tar.gz
Use uint16s for port numbers in webrtc/p2p/base.
This is a necessary precursor to using uint16s for port numbers more consistently in Chromium code. This also makes some minor formatting changes in surrounding code (function declaration wrapping, virtual -> override). BUG=chromium:81439 TEST=none R=henrike@webrtc.org Review URL: https://webrtc-codereview.appspot.com/32379004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@7656 4adac7df-926f-26a2-2b94-8c16560cd09d
Diffstat (limited to 'webrtc/p2p/base/port.cc')
-rw-r--r--webrtc/p2p/base/port.cc19
1 files changed, 13 insertions, 6 deletions
diff --git a/webrtc/p2p/base/port.cc b/webrtc/p2p/base/port.cc
index f569d9f508..a8357ad6bb 100644
--- a/webrtc/p2p/base/port.cc
+++ b/webrtc/p2p/base/port.cc
@@ -152,9 +152,12 @@ static std::string ComputeFoundation(
return rtc::ToString<uint32>(rtc::ComputeCrc32(ost.str()));
}
-Port::Port(rtc::Thread* thread, rtc::PacketSocketFactory* factory,
- rtc::Network* network, const rtc::IPAddress& ip,
- const std::string& username_fragment, const std::string& password)
+Port::Port(rtc::Thread* thread,
+ rtc::PacketSocketFactory* factory,
+ rtc::Network* network,
+ const rtc::IPAddress& ip,
+ const std::string& username_fragment,
+ const std::string& password)
: thread_(thread),
factory_(factory),
send_retransmit_count_attribute_(false),
@@ -176,10 +179,14 @@ Port::Port(rtc::Thread* thread, rtc::PacketSocketFactory* factory,
Construct();
}
-Port::Port(rtc::Thread* thread, const std::string& type,
+Port::Port(rtc::Thread* thread,
+ const std::string& type,
rtc::PacketSocketFactory* factory,
- rtc::Network* network, const rtc::IPAddress& ip,
- int min_port, int max_port, const std::string& username_fragment,
+ rtc::Network* network,
+ const rtc::IPAddress& ip,
+ uint16 min_port,
+ uint16 max_port,
+ const std::string& username_fragment,
const std::string& password)
: thread_(thread),
factory_(factory),