Avoid possible [-Wstrict-prototypes] build warnings

This commit is contained in:
Patrick Allaert 2022-02-24 16:14:47 +01:00
parent 67dd48fbd5
commit 8c60e21515
No known key found for this signature in database
GPG key ID: 199F9DFEF6FFBAFD
5 changed files with 6 additions and 6 deletions

View file

@ -2816,7 +2816,7 @@ static void *tracked_realloc(void *ptr, size_t new_size) {
return ptr; return ptr;
} }
static void tracked_free_all() { static void tracked_free_all(void) {
HashTable *tracked_allocs = AG(mm_heap)->tracked_allocs; HashTable *tracked_allocs = AG(mm_heap)->tracked_allocs;
zend_ulong h; zend_ulong h;
ZEND_HASH_FOREACH_NUM_KEY(tracked_allocs, h) { ZEND_HASH_FOREACH_NUM_KEY(tracked_allocs, h) {

View file

@ -203,7 +203,7 @@ static int zend_extension_startup(zend_extension *extension)
} }
void zend_startup_extensions_mechanism() void zend_startup_extensions_mechanism(void)
{ {
/* Startup extensions mechanism */ /* Startup extensions mechanism */
zend_llist_init(&zend_extensions, sizeof(zend_extension), (void (*)(void *)) zend_extension_dtor, 1); zend_llist_init(&zend_extensions, sizeof(zend_extension), (void (*)(void *)) zend_extension_dtor, 1);
@ -212,7 +212,7 @@ void zend_startup_extensions_mechanism()
} }
void zend_startup_extensions() void zend_startup_extensions(void)
{ {
zend_llist_apply_with_del(&zend_extensions, (int (*)(void *)) zend_extension_startup); zend_llist_apply_with_del(&zend_extensions, (int (*)(void *)) zend_extension_startup);
} }

View file

@ -1695,7 +1695,7 @@ ZEND_API void zend_get_gc_buffer_grow(zend_get_gc_buffer *gc_buffer) {
gc_buffer->cur = gc_buffer->start + old_capacity; gc_buffer->cur = gc_buffer->start + old_capacity;
} }
static void zend_get_gc_buffer_release() { static void zend_get_gc_buffer_release(void) {
zend_get_gc_buffer *gc_buffer = &EG(get_gc_buffer); zend_get_gc_buffer *gc_buffer = &EG(get_gc_buffer);
efree(gc_buffer->start); efree(gc_buffer->start);
gc_buffer->start = gc_buffer->end = gc_buffer->cur = NULL; gc_buffer->start = gc_buffer->end = gc_buffer->cur = NULL;

View file

@ -323,7 +323,7 @@ typedef size_t (*crc32_x86_simd_func_t)(X86_CRC32_TYPE type, uint32_t *crc, cons
ZEND_NO_SANITIZE_ADDRESS ZEND_NO_SANITIZE_ADDRESS
ZEND_ATTRIBUTE_UNUSED /* clang mistakenly warns about this */ ZEND_ATTRIBUTE_UNUSED /* clang mistakenly warns about this */
static crc32_x86_simd_func_t resolve_crc32_x86_simd_update() { static crc32_x86_simd_func_t resolve_crc32_x86_simd_update(void) {
if (zend_cpu_supports_sse42() && zend_cpu_supports_pclmul()) { if (zend_cpu_supports_sse42() && zend_cpu_supports_pclmul()) {
return crc32_sse42_pclmul_update; return crc32_sse42_pclmul_update;
} }

View file

@ -1742,7 +1742,7 @@ void fcgi_free_mgmt_var_cb(zval *zv)
pefree(Z_STR_P(zv), 1); pefree(Z_STR_P(zv), 1);
} }
const char *fcgi_get_last_client_ip() const char *fcgi_get_last_client_ip(void)
{ {
static char str[INET6_ADDRSTRLEN]; static char str[INET6_ADDRSTRLEN];