[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tlsdate/master] Document magic "1900" value



commit 9d2f77df0b99ec03545418caa05903dd6aaf1adc
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date:   Thu Oct 10 15:11:17 2013 -0400

    Document magic "1900" value
---
 src/tlsdate-helper.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/tlsdate-helper.c b/src/tlsdate-helper.c
index a5017d5..a724402 100644
--- a/src/tlsdate-helper.c
+++ b/src/tlsdate-helper.c
@@ -270,6 +270,8 @@ handle_date_line(const char *dateline, uint32_t *result)
       sscanf(dateline, "%3s %d %d:%d:%d %d",
              month, &day, &hour, &min, &sec, &year) == 6) {
 
+    /* Two digit dates are defined to be relative to 1900; all other dates
+     * are supposed to be represented as four digits. */
     if (year < 100)
       year += 1900;
 



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits