From 4d0bf673a577b23edab3fddea88bf54b9d2b66a4 Mon Sep 17 00:00:00 2001 From: olli <> Date: Wed, 26 Jun 2024 21:17:24 +0200 Subject: [PATCH] fixes --- gaboshlib/g_python.sh | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/gaboshlib/g_python.sh b/gaboshlib/g_python.sh index 1ff71a4..cfa10b2 100644 --- a/gaboshlib/g_python.sh +++ b/gaboshlib/g_python.sh @@ -33,17 +33,22 @@ print('')" >&${g_fd_python_in} read -u ${g_fd_python_out} g_python_result local g_errline - local g_err_array + local g_err_msg # look for error while read -t 0.001 -u ${g_fd_python_error} g_errline do [[ "$g_errline" =~ \>\>\>$ ]] && break [ -z "$g_errline" ] && break - echo $g_errline 1>&2 - g_err_array+=("$g_errline") + g_err_msg="$g_err_msg +$g_errline" done - [ -n "$g_err_array" ] && return 1 + if [ -n "$g_err_msg" ] + then + g_echo_error "$g_err_msg" + return 1 + fi + }