From 683ccfc78ffb621bdf3265d4c10d517ac285aa48 Mon Sep 17 00:00:00 2001 From: hidnplayr Date: Thu, 30 Sep 2021 16:36:29 +0000 Subject: [PATCH] Bugfix from 'Jurgen' for repne scasw / repnz stosw and handling of unknown/invalid opcodes. See https://board.kolibrios.org/viewtopic.php?p=77209#p77209 for details. git-svn-id: svn://kolibrios.org@9209 a494cfbc-eb01-0410-851d-a64ba20cac60 --- programs/develop/mtdbg/disasm.inc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/programs/develop/mtdbg/disasm.inc b/programs/develop/mtdbg/disasm.inc index 7f3292a0a5..44d1b6c465 100644 --- a/programs/develop/mtdbg/disasm.inc +++ b/programs/develop/mtdbg/disasm.inc @@ -264,8 +264,8 @@ crep: cmp al, 0x6E jz .prefix - .noprefix: pop [disasm_cur_pos] + .noprefix: and byte [edi-1], 0 ret @@ -328,6 +328,10 @@ crepnz: mov al, ' ' stosb movzx eax, dl + cmp al, 66h + je c66 + cmp al, 67h + je c67 cmp al, 0x6C jb crep.noprefix cmp al, 0x6F