Function at 0x40db30
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x50d758
mov eax, dword fs:[0]
push eax
sub esp, 0x4c
mov eax, dword [0x557768]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x18], 0
lea eax, [ebp - 0x18]
push eax
mov ecx, dword [ebp + 8]
call fcn.0040d9f0
push eax
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov dword [ebp - 0x44], eax
cmp dword [ebp - 0x44], 0
je 0x40ddc4
mov ecx, dword [ebp - 0x44]
push ecx
call fcn.004a2889
add esp, 4
mov dword [ebp - 0x4c], eax
mov edx, dword [ebp - 0x4c]
mov dword [ebp - 0x38], edx
cmp dword [ebp - 0x38], 0
je 0x40ddc4
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x50], eax
mov ecx, dword [ebp + 8]
call fcn.0040d9f0
mov dword [ebp - 0x54], eax
mov ecx, dword [ebp - 0x38]
push ecx
mov edx, dword [ebp - 0x44]
push edx
mov eax, dword [ebp - 0x50]
push eax
mov ecx, dword [ebp - 0x54]
push ecx
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
je 0x40dd96
call fcn.0040e0c0
movzx edx, al
test edx, edx
je 0x40dcf7
call fcn.0040dff0
movzx eax, al
test eax, eax
jne 0x40dcf7
mov dword [ebp - 0x1c], 0
lea ecx, [ebp - 0x1c]
push ecx
lea edx, [ebp - 0x2c]
push edx
push str.VarFileInfoTranslation
mov eax, dword [ebp - 0x38]
push eax
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x40dcf7
mov dword [ebp - 0x3c], 0
jmp 0x40dc29
mov ecx, dword [ebp - 0x3c]
add ecx, 1
mov dword [ebp - 0x3c], ecx
mov edx, dword [ebp - 0x1c]
shr edx, 2
cmp dword [ebp - 0x3c], edx
jae 0x40dcf7
push 4
lea ecx, [ebp - 0x14]
call fcn.0040e4c0
lea ecx, [ebp - 0x14]
call fcn.00406460
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x2c]
movzx edx, word [ecx + eax*4 + 2]
push edx
mov eax, dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x2c]
movzx edx, word [ecx + eax*4]
push edx
push str.StringFileInfo_04x_04xFileVersion
lea eax, [ebp - 0x14]
push eax
call fcn.004050f0
add esp, 0x10
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x20], 0
lea ecx, [ebp - 0x20]
push ecx
lea edx, [ebp - 0x30]
push edx
lea ecx, [ebp - 0x14]
call fcn.0040d9f0
push eax
mov eax, dword [ebp - 0x38]
push eax
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x40dce3
mov ecx, dword [ebp - 0x20]
push ecx
mov edx, dword [ebp - 0x30]
push edx
mov ecx, dword [ebp + 0xc]
call fcn.0040e400
push 0x2e
push 0x2c
mov ecx, dword [ebp + 0xc]
call fcn.0040e2e0
push 0x20
mov ecx, dword [ebp + 0xc]
call fcn.0040e1e0
mov dword [ebp - 0x40], 1
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.004048c0
jmp 0x40dcf7
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.004048c0
jmp 0x40dc20
cmp dword [ebp - 0x40], 0
je 0x40dd10
mov ecx, dword [ebp + 0xc]
call fcn.0040df20
movzx eax, al
test eax, eax
je 0x40dd96
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x24], 0
lea ecx, [ebp - 0x24]
push ecx
lea edx, [ebp - 0x28]
push edx
push 0x5179e0
mov eax, dword [ebp - 0x38]
push eax
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x40dd96
mov ecx, dword [ebp - 0x28]
mov edx, dword [ecx + 0xc]
and edx, 0xffff
movzx eax, dx
push eax
mov ecx, dword [ebp - 0x28]
mov edx, dword [ecx + 0xc]
shr edx, 0x10
and edx, 0xffff
movzx eax, dx
push eax
mov ecx, dword [ebp - 0x28]
mov edx, dword [ecx + 8]
and edx, 0xffff
movzx eax, dx
push eax
mov ecx, dword [ebp - 0x28]
mov edx, dword [ecx + 8]
shr edx, 0x10
and edx, 0xffff
movzx eax, dx
push eax
push str._d._d._d._d
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.004050f0
add esp, 0x18
mov dword [ebp - 0x40], 1
mov edx, dword [ebp - 0x38]
mov dword [ebp - 0x48], edx
mov eax, dword [ebp - 0x48]
push eax
call fcn.004a2884
add esp, 4
cmp dword [ebp - 0x48], 0
jne 0x40ddb7
mov dword [ebp - 0x58], 0
jmp 0x40ddc4
mov dword [ebp - 0x38], 0x8123
mov ecx, dword [ebp - 0x38]
mov dword [ebp - 0x58], ecx
cmp dword [ebp - 0x40], 0
je 0x40ddd0
mov byte [ebp - 0x31], 1
jmp 0x40ddd4
mov byte [ebp - 0x31], 0
mov al, byte [ebp - 0x31]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004a2820
mov esp, ebp
pop ebp
ret