From a702bab465d9d9cbb6aaad711aae7c7370c4adac Mon Sep 17 00:00:00 2001 From: GloriousEggroll Date: Thu, 8 Feb 2024 18:34:33 -0700 Subject: [PATCH] fixup incorrect posix ldconfig_output case (credits user: https://github.com/apprehensions) and remove double exit 1 lines --- ulwgl-run | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/ulwgl-run b/ulwgl-run index 9cda6e4..2ca1116 100755 --- a/ulwgl-run +++ b/ulwgl-run @@ -32,7 +32,7 @@ fi if [ -n "$PROTONPATH" ]; then if [ ! -d "$PROTONPATH" ]; then - echo "ERROR: $PROTONPATH is invalid, aborting!" exit 1 + echo "ERROR: $PROTONPATH is invalid, aborting!" exit 1 fi fi @@ -68,15 +68,15 @@ if [ -z "$STEAM_RUNTIME_LIBRARY_PATH" ]; then echo "Warning: An unexpected error occurred while executing \"/sbin/ldconfig -XNv\", the exit status was $exit_status" fi - echo "$ldconfig_output" | while IFS= read -r line; do + while read -r line; do # If line starts with a leading / and contains :, it's a new path prefix - case "$line" in - /*:*) + case "$line" in /*:*) library_path_prefix=$(echo "$line" | cut -d: -f1) - host_library_paths="$host_library_paths$library_path_prefix:" - ;; + host_library_paths=$host_library_paths$library_path_prefix: esac - done + done <