1--TEST--
2Test function getservbyname() by calling it more than or less than its expected arguments
3--CREDITS--
4Italian PHP TestFest 2009 Cesena 19-20-21 june
5Fabio Fabbrucci (fabbrucci@grupporetina.com)
6Michele Orselli (mo@ideato.it)
7Danilo Sanchi (sanchi@grupporetina.com)
8--FILE--
9<?php
10$service = "www";
11$protocol = "tcp";
12$extra_arg = 12;
13var_dump(getservbyname($service, $protocol, $extra_arg ) );
14var_dump(getservbyname($service));
15?>
16--EXPECTF--
17Warning: getservbyname() expects exactly 2 parameters, %d given in %s on line %d
18NULL
19
20Warning: getservbyname() expects exactly 2 parameters, %d given in %s on line %d
21NULL
22