27static int last_resource_number;
31#if ZEND_EXTENSIONS_SUPPORT
37 fprintf(stderr,
"Failed loading %s: %s\n", path, DL_ERROR());
39 fprintf(stderr,
"Failed loading %s\n", path);
54 fprintf(stderr,
"Extensions are not supported on this platform.\n");
65#if ZEND_EXTENSIONS_SUPPORT
69 if (!extension_version_info) {
76 if (!extension_version_info || !new_extension) {
77 fprintf(stderr,
"%s doesn't appear to be a valid Zend extension\n", path);
89 fprintf(stderr,
"%s requires Zend Engine API version %d.\n"
90 "The Zend Engine API version %d which is installed, is outdated.\n\n",
101 fprintf(stderr,
"%s requires Zend Engine API version %d.\n"
102 "The Zend Engine API version %d which is installed, is newer.\n"
103 "Contact %s at %s for a later version of %s.\n\n",
109 new_extension->
name);
119 fprintf(stderr,
"Cannot load %s - it was built with configuration %s, whereas running engine is %s\n",
128 fprintf(stderr,
"Cannot load %s - it was already loaded\n", new_extension->
name);
140 fprintf(stderr,
"Extensions are not supported on this platform.\n");
152#if ZEND_EXTENSIONS_SUPPORT
155 extension = *new_extension;
184#if ZEND_EXTENSIONS_SUPPORT
194#if ZEND_EXTENSIONS_SUPPORT
212 last_resource_number = 0;
231#if ZEND_EXTENSIONS_SUPPORT && !ZEND_DEBUG
232 if (extension->
handle && !
getenv(
"ZEND_DONT_UNLOAD_MODULES")) {
233 DL_UNLOAD(extension->
handle);
247 message = va_arg(
args,
int);
263 return last_resource_number++;
328 size_t functions = zend_hash_num_elements(
CG(function_table));
337 CG(internal_run_time_cache) =
ptr;
338 CG(internal_run_time_cache_size) = alloc_size;
359 if (
CG(internal_run_time_cache)) {
360 memset(
CG(internal_run_time_cache), 0,
CG(internal_run_time_cache_size));
371 if (!
strcmp(extension->
name, extension_name)) {
407 data.op_array = op_array;
421 data.op_array = op_array;
fprintf($stream, string $format, mixed ... $values)
getenv(?string $name=null, bool $local_only=false)
memset(ptr, 0, type->size)
int zend_extension_api_no
message_handler_func_t message_handler
op_array_persist_calc_func_t op_array_persist_calc
op_array_persist_func_t op_array_persist
int(* build_id_check)(const char *build_id)
op_array_dtor_func_t op_array_dtor
op_array_ctor_func_t op_array_ctor
op_array_handler_func_t op_array_handler
int(* api_no_check)(int api_no)
struct _zend_llist_element * next
PHP_WINUTIL_API BOOL php_win32_image_compatible(HMODULE handle, char **err)
ZEND_API ZEND_COLD void zend_error(int type, const char *format,...)
ZEND_API void zend_append_version_info(const zend_extension *extension)
#define pemalloc(size, persistent)
strcmp(string $string1, string $string2)
#define ZEND_USER_CODE(type)
struct _zend_op_array zend_op_array
struct _zend_internal_function zend_internal_function
ZEND_API int zend_internal_function_extension_handles
ZEND_API int zend_get_internal_function_extension_handles(const char *module_name, int handles)
void zend_register_extension(zend_extension *new_extension, DL_HANDLE handle)
void zend_startup_extensions(void)
zend_result zend_load_extension(const char *path)
ZEND_API uint32_t zend_extension_flags
ZEND_API size_t zend_extensions_op_array_persist(zend_op_array *op_array, void *mem)
ZEND_API void zend_init_internal_run_time_cache(void)
ZEND_API int zend_get_resource_handle(const char *module_name)
ZEND_API size_t zend_extensions_op_array_persist_calc(zend_op_array *op_array)
ZEND_API zend_extension * zend_get_extension(const char *extension_name)
ZEND_API int zend_get_internal_function_extension_handle(const char *module_name)
void zend_shutdown_extensions(void)
ZEND_API int zend_get_op_array_extension_handles(const char *module_name, int handles)
ZEND_API void zend_reset_internal_run_time_cache(void)
ZEND_API zend_llist zend_extensions
zend_result zend_load_extension_handle(DL_HANDLE handle, const char *path)
struct _zend_extension_persist_data zend_extension_persist_data
ZEND_API void zend_extension_dispatch_message(int message, void *arg)
ZEND_API int zend_get_op_array_extension_handle(const char *module_name)
ZEND_API size_t zend_internal_run_time_cache_reserved_size(void)
ZEND_API int zend_op_array_extension_handles
void zend_startup_extensions_mechanism(void)
void zend_extension_dtor(zend_extension *extension)
struct _zend_extension_version_info zend_extension_version_info
#define ZEND_EXTENSION_BUILD_ID
#define ZEND_EXTENSIONS_HAVE_OP_ARRAY_PERSIST
#define ZEND_EXTENSIONS_HAVE_OP_ARRAY_CTOR
#define ZEND_EXTMSG_NEW_EXTENSION
#define ZEND_EXTENSIONS_HAVE_OP_ARRAY_HANDLER
#define ZEND_EXTENSIONS_HAVE_OP_ARRAY_PERSIST_CALC
#define ZEND_EXTENSIONS_HAVE_OP_ARRAY_DTOR
struct _zend_extension zend_extension
#define ZEND_EXTENSION_API_NO
#define ZEND_HASH_MAP_FOREACH_PTR(ht, _ptr)
#define ZEND_HASH_FOREACH_END()
ZEND_API void zend_llist_destroy(zend_llist *l)
ZEND_API void zend_llist_add_element(zend_llist *l, const void *element)
ZEND_API void zend_llist_init(zend_llist *l, size_t size, llist_dtor_func_t dtor, unsigned char persistent)
ZEND_API void zend_llist_apply_with_del(zend_llist *l, int(*func)(void *data))
ZEND_API void zend_llist_apply_with_arguments(zend_llist *l, llist_apply_with_args_func_t func, int num_args,...)
ZEND_API void zend_llist_apply(zend_llist *l, llist_apply_func_t func)
ZEND_API void zend_llist_apply_with_argument(zend_llist *l, llist_apply_with_arg_func_t func, void *arg)
struct _zend_llist_element zend_llist_element
void(* llist_apply_with_args_func_t)(void *data, int num_args, va_list args)
void(* llist_apply_with_arg_func_t)(void *data, void *arg)
void(* llist_apply_func_t)(void *)
struct _zend_llist zend_llist
#define ZEND_MAP_PTR_GET(ptr)
#define ZEND_MAP_PTR_SET(ptr, val)
#define ZEND_MAX_RESERVED_RESOURCES
struct _zend_class_entry zend_class_entry
ZEND_API zend_result zend_add_system_entropy(const char *module_name, const char *hook_name, const void *data, size_t size)
ZEND_RESULT_CODE zend_result