소스 검색

Compiler throws warnings all over the place about our close methods, this one is no different.

GJ 11 년 전
부모
커밋
d8f3a54f9b
1개의 변경된 파일1개의 추가작업 그리고 8개의 파일을 삭제
  1. 1 8
      src/main/java/com/gmail/nossr50/database/FlatfileDatabaseManager.java

+ 1 - 8
src/main/java/com/gmail/nossr50/database/FlatfileDatabaseManager.java

@@ -401,14 +401,7 @@ public final class FlatfileDatabaseManager implements DatabaseManager {
                 e.printStackTrace();
             }
             finally {
-                // Silly inlining of tryClose() because the compiler is giving a warning when I use tryClose()
-                try {
-                    if (in != null) {
-                        in.close();
-                    }
-                }
-                catch (IOException e) {
-                }
+                tryClose(in);
             }
         }