Skip to content

Commit

Permalink
Avoid ConcurrentModificationException when reading column names
Browse files Browse the repository at this point in the history
  • Loading branch information
lenhard committed Dec 28, 2015
1 parent 0b588f5 commit 372d06d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/main/java/net/sf/jabref/sql/importer/DBImporter.java
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,9 @@ public ArrayList<Object[]> performImport(DBStrings dbs, List<String> listOfDBs)
rsEntryType.getStatement().close();
}

List<String> colNames = this.readColumnNames(conn);
for (String next : colNames) {
List<String> allColNames = this.readColumnNames(conn);
List<String> colNames = new ArrayList<>(allColNames.size());
for (String next : allColNames) {
if (!columnsNotConsideredForEntries.contains(next)) {
colNames.add(next);
}
Expand Down

0 comments on commit 372d06d

Please sign in to comment.