2022-05-24 21:22:12 +02:00
|
|
|
use32
|
|
|
|
org 0
|
|
|
|
db 'MENUET01'
|
|
|
|
dd 1, start, i_end, e_end, e_end, 0, 0
|
|
|
|
|
|
|
|
__DEBUG__ = 1
|
|
|
|
__DEBUG_LEVEL__ = 1
|
|
|
|
|
|
|
|
include 'proc32.inc'
|
|
|
|
include 'macros.inc'
|
|
|
|
include 'debug-fdo.inc'
|
|
|
|
|
2022-06-25 00:41:23 +02:00
|
|
|
EFLAGS.ID = 1 SHL 21
|
|
|
|
|
2022-05-24 21:22:12 +02:00
|
|
|
start:
|
2022-06-25 00:41:23 +02:00
|
|
|
pushfd
|
|
|
|
btr dword[esp], BSF EFLAGS.ID
|
|
|
|
popfd
|
2023-01-12 22:24:06 +01:00
|
|
|
mov ecx, '0'
|
|
|
|
next_char:
|
|
|
|
cmp ecx, '9'
|
|
|
|
jbe @f
|
|
|
|
mov ecx, '0'
|
2022-06-25 00:41:23 +02:00
|
|
|
@@:
|
2023-01-12 22:24:06 +01:00
|
|
|
mcall 63, 1
|
|
|
|
;jmp $
|
|
|
|
mcall 5, 10
|
|
|
|
inc ecx
|
|
|
|
jmp next_char
|
2022-05-24 21:22:12 +02:00
|
|
|
exit:
|
|
|
|
mcall 18, 9, 2
|
|
|
|
mcall -1
|
|
|
|
mcall -2 ; just to check it's unreachable
|
|
|
|
|
2022-06-25 00:41:23 +02:00
|
|
|
;include_debug_strings
|
2022-05-24 21:22:12 +02:00
|
|
|
i_end:
|
|
|
|
rb 0x100 ;stack
|
|
|
|
e_end:
|