Function at 0x42a210
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x238
mov dword [ebp - 0xc], ebx
mov dword [ebp - 8], edi
mov dword [ebp - 4], esi
mov esi, ecx
mov ebx, edx
mov edi, eax
mov edx, dword [0x4ee748]
mov eax, dword [0x4fb418]
dec eax
cmp edx, eax
jg 0x42a2c5
mov eax, dword [0x4fb41c]
mov ecx, dword [eax + edx*4]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x42a25b
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x42a246
dec eax
push eax
push ecx
push dword [ebx]
mov dword [esi], eax
call fcn.004ae9a0
add esp, 0xc
mov edx, dword [ebx]
mov eax, dword [esi]
mov byte [eax + edx], 0
mov ecx, dword [0x4ee748]
inc ecx
mov dword [0x4ee748], ecx
push ecx
push 0x4ee748
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
mov edx, dword [ebx]
mov eax, dword [esi]
cmp byte [edx], 0x20
jne 0x42a2a2
test eax, eax
jle 0x42a2bf
inc edx
mov dword [ebx], edx
dec eax
cmp byte [edx], 0x20
mov dword [esi], eax
je 0x42a293
test eax, eax
jle 0x42a2bf
movsx ecx, byte [eax + edx - 1]
cmp ecx, 0x20
je 0x42a2b8
test ecx, ecx
jne 0x42ab86
dec eax
mov dword [esi], eax
test eax, eax
jg 0x42a2a6
jne 0x42ab86
cmp dword [0x4fb140], 0
je 0x42a35b
push dword [edi + 0xf8]
push str.Open:_Select_File_for_Unit
lea eax, [ebp - 0x230]
push str._s_d
push eax
call fcn.0045b620
lea eax, [ebp - 0x230]
add esp, 0x10
mov edx, dword [ebx]
mov edi, eax
jmp 0x42a2ff
mov edx, dword [ebx]
push edi
push 0x100
push edx
call fcn.004b8f70
add esp, 0xc
test eax, eax
je 0x42a339
mov ecx, dword [ebx]
movzx edx, byte [ecx]
test edx, edx
je 0x42a339
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x42a332
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x42a31d
dec eax
mov dword [esi], eax
jmp 0x42ab86
push 0x2134
push str.File_Open_Error
push str.A_File_Must_be_Selected_r_rTerminate_Program_
call fcn.004b9100
add esp, 0xc
cmp eax, 6
je 0x42ab95
jmp 0x42a2fd
push 0
push 0x20b
call fcn.00405df0
lea edx, [ebp - 0x164]
push eax
push str._s_r_n
push edx
call fcn.0045b620
add esp, 0x14
lea ecx, [ebp - 0x164]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x42a399
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x42a384
dec eax
push dword [edi + 0xf8]
push 1
mov edx, eax
push 0x20c
mov dword [ebp - 0x230], edx
call fcn.00405df0
mov edx, dword [ebp - 0x230]
lea ecx, [ebp - 0x164]
push eax
push 0x4cbc60
add edx, ecx
push edx
call fcn.0045b620
add esp, 0x18
lea ecx, [ebp - 0x164]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x42a3ed
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x42a3d8
dec eax
cmp dword [edi + 0xf8], 6
mov dword [ebp - 0x10], eax
je 0x42a41a
lea edx, [ebp - 0x18]
lea eax, [ebp - 0x60]
push 4
push eax
push edx
push 6
call fcn.0041ac50
add esp, 0x10
test eax, eax
jne 0x42a47f
cmp dword [edi + 0xf8], 5
je 0x42a468
lea edx, [ebp - 0x14]
lea eax, [ebp - 0x40]
push 1
push eax
push edx
push 5
call fcn.0041ac50
mov dword [ebp - 0x230], eax
add esp, 0x10
cmp dword [ebp - 0x230], 0
je 0x42a468
cmp dword [edi + 0xf8], 6
je 0x42a455
mov eax, dword [ebp - 0x18]
push dword [eax + 0xf8]
call fcn.0041a480
pop ecx
mov eax, dword [ebp - 0x230]
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x1c]
push eax
push 1
push 0x178
call fcn.00419300
add esp, 0xc
test eax, eax
je 0x42a48c
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x20]
push eax
push 1
push 0x178
call fcn.00419300
add esp, 0xc
test eax, eax
je 0x42a4b0
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
push 0x178
push 0
push dword [ebp - 0x1c]
call fcn.004aea20
push 0x178
push 0
push dword [ebp - 0x20]
call fcn.004aea20
lea eax, [ebp - 0x230]
push 0xc4
push 0
push eax
call fcn.004aea20
add esp, 0x24
mov eax, dword [ebp - 0x1c]
mov dword [eax + 0xf8], 6
movzx ecx, byte [edi + 0x160]
and ecx, 1
mov eax, dword [ebp - 0x1c]
movzx edx, byte [eax + 0x160]
and edx, 0xfffffffe
or edx, ecx
mov byte [eax + 0x160], dl
movzx edx, byte [edi + 0x160]
mov ecx, dword [ebp - 0x1c]
movzx eax, byte [ecx + 0x160]
and eax, 0xfffffffd
and edx, 2
or eax, edx
mov byte [ecx + 0x160], al
mov edx, dword [ebp - 0x1c]
movzx ecx, byte [edx + 0x160]
movzx eax, byte [edi + 0x160]
and ecx, 0xfffffffb
and eax, 4
or ecx, eax
mov byte [edx + 0x160], cl
mov edx, dword [ebp - 0x1c]
movzx eax, byte [edx + 0x160]
movzx ecx, byte [edi + 0x160]
and eax, 0xfffffff7
and ecx, 8
or eax, ecx
mov byte [edx + 0x160], al
mov ecx, dword [ebp - 0x1c]
movzx edx, byte [ecx + 0x160]
movzx eax, byte [edi + 0x160]
and edx, 0xffffffdf
and eax, 0x20
or edx, eax
mov byte [ecx + 0x160], dl
mov ecx, dword [ebp - 0x1c]
movzx eax, byte [ecx + 0x169]
movzx edx, byte [edi + 0x169]
and eax, 0xfffffffb
and edx, 4
or eax, edx
mov byte [ecx + 0x169], al
movzx eax, byte [edi + 0x169]
and eax, 8
mov edx, dword [ebp - 0x1c]
movzx ecx, byte [edx + 0x169]
and ecx, 0xfffffff7
or ecx, eax
mov byte [edx + 0x169], cl
movzx ecx, byte [edi + 0x160]
mov edx, dword [ebp - 0x1c]
movzx eax, byte [edx + 0x160]
and eax, 0xffffffbf
and ecx, 0x40
or eax, ecx
mov byte [edx + 0x160], al
mov ecx, dword [ebp - 0x1c]
movzx edx, byte [ecx + 0x160]
movzx eax, byte [edi + 0x160]
and edx, 0x7f
and eax, 0xffffff80
or edx, eax
mov byte [ecx + 0x160], dl
mov ecx, dword [ebp - 0x1c]
movzx eax, byte [ecx + 0x160]
movzx edx, byte [edi + 0x160]
and eax, 0xffffffef
and edx, 0x10
or eax, edx
mov byte [ecx + 0x160], al
mov dword [ebp - 0x1d8], 4
mov eax, 1
mov dword [ebp - 0x230], eax
mov dword [ebp - 0x1fc], eax
mov ecx, 0x4cf958
mov dword [ebp - 0x204], ecx
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x42a664
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x42a64f
dec eax
mov edx, dword [ebp - 0x1c]
mov dword [ebp - 0x200], eax
lea eax, [ebp - 0x230]
call fcn.0042ada8
mov dword [ebp - 0x16c], eax
cmp dword [ebp - 0x16c], 0
je 0x42a6dd
push dword [ebp - 0x1c]
call fcn.004193c0
push dword [ebp - 0x20]
call fcn.004193c0
add esp, 8
cmp dword [edi + 0xf8], 6
je 0x42a6bb
mov eax, dword [ebp - 0x18]
push dword [eax + 0xf8]
call fcn.0041a480
pop ecx
cmp dword [edi + 0xf8], 5
je 0x42a6ca
mov eax, dword [ebp - 0x14]
push dword [eax + 0xf8]
call fcn.0041a480
pop ecx
mov eax, dword [ebp - 0x16c]
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x20]
mov dword [eax + 0xf8], 5
movzx ecx, byte [edi + 0x160]
and ecx, 1
mov eax, dword [ebp - 0x20]
movzx edx, byte [eax + 0x160]
and edx, 0xfffffffe
or edx, ecx
mov byte [eax + 0x160], dl
movzx edx, byte [edi + 0x160]
mov ecx, dword [ebp - 0x20]
movzx eax, byte [ecx + 0x160]
and eax, 0xfffffffd
and edx, 2
or eax, edx
mov byte [ecx + 0x160], al
mov edx, dword [ebp - 0x20]
movzx ecx, byte [edx + 0x160]
movzx eax, byte [edi + 0x160]
and ecx, 0xfffffffb
and eax, 4
or ecx, eax
mov byte [edx + 0x160], cl
mov edx, dword [ebp - 0x20]
movzx eax, byte [edx + 0x160]
movzx ecx, byte [edi + 0x160]
and eax, 0xfffffff7
and ecx, 8
or eax, ecx
mov byte [edx + 0x160], al
mov ecx, dword [ebp - 0x20]
movzx edx, byte [ecx + 0x160]
movzx eax, byte [edi + 0x160]
and edx, 0xffffffdf
and eax, 0x20
or edx, eax
mov byte [ecx + 0x160], dl
mov ecx, dword [ebp - 0x20]
movzx eax, byte [ecx + 0x169]
movzx edx, byte [edi + 0x169]
and eax, 0xfffffffb
and edx, 4
or eax, edx
mov byte [ecx + 0x169], al
movzx eax, byte [edi + 0x169]
and eax, 8
mov edx, dword [ebp - 0x20]
movzx ecx, byte [edx + 0x169]
and ecx, 0xfffffff7
or ecx, eax
mov byte [edx + 0x169], cl
movzx ecx, byte [edi + 0x160]
mov edx, dword [ebp - 0x20]
movzx eax, byte [edx + 0x160]
and eax, 0xffffffbf
and ecx, 0x40
or eax, ecx
mov byte [edx + 0x160], al
mov ecx, dword [ebp - 0x20]
movzx edx, byte [ecx + 0x160]
movzx eax, byte [edi + 0x160]
and edx, 0x7f
and eax, 0xffffff80
or edx, eax
mov byte [ecx + 0x160], dl
mov ecx, dword [ebp - 0x20]
movzx eax, byte [ecx + 0x160]
movzx edx, byte [edi + 0x160]
and eax, 0xffffffef
and edx, 0x10
or eax, edx
mov byte [ecx + 0x160], al
mov ecx, 0x4cf950
mov dword [ebp - 0x204], ecx
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x42a842
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x42a82d
dec eax
mov edx, dword [ebp - 0x20]
mov dword [ebp - 0x220], 0
mov dword [ebp - 0x200], eax
lea eax, [ebp - 0x230]
call fcn.0042ada8
mov dword [ebp - 0x16c], eax
cmp dword [ebp - 0x16c], 0
jne 0x42ad39
mov eax, dword [ebp - 0x1c]
mov byte [eax + 0x14e], 3
mov edx, dword [ebp - 0x1c]
or byte [edx + 0x165], 0x40
cmp dword [esi], 0
jne 0x42ab2f
mov dword [ebp - 0x64], edi
mov edi, dword [ebp - 0x1c]
push 0
push edi
call fcn.0041e580
add esp, 8
test eax, eax
jne 0x42acb4
movsx ecx, byte [edi + 0x14c]
lea eax, [ecx - 1]
cmp eax, 7
ja case.default.0x42a8c3
mov eax, dword [eax*4 + 0x4d243c]
jmp eax
mov edx, dword [edi + 0x40]
test edx, edx
je 0x42a8d1
mov dword [edi + 0x3c], edx
jmp 0x42a8d7
mov edx, dword [edi + 0x38]
mov dword [edi + 0x3c], edx
mov eax, dword [edi + 0xf0]
lea ecx, [edx + eax - 1]
movzx eax, byte [edi + 0x160]
mov dword [edi + 0x44], ecx
jmp 0x42aa0a
mov eax, dword [edi + 0x18]
test eax, eax
je 0x42aba6
test byte [eax + 0x44], 2
je 0x42a930
mov edx, 0x2c
mov dword [eax + 0x38], edx
mov eax, dword [edi + 0x18]
mov dword [eax + 0x3c], edx
mov eax, dword [edi + 0x64]
test eax, eax
je 0x42a91e
xor edx, edx
mov dword [eax + 4], edx
mov dword [edi + 0x64], edx
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov eax, 0x2c
mov esp, ebp
pop ebp
ret
movzx edx, byte [edi + 0x164]
and edx, 7
mov eax, 0x2c
push eax
push eax
push edx
push 0xffffffffffffffff
push edi
call fcn.004243b0
add esp, 0x14
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
mov edx, dword [edi + 0x40]
test edx, edx
je 0x42a966
add edx, 4
jmp 0x42a96c
mov edx, dword [edi + 0x38]
add edx, 4
mov eax, dword [edi + 0xf0]
mov dword [edi + 0x3c], edx
lea ecx, [edx + eax - 8]
movzx eax, byte [edi + 0x160]
mov dword [edi + 0x44], ecx
jmp 0x42aa0a
mov edx, dword [edi + 0x40]
test edx, edx
je 0x42a994
mov dword [edi + 0x3c], edx
jmp 0x42a99a
mov edx, dword [edi + 0x38]
mov dword [edi + 0x3c], edx
mov eax, dword [edi + 0xf0]
mov dword [ebp - 0x16c], eax
add eax, edx
mov dword [ebp - 0x168], eax
movzx eax, byte [edi + 0x160]
test al, 4
je 0x42a9d0
test byte [edi + 0x162], 0x40
je 0x42a9d0
test byte [edi + 0x163], 8
je 0x42a9d0
cmp ecx, 1
je 0x42a9db
mov ecx, dword [ebp - 0x168]
mov dword [edi + 0x44], ecx
jmp 0x42aa0a
mov ecx, dword [ebp - 0x16c]
lea ecx, [edx + ecx - 2]
mov dword [edi + 0x44], ecx
jmp 0x42aa0a
push 0x1608
push str.for_nt_open_proc.c
push 2
push 8
call fcn.00404e90
add esp, 0x10
movzx eax, byte [edi + 0x160]
mov edx, dword [edi + 0x3c]
test al, 4
je 0x42aa29
test byte [edi + 0x162], 0x40
je 0x42aa29
test byte [edi + 0x163], 8
je 0x42aa29
cmp byte [edi + 0x14c], 1
je 0x42aa74
movsx eax, byte [edi + 0x14e]
cmp eax, 2
jne 0x42aa50
movsx eax, byte [edi + 0x14c]
cmp eax, 7
je 0x42aa74
cmp eax, 6
je 0x42aa74
cmp eax, 8
je 0x42aa74
dec dword [edi + 0x44]
jmp 0x42aa74
cmp eax, 1
jne 0x42aa74
movsx eax, byte [edi + 0x14c]
cmp eax, 7
je 0x42aa6e
cmp eax, 6
je 0x42aa6e
cmp eax, 8
je 0x42aa6e
dec dword [edi + 0x44]
add edx, 5
mov dword [edi + 0x3c], edx
push dword [ebp - 0x10]
mov dword [edi + 0x4c], 0
lea eax, [ebp - 0x164]
push eax
mov dword [edi + 0x48], edx
mov edx, dword [ebp - 0x1c]
push dword [edx + 0x3c]
call fcn.004ae9a0
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x10]
add dword [edx + 0x3c], eax
push dword [ebp - 0x1c]
call fcn.0041d070
add esp, 0x10
test eax, eax
jne 0x42ac49
xor eax, eax
push eax
push eax
push dword [ebp - 0x20]
call fcn.0042e5c0
add esp, 0xc
test eax, eax
jne 0x42abde
mov edi, dword [ebp - 0x20]
mov edx, dword [edi + 0x3c]
mov edi, dword [edi + 0x44]
sub edi, edx
push edi
push edx
push dword [ebx]
call fcn.004ae9a0
add esp, 0xc
mov edx, dword [ebx]
mov byte [edx + edi], 0
cmp byte [edx], 0x20
jne 0x42aaf9
test edi, edi
jle 0x42abd1
inc edx
mov dword [ebx], edx
dec edi
cmp byte [edx], 0x20
je 0x42aae8
test edi, edi
jle 0x42abd1
movsx ecx, byte [edi + edx - 1]
cmp ecx, 0x20
je 0x42ab13
test ecx, ecx
jne 0x42abc5
dec edi
test edi, edi
jg 0x42ab01
lea esi, [esi]
lea edi, [edi]
mov dword [esi], edi
je 0x42a893
mov edi, dword [ebp - 0x64]
push 0
push dword [ebp - 0x1c]
call fcn.00419f80
push 0
push dword [ebp - 0x20]
call fcn.00419f80
push dword [ebp - 0x1c]
call fcn.004193c0
push dword [ebp - 0x20]
call fcn.004193c0
add esp, 0x18
cmp dword [edi + 0xf8], 6
je 0x42ab77
mov eax, dword [ebp - 0x18]
push dword [eax + 0xf8]
call fcn.0041a480
pop ecx
cmp dword [edi + 0xf8], 5
je 0x42ab86
mov eax, dword [ebp - 0x14]
push dword [eax + 0xf8]
call fcn.0041a480
pop ecx
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
xor eax, eax
mov esp, ebp
pop ebp
ret
push 1
call fcn.004b9240
push 1
call fcn.0045d2e0
add esp, 8
push edi
mov eax, 0x2c
push eax
push eax
push 1
call fcn.00402df0
add esp, 0x10
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
mov eax, edi
mov edi, dword [ebp - 0x64]
mov dword [esi], eax
jmp 0x42ab2f
mov dword [esi], edi
je 0x42a893
jmp 0x42ab2c
mov edi, dword [ebp - 0x64]
push 0
mov ebx, eax
push dword [ebp - 0x1c]
call fcn.00419f80
push 0
push dword [ebp - 0x20]
call fcn.00419f80
push dword [ebp - 0x1c]
call fcn.004193c0
push dword [ebp - 0x20]
call fcn.004193c0
add esp, 0x18
cmp dword [edi + 0xf8], 6
je 0x42ac2b
mov edx, dword [ebp - 0x18]
push dword [edx + 0xf8]
call fcn.0041a480
pop ecx
cmp dword [edi + 0xf8], 5
je 0x42ac3a
mov edx, dword [ebp - 0x14]
push dword [edx + 0xf8]
call fcn.0041a480
pop ecx
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov eax, ebx
mov ebx, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret
mov edi, dword [ebp - 0x64]
push 0
mov ebx, eax
push dword [ebp - 0x1c]
call fcn.00419f80
push 0
push dword [ebp - 0x20]
call fcn.00419f80
push dword [ebp - 0x1c]
call fcn.004193c0
push dword [ebp - 0x20]
call fcn.004193c0
add esp, 0x18
cmp dword [edi + 0xf8], 6
je 0x42ac96
mov edx, dword [ebp - 0x18]
push dword [edx + 0xf8]
call fcn.0041a480
pop ecx
cmp dword [edi + 0xf8], 5
je 0x42aca5
mov edx, dword [ebp - 0x14]
push dword [edx + 0xf8]
call fcn.0041a480
pop ecx
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov eax, ebx
mov ebx, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 0x18]
test eax, eax
je 0x42ad1a
test byte [eax + 0x44], 2
je 0x42acf0
mov edx, 0x26
mov dword [eax + 0x38], edx
mov eax, dword [edi + 0x18]
mov dword [eax + 0x3c], edx
mov eax, dword [edi + 0x64]
test eax, eax
je 0x42acde
xor edx, edx
mov dword [eax + 4], edx
mov dword [edi + 0x64], edx
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov eax, 0x26
mov esp, ebp
pop ebp
ret
movzx edx, byte [edi + 0x164]
and edx, 7
mov eax, 0x26
push eax
push eax
push edx
push 0xffffffffffffffff
push edi
call fcn.004243b0
add esp, 0x14
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
push edi
mov eax, 0x26
push eax
push eax
push 1
call fcn.00402df0
add esp, 0x10
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
push 0
push dword [ebp - 0x1c]
call fcn.00419f80
push dword [ebp - 0x1c]
call fcn.004193c0
push dword [ebp - 0x20]
call fcn.004193c0
add esp, 0x10
cmp dword [edi + 0xf8], 6
je 0x42ad77
mov eax, dword [ebp - 0x18]
push dword [eax + 0xf8]
call fcn.0041a480
pop ecx
cmp dword [edi + 0xf8], 5
je 0x42ad86
mov eax, dword [ebp - 0x14]
push dword [eax + 0xf8]
call fcn.0041a480
pop ecx
mov eax, dword [ebp - 0x16c]
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret