diff --git a/bin/tests/system/idna/tests.sh b/bin/tests/system/idna/tests.sh index b4aaf6e71b..19a086dff2 100644 --- a/bin/tests/system/idna/tests.sh +++ b/bin/tests/system/idna/tests.sh @@ -11,9 +11,13 @@ SYSTEMTESTTOP=.. . $SYSTEMTESTTOP/conf.sh # Set known locale for the tests -LC_ALL="en_US.UTF-8" -export LC_ALL +if locale -a | grep -qE "^C\\.(UTF-8|utf8)"; then + LC_ALL="C.UTF-8" +elif locale -a | grep -qE "^en_US\\.(UTF-8|utf8)"; then + LC_ALL="en_US.UTF-8" +fi +export LC_ALL # This set of tests check the behavior of the IDNA options in "dig". #