Another fix.

This commit is contained in:
OBattler
2022-08-08 02:24:20 +02:00
parent 69a56d9d30
commit 745c9f3eb5
2 changed files with 10 additions and 1 deletions

View File

@@ -32,7 +32,12 @@ static int opAAM(uint32_t fetchdat)
{ {
int base = getbytef(); int base = getbytef();
if (!base || !cpu_isintel) base = 10; if (base == 0) {
x86de(NULL, 0);
return 1;
}
if (!cpu_isintel) base = 10;
AH = AL / base; AH = AL / base;
AL %= base; AL %= base;

View File

@@ -168,8 +168,12 @@ x86_doabrt(int x86_abrt)
void void
x86de(char *s, uint16_t error) x86de(char *s, uint16_t error)
{ {
#ifdef BAD_CODE
cpu_state.abrt = ABRT_DE; cpu_state.abrt = ABRT_DE;
abrt_error = error; abrt_error = error;
#else
x86_int(0);
#endif
} }