cvs: php4 /ext/standard datetime.c
| From: | Rasmus Lerdorf | Date: | Wed, 14 Jun 2000 16:35:48 +0000 |
| Subject: | cvs: php4 /ext/standard datetime.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-257@lists.php.net to get a copy of this message | ||
rasmus Wed Jun 14 09:35:48 2000 EDT
Modified files:
/php4/ext/standard datetime.c
Log:
Require the year arg to checkdate to be an integer - fix for bug #5034
@Require the year arg to checkdate to be an integer (Rasmus)
Index: php4/ext/standard/datetime.c
diff -u php4/ext/standard/datetime.c:1.43 php4/ext/standard/datetime.c:1.44
--- php4/ext/standard/datetime.c:1.43 Fri Jun 9 13:18:36 2000
+++ php4/ext/standard/datetime.c Wed Jun 14 09:35:48 2000
@@ -19,7 +19,7 @@
*/
-/* $Id: datetime.c,v 1.43 2000/06/09 20:18:36 andrei Exp $ */
+/* $Id: datetime.c,v 1.44 2000/06/14 16:35:48 rasmus Exp $ */
#include "php.h"
@@ -600,6 +600,9 @@
if (ZEND_NUM_ARGS() != 3 ||
zend_get_parameters_ex(3, &month, &day, &year) == FAILURE) {
WRONG_PARAM_COUNT;
+ }
+ if((*year)->type != IS_LONG) {
+ RETURN_FALSE;
}
convert_to_long_ex(day);
convert_to_long_ex(month);