Fixes #34 - Trace shows old stack values

This commit is contained in:
Stefan Arentz 2016-11-21 22:52:43 -05:00
parent a1f656b630
commit 15b3eda350

1
fmt.c
View File

@ -43,6 +43,7 @@ void cpu_format_state(struct cpu_t *cpu, char *buffer) {
}
void cpu_format_stack(struct cpu_t *cpu, char buffer[764]) {
buffer[0] = 0x00;
if (cpu->state.sp != 0xff) {
char *p = buffer;
*p = 0x00;