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

Unified Diff: net/cert/cert_verify_proc.cc

Issue 2441713002: Remove some thread-unsafe statics in (Closed)
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/cert/cert_verify_proc.cc
diff --git a/net/cert/cert_verify_proc.cc b/net/cert/cert_verify_proc.cc
index 8fdd93cbb1bb0c4720273867ee9c9de3fb723ed6..7ef5437503d59c815e44871bc5eefaf9269212e0 100644
--- a/net/cert/cert_verify_proc.cc
+++ b/net/cert/cert_verify_proc.cc
@@ -693,12 +693,12 @@ bool CertVerifyProc::HasTooLongValidity(const X509Certificate& cert) {
if (exploded_expiry.day_of_month > exploded_start.day_of_month)
++month_diff;
- static const base::Time time_2012_07_01 =
- base::Time::FromUTCExploded({2012, 7, 0, 1, 0, 0, 0, 0});
- static const base::Time time_2015_04_01 =
- base::Time::FromUTCExploded({2015, 4, 0, 1, 0, 0, 0, 0});
- static const base::Time time_2019_07_01 =
- base::Time::FromUTCExploded({2019, 7, 0, 1, 0, 0, 0, 0});
+ const base::Time time_2012_07_01 =
+ base::Time::FromInternalValue(INT64_C(12985574400000000));
Ryan Sleevi 2016/10/20 20:24:56 This is no longer necessary for C++11 - as promoti
eroman 2016/10/20 21:06:15 Done -- Did not know that, thanks!
+ const base::Time time_2015_04_01 =
+ base::Time::FromInternalValue(INT64_C(13072320000000000));
+ const base::Time time_2019_07_01 =
+ base::Time::FromInternalValue(INT64_C(13206412800000000));
// For certificates issued before the BRs took effect.
if (start < time_2012_07_01 && (month_diff > 120 || expiry > time_2019_07_01))
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698