add overrun check to SEE

master
Ondřej Hruška 2 years ago
parent 6e045af565
commit 10dbb3b425
  1. 6
      src/fh_see.c

@ -15,6 +15,12 @@ static void show_word(struct fh_thread_s *fh, const struct fh_word_s *w)
while (1) {
// make sure it's aligned
execptr = WORDALIGNED(execptr);
if (execptr == 0 || execptr > fh->here) {
LOGE("Exec overrun without ENDWORD!");
break;
}
FHPRINT("0x%08x: ", execptr);
const struct fh_instruction_s *instr = fh_instr_at(fh, execptr);
if (!instr) {

Loading…
Cancel
Save