Skip to content
Snippets Groups Projects
Commit b8e3aec5 authored by Seblu's avatar Seblu
Browse files

Fix confirm loop when stdout is closed

parent 5e60f858
No related branches found
No related tags found
No related merge requests found
...@@ -83,7 +83,7 @@ confirm_restart() { ...@@ -83,7 +83,7 @@ confirm_restart() {
if (( $confirm == 1 )); then if (( $confirm == 1 )); then
while true; do while true; do
printf 'Confirm services restart? [y|N] ' printf 'Confirm services restart? [y|N] '
read -r ans read -r ans || return 1
case $ans in case $ans in
y|Y|yes|Yes) return 0;; y|Y|yes|Yes) return 0;;
n|N|no|No) return 1;; n|N|no|No) return 1;;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment