com php-src: Suppress warning in pcntl_unshare skipif: ext/pcntl/tests/pcntl_unshare_01.phpt
| From: | Nikita Popov | Date: | Wed, 05 Aug 2020 07:46:07 +0000 |
| Subject: | com php-src: Suppress warning in pcntl_unshare skipif: ext/pcntl/tests/pcntl_unshare_01.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-112561@lists.php.net to get a copy of this message | ||
Commit: 36a1197f121842b7d3599ebc89480c924bfcf926
Author: Nikita Popov <nikita.ppv@gmail.com> Tue, 4 Aug 2020 16:05:11 +0200
Parents: b0d139456aad9921d30ba8dfd32fc6cac79dedf9
Branches: PHP-7.4 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=36a1197f121842b7d3599ebc89480c924bfcf926
Log:
Suppress warning in pcntl_unshare skipif
Changed paths:
M ext/pcntl/tests/pcntl_unshare_01.phpt
Diff:
diff --git a/ext/pcntl/tests/pcntl_unshare_01.phpt b/ext/pcntl/tests/pcntl_unshare_01.phpt
index d914723dc1..815a3ce964 100644
--- a/ext/pcntl/tests/pcntl_unshare_01.phpt
+++ b/ext/pcntl/tests/pcntl_unshare_01.phpt
@@ -6,7 +6,7 @@ if (!extension_loaded("pcntl")) die("skip");
if (!extension_loaded("posix")) die("skip posix extension not available");
if (!function_exists("pcntl_unshare")) die("skip pcntl_unshare is not
available");
if (!defined("CLONE_NEWUSER")) die("skip flag unavailable");
-if (pcntl_unshare(CLONE_NEWUSER) == false && pcntl_get_last_error() == PCNTL_EPERM) {
+if (@pcntl_unshare(CLONE_NEWUSER) == false && pcntl_get_last_error() == PCNTL_EPERM) {
die("skip Insufficient previleges to use CLONE_NEWUSER");
}