cvs: php4 /ext/standard datetime.c

From: Date: Sun, 03 Sep 2000 04:09:49 +0000
Subject: cvs: php4 /ext/standard datetime.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-1507@lists.php.net to get a copy of this message
sniper Sat Sep 2 21:09:49 2000 EDT Modified files: /php4/ext/standard datetime.c Log: @- Fixed a bug in checkdate() which caused < 1 years to be valid (Jani) # Bug #6254 Index: php4/ext/standard/datetime.c diff -u php4/ext/standard/datetime.c:1.54 php4/ext/standard/datetime.c:1.55 --- php4/ext/standard/datetime.c:1.54 Sat Sep 2 20:50:59 2000 +++ php4/ext/standard/datetime.c Sat Sep 2 21:09:48 2000 @@ -19,7 +19,7 @@ */ -/* $Id: datetime.c,v 1.54 2000/09/03 03:50:59 sniper Exp $ */ +/* $Id: datetime.c,v 1.55 2000/09/03 04:09:48 sniper Exp $ */ #include "php.h" @@ -616,7 +616,7 @@ /* {{{ proto bool checkdate(int month, int day, int year) - Returns true(1) if it is a valid date */ + Returns true(1) if it is a valid date in gregorian calendar */ PHP_FUNCTION(checkdate) { pval **month, **day, **year; @@ -640,7 +640,7 @@ m = (*month)->value.lval; d = (*day)->value.lval; - if (y < 0 || y > 32767) { + if (y < 1 || y > 32767) { RETURN_FALSE; } if (m < 1 || m > 12) {

« previous php.cvs (#1507) next »