OSDN Git Service

resource閉じ忘れ修正
authoryukihane <yukihane.feather@gmail.com>
Mon, 12 Sep 2011 03:15:39 +0000 (12:15 +0900)
committeryukihane <yukihane.feather@gmail.com>
Mon, 12 Sep 2011 03:15:39 +0000 (12:15 +0900)
frontend/src/saccubus/FfmpegOption.java

index 59d4857..7d742ad 100644 (file)
@@ -25,7 +25,9 @@ public class FfmpegOption {
 
     public static FfmpegOption load(File file) throws IOException {
         Properties prop = new Properties();
-        prop.loadFromXML(new FileInputStream(file));
+        try (final FileInputStream fis = new FileInputStream(file)) {
+            prop.loadFromXML(fis);
+        }
         String ext = prop.getProperty("EXT");
         String main = prop.getProperty("MAIN", "");
         String in = prop.getProperty("IN", "");