Function at 0x40d790
Capabilities:
Check if file exists
Get file attributes
Get file version info

Disassembly:
push 0xffffffffffffffff
push 0x425478
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x218
mov eax, dword [0x42f180]
mov dword [esp + 0x214], eax
push ebx
push str.0.0.0.0
mov dword [esp + 0x228], 0
call fcn.0041b05a
mov ecx, dword [esp + 0x234]
add esp, 4
push eax
push str.0.0.0.0
call fcn.00409a30
mov ebx, dword [esp + 0x22c]
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40d820
add ebx, 0xfffffff0
mov dword [esp + 0x224], eax
lea eax, [ebx + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40d816
mov ecx, dword [ebx]
mov edx, dword [ecx]
push ebx
call dword [edx + 4]
mov eax, 0x80004005
jmp 0x40d9d1
push ebp
push esi
push edi
push 0
push ebx
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov ebp, eax
lea eax, [ebp + ebp]
push eax
call fcn.00419b03
mov esi, eax
add esp, 4
mov ecx, ebp
mov edx, ecx
shr ecx, 2
push esi
xor eax, eax
mov edi, esi
rep stosd dword es:[edi], eax
push ebp
mov ecx, edx
xor ebp, ebp
push ebp
and ecx, 3
push ebx
rep stosb byte es:[edi], al
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
jne 0x40d897
push esi
call fcn.0041a33d
add ebx, 0xfffffff0
add esp, 4
mov dword [esp + 0x230], 0xffffffff
lea eax, [ebx + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40d88d
mov ecx, dword [ebx]
mov edx, dword [ecx]
push ebx
call dword [edx + 4]
mov eax, 0x80004005
jmp 0x40d9ce
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x1c]
push ecx
push str.VarFileInfoTranslation
push esi
mov dword [esp + 0x20], ebp
call sub.VERSION.dll_VerQueryValueW
test eax, eax
jne 0x40d8da
push esi
call fcn.0041a33d
add ebx, 0xfffffff0
add esp, 4
mov dword [esp + 0x230], 0xffffffff
lea edx, [ebx + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jmp 0x40d883
xor eax, eax
mov word [esp + 0x1c], bp
mov ecx, 0x81
lea edi, [esp + 0x1e]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov eax, dword [esp + 0x10]
xor edi, edi
test eax, 0xfffffffc
jbe 0x40d92d
jmp 0x40d900
mov eax, dword [esp + 0x18]
movzx ecx, word [eax + edi*4 + 2]
movzx edx, word [eax + edi*4]
push ecx
push edx
lea eax, [esp + 0x24]
push str.StringFileInfo_04x_04xFileVersion
push eax
call fcn.0041ab14
mov ecx, dword [esp + 0x20]
add esp, 0x10
inc edi
shr ecx, 2
cmp edi, ecx
jb 0x40d900
lea edx, [esp + 0x10]
push edx
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x24]
push ecx
push esi
mov dword [esp + 0x24], ebp
call sub.VERSION.dll_VerQueryValueW
test eax, eax
jne 0x40d973
push esi
call fcn.0041a33d
add ebx, 0xfffffff0
add esp, 4
mov dword [esp + 0x230], 0xffffffff
lea edx, [ebx + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jmp 0x40d883
mov eax, dword [esp + 0x14]
mov edi, dword [esp + 0x23c]
push eax
push 0x428368
push edi
call fcn.0040a140
add esp, 0xc
push 0x428364
push 0x42835c
mov ecx, edi
call fcn.00409700
push esi
call fcn.0041a33d
add ebx, 0xfffffff0
add esp, 4
mov dword [esp + 0x230], 0xffffffff
lea ecx, [ebx + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d9cc
mov ecx, dword [ebx]
mov eax, dword [ecx]
push ebx
call dword [eax + 4]
xor eax, eax
pop edi
pop esi
pop ebp
mov ecx, dword [esp + 0x21c]
mov dword fs:[0], ecx
mov ecx, dword [esp + 0x218]
pop ebx
call fcn.00419d15
add esp, 0x224
ret 8