mirror of
https://github.com/php/php-src.git
synced 2024-09-22 02:17:32 +00:00
Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0: socket cmsg credential test fixes, "backporting" from the FreeBSD PR.
This commit is contained in:
commit
938a81cf01
@ -14,10 +14,6 @@ die('skip not for AIX');
|
||||
if (!defined('SO_PASSCRED')) {
|
||||
die('skip SO_PASSCRED is not defined');
|
||||
}
|
||||
--CLEAN--
|
||||
<?php
|
||||
$path = __DIR__ . "/socket_cmsg_credentials.sock";
|
||||
@unlink($path);
|
||||
--FILE--
|
||||
<?php
|
||||
include __DIR__."/mcast_helpers.php.inc";
|
||||
@ -35,7 +31,7 @@ $s = socket_create(AF_UNIX, SOCK_DGRAM, 0) or die("err");
|
||||
var_dump($s);
|
||||
$br = socket_bind($s, $path) or die("err");
|
||||
var_dump($br);
|
||||
socket_set_nonblock($sends1) or die("Could not put in non-blocking mode");
|
||||
socket_set_nonblock($s) or die("Could not put in non-blocking mode");
|
||||
socket_set_option($s, SOL_SOCKET, SO_PASSCRED, 1) or die("could not set SO_PASSCRED");
|
||||
|
||||
|
||||
@ -57,6 +53,10 @@ print_r($data);
|
||||
$pid = getmypid();
|
||||
var_dump($data['control'][0]['data']['pid'] === $pid);
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
$path = __DIR__ . "/socket_cmsg_credentials.sock";
|
||||
@unlink($path);
|
||||
--EXPECTF--
|
||||
creating send socket
|
||||
object(Socket)#%d (0) {
|
||||
|
Loading…
Reference in New Issue
Block a user