Skip to content

Commit f06a6b4

Browse files
chuckadamsGirgias
authored andcommitted
(ffi) fix ifdefs for non-windows systems without long double
Closes GH-5840
1 parent 340e2ea commit f06a6b4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

ext/ffi/ffi.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@ static ffi_type *zend_ffi_make_fake_struct_type(zend_ffi_type *type) /* {{{ */
312312
case ZEND_FFI_TYPE_DOUBLE:
313313
t->elements[i] = &ffi_type_double;
314314
break;
315-
#ifndef PHP_WIN32
315+
#ifdef HAVE_LONG_DOUBLE
316316
case ZEND_FFI_TYPE_LONGDOUBLE:
317317
t->elements[i] = &ffi_type_longdouble;
318318
break;
@@ -359,7 +359,7 @@ static ffi_type *zend_ffi_get_type(zend_ffi_type *type) /* {{{ */
359359
return &ffi_type_float;
360360
case ZEND_FFI_TYPE_DOUBLE:
361361
return &ffi_type_double;
362-
#ifndef PHP_WIN32
362+
#ifdef HAVE_LONG_DOUBLE
363363
case ZEND_FFI_TYPE_LONGDOUBLE:
364364
return &ffi_type_longdouble;
365365
#endif

0 commit comments

Comments
 (0)