bjori Mon Nov 6 16:11:26 2006 UTC
Modified files: (Branch: PHP_5_2)
/php-src/ext/date php_date.c
Log:
MFH: throw exception on invalid parameters
http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.43.2.45.2.33&r2=1.43.2.45.2.34&diff_format=u
Index: php-src/ext/date/php_date.c
diff -u php-src/ext/date/php_date.c:1.43.2.45.2.33
php-src/ext/date/php_date.c:1.43.2.45.2.34
--- php-src/ext/date/php_date.c:1.43.2.45.2.33 Fri Nov 3 15:06:51 2006
+++ php-src/ext/date/php_date.c Mon Nov 6 16:11:26 2006
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: php_date.c,v 1.43.2.45.2.33 2006/11/03 15:06:51 bjori Exp $ */
+/* $Id: php_date.c,v 1.43.2.45.2.34 2006/11/06 16:11:26 bjori Exp $ */
#include "php.h"
#include "php_streams.h"
@@ -1679,11 +1679,11 @@
char *time_str = NULL;
int time_str_len = 0;
+ php_set_error_handling(EH_THROW, NULL TSRMLS_CC);
if (SUCCESS == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|sO",
&time_str, &time_str_len, &timezone_object, date_ce_timezone)) {
- php_set_error_handling(EH_THROW, NULL TSRMLS_CC);
date_initialize(zend_object_store_get_object(getThis()
TSRMLS_CC), time_str, time_str_len, timezone_object TSRMLS_CC);
- php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
}
+ php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
}
/* }}} */
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php