Skip to content

NetBSD build warning fixes. #7819

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Zend/zend_cpuinfo.c
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ static void __zend_cpuid(uint32_t func, uint32_t subfunc, zend_cpu_info *cpuinfo

#if defined(__i386__) || defined(__x86_64__)
/* Function based on compiler-rt implementation. */
static unsigned get_xcr0_eax() {
static unsigned get_xcr0_eax(void) {
# if defined(__GNUC__) || defined(__clang__)
// Check xgetbv; this uses a .byte sequence instead of the instruction
// directly because older assemblers do not include support for xgetbv and
Expand All @@ -90,7 +90,7 @@ static unsigned get_xcr0_eax() {
# endif
}

static zend_bool is_avx_supported() {
static zend_bool is_avx_supported(void) {
if (!(cpuinfo.ecx & ZEND_CPU_FEATURE_AVX)) {
/* No support for AVX */
return 0;
Expand All @@ -106,7 +106,7 @@ static zend_bool is_avx_supported() {
return 1;
}
#else
static zend_bool is_avx_supported() {
static zend_bool is_avx_supported(void) {
return 0;
}
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/sockets/multicast.c
Original file line number Diff line number Diff line change
Expand Up @@ -784,7 +784,7 @@ int php_add4_to_if_index(struct in_addr *addr, php_socket *php_sock, unsigned *i
}

for (p = if_conf.ifc_buf;
p < if_conf.ifc_buf + if_conf.ifc_len;
p < ((char *)if_conf.ifc_buf) + if_conf.ifc_len;
p += entry_len) {
/* p may be misaligned on macos. */
struct ifreq cur_req;
Expand Down