From 1e5e330b7a100636ef7d3874a322e7c23d7fe575 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Tue, 3 Mar 2015 18:28:19 +0100 Subject: [PATCH] common: Allow undefined $gsu_errors. If this variable is undefined, and the nounset option is turned on (set -u), gsu aborts early when setting up the gsu_error_txt array. Fix this by using ${gsu_errors:-} instead of plain $gsu_errors to allow for scripts without error codes. Reported by Congmao Wang. --- common | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common b/common index e326890..d418095 100644 --- a/common +++ b/common @@ -19,7 +19,7 @@ E_GSU_GETOPTS getopts error E_GSU_DIALOG dialog error E_GSU_MKTEMP mktemp error E_GSU_MENU_TREE invalid menu tree -$gsu_errors +${gsu_errors:-} " local a b i=0 while read a b; do -- 2.30.2