diff options
author | Kris Maglione <maglione.k@gmail.com> | 2011-10-03 22:52:22 -0400 |
---|---|---|
committer | Kris Maglione <maglione.k@gmail.com> | 2011-10-03 22:52:22 -0400 |
commit | 1afa56335d0c54d8b2a9694c31721c7147bfe063 (patch) | |
tree | c383af756859036b0c562178fbc48a8625a03be4 /common/modules/config.jsm | |
parent | 54357e1f226a5ea44bd613d3538ea9c17d051040 (diff) | |
download | pentadactyl-1afa56335d0c54d8b2a9694c31721c7147bfe063.tar.gz |
Add a conditional clause because conditional clauses are awesome.
Diffstat (limited to 'common/modules/config.jsm')
-rw-r--r-- | common/modules/config.jsm | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/common/modules/config.jsm b/common/modules/config.jsm index 75c854fe..fbcbcea6 100644 --- a/common/modules/config.jsm +++ b/common/modules/config.jsm @@ -259,11 +259,14 @@ var ConfigBase = Class("ConfigBase", { } function processJar(file) { let jar = services.ZipReader(file); - if (jar) { - if (jar.hasEntry("chrome.manifest")) - process(File.readStream(jar.getInputStream("chrome.manifest"))); - jar.close(); - } + if (jar) + try { + if (jar.hasEntry("chrome.manifest")) + process(File.readStream(jar.getInputStream("chrome.manifest"))); + } + finally { + jar.close(); + } } for each (let dir in ["UChrm", "AChrom"]) { |