summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2020-08-10 14:36:06 +0200
committerNikita Popov <nikita.ppv@gmail.com>2020-08-10 15:59:08 +0200
commit657707a105832f2cbd4de4cbdaa3fc5f48a06d97 (patch)
treeea562efb5d9221592edf40a2ac4e5471bf5e268c
parent217d05b18e47400a40ebf4a627a08cf5a164f230 (diff)
downloadphp-git-657707a105832f2cbd4de4cbdaa3fc5f48a06d97.tar.gz
Skip bug70417.phpt if lsof output looks wrong
On alpine lsof accepts -p but it doesn't actually do anything. Add a crude check for whether lsof looks like Linux lsof.
-rw-r--r--ext/phar/tests/tar/bug70417.phpt3
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/phar/tests/tar/bug70417.phpt b/ext/phar/tests/tar/bug70417.phpt
index f288efc8f5..021342c234 100644
--- a/ext/phar/tests/tar/bug70417.phpt
+++ b/ext/phar/tests/tar/bug70417.phpt
@@ -9,6 +9,9 @@ exec('lsof -p ' . getmypid(), $out, $status);
if ($status !== 0) {
die("skip lsof(8) not available");
}
+if (!str_starts_with($out[0], 'COMMAND')) {
+ die("skip Might be a different lsof");
+}
?>
--FILE--
<?php