Skip to content

Commit 1c129c7

Browse files
committed
ext/standard: Use zend_string in get_include_path()
1 parent 7896276 commit 1c129c7

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

ext/standard/basic_functions.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2088,17 +2088,15 @@ PHP_FUNCTION(set_include_path)
20882088
/* {{{ Get the current include_path configuration option */
20892089
PHP_FUNCTION(get_include_path)
20902090
{
2091-
char *str;
2092-
20932091
ZEND_PARSE_PARAMETERS_NONE();
20942092

2095-
str = zend_ini_string("include_path", sizeof("include_path") - 1, 0);
2093+
zend_string *str = zend_ini_str("include_path", sizeof("include_path") - 1, 0);
20962094

20972095
if (str == NULL) {
20982096
RETURN_FALSE;
20992097
}
21002098

2101-
RETURN_STRING(str);
2099+
RETURN_STR_COPY(str);
21022100
}
21032101
/* }}} */
21042102

0 commit comments

Comments
 (0)