exit if user hits the cancel button in dialog mode; bug 108137
authorSimon Stelling <blubb@gentoo.org>
Thu, 13 Apr 2006 17:59:44 +0000 (17:59 -0000)
committerSimon Stelling <blubb@gentoo.org>
Thu, 13 Apr 2006 17:59:44 +0000 (17:59 -0000)
svn path=/main/trunk/; revision=3141

bin/etc-update

index f39801894c5c540d06ef776f2303dd2f653e43e4..a8bf13325d299612244da80193aa14c14b2a5453 100755 (executable)
@@ -139,7 +139,7 @@ configuration file is followed by a list of possible replacement files."
                        else
                                dialog --title "${title}" --menu "${my_title}" \
                                        0 0 0 $(echo -e "-1 Exit\n$(<${TMP}/menuitems)") \
-                                       2> ${TMP}/input
+                                       2> ${TMP}/input || die "User termination!" 0
                                input=$(<${TMP}/input)
                        fi
                        if (( ${input} == -5 )); then
@@ -193,7 +193,7 @@ function do_file() {
                                else
                                        dialog --title "${title}" --menu "${my_title}" \
                                                0 0 0 `echo -e "$(<${TMP}/menuitems)\n${fcount} Exit"` \
-                                               2> ${TMP}/input
+                                               2> ${TMP}/input || die "User termination!" 0
                                        my_input=$(<${TMP}/input)
                                fi
                        fi # OVERWRITE_ALL