Skip to content

Commit e05ff43

Browse files
lwesiersgfxbot
authored andcommitted
Fix issue on clearlinux with generating _igc_bif_BC_122_size.
Fixes #75 Change-Id: I105e7818dd6b7491e497882b461b43f704c7ce7b
1 parent e5229c2 commit e05ff43

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

IGC/BiFModule/resource_embedder.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def PrintHelp():
7676

7777

7878
try:
79-
outFile = open(sys.argv[2], 'wb')
79+
outFile = open(sys.argv[2], 'w')
8080
except EnvironmentError as ex:
8181
sys.stderr.write('ERROR: Cannot create/open output file "{0}".\n {1}.\n'.format(sys.argv[2], ex.strerror))
8282
exit(1)
@@ -103,6 +103,9 @@ def PrintHelp():
103103

104104
except Exception as ex:
105105
sys.stderr.write('ERROR: Unknown error.\n {0}.\n'.format(repr(ex)))
106+
for openedFile in openedFiles:
107+
openedFile.close()
108+
exit(1)
106109
finally:
107110
for openedFile in openedFiles:
108111
openedFile.close()

0 commit comments

Comments
 (0)