Commit 4bd52b3c authored by Jeffrey I. Schiller's avatar Jeffrey I. Schiller

Close the "fixid" mapfile when no longer needed.

Change-Id: Ifa2245e7032ad00b54624ba96de85396af4c1560
parent 25b4566e
...@@ -64,7 +64,9 @@ public class IdMap { ...@@ -64,7 +64,9 @@ public class IdMap {
IdMap() { IdMap() {
validfixId = false; validfixId = false;
try { try {
parseToMap(new CsvParser(new FileInputStream(pathTofixId))); FileInputStream mapfile = new FileInputStream(pathTofixId);
parseToMap(new CsvParser(mapfile));
mapfile.close(); // Avoid file descriptor leak, expicitly close the mapfile once we no longer need it.
if (addresses.size() == 0) { if (addresses.size() == 0) {
LOG.severe("fixid list contained no entries."); LOG.severe("fixid list contained no entries.");
} else { } else {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment