Function at 0x4051db
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
mov edi, dword [0x42fbcc]
push 6
call fcn.004058f0
xor ebx, ebx
cmp eax, ebx
je 0x405209
call eax
movzx eax, ax
push eax
push 0x436000
call fcn.00405738
jmp 0x405253
push ebx
mov esi, 0x42c1a8
push esi
push ebx
push str.Control_PanelDesktopResourceLocale
push 0x80000001
mov dword [0x436000], 0x7830
call fcn.004056c1
cmp byte [0x42c1a8], bl
jne 0x405248
push ebx
push esi
push 0x4074b6
push str..DEFAULTControl_PanelInternational
push 0x80000003
call fcn.004056c1
push esi
push 0x436000
call sub.KERNEL32.dll_lstrcatA
call fcn.004038e9
mov eax, dword [0x42fc28]
and eax, 0x20
push 0x435400
mov dword [0x42fc80], eax
mov dword [0x42fc9c], 0x10000
call fcn.004059ad
test eax, eax
jne 0x40530e
cmp dword [edi + 0x48], ebx
je 0x40530e
push ebx
mov esi, 0x42eb60
push esi
push dword [edi + 0x4c]
call fcn.004057fa
push eax
push dword [edi + 0x48]
call fcn.004057fa
push eax
push dword [edi + 0x44]
call fcn.004056c1
mov al, byte [0x42eb60]
cmp al, bl
je 0x40530e
cmp al, 0x22
jne 0x4052c9
mov eax, 0x42eb61
push 0x22
push eax
mov esi, eax
call fcn.0040556f
mov byte [eax], bl
push esi
call sub.KERNEL32.dll_lstrlenA
lea eax, [eax + esi - 4]
cmp eax, esi
jbe 0x4052fd
push str..exe
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x4052fd
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x4052f7
test al, 0x10
jne 0x4052fd
push esi
call fcn.00405986
push esi
call fcn.00405959
push eax
push 0x435400
call fcn.004057d8
mov esi, 0x435400
push esi
call fcn.004059ad
test eax, eax
jne 0x405329
push dword [edi + 0x118]
push esi
call fcn.00405a85
push 0x8040
push ebx
push ebx
push 1
push 0x67
push dword [0x42fbc8]
call dword [sym.imp.USER32.dll_LoadImageA]
mov dword [0x42f390], eax
cmp dword [edi + 0x50], 0xffffffff
mov esi, 0x42f360
je 0x4053cf
mov ecx, dword [0x42fbc8]
mov dword [0x42f374], eax
lea eax, [ebp - 4]
push esi
mov dword [ebp - 4], 0x624e5f
mov dword [0x42f364], 0x401000
mov dword [0x42f370], ecx
mov dword [0x42f384], eax
call dword [sym.imp.USER32.dll_RegisterClassA]
test ax, ax
je 0x4054a1
push ebx
lea eax, [ebp - 0x14]
push eax
push ebx
push 0x30
call dword [sym.imp.USER32.dll_SystemParametersInfoA]
mov eax, dword [ebp - 8]
sub eax, dword [ebp - 0x10]
push ebx
push dword [0x42fbc8]
push ebx
push ebx
push eax
mov eax, dword [ebp - 0xc]
sub eax, dword [ebp - 0x14]
push eax
push dword [ebp - 0x10]
lea eax, [ebp - 4]
push dword [ebp - 0x14]
push 0x80000000
push ebx
push eax
push 0x80
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [0x42b5a4], eax
push ebx
call fcn.0040141a
test eax, eax
je 0x4053e1
push 2
pop eax
jmp 0x4054a3
call fcn.004038e9
cmp dword [0x42fca0], ebx
jne 0x405478
push 5
push dword [0x42b5a4]
call dword [sym.imp.USER32.dll_ShowWindow]
mov edi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push str.RichEd20
call edi
test eax, eax
jne 0x405418
push str.RichEd32
call edi
mov edi, dword [sym.imp.USER32.dll_GetClassInfoA]
push esi
push str.RichEdit20A
push ebx
call edi
test eax, eax
jne 0x405445
push esi
push str.RichEdit
push ebx
call edi
push esi
mov dword [0x42f384], 0x407444
call dword [sym.imp.USER32.dll_RegisterClassA]
mov eax, dword [0x42f39c]
push ebx
push 0x404d2d
add eax, 0x69
movzx eax, ax
push ebx
push eax
push dword [0x42fbc8]
call dword [sym.imp.USER32.dll_DialogBoxParamA]
push 5
mov esi, eax
call fcn.0040141a
push 1
call fcn.004036dd
mov eax, esi
jmp 0x4054a3
push ebx
call fcn.00404939
test eax, eax
je 0x40549a
cmp dword [0x42f394], ebx
jne 0x4053d9
push 2
call fcn.0040141a
jmp 0x4053d9
push 1
call fcn.0040141a
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret