Skip to content

Commit b0c1773

Browse files
andypostcmb69
authored andcommitted
Make socket path shorter for ext/sockets/tests/socket_cmsg_{rights|credentials}.phpt
When running in CI it fails when path/address is longer 108 Closes GH-8617.
1 parent b7b5ad7 commit b0c1773

File tree

2 files changed

+10
-6
lines changed

2 files changed

+10
-6
lines changed

ext/sockets/tests/socket_cmsg_credentials.phpt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,9 @@ die('skip SO_PASSCRED is not defined');
1616
}
1717
--FILE--
1818
<?php
19-
include __DIR__."/mcast_helpers.php.inc";
20-
$path = __DIR__ . "/socket_cmsg_credentials.sock";
19+
chdir(__DIR__);
20+
include "./mcast_helpers.php.inc";
21+
$path = "./socket_cmsg_credentials.sock";
2122

2223
@unlink($path);
2324

@@ -55,7 +56,8 @@ var_dump($data['control'][0]['data']['pid'] === $pid);
5556
?>
5657
--CLEAN--
5758
<?php
58-
$path = __DIR__ . "/socket_cmsg_credentials.sock";
59+
chdir(__DIR__);
60+
$path = "./socket_cmsg_credentials.sock";
5961
@unlink($path);
6062
--EXPECTF--
6163
creating send socket

ext/sockets/tests/socket_cmsg_rights.phpt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,14 @@ die('skip not for AIX');
1313
}
1414
--CLEAN--
1515
<?php
16-
$path = __DIR__ . "/socket_cmsg_rights.sock";
16+
chdir(__DIR__);
17+
$path = "./socket_cmsg_rights.sock";
1718
@unlink($path);
1819
--FILE--
1920
<?php
20-
include __DIR__."/mcast_helpers.php.inc";
21-
$path = __DIR__ . "/socket_cmsg_rights.sock";
21+
chdir(__DIR__);
22+
include "./mcast_helpers.php.inc";
23+
$path = "./socket_cmsg_rights.sock";
2224

2325
@unlink($path);
2426

0 commit comments

Comments
 (0)