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

Disassembly:
sub esp, 0x10
push ebx
push ebp
push esi
push edi
mov edi, dword [0x4473f0]
push 2
pop ebp
push ebp
call fcn.00405ebe
xor ebx, ebx
test eax, eax
je 0x405333
call eax
movzx eax, ax
push eax
push 0x478000
call fcn.00405bdd
jmp 0x405382
push ebx
mov esi, 0x42a1b0
mov word [0x478000], 0x7830
push esi
push ebx
push str.Control_PanelDesktopResourceLocale
push 0x80000001
mov byte [0x478002], bl
call fcn.00405f52
cmp byte [0x42a1b0], bl
jne 0x405377
push ebx
push esi
push 0x4084f2
push str..DEFAULTControl_PanelInternational
push 0x80000003
call fcn.00405f52
push esi
push 0x478000
call sub.KERNEL32.dll_lstrcatA
call fcn.00405228
mov eax, dword [0x4473ec]
and eax, 0x20
mov dword [0x4474bc], 0x10000
push 0x472000
mov dword [0x4474a0], eax
call fcn.00405bf6
test eax, eax
jne 0x40543c
mov edx, dword [edi + 0x48]
test edx, edx
je 0x40543c
mov ecx, dword [0x447418]
mov esi, 0x43f380
mov eax, dword [edi + 0x4c]
push ebx
push esi
add eax, ecx
push eax
lea eax, [edx + ecx]
push eax
push dword [edi + 0x44]
call fcn.00405f52
mov al, byte [0x43f380]
test al, al
je 0x40543c
cmp al, 0x22
jne 0x4053f6
push 0x22
mov esi, 0x43f381
push esi
call fcn.00405bb9
mov byte [eax], bl
push esi
call sub.KERNEL32.dll_lstrlenA
add eax, 0xfffffffc
add eax, esi
cmp eax, esi
jbe 0x40542b
push str..exe
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x40542b
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x405425
test al, 0x10
jne 0x40542b
push esi
call fcn.00406207
push esi
call fcn.00405b1b
push eax
push 0x472000
call fcn.004060a1
push 0x472000
call fcn.00405bf6
test eax, eax
jne 0x40545a
push dword [edi + 0x118]
push 0x472000
call fcn.004056c3
push 0x8040
push ebx
push ebx
push 1
push 0x67
push dword [0x4433d4]
call dword [sym.imp.USER32.dll_LoadImageA]
mov ecx, eax
mov dword [0x4433b8], ecx
cmp dword [edi + 0x50], 0xffffffff
mov edi, dword [sym.imp.USER32.dll_RegisterClassA]
je 0x405503
mov eax, dword [0x4433d4]
mov esi, 0x40852c
push 0x443380
mov dword [0x443384], 0x401000
mov dword [0x443390], eax
mov dword [0x443394], ecx
mov dword [0x4433a4], esi
call edi
test ax, ax
je 0x4055d4
push ebx
lea eax, [esp + 0x14]
push eax
push ebx
push 0x30
call dword [sym.imp.USER32.dll_SystemParametersInfoA]
mov eax, dword [esp + 0x1c]
sub eax, dword [esp + 0x14]
push ebx
push dword [0x4433d4]
push ebx
push ebx
push eax
mov eax, dword [esp + 0x2c]
sub eax, dword [esp + 0x24]
push eax
push dword [esp + 0x2c]
push dword [esp + 0x2c]
push 0x80000000
push ebx
push esi
push 0x80
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [0x4321b8], eax
push ebx
call fcn.00401424
test eax, eax
je 0x405514
mov eax, ebp
jmp 0x4055d6
call fcn.00405228
cmp dword [0x4474c0], ebx
jne 0x4055ac
push 5
push dword [0x4321b8]
call dword [sym.imp.USER32.dll_ShowWindow]
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push str.RichEd20
call esi
test eax, eax
jne 0x40554b
push str.RichEd32
call esi
mov esi, dword [sym.imp.USER32.dll_GetClassInfoA]
mov ebp, 0x443380
push ebp
push str.RichEdit20A
push ebx
call esi
test eax, eax
jne 0x405579
push ebp
push str.RichEdit
push ebx
call esi
push ebp
mov dword [0x4433a4], 0x408548
call edi
mov eax, dword [0x4433b4]
push ebx
push 0x404903
add eax, 0x69
push ebx
movzx eax, ax
push eax
push dword [0x4433d4]
call dword [sym.imp.USER32.dll_DialogBoxParamA]
push 5
mov esi, eax
call fcn.00401424
push 1
call fcn.00403767
mov eax, esi
jmp 0x4055d6
push ebx
call fcn.00405109
test eax, eax
je 0x4055cd
cmp dword [0x4433cc], ebx
jne 0x40550d
push ebp
call fcn.00401424
jmp 0x40550d
push 1
call fcn.00401424
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret