Permalink
Browse files

Merge pull request #35 from tivac/25dd3d9c884ed9596e07ffd4b168613782a…

…cdc0e

Closing FileOutputStream
  • Loading branch information...
2 parents 2e168c0 + 25dd3d9 commit 17f9872611f28eb042e74adfaa28f753d92e0d6b @nzakas committed Nov 23, 2011
Showing with 4 additions and 1 deletion.
  1. +4 −1 src/net/nczonline/web/cssembed/CSSEmbedTask.java
@@ -228,11 +228,14 @@ private void embed(File input, File output, int options) throws IOException {
out.close();
if(bytes.size() > 0) {
+ FileOutputStream fos = new FileOutputStream(output);
+
if(verbose) {
log("[INFO] Writing to file: " + output);
}
- bytes.writeTo(new FileOutputStream(output));
+ bytes.writeTo(fos);
+ fos.close();
}
}
}

0 comments on commit 17f9872

Please sign in to comment.