Fix a bug where v[X] was not handled in 0xFX55 and 0xFX65, use memcpy instead of looping, increment i like in the original implementation
This commit is contained in:
parent
522af3833a
commit
ab05516329
@ -388,13 +388,13 @@ op_handler(void)
|
||||
pc += 2;
|
||||
return 1;
|
||||
case 0xF055:
|
||||
for (register uint_fast8_t t = 0; t < X; ++t)
|
||||
memory[i + t] = v[t];
|
||||
memcpy(memory + i, v, ((X) + 1) * sizeof(byte));
|
||||
i += (X) + 1;
|
||||
pc += 2;
|
||||
return 1;
|
||||
case 0xF065:
|
||||
for (register uint_fast8_t t = 0; t < X; ++t)
|
||||
v[t] = memory[i + t];
|
||||
memcpy(v, memory + i, ((X) + 1) * sizeof(byte));
|
||||
i += (X) + 1;
|
||||
pc += 2;
|
||||
return 1;
|
||||
default:
|
||||
|
Loading…
Reference in New Issue
Block a user