From 348c0af58c90587c0f818358d8fa471078f51b8f Mon Sep 17 00:00:00 2001 From: ADAM David Alan Martin Date: Sat, 4 Jun 2022 23:40:37 -0400 Subject: [PATCH] Report errors that were originally silent. --- bin/__build_sgr_code | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/bin/__build_sgr_code b/bin/__build_sgr_code index 1b101b7..74d9f14 100755 --- a/bin/__build_sgr_code +++ b/bin/__build_sgr_code @@ -116,7 +116,7 @@ function setup_color_depth() then use_3_bit=1 else - exit -1 + echo "ERROR!" 1>&2 ; exit -1 fi fi } @@ -149,7 +149,7 @@ function ansi_color() { if (( ${1} > 15 )) then - exit -1 + echo "ERROR!" 1>&2 ; exit -1 elif (( ${1} >= 8 )) then use_4_bit=1 @@ -165,10 +165,9 @@ function ansi_color() function ext_color() { use_8_bit=1 - selection=${1:4} if (( ${1} > 255 )) then - exit -1 + echo "ERROR!" 1>&2 ; exit -1 else ext_8_bit=${1} fi