Skip to content

Commit

Permalink
Prevent attempting to load any class twice
Browse files Browse the repository at this point in the history
  • Loading branch information
NathanJPhillips committed Mar 28, 2018
1 parent 97a6713 commit 84b6f65
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/java_bytecode/java_bytecode_convert_class.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,12 @@ void java_bytecode_convert_classt::operator()(
PRECONDITION(!parse_trees.empty());
const irep_idt &class_name = parse_trees.front().parsed_class.name;

if (symbol_table.has_symbol("java::" + id2string(class_name)))
{
debug() << "Skip class " << class_name << " (already loaded)" << eom;
return;
}

// Add array types to the symbol table
add_array_types(symbol_table);

Expand Down

0 comments on commit 84b6f65

Please sign in to comment.