From f30dbd9f54df4827bcc4631da968111923d74c79 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 5 Dec 2005 17:27:24 +0000 Subject: [PATCH] MFB51: Fixed bug #35558 (mktime() interpreting 3 digit years incorrectly). --- ext/date/php_date.c | 2 +- ext/date/tests/mktime-3.phpt | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 2d7a1e2271..5a6e9de824 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -967,7 +967,7 @@ PHPAPI void php_mktime(INTERNAL_FUNCTION_PARAMETERS, int gmt) case 6: if (yea >= 0 && yea < 70) { yea += 2000; - } else if (yea >= 70 && yea <= 100) { + } else if (yea >= 70 && yea <= 110) { yea += 1900; } now->y = yea; diff --git a/ext/date/tests/mktime-3.phpt b/ext/date/tests/mktime-3.phpt index 7e9aa62d93..d02caf644c 100644 --- a/ext/date/tests/mktime-3.phpt +++ b/ext/date/tests/mktime-3.phpt @@ -5,7 +5,7 @@ error_reporting=2047 --FILE--