Project

General

Profile

Actions

Added in 1.9.0

$portfree(N,[ipaddress])

Returns $true if the specified port number is not in use, otherwise $false.

Parameters

Parameter Description
N The port number to check.
[ipaddress] If specified, only the interface with that IP address is checked for used ports, otherwise all active interfaces are checked. An adapter name can also be used instead of an IP address.

Example

; Check if port 4242 is free.
//echo -ag Port 4242 is $iif($portfree(4242), open, not open)

Updated by Per Amundsen about 1 year ago · 3 revisions

Also available in: PDF HTML TXT