]> granicus.if.org Git - php/commitdiff
- Fixed bug #46067 (Collator methods - Segfault)
authorFelipe Pena <felipe@php.net>
Sat, 20 Sep 2008 22:06:18 +0000 (22:06 +0000)
committerFelipe Pena <felipe@php.net>
Sat, 20 Sep 2008 22:06:18 +0000 (22:06 +0000)
ext/unicode/collator.c

index 1535be7ea357086dd753eb9afb2ce1faf4b03fc0..13acaf995c6dedc01cafa13d8976d5e221c4479a 100644 (file)
@@ -180,10 +180,14 @@ PHP_FUNCTION(collator_create)
        int               collator_name_len;
        zval                     *object;
        UCollator                *ucoll;
+       zend_error_handling error_handling;
+
+       zend_replace_error_handling(EH_THROW, NULL, &error_handling TSRMLS_CC);
 
        if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &collator_name, &collator_name_len) == FAILURE) {
                RETURN_FALSE;
        }
+       zend_restore_error_handling(&error_handling TSRMLS_CC);
 
        if ((object = getThis()) == NULL) {
                object = return_value;