mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
replace the stack var by a macro
This commit is contained in:
parent
9470b2016c
commit
9ad0d0ca3c
4 changed files with 8 additions and 12 deletions
|
@ -375,16 +375,12 @@ static void php_load_zend_extension_cb(void *arg)
|
|||
|
||||
if (VCWD_ACCESS(libpath, F_OK)) {
|
||||
/* If file does not exist, consider as extension name and build file name */
|
||||
const char *libpath_prefix = "";
|
||||
char *orig_libpath = libpath;
|
||||
#if PHP_WIN32
|
||||
libpath_prefix = "php_";
|
||||
#endif
|
||||
|
||||
if (slash_suffix) {
|
||||
spprintf(&libpath, 0, "%s%s%s." PHP_SHLIB_SUFFIX, extension_dir, libpath_prefix, filename); /* SAFE */
|
||||
spprintf(&libpath, 0, "%s" PHP_SHLIB_EXT_PREFIX "%s." PHP_SHLIB_SUFFIX, extension_dir, filename); /* SAFE */
|
||||
} else {
|
||||
spprintf(&libpath, 0, "%s%c%s%s." PHP_SHLIB_SUFFIX, extension_dir, DEFAULT_SLASH, libpath_prefix, filename); /* SAFE */
|
||||
spprintf(&libpath, 0, "%s%c" PHP_SHLIB_EXT_PREFIX "%s." PHP_SHLIB_SUFFIX, extension_dir, DEFAULT_SLASH, filename); /* SAFE */
|
||||
}
|
||||
|
||||
if (VCWD_ACCESS(libpath, F_OK)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue