Exit on all failures and don't use a kernel dependent default gpt type

Thanks James Page <james.page@ubuntu.com> for the missing exit
This commit is contained in:
Guillaume Delacour
2014-07-23 01:20:48 +02:00
parent a920398fa3
commit fbb1ae5140

View File

@@ -147,7 +147,7 @@ EOF
;;
sgdisk)
$SGDISK_BIN $TEMP_DISK -${OPT_NEW} 1 -${OPT_CHANGE_NAME} 1:"${TEST_PART_DEFAULT_NAME}"
$SGDISK_BIN $TEMP_DISK -${OPT_NEW} 1 -${OPT_CHANGE_NAME} 1:"${TEST_PART_DEFAULT_NAME}" -${OPT_CHANGE_TYPE} 1:$TEST_PART_TYPE
;;
esac
@@ -311,6 +311,7 @@ EOF
pretty_print "SUCCESS" "GUID of disk has been sucessfully changed"
else
pretty_print "FAILED" "GUID of disk is the same as the previous one"
exit 1
fi
}