Skip to content

Commit

Permalink
Add check for nullptr dereference in process_port
Browse files Browse the repository at this point in the history
  • Loading branch information
Szelwiga committed Nov 28, 2024
1 parent fa2bcb1 commit e780935
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/frontends/systemverilog/uhdm_ast.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4997,6 +4997,8 @@ void UhdmAst::process_port()
std::vector<AST::AstNode *> unpacked_ranges; // comes after wire name
if (lowConn_h) {
vpiHandle actual_h = vpi_handle(vpiActual, lowConn_h);
if (!actual_h)
log_error("vpiPort doesn't contain vpiActual in it's subtree. Aborting.\n");
auto actual_type = vpi_get(vpiType, actual_h);
switch (actual_type) {
case vpiModport: {
Expand Down

0 comments on commit e780935

Please sign in to comment.