diff --git a/data/helpers.d/network b/data/helpers.d/network index e06656820..42616d513 100644 --- a/data/helpers.d/network +++ b/data/helpers.d/network @@ -5,7 +5,7 @@ # usage: ynh_find_port begin_port # | arg: begin_port - port to start to search ynh_find_port () { - port=$(echo "$1" | sed 's/[^0-9]//g') # Eliminate all non-digit characters + port=$1 test -n "$port" || ynh_die "The argument of ynh_find_port must be a valid port." while netcat -z 127.0.0.1 $port # Check if the port is free do