Using 64-bit timestamp to replace the 32-bit one in webrtc/p2p.
Also changed from unsigned to signed integer per the style guide.
By the way, I kept all delta-times to be 32-bit int.
The only things left in the p2p dir are
1. proberprober/main.cc where Time() is used as the input for a random number.
2. pseudotcp.cc: where 32-bit time info is sent over the wire.
BUG=webrtc:5636
Review URL: https://codereview.webrtc.org/1793553002
Cr-Commit-Position: refs/heads/master@{#12019}
diff --git a/webrtc/p2p/base/stunrequest.cc b/webrtc/p2p/base/stunrequest.cc
index 3338861..9ceb6da 100644
--- a/webrtc/p2p/base/stunrequest.cc
+++ b/webrtc/p2p/base/stunrequest.cc
@@ -191,8 +191,8 @@
return msg_;
}
-uint32_t StunRequest::Elapsed() const {
- return rtc::TimeSince(tstamp_);
+int StunRequest::Elapsed() const {
+ return static_cast<int>(rtc::Time64() - tstamp_);
}
@@ -211,7 +211,7 @@
return;
}
- tstamp_ = rtc::Time();
+ tstamp_ = rtc::Time64();
rtc::ByteBuffer buf;
msg_->Write(&buf);