1--TEST--
2Test function getservbyname() by substituting argument 2 with emptyUnsetUndefNull values.
3--SKIPIF--
4<?php
5if(PHP_OS == 'Darwin') {
6  die("skip.. Mac OS X is fine with NULLs in getservbyname");
7}
8?>
9--FILE--
10<?php
11
12
13echo "*** Test substituting argument 2 with emptyUnsetUndefNull values ***\n";
14
15$service = "www";
16
17
18$unset_var = 10;
19unset($unset_var);
20
21$variation_array = array(
22  'unset var' => @$unset_var,
23  'undefined var' => @$undefined_var,
24  'empty string DQ' => "",
25  'empty string SQ' => '',
26  'uppercase NULL' => NULL,
27  'lowercase null' => null,
28  );
29
30
31foreach ( $variation_array as $var ) {
32  var_dump(getservbyname( $service, $var  ) );
33}
34?>
35--EXPECT--
36*** Test substituting argument 2 with emptyUnsetUndefNull values ***
37bool(false)
38bool(false)
39bool(false)
40bool(false)
41bool(false)
42bool(false)
43