From: Hannes Magnusson Date: Tue, 9 Dec 2008 10:11:21 +0000 (+0000) Subject: Fixed bug#46811 ini_set() doesn't return false on failure X-Git-Tag: php-5.3.0beta1~487 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a2f63f583bb3e5c1de93df9bd33894ac187d3b39;p=php Fixed bug#46811 ini_set() doesn't return false on failure --- diff --git a/Zend/tests/bug46811.phpt b/Zend/tests/bug46811.phpt new file mode 100644 index 0000000000..06e10d78fa --- /dev/null +++ b/Zend/tests/bug46811.phpt @@ -0,0 +1,13 @@ +--TEST-- +ini_set() function +--INI-- +arg_separator.output=& +--FILE-- + +--EXPECT-- +bool(false) +string(1) "&" + diff --git a/Zend/zend_ini.c b/Zend/zend_ini.c index 5979e67fb1..ba285d4c46 100644 --- a/Zend/zend_ini.c +++ b/Zend/zend_ini.c @@ -291,6 +291,7 @@ ZEND_API int zend_alter_ini_entry_ex(char *name, uint name_length, char *new_val ini_entry->value_length = new_value_length; } else { efree(duplicate); + return FAILURE; } return SUCCESS;