Skip to content

Commit d5e2761

Browse files
committed
Close InputStream within finally block
See #292 (comment).
1 parent 9100b13 commit d5e2761

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

core/src/main/java/com/github/jsonldjava/utils/JsonUtils.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,10 @@ public static Object fromInputStream(InputStream input) throws IOException {
116116
}
117117
}
118118
return fromInputStream(bOMInputStream, charset);
119+
} finally {
120+
if (input != null) {
121+
input.close();
122+
}
119123
}
120124
}
121125

0 commit comments

Comments
 (0)