summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph M. Becker <cmbecker69@gmx.de>2020-05-12 13:31:53 +0200
committerChristoph M. Becker <cmbecker69@gmx.de>2020-05-12 13:31:53 +0200
commit8623a85cb9a76694c2dae886f65f7bffb85657a9 (patch)
treef43984eb83381611b34cb763c53493779455425a
parent4b0d5e0faf38f936625ac127a954c1a16dd1cb07 (diff)
downloadphp-git-8623a85cb9a76694c2dae886f65f7bffb85657a9.tar.gz
Skip test on big-endian architectures
Due to the memory layout on BE architectures, the address would be `0x2a00000000` instead of `0x2a` on little-endian architectures.
-rw-r--r--ext/ffi/tests/bug79571.phpt3
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/ffi/tests/bug79571.phpt b/ext/ffi/tests/bug79571.phpt
index cff3fab43e..8880167306 100644
--- a/ext/ffi/tests/bug79571.phpt
+++ b/ext/ffi/tests/bug79571.phpt
@@ -3,6 +3,9 @@ Bug #79571 (FFI: var_dumping unions may segfault)
--SKIPIF--
<?php
if (!extension_loaded('ffi')) die('skip ffi extension not available');
+if (pack('S', 0xABCD) !== pack('v', 0xABCD)) {
+ die('skip for little-endian architectures only');
+}
?>
--FILE--
<?php