clean locales for timedatectl call
[mirror/dsa-nagios.git] / dsa-nagios-checks / checks / dsa-check-timedatectl
index 3711fc1..1c61cf3 100755 (executable)
@@ -61,7 +61,7 @@ fi
 temp="$(mktemp)"
 trap "rm -f '$temp'" EXIT
 
-timedatectl > "$temp"
+LC_ALL=C timedatectl > "$temp"
 ut=$(sed '/Universal time:/ { s/^[^:]*: *//; p}; d' "$temp")
 rtc=$(sed '/RTC time:/ { s/^[^:]*: *//; p}; d' "$temp")
 ntpenabled=$(sed '/\(NTP enabled\|Network time on\):/ { s/^[^:]*: *//; p}; d' "$temp")