From f2309f52e8710ef14f62f0cbb16527287aa5720d Mon Sep 17 00:00:00 2001 From: Jonathan Bauer Date: Mon, 13 Sep 2021 14:58:04 +0200 Subject: [dnbd3-rootfs] assign return_code before printing it --- modules.d/dnbd3-rootfs/hooks/fetch-config.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/modules.d/dnbd3-rootfs/hooks/fetch-config.sh b/modules.d/dnbd3-rootfs/hooks/fetch-config.sh index 2f075cc9..a282fa28 100755 --- a/modules.d/dnbd3-rootfs/hooks/fetch-config.sh +++ b/modules.d/dnbd3-rootfs/hooks/fetch-config.sh @@ -36,6 +36,7 @@ config_path="/etc/openslx.tmp" echo "Downloading '$config_url'..." slx-tools download_retry -s "$config_url" > "$config_path" +return_code="$?" if [ ! -s "$config_path" ] ; then emergency_shell "Downloading netboot configuration file from '$config_url' failed with: $return_code" -- cgit v1.2.3-55-g7522