From c14496eabe153f9b8a5642be41ef74fdc4813d79 Mon Sep 17 00:00:00 2001 From: Helmut Grohne Date: Sun, 19 Mar 2023 19:48:29 +0100 Subject: debvm-waitssh: improve comment about character ranges Reported-by: Jakub Wilk --- bin/debvm-waitssh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'bin') diff --git a/bin/debvm-waitssh b/bin/debvm-waitssh index 82eb14d..2b843a5 100755 --- a/bin/debvm-waitssh +++ b/bin/debvm-waitssh @@ -151,8 +151,8 @@ case "$HOST" in *@*) # Guard against strings containing anything but digits, strings starting with # zero and empty strings as the port number. # -# We cannot use [!0-9] because that matches on any character (or possibly -# multi-character collation element) that sorts in between 0 and 9. +# In some locales, [0-9] can match other kinds of digits, see +# https://unix.stackexchange.com/a/414230/46985. case "$PORT" in *[!0123456789]*|0?*|""|??????*) die "$0: port '$PORT' is not an integer between 1 and 65535" ;; esac -- cgit v1.2.3