$portfree » History » Version 3
Per Amundsen, 02/23/2023 07:16 PM
| 1 | 1 | Per Amundsen | _Added in 1.9.0_ |
|---|---|---|---|
| 2 | |||
| 3 | *$portfree(N,[ipaddress])* |
||
| 4 | |||
| 5 | Returns [[$true]] if the specified port number is not in use, otherwise [[$false]]. |
||
| 6 | |||
| 7 | *Parameters* |
||
| 8 | |||
| 9 | 3 | Per Amundsen | table(ktable). |
| 10 | |*Parameter*|*Description*| |
||
| 11 | | N | The port number to check. | |
||
| 12 | | [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. | |
||
| 13 | 1 | Per Amundsen | |
| 14 | *Example* |
||
| 15 | |||
| 16 | <pre> |
||
| 17 | ; Check if port 4242 is free. |
||
| 18 | //echo -ag Port 4242 is $iif($portfree(4242), open, not open) |
||
| 19 | </pre> |