]> granicus.if.org Git - php/commitdiff
Fix test (skip on unable to create socket)
authorXinchen Hui <laruence@php.net>
Sun, 3 Mar 2013 03:24:45 +0000 (11:24 +0800)
committerXinchen Hui <laruence@php.net>
Sun, 3 Mar 2013 03:24:45 +0000 (11:24 +0800)
ext/sockets/tests/mcast_ipv6_recv.phpt

index 38390c025cecc39a90f5117f407087ee1992797a..61d1e8458f14b842e594c05859bf83374c79a152 100644 (file)
@@ -9,6 +9,9 @@ if (!defined('IPPROTO_IPV6')) {
        die('skip IPv6 not available.');\r
 }\r
 $s = socket_create(AF_INET6, SOCK_DGRAM, SOL_UDP);\r
+if ($s === false) {\r
+  die("skip unable to create socket");\r
+}\r
 $br = socket_bind($s, '::', 3000);\r
 /* On Linux, there is no route ff00::/8 by default on lo, which makes it\r
  * troublesome to send multicast traffic from lo, which we must since\r