diff options
| author | Christoph M. Becker <cmbecker69@gmx.de> | 2019-11-11 12:56:32 +0100 |
|---|---|---|
| committer | Christoph M. Becker <cmbecker69@gmx.de> | 2019-11-11 12:56:55 +0100 |
| commit | 2804ea612779b89d3c62d974eb35783dd31f7dee (patch) | |
| tree | 63960a6ec8f5c77f3a63e0fbe1057a328b774833 /ext | |
| parent | 0a33536526a4da086ba09fe23b5b7ffc63273aac (diff) | |
| parent | ce047e60911400c97d585a09a69770898aa4cf78 (diff) | |
| download | php-git-2804ea612779b89d3c62d974eb35783dd31f7dee.tar.gz | |
Merge branch 'PHP-7.4'
* PHP-7.4:
Fix test case for Windows
Diffstat (limited to 'ext')
| -rw-r--r-- | ext/ffi/tests/bug78714.phpt | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/ext/ffi/tests/bug78714.phpt b/ext/ffi/tests/bug78714.phpt index c99607c11c..a73b37cae1 100644 --- a/ext/ffi/tests/bug78714.phpt +++ b/ext/ffi/tests/bug78714.phpt @@ -6,7 +6,13 @@ Bug #78714 (funcs returning pointer can't use call convention spec) ffi.enable=1 --FILE-- <?php -$ffi = FFI::cdef('char * __cdecl get_zend_version(void);'); +$def = 'char * __cdecl get_zend_version(void);'; +if (substr(PHP_OS, 0, 3) != 'WIN') { + $ffi = FFI::cdef($def); +} else { + $dll = 'php8' . (PHP_ZTS ? 'ts' : '') . (PHP_DEBUG ? '_debug' : '') . '.dll'; + $ffi = FFI::cdef($def, $dll); +} echo substr(FFI::string($ffi->get_zend_version()), 0, 4) . "\n"; ?> --EXPECT-- |
