diff --git a/dracut-module-setup.sh b/dracut-module-setup.sh
index 141a67e..515cff0 100755
--- a/dracut-module-setup.sh
+++ b/dracut-module-setup.sh
@@ -516,7 +516,10 @@ kdump_setup_znet() {
 kdump_get_ip_route()
 {
     local _route=$(/sbin/ip -o route get to $1 2>&1)
-    [ $? != 0 ] && die "Bad kdump network destination: $1"
+    if [[ $? != 0 ]]; then
+        derror "Bad kdump network destination: $1"
+        exit 1
+    fi
     echo $_route
 }