From 6f465484126b1ab83f90e32a8d1d03eec556b44a Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Wed, 16 Oct 2002 14:08:47 +0000 Subject: [PATCH] modified zend_bool handling code. --- ext/mbstring/mbstring.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index d39404347bf..a218eb39ab4 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -664,7 +664,7 @@ static PHP_INI_MH(OnUpdate_mbstring_encoding_translation) new_value_length = sizeof("1"); } - MBSTRG(encoding_translation) = (zend_bool) atoi(new_value); + OnUpdateInt(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC); if (MBSTRG(encoding_translation)){ sapi_unregister_post_entry(php_post_entries); @@ -693,7 +693,9 @@ PHP_INI_BEGIN() STD_PHP_INI_ENTRY("mbstring.func_overload", "0", PHP_INI_SYSTEM | PHP_INI_PERDIR, OnUpdateInt, func_overload, zend_mbstring_globals, mbstring_globals) - PHP_INI_ENTRY("mbstring.encoding_translation", "0", PHP_INI_SYSTEM | PHP_INI_PERDIR, OnUpdate_mbstring_encoding_translation) + STD_PHP_INI_BOOLEAN("mbstring.encoding_translation", "0", + PHP_INI_SYSTEM | PHP_INI_PERDIR, OnUpdate_mbstring_encoding_translation, + encoding_translation, zend_mbstring_globals, mbstring_globals) PHP_INI_END()