sign_official_buid: Fix "incorrect rootfs hash" when image has no firmware updater .

For each mount_image_partition, we have to unmount explicitly before doing other
changes (especially when using dd) to image. Otherwise system may flush data
when releaseing loop device and cause output image to be corrupted.

BUG=chromium:449450 factory factory_install_shim.bin \
     ../../../tests/devkeys signed.bin ../../../tests/devkeys/key.versions verify signed.bin

Change-Id: I20756d9769c3737e25cfea348a9a4d64cc43b202
Signed-off-by: Hung-Te Lin <>
Reviewed-by: Mike Frysinger <>
1 file changed