Function at 0x4021f0
Capabilities:
Get file version info

Disassembly:
push 0xffffffffffffffff
push 0x44a981
mov eax, dword fs:[0]
push eax
sub esp, 0x334
mov eax, dword [0x46a74c]
xor eax, esp
mov dword [esp + 0x330], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x46a74c]
xor eax, esp
push eax
lea eax, [esp + 0x348]
mov dword fs:[0], eax
mov ebx, dword [esp + 0x358]
push 0x104
lea eax, [esp + 0x148]
xor ebp, ebp
push eax
push ebp
mov dword [esp + 0x38], ebx
mov dword [esp + 0x2c], ebp
call dword [sym.imp.KERNEL32.DLL_GetModuleFileNameA]
lea ecx, [esp + 0x144]
push ecx
lea edx, [esp + 0x40]
push 0x105
push edx
call fcn.0042eaee
add esp, 0xc
lea eax, [esp + 0x38]
push eax
lea ecx, [esp + 0x40]
push ecx
call sub.VERSION.dll_GetFileVersionInfoSizeA
mov edi, eax
push edi
call fcn.0041c39f
add esp, 4
mov esi, eax
push esi
push edi
push ebp
lea edx, [esp + 0x48]
push edx
call sub.VERSION.dll_GetFileVersionInfoA
test eax, eax
je 0x40251f
lea eax, [esp + 0x30]
push eax
lea ecx, [esp + 0x2c]
push ecx
push str.VarFileInfoTranslation
push esi
call sub.VERSION.dll_VerQueryValueA
call fcn.0041d031
xor ecx, ecx
cmp eax, ebp
setne cl
cmp ecx, ebp
jne 0x4022ca
push 0x80004005
call fcn.00401080
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x28]
movzx ecx, word [eax + 2]
movzx edx, word [eax]
push ecx
push edx
lea eax, [esp + 0x20]
push str.StringFileInfo_04x_04xFileVersion
push eax
mov dword [esp + 0x360], ebp
call fcn.00401ab0
mov ebx, dword [esp + 0x28]
mov edx, dword [ebx - 0xc]
mov eax, dword [ebx - 8]
mov ecx, 1
sub ecx, dword [ebx - 4]
sub eax, edx
add esp, 0x10
or eax, ecx
jge 0x402326
push edx
lea ecx, [esp + 0x1c]
call fcn.004013f0
mov ebx, dword [esp + 0x18]
lea ecx, [esp + 0x34]
push ecx
lea edx, [esp + 0x28]
push edx
push ebx
push esi
call sub.VERSION.dll_VerQueryValueA
call fcn.0041d031
xor ecx, ecx
cmp eax, ebp
setne cl
cmp ecx, ebp
jne 0x402351
push 0x80004005
call fcn.00401080
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea edi, [eax + 0x10]
mov dword [esp + 0x1c], edi
mov byte [esp + 0x350], 1
call fcn.0041d031
xor ecx, ecx
cmp eax, ebp
setne cl
cmp ecx, ebp
jne 0x402383
push 0x80004005
call fcn.00401080
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x20], eax
mov ecx, dword [esp + 0x24]
push ecx
lea edx, [esp + 0x24]
push 0x450694
push edx
mov byte [esp + 0x35c], 2
call fcn.00401ab0
push esi
call fcn.0041c39a
mov esi, dword [esp + 0x30]
mov eax, dword [esi - 0xc]
add esp, 0x10
test eax, eax
jle 0x402469
test ebp, ebp
jl 0x402471
cmp ebp, eax
jg 0x402471
movsx eax, byte [esi + ebp]
push eax
call fcn.0042f1c7
add esp, 4
test eax, eax
je 0x40243c
cmp ebp, dword [esi - 0xc]
jg 0x402471
mov cl, byte [esi + ebp]
mov ebx, dword [edi - 0xc]
mov eax, dword [edi - 8]
mov byte [esp + 0x17], cl
mov ecx, 1
sub ecx, dword [edi - 4]
lea esi, [ebx + 1]
sub eax, esi
or eax, ecx
jge 0x40241d
push esi
lea ecx, [esp + 0x20]
call fcn.004013f0
mov edi, dword [esp + 0x1c]
test esi, esi
mov dl, byte [esp + 0x17]
mov byte [ebx + edi], dl
jl 0x402471
cmp esi, dword [edi - 8]
jg 0x402471
mov ebx, dword [esp + 0x18]
mov dword [edi - 0xc], esi
mov byte [esi + edi], 0
mov esi, dword [esp + 0x20]
cmp ebp, dword [esi - 0xc]
jg 0x402471
cmp byte [esi + ebp], 0x2c
jne 0x40245b
push 1
push 0x450840
lea ecx, [esp + 0x24]
call fcn.00401980
mov edi, dword [esp + 0x1c]
mov eax, dword [esi - 0xc]
add ebp, 1
cmp ebp, eax
jl 0x4023c7
test ebx, ebx
jne 0x40247b
xor eax, eax
jmp 0x40248d
push 0x80070057
call fcn.00401080
mov eax, ebx
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x402480
sub eax, edx
js 0x402471
cmp eax, dword [ebx - 8]
jg 0x402471
add edi, 0xfffffff0
mov dword [ebx - 0xc], eax
push edi
mov byte [eax + ebx], 0
call fcn.00401440
mov ebp, dword [esp + 0x30]
add eax, 0x10
add esi, 0xfffffff0
mov dword [ebp], eax
add esp, 4
mov byte [esp + 0x350], 1
lea eax, [esi + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4024d3
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
mov byte [esp + 0x350], 0
lea ecx, [edi + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4024f4
mov ecx, dword [edi]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push edi
call edx
add ebx, 0xfffffff0
mov dword [esp + 0x350], 0xffffffff
lea eax, [ebx + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40251b
mov ecx, dword [ebx]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push ebx
call eax
mov eax, ebp
jmp 0x402536
push esi
call fcn.0041c39a
add esp, 4
push 0x4506d9
mov ecx, ebx
call fcn.00402130
mov eax, ebx
mov ecx, dword [esp + 0x348]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x330]
xor ecx, esp
call fcn.0042e802
add esp, 0x340
ret