aboutsummaryrefslogtreecommitdiff
path: root/src/or/rephist.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/or/rephist.c')
-rw-r--r--src/or/rephist.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/or/rephist.c b/src/or/rephist.c
index 2c84e40c2f..8908e03294 100644
--- a/src/or/rephist.c
+++ b/src/or/rephist.c
@@ -741,7 +741,7 @@ parse_possibly_bad_iso_time(const char *s, time_t *time_out)
char b[5];
strlcpy(b, s, sizeof(b));
b[4] = '\0';
- year = atoi(b);
+ year = (int)tor_parse_long(b, 10, 0, INT_MAX, NULL, NULL);
if (year < 1970) {
*time_out = 0;
++n_bogus_times;