build_image_util.sh: Don't compress extracted partition unnecessarily

I know I recently deduplicated the code between extract_update and
generate_update recently, but now that generate_update will sometimes be
called at a later time, I've realised that it is compressing and
uploading the partition twice.

Signed-off-by: James Le Cuirot <jlecuirot@microsoft.com>
This commit is contained in:
James Le Cuirot 2024-12-20 17:55:11 +00:00
parent 94f95acdc7
commit 29a5131380
No known key found for this signature in database
GPG Key ID: 1226415D00DD3137

View File

@ -79,7 +79,9 @@ generate_update() {
local devkey="/usr/share/update_engine/update-payload-key.key.pem"
# Extract the partition if it isn't extracted already.
[[ -s ${update} ]] || extract_update "${image_name}" "${disk_layout}"
[[ -s ${update} ]] ||
"${BUILD_LIBRARY_DIR}/disk_util" --disk_layout="${disk_layout}" \
extract "${BUILD_DIR}/${image_name}" "USR-A" "${update}"
echo "Generating update payload, signed with a dev key"
delta_generator \