mirror of
https://github.com/Alvin-Zilverstand/bob16.git
synced 2026-12-03 14:51:19 +01:00
make output work on linux hopefully
This commit is contained in:
1 parent
f71f008aee
commit
cc01942b5b
1 file changed
+3
-1
@@ -295,6 +295,8 @@ void execute() {
|
||||
cpu.pc++;
|
||||
}
|
||||
|
||||
putchar('\n');
|
||||
|
||||
cpu.pc = cpu.regFile[7];
|
||||
break;
|
||||
case GETS:
|
||||
@@ -407,7 +409,7 @@ int assemble() {
|
||||
return -4;
|
||||
}
|
||||
|
||||
if (sscanf(tokens[1], "%x", &instruction) != 1) {
|
||||
if (sscanf(tokens[1], "%hX", &instruction) != 1) {
|
||||
printf("Wrong token on line %d!\n", lineCount);
|
||||
return -3;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user