From 697c8cc1f9acbe508be2b5ce144291a11ec65140 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Sun, 8 Dec 2019 19:39:09 +0100 Subject: [PATCH] Forcing locale "C" to avoid grep ambiguities and locale bugs --- xorriso-dd-target/xorriso-dd-target | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/xorriso-dd-target/xorriso-dd-target b/xorriso-dd-target/xorriso-dd-target index e054ff1b..2d3fe662 100755 --- a/xorriso-dd-target/xorriso-dd-target +++ b/xorriso-dd-target/xorriso-dd-target @@ -5,6 +5,9 @@ # Thomas Schmitt # Provided under GPL version 2 or later. +export LANG=C +export LC_ALL=C + # Check whether we are on GNU/Linux if uname -s | grep -v '^Linux' >/dev/null then @@ -139,7 +142,7 @@ round_down_div_million() { check_parameter() { if test "$2" = "device_name" then - if echo "$1" | grep '[^A-za-z0-9_/-]' >/dev/null + if echo "$1" | grep '[^A-Za-z0-9_/-]' >/dev/null then echo "SORRY: Given device name contains unexpected character. Ok: [A-za-z0-9_/-]" >&2 exit 12