mirror of
https://gitlab.com/shorewall/code.git
synced 2024-11-09 01:04:06 +01:00
Allow port numbers to be specified in Hex
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
5ec7759d81
commit
aad8ea837a
@ -301,7 +301,7 @@ sub validate_port( $$ ) {
|
||||
|
||||
my $value;
|
||||
|
||||
if ( $port =~ /^(\d+)$/ ) {
|
||||
if ( $port =~ /^(\d+)$/ || $port =~ /^0x/ ) {
|
||||
$port = numeric_value $port;
|
||||
return $port if defined $port && $port && $port <= 65535;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user