summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorjaortega <jaortega>2000-11-18 21:18:07 +0000
committerjaortega <jaortega>2000-11-18 21:18:07 +0000
commit8794638b9b3b29e49d9483cfd99ad46620fc7ebf (patch)
tree10f789434d8faa9e1c77670df767b3e11b5b548d
parentf1eda05c5389d2b79207e7b418a3189716a3fb61 (diff)
downloadmdk-8794638b9b3b29e49d9483cfd99ad46620fc7ebf.tar.gz
mdk-8794638b9b3b29e49d9483cfd99ad46620fc7ebf.tar.bz2
(mix_vm_run) the virtual machine halts if the program counter overflows
-rw-r--r--mixlib/mix_vm.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/mixlib/mix_vm.c b/mixlib/mix_vm.c
index 7e17979..3af272d 100644
--- a/mixlib/mix_vm.c
+++ b/mixlib/mix_vm.c
@@ -296,6 +296,7 @@ mix_vm_run (mix_vm_t *vm)
return MIX_VM_ERROR;
if (bp_is_set_ (vm, get_loc_ (vm)))
return MIX_VM_BREAK;
+ if (get_loc_ (vm) >= MIX_VM_CELL_NO) halt_ (vm, TRUE);
}
return MIX_VM_HALT;
}