From f06a6b4697d7a9eed2a9927912b970126c6ea16e Mon Sep 17 00:00:00 2001 From: Chuck Adams Date: Sat, 11 Jul 2020 09:47:33 -0600 Subject: [PATCH] (ffi) fix ifdefs for non-windows systems without long double Closes GH-5840 --- ext/ffi/ffi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/ffi/ffi.c b/ext/ffi/ffi.c index f2e5dae346..6eac3a04a4 100644 --- a/ext/ffi/ffi.c +++ b/ext/ffi/ffi.c @@ -312,7 +312,7 @@ static ffi_type *zend_ffi_make_fake_struct_type(zend_ffi_type *type) /* {{{ */ case ZEND_FFI_TYPE_DOUBLE: t->elements[i] = &ffi_type_double; break; -#ifndef PHP_WIN32 +#ifdef HAVE_LONG_DOUBLE case ZEND_FFI_TYPE_LONGDOUBLE: t->elements[i] = &ffi_type_longdouble; break; @@ -359,7 +359,7 @@ again: return &ffi_type_float; case ZEND_FFI_TYPE_DOUBLE: return &ffi_type_double; -#ifndef PHP_WIN32 +#ifdef HAVE_LONG_DOUBLE case ZEND_FFI_TYPE_LONGDOUBLE: return &ffi_type_longdouble; #endif -- 2.40.0