Function at 0x4bf940
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x50
mov esi, dword [esp + 0x64]
mov dword [esp + 8], ecx
call 0x4bf954
pop eax
mov dword [esp + 4], edx
mov dword [esp + 0x2c], eax
mov edi, dword [esi]
mov ecx, dword [esi + 8]
mov eax, edi
mov dword [esp + 0x40], edi
mov dword [esp + 0x24], ecx
sub eax, ecx
cmp eax, 0x20
mov eax, esi
jae 0x4bf9a7
lea ecx, [esp + 0xc]
push eax
call fcn.004bfeb0
add esp, 4
movzx eax, byte [esp + 0xc]
cmp al, 4
jne 0x4bfe1c
cmp dword [esp + 0x10], 0
je 0x4bfe3c
mov eax, dword [esp + 0x64]
mov edx, dword [esp + 4]
mov edi, dword [eax]
mov ecx, dword [eax + 8]
xor esi, esi
mov dword [esp + 0x20], 0x2000
cmp ecx, edi
jne 0x4bf9e9
cmp edi, dword [esp + 0x40]
jne 0x4bf9e9
lea ecx, [esp + 0xc]
push eax
call fcn.004bfeb0
add esp, 4
movzx eax, byte [esp + 0xc]
cmp al, 4
jne 0x4bfe1c
cmp dword [esp + 0x10], 0
je 0x4bfe57
mov eax, dword [esp + 0x64]
mov edi, dword [eax]
mov ecx, dword [eax + 8]
cmp ecx, edi
jne 0x4bfa30
cmp edi, 0xffffffdf
ja 0x4bfe4c
mov edx, edi
add edi, 0x20
lea eax, [edx + edx]
cmp eax, edi
cmova edi, eax
mov eax, dword [esp + 0x64]
test edi, edi
js 0x4bfe4c
mov ebp, ecx
test edx, edx
je 0x4bfa35
mov eax, dword [eax + 4]
mov dword [esp + 0xc], eax
mov eax, 1
mov dword [esp + 0x14], edx
jmp 0x4bfa37
mov edx, dword [eax + 4]
jmp 0x4bfa6c
xor eax, eax
mov dword [esp + 0x10], eax
lea eax, [esp + 0xc]
lea ecx, [esp + 0x44]
mov edx, 1
push eax
push edi
call fcn.00422eb0
add esp, 8
cmp dword [esp + 0x44], 1
je 0x4bfe4c
mov edx, dword [esp + 0x48]
mov eax, dword [esp + 0x64]
mov ecx, ebp
mov dword [eax + 4], edx
mov dword [eax], edi
mov ebp, dword [esp + 0x20]
mov dword [esp + 0x3c], edi
sub edi, ecx
add edx, ecx
mov dword [esp + 0x28], ecx
mov dword [esp + 0x38], edi
mov dword [esp + 0x18], edx
cmp edi, ebp
cmovb ebp, edi
mov eax, ebp
sub eax, esi
add esi, edx
push eax
push 0
push esi
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
mov edx, dword [esp + 4]
mov edi, dword [edx + 0x78]
mov esi, dword [edx + 0x74]
mov ecx, edi
sub ecx, esi
jne 0x4bfae0
lea ecx, [esp + 0xc]
call fcn.004beaf0
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x14]
test byte [esp + 0xc], 1
je 0x4bfb00
mov edx, dword [esp + 4]
cmp al, 4
je 0x4bfb7e
xor edi, edi
mov ebx, eax
jmp 0x4bfb94
mov eax, dword [edx + 0x6c]
add eax, esi
cmp ecx, ebp
cmovae ecx, ebp
cmp ecx, 1
mov dword [esp + 0x1c], ecx
jne 0x4bfb20
movzx eax, byte [eax]
mov ecx, dword [esp + 0x18]
mov byte [ecx], al
jmp 0x4bfb32
cmp ecx, ebp
cmovae ecx, ebp
cmp ecx, 1
jne 0x4bfb4b
movzx eax, byte [eax]
mov edx, dword [esp + 0x18]
mov edi, ecx
mov byte [edx], al
jmp 0x4bfb5b
push ecx
push eax
push dword [esp + 0x20]
call sub.VCRUNTIME140.dll_memcpy
mov edx, dword [esp + 0x10]
add esp, 0xc
mov ecx, dword [esp + 0x1c]
add esi, ecx
cmp esi, edi
cmovae esi, edi
mov eax, 4
mov dword [edx + 0x74], esi
cmp al, 4
jne 0x4bfacf
jmp 0x4bfb7e
push ecx
push eax
push dword [esp + 0x20]
mov edi, ecx
call sub.VCRUNTIME140.dll_memcpy
add esp, 0xc
mov edx, dword [esp + 4]
mov ecx, edi
mov esi, dword [edx + 0x74]
mov eax, dword [edx + 0x78]
add esi, edi
cmp esi, eax
cmovae esi, eax
mov eax, 4
mov dword [edx + 0x74], esi
cmp al, 4
jne 0x4bfacf
cmp ecx, ebp
ja 0x4bfe85
mov edi, ecx
mov ecx, dword [esp]
and ebx, 0xffffff00
or ebx, 4
movzx eax, bl
mov dword [esp + 0x30], ebp
mov eax, dword [eax*4 + 0x4bfe88]
add eax, dword [esp + 0x2c]
jmp eax
movzx ecx, byte [esp + 0xf]
mov edx, dword [esp + 8]
movzx edi, word [esp + 0xd]
mov esi, dword [esp + 0x10]
mov byte [edx + 3], cl
mov word [edx + 1], di
mov byte [edx], al
mov dword [edx + 4], esi
jmp 0x4bfe6c
mov eax, dword [esp + 8]
mov dword [eax + 4], 0
mov byte [eax], 4
jmp 0x4bfe6c
mov eax, dword [esp + 8]
mov word [eax], 0x2601
jmp 0x4bfe6c
mov eax, dword [esp + 0x64]
mov ecx, dword [esp + 8]
mov eax, dword [eax + 8]
sub eax, dword [esp + 0x24]
mov dword [ecx + 4], eax
mov byte [ecx], 4
add esp, 0x50
pop esi
pop edi
pop ebx
pop ebp
ret
ud2