Skip to content

Commit

Permalink
add check for translation error in ibus error generation
Browse files Browse the repository at this point in the history
  • Loading branch information
wysiwyng committed Jan 23, 2024
1 parent 9fa1218 commit 739573d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/Translation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -491,6 +491,9 @@ etiss::int32 Translation::translateBlock(CodeBlock &cb)
auto instr = &vis_->getMain()->getInvalid();
CodeBlock::Line &line = cb.append(cb.endaddress_); // allocate codeset for instruction
bool ok = instr->translate(errba, line.getCodeSet(), context);
if (unlikely(!ok)) {
return etiss::RETURNCODE::GENERALERROR;
}
cb.endaddress_ += mainba.byteCount(); // update end address
return etiss::RETURNCODE::NOERROR;
}
Expand Down

0 comments on commit 739573d

Please sign in to comment.