diff options
Diffstat (limited to 'subx/010---vm.cc')
-rw-r--r-- | subx/010---vm.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/subx/010---vm.cc b/subx/010---vm.cc index 9fbecbc0..6fac9cf7 100644 --- a/subx/010---vm.cc +++ b/subx/010---vm.cc @@ -223,8 +223,10 @@ inline uint8_t* mem_addr_u8(uint32_t addr) { result = &Mem.at(i).data(addr); } } - if (result == NULL) + if (result == NULL) { + if (Trace_file) Trace_file.flush(); raise << "Tried to access uninitialized memory at address 0x" << HEXWORD << addr << '\n' << end(); + } return result; } inline int8_t* mem_addr_i8(uint32_t addr) { |