/
proc
/
3430793
/
root
/
usr
/
local
/
lsws
/
phpbuild
/
php-8.0.7
/
ext
/
snmp
/
tests
/
File Upload :
llllll
Current File: //proc/3430793/root/usr/local/lsws/phpbuild/php-8.0.7/ext/snmp/tests/bug60749.phpt
--TEST-- Bug #60749: SNMP module should not strip non-standard SNMP port from hostname --CREDITS-- Boris Lytochkin --SKIPIF-- <?php require_once(__DIR__.'/skipif.inc'); ?> --FILE-- <?php require_once(__DIR__.'/snmp_include.inc'); $hostname = "php.net"; $ip = gethostbyname($hostname); if (ip2long($ip) === FALSE) { echo "Could not resolve $hostname properly!\n"; exit(1); } $port = 1161; $session = new SNMP(SNMP::VERSION_1, "$hostname:$port", $community, $timeout, $retries); $info = $session->info; if (strcmp($info["hostname"], "$ip:$port") !== 0) { echo "'" . $info["hostname"] . "' != '$ip:$port'\n"; } var_dump($session->close()); ?> --EXPECT-- bool(true)
Copyright ©2k19 -
Hexid
|
Tex7ure