Function at 0x401460
Capabilities:
Access peb ldr_data
Get process heap flags
Terminate process

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x350
mov edi, dword [ebp + 0xc]
mov ebx, dword [sym.imp.ucrtbase.dll___acrt_iob_func]
mov dword [esp], 1
call ebx
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll__fileno]
mov dword [esp + 4], pe_overlay
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll__setmode]
lea eax, [edi + 4]
mov dword [ebp - 0x31c], eax
mov esi, eax
mov eax, dword [edi + 4]
test eax, eax
je 0x401a78
mov ecx, 1
mov dword [ebp - 0x324], ebx
mov dword [ebp - 0x330], 0
mov dword [ebp - 0x320], ecx
jmp 0x4014ea
mov dword [ebp - 0x320], ebx
mov esi, ebx
mov ecx, 1
lea esi, [edi + esi*4]
mov eax, dword [esi]
test eax, eax
je 0x401547
test cl, cl
je 0x401547
mov ecx, dword [ebp - 0x320]
cmp word [eax], 0x2d
lea ebx, [ecx + 1]
jne 0x4014d0
cmp word [eax + 2], 0x2d
jne 0x4018d3
xor ecx, ecx
cmp word [eax + 4], 0
jne 0x401bce
mov eax, dword [ebp - 0x320]
lea edx, [edi + eax*4]
mov esi, eax
cmp dword [edx], 0
je 0x4014dd
shl eax, 2
sub edx, eax
lea esi, [esi]
lea esi, [esi]
mov eax, dword [edi + ebx*4]
mov dword [edx + ebx*4 - 4], eax
add ebx, 1
test eax, eax
jne 0x401530
lea esi, [edi + esi*4]
mov eax, dword [esi]
test eax, eax
jne 0x4014e6
mov eax, dword [ebp - 0x330]
mov ebx, dword [ebp - 0x324]
mov dword [ebp - 0x324], 0xa
test al, 0x10
je 0x401572
xor eax, 0x10
mov dword [ebp - 0x330], eax
xor eax, eax
mov dword [ebp - 0x324], eax
mov eax, dword [ebp - 0x330]
test eax, eax
je 0x401a82
xor esi, esi
and eax, 4
mov dword [ebp - 0x320], esi
mov dword [ebp - 0x32c], eax
jne 0x401c77
mov eax, dword [ebp - 0x330]
xor ecx, ecx
and eax, 8
mov dword [ebp - 0x328], eax
jne 0x401ad4
mov eax, dword [edi + 4]
mov edi, dword [ebp - 0x330]
mov edx, edi
and edi, 1
and edx, 2
mov dword [ebp - 0x334], edi
mov dword [ebp - 0x330], edx
test eax, eax
je 0x4019c6
mov dword [ebp - 0x338], ecx
jmp 0x401621
mov eax, dword [ebp - 0x334]
test eax, eax
jne 0x401686
mov eax, dword [ebp - 0x32c]
test eax, eax
jne 0x4016e2
mov ecx, dword [ebp - 0x328]
test ecx, ecx
jne 0x40178b
add dword [ebp - 0x31c], 4
mov eax, dword [ebp - 0x31c]
mov eax, dword [eax]
test eax, eax
je 0x4019c6
mov edx, dword [ebp - 0x330]
mov byte [ebp - 0x318], 0
test edx, edx
je 0x4015e0
lea esi, [ebp - 0x214]
mov dword [esp], eax
lea ebx, [ebp - 0x318]
mov dword [esp + 8], 0x104
mov dword [esp + 4], esi
call dword [sym.imp.kernel32.dll_GetLongPathNameW]
sub esp, 0xc
test eax, eax
jne 0x4019d3
mov eax, dword [ebp - 0x324]
mov dword [esp + 4], ebx
mov dword [esp], str._s_c
mov dword [esp + 8], eax
call sym._printf
mov eax, dword [ebp - 0x334]
test eax, eax
je 0x4015ee
mov eax, dword [ebp - 0x31c]
lea esi, [ebp - 0x214]
mov dword [esp + 8], 0x104
lea ebx, [ebp - 0x318]
mov dword [esp + 4], esi
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetShortPathNameW]
sub esp, 0xc
test eax, eax
jne 0x401a18
mov eax, dword [ebp - 0x324]
mov dword [esp + 4], ebx
mov dword [esp], str._s_c
mov dword [esp + 8], eax
call sym._printf
mov eax, dword [ebp - 0x32c]
test eax, eax
je 0x4015fc
mov eax, dword [ebp - 0x31c]
mov edi, dword [eax]
cmp word [edi], 0
mov ebx, edi
je 0x401701
lea esi, [esi]
add ebx, 2
cmp word [ebx], 0
jne 0x4016f8
sub ebx, edi
lea eax, [ebx + 2]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll_malloc]
mov esi, eax
xor eax, eax
lea esi, [esi]
nop
movzx edx, word [edi + eax]
mov word [esi + eax], dx
add eax, 2
test dx, dx
jne 0x401718
mov dword [esp], esi
mov eax, dword [ebp - 0x320]
add ebx, esi
call eax
mov edx, eax
test eax, eax
je 0x40175a
jmp 0x401c3e
movzx eax, word [ebx]
cmp ax, 0x2f
je 0x401930
cmp ax, 0x5c
je 0x401930
sub ebx, 2
cmp esi, ebx
jne 0x401740
mov eax, dword [ebp - 0x324]
mov dword [esp], 0x404169
mov dword [esp + 4], eax
call sym._printf
mov dword [esp], esi
call dword [sym.imp.ucrtbase.dll_free]
mov ecx, dword [ebp - 0x328]
test ecx, ecx
je 0x40160a
mov eax, dword [ebp - 0x31c]
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov edi, dword [sym.imp.kernel32.dll_WideCharToMultiByte]
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0xffffffff
mov eax, dword [eax]
mov dword [esp + 4], 0
mov dword [esp + 8], eax
mov dword [esp], 0xfdf2
call edi
sub esp, 0x20
mov ebx, eax
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll_malloc]
mov dword [esp + 0x1c], 0
mov dword [esp + 0x10], eax
mov esi, eax
mov eax, dword [ebp - 0x31c]
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], ebx
mov dword [esp + 0xc], 0xffffffff
mov eax, dword [eax]
mov dword [esp + 4], 0
mov dword [esp + 8], eax
mov dword [esp], 0xfdf2
call edi
mov eax, dword [ebp - 0x338]
sub esp, 0x20
mov dword [esp], esi
call eax
test eax, eax
je 0x401a5d
lea ebx, [ebp - 0x318]
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x104
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], 0xffffffff
mov dword [esp + 8], eax
mov dword [ebp - 0x33c], eax
mov dword [esp + 4], 0
mov dword [esp], 0xfdf2
call edi
mov eax, dword [ebp - 0x324]
sub esp, 0x20
mov dword [esp + 8], eax
mov dword [esp + 4], ebx
mov dword [esp], str._s_c
call sym._printf
mov edx, dword [ebp - 0x33c]
mov dword [esp + 4], 0
mov eax, dword fs:[0x18]
mov dword [esp + 8], edx
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_HeapFree]
sub esp, 0xc
mov dword [esp], esi
call dword [sym.imp.ucrtbase.dll_free]
jmp 0x40160a
mov eax, dword [esi]
mov ecx, 4
movzx eax, word [eax + 2]
test ax, ax
je 0x401926
mov dword [ebp + 0xc], edi
mov edi, esi
mov esi, dword [ebp - 0x330]
mov dword [ebp - 0x328], ebx
mov ebx, ecx
lea esi, [esi]
lea esi, [esi]
xor edx, edx
call sym._option
or esi, eax
mov eax, dword [edi]
movzx eax, word [eax + ebx]
add ebx, 2
test ax, ax
jne 0x401900
mov ebx, dword [ebp - 0x328]
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x330], esi
mov ecx, 1
jmp 0x401511
movzx eax, word [ebx + 2]
lea edi, [ebx + 2]
mov ecx, edi
cmp ax, 0x2a
je 0x401976
test ax, ax
je 0x40197f
cmp ax, 0x3e
je 0x40175e
ja 0x4019b0
cmp ax, 0x22
je 0x40175e
cmp ax, 0x3c
je 0x40175e
movzx eax, word [ecx + 2]
add ecx, 2
test ax, ax
je 0x40197f
cmp ax, 0x2a
jne 0x401944
test ax, ax
jne 0x40175e
test edx, edx
je 0x40198b
mov eax, 0x2f
mov word [edx], ax
xor eax, eax
mov word [ebx], ax
mov eax, dword [ebp - 0x320]
mov dword [esp], esi
call eax
test eax, eax
jne 0x401b37
mov edx, ebx
jmp 0x40175a
cmp ax, 0x3f
je 0x40175e
cmp ax, 0x7c
je 0x40175e
jmp 0x401964
mov dword [esp], 0
call dword [sym.imp.ucrtbase.dll_exit]
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x104
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], 0xffffffff
mov dword [esp + 8], esi
mov dword [esp + 4], 0
mov dword [esp], 0xfdf2
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
sub esp, 0x20
jmp 0x40165e
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x104
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], 0xffffffff
mov dword [esp + 8], esi
mov dword [esp + 4], 0
mov dword [esp], 0xfdf2
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
sub esp, 0x20
jmp 0x4016ba
mov eax, dword [ebp - 0x324]
mov dword [esp], 0x404169
mov dword [esp + 4], eax
call sym._printf
jmp 0x4018c5
mov dword [ebp - 0x324], 0xa
mov dword [esp], str.KERNEL32
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
push esi
mov dword [esp + 4], str.wine_get_unix_file_name
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov dword [ebp - 0x320], eax
push edx
push edx
test eax, eax
je 0x401cb0
mov dword [ebp - 0x32c], 4
xor ecx, ecx
mov dword [ebp - 0x328], ecx
xor ecx, ecx
mov dword [ebp - 0x330], 4
jmp 0x4015ae
mov dword [esp], str.KERNEL32
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
push ecx
mov dword [esp + 4], str.wine_get_dos_file_name
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov dword [ebp - 0x328], 8
push esi
mov ecx, eax
push esi
test eax, eax
jne 0x4015ae
mov dword [esp], 2
call ebx
mov dword [esp + 8], str.winepath
mov dword [esp + 4], str._s:_cannot_get_the_address_of_wine_get_dos_file_name_n
mov dword [esp], eax
call sym._fprintf
mov dword [esp], 3
call dword [sym.imp.ucrtbase.dll_exit]
xor edx, edx
mov dword [ebp - 0x33c], eax
lea ebx, [ebp - 0x318]
xor eax, eax
mov dword [esp + 4], edx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], 0x104
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], 0xffffffff
mov dword [esp + 8], edi
mov dword [esp], 0xfdf2
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
mov edx, dword [ebp - 0x33c]
mov eax, dword [ebp - 0x324]
sub esp, 0x20
mov dword [esp + 4], edx
mov dword [esp + 0xc], eax
mov dword [esp + 8], ebx
mov dword [esp], str._s__s_c
call sym._printf
mov edx, dword [ebp - 0x33c]
mov dword [esp + 8], edx
mov dword [esp + 4], 0
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_HeapFree]
sub esp, 0xc
jmp 0x401774
xor ecx, ecx
mov edx, 0x4040b0
mov dword [ebp - 0x328], ebx
mov ebx, esi
mov dword [ebp + 0xc], edi
mov esi, edx
mov edi, ecx
jmp 0x401bfe
add edi, 1
mov esi, dword [edi*4 + 0x404498]
test esi, esi
je 0x401c69
mov dword [esp + 4], esi
mov eax, dword [ebx]
add eax, 4
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_lstrcmpiW]
sub esp, 8
test eax, eax
jne 0x401bf0
mov edx, esi
mov esi, ebx
mov edi, dword [ebp + 0xc]
mov ebx, dword [ebp - 0x328]
movzx eax, word [edx]
mov edx, dword [esi]
call sym._option
mov ecx, 1
or dword [ebp - 0x330], eax
jmp 0x401511
mov eax, dword [ebp - 0x324]
mov dword [esp + 4], edx
mov dword [esp], str._s_c
mov dword [esp + 8], eax
mov dword [ebp - 0x33c], edx
call sym._printf
mov edx, dword [ebp - 0x33c]
jmp 0x401ba5
mov ebx, dword [ebp - 0x328]
mov edi, dword [ebp + 0xc]
jmp 0x401926
mov dword [esp], str.KERNEL32
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
push edx
mov dword [esp + 4], str.wine_get_unix_file_name
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov dword [ebp - 0x32c], 4
push ecx
mov dword [ebp - 0x320], eax
push ecx
test eax, eax
jne 0x401597
mov dword [esp], 2
call ebx
mov dword [esp + 8], str.winepath
mov dword [esp + 4], str._s:_cannot_get_the_address_of_wine_get_unix_file_name_n
mov dword [esp], eax
call sym._fprintf
mov dword [esp], 3
call dword [sym.imp.ucrtbase.dll_exit]
nop
nop