Fix password echo

This commit is contained in:
Richard Bonhomme authored and GitHub committed 2018-12-16 18:16:48 +00:00
1 parent 96696bcc7b
commit 482c4b517f
1 file changed
+3 -3
+3 -3
View File
@@ -298,7 +298,7 @@ clean_temp() {
prog_exit() {
ESTAT=0
[ ! -z "$1" ] && ESTAT=$1
(set -o echo 2>/dev/null) || stty echo
(stty echo 2>/dev/null) || set -o echo
echo "" # just to get a clean line
exit "$ESTAT"
} # => prog_exit()
@@ -463,9 +463,9 @@ Your newly created PKI dir is: $EASYRSA_PKI
hide_read_pass()
{
(set +o echo 2>/dev/null) || stty -echo
(stty -echo 2>/dev/null) || set +o echo
read -r "$@"
(set -o echo 2>/dev/null) || stty echo
(stty echo 2>/dev/null) || set -o echo
} # => hide_read_pass()
# build-ca backend: