summaryrefslogtreecommitdiff
path: root/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt')
-rw-r--r--ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt24
1 files changed, 12 insertions, 12 deletions
diff --git a/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt b/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt
index 88654e1973..ff61d3a230 100644
--- a/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt
+++ b/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt
@@ -8,8 +8,8 @@ if (!defined('IPPROTO_IPV6'))
die('skip IPv6 not available.');
/* Windows supports IPV6_RECVTCLASS and is able to receive the tclass via
* WSARecvMsg (though only the top 6 bits seem to reported), but WSASendMsg
- * does not accept IPV6_TCLASS messages. We still test that sendmsg() works
- * corectly by sending an IPV6_PKTINFO message that will have no effect */
+ * does not accept IPV6_TCLASS messages. We still test that sendmsg() works
+ * correctly by sending an IPV6_PKTINFO message that will have no effect */
--FILE--
<?php
include __DIR__."/mcast_helpers.php.inc";
@@ -32,16 +32,16 @@ socket_set_option($s, IPPROTO_IPV6, IPV6_RECVPKTINFO, 1) or die("err");
socket_set_option($s, IPPROTO_IPV6, IPV6_RECVTCLASS, 1) or die("err");
$r = socket_sendmsg($sends1, [
- "name" => [ "addr" => "::1", "port" => 3003],
- "iov" => ["test ", "thing", "\n"],
- "control" => [[
- "level" => IPPROTO_IPV6,
- "type" => IPV6_PKTINFO,
- "data" => [
- 'addr' => '::1',
+ "name" => [ "addr" => "::1", "port" => 3003],
+ "iov" => ["test ", "thing", "\n"],
+ "control" => [[
+ "level" => IPPROTO_IPV6,
+ "type" => IPV6_PKTINFO,
+ "data" => [
+ 'addr' => '::1',
'ifindex' => 1 /* we're assuming loopback is 1. Is this a safe assumption? */
- ],
- ]]
+ ],
+ ]]
], 0);
var_dump($r);
checktimeout($s, 500);
@@ -50,7 +50,7 @@ $data = [
"name" => ["family" => AF_INET6, "addr" => "::1"],
"buffer_size" => 2000,
"controllen" => socket_cmsg_space(IPPROTO_IPV6, IPV6_PKTINFO) +
- socket_cmsg_space(IPPROTO_IPV6, IPV6_TCLASS),
+ socket_cmsg_space(IPPROTO_IPV6, IPV6_TCLASS),
];
if (!socket_recvmsg($s, $data, 0)) die("recvmsg");
print_r($data);