diff --git a/kdumpctl b/kdumpctl index 40dcb1e..edf9d1b 100755 --- a/kdumpctl +++ b/kdumpctl @@ -142,6 +142,7 @@ rebuild_kdump_initrd() rebuild_initrd() { + local _ret if [[ ! -w $(dirname "$TARGET_INITRD") ]]; then derror "$(dirname "$TARGET_INITRD") does not have write permission. Cannot rebuild $TARGET_INITRD" return 1 @@ -152,8 +153,10 @@ rebuild_initrd() else rebuild_kdump_initrd fi + _ret=$? set_vmcore_creation_status 'clear' "$VMCORE_CREATION_STATUS" + return $_ret } #$1: the files to be checked with IFS=' '