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

Side by Side Diff: webrtc/base/opensslstreamadapter.cc

Issue 2514553003: Change rtc::TimeNanos and rtc::TimeMicros return value from uint64_t to int64_t. (Closed)
Patch Set: Drop one more unsigned suffix. Created 4 years, 1 month 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 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 static SrtpCipherMapEntry SrtpCipherMap[] = { 57 static SrtpCipherMapEntry SrtpCipherMap[] = {
58 {"SRTP_AES128_CM_SHA1_80", SRTP_AES128_CM_SHA1_80}, 58 {"SRTP_AES128_CM_SHA1_80", SRTP_AES128_CM_SHA1_80},
59 {"SRTP_AES128_CM_SHA1_32", SRTP_AES128_CM_SHA1_32}, 59 {"SRTP_AES128_CM_SHA1_32", SRTP_AES128_CM_SHA1_32},
60 {"SRTP_AEAD_AES_128_GCM", SRTP_AEAD_AES_128_GCM}, 60 {"SRTP_AEAD_AES_128_GCM", SRTP_AEAD_AES_128_GCM},
61 {"SRTP_AEAD_AES_256_GCM", SRTP_AEAD_AES_256_GCM}, 61 {"SRTP_AEAD_AES_256_GCM", SRTP_AEAD_AES_256_GCM},
62 {nullptr, 0}}; 62 {nullptr, 0}};
63 #endif 63 #endif
64 64
65 #ifdef OPENSSL_IS_BORINGSSL 65 #ifdef OPENSSL_IS_BORINGSSL
66 static void TimeCallback(const SSL* ssl, struct timeval* out_clock) { 66 static void TimeCallback(const SSL* ssl, struct timeval* out_clock) {
67 uint64_t time = TimeNanos(); 67 int64_t time = TimeNanos();
68 out_clock->tv_sec = time / kNumNanosecsPerSec; 68 out_clock->tv_sec = time / kNumNanosecsPerSec;
69 // TODO(nisse): The below looks very wrong.
pthatcher1 2016/11/18 22:11:16 Why?
nisse-webrtc 2016/11/21 07:45:07 It's wrong in several ways. With struct timeval
kwiberg-webrtc 2016/11/21 12:12:34 Post a bug about this and point to it in the comme
nisse-webrtc 2016/11/21 12:39:12 Filed bug https://bugs.chromium.org/p/webrtc/issue
69 out_clock->tv_usec = time / kNumNanosecsPerMicrosec; 70 out_clock->tv_usec = time / kNumNanosecsPerMicrosec;
70 } 71 }
71 #else // #ifdef OPENSSL_IS_BORINGSSL 72 #else // #ifdef OPENSSL_IS_BORINGSSL
72 73
73 // Cipher name table. Maps internal OpenSSL cipher ids to the RFC name. 74 // Cipher name table. Maps internal OpenSSL cipher ids to the RFC name.
74 struct SslCipherMapEntry { 75 struct SslCipherMapEntry {
75 uint32_t openssl_id; 76 uint32_t openssl_id;
76 const char* rfc_name; 77 const char* rfc_name;
77 }; 78 };
78 79
(...skipping 1180 matching lines...) Expand 10 before | Expand all | Expand 10 after
1259 return true; 1260 return true;
1260 } 1261 }
1261 } 1262 }
1262 1263
1263 return false; 1264 return false;
1264 } 1265 }
1265 1266
1266 } // namespace rtc 1267 } // namespace rtc
1267 1268
1268 #endif // HAVE_OPENSSL_SSL_H 1269 #endif // HAVE_OPENSSL_SSL_H
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698