projects
/
tools
/
bmap-tools.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1f81c69
)
BmapCreate: handle flush() exception
author
Artem Bityutskiy
<artem.bityutskiy@intel.com>
Fri, 23 Nov 2012 07:25:17 +0000
(09:25 +0200)
committer
Artem Bityutskiy
<artem.bityutskiy@intel.com>
Fri, 23 Nov 2012 11:22:17 +0000
(13:22 +0200)
We handle file.flush() exceptions for the image, but not for bmap. This is
inconsistent. Let's handle them for both.
Change-Id: Ie4e9e28b865d2dcb9da278d577443f3665a4a907
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@intel.com>
bmaptools/BmapCreate.py
patch
|
blob
|
history
diff --git
a/bmaptools/BmapCreate.py
b/bmaptools/BmapCreate.py
index
45bceaf
..
6a02af5
100644
(file)
--- a/
bmaptools/BmapCreate.py
+++ b/
bmaptools/BmapCreate.py
@@
-323,7
+323,11
@@
class BmapCreate:
self._bmap_file_end()
- self._f_bmap.flush()
+ try:
+ self._f_bmap.flush()
+ except IOError as err:
+ raise Error("cannot flush the bmap file '%s': %s" \
+ % (self._bmap_path, err))
self._f_image.seek(image_pos)