cros_bundle_firmware: Use enter/exit instead of del

This change makes use of Python's 'with' construct which is a nicer way to
deal with the finalization problem.

TEST=run cros_bundle_firmware; check that output is still consistent and
output directory is removed.

Change-Id: I81045a5e52af68f512dbf4a48a6151832e7c47d5
Reviewed-by: Che-Liang Chiou <>
Tested-by: Simon Glass <>
3 files changed