Function at 0x519de0
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4ca660
mov eax, dword fs:[0]
push eax
sub esp, 0x20
push ebx
push esi
push edi
mov eax, dword [0x503870]
xor eax, esp
push eax
lea eax, [esp + 0x30]
mov dword fs:[0], eax
mov eax, dword [0x50a72c]
push eax
call fcn.005016e0
mov edi, dword [eax + 0x10]
sub edi, dword [eax + 0xc]
xor esi, esi
sar edi, 2
mov dword [esp + 0x24], edi
mov dword [esp + 0x18], esi
test edi, edi
jle 0x51a0df
mov ecx, dword [0x50a72c]
push ecx
call fcn.005016e0
mov ebx, esi
call fcn.00531b70
mov eax, dword [eax]
mov ebx, dword [eax + 4]
push 0x4dda18
mov dword [esp + 0x14], eax
call 0x55a5a0
mov ecx, eax
call 0x559f10
cmp eax, 7
jne 0x51a0d2
mov edi, dword [ebp + 8]
push esi
push 0x4e079c
mov esi, edi
call fcn.00515fa0
mov edx, dword [esp + 0x18]
mov eax, dword [edx + 0x20]
add esp, 8
push 7
push eax
call 0x5412d0
mov esi, eax
lea ecx, [esp + 0x14]
mov dword [esp + 0x20], esi
call fcn.004eb120
mov dword [esp + 0x38], 0
mov ebx, dword [esi + 4]
push 0x4dc860
call 0x55a5a0
mov eax, dword [eax]
push eax
call fcn.004e7980
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x519ed3
mov eax, ebx
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x519ec4
sub eax, edx
sar eax, 1
push eax
push ebx
lea ecx, [esp + 0x1c]
call fcn.004e8b30
push ebx
call 0x5600be
mov ebx, dword [esi + 4]
add esp, 4
push 0x4dc858
call 0x55a5a0
mov ecx, eax
call 0x559f10
test eax, eax
jne 0x519f23
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
mov eax, dword [edx + 0x20]
push ecx
push eax
push 0x4e07b8
push 0
push 1
push edi
call fcn.005178a0
add esp, 0x18
jmp 0x51a07c
mov ebx, dword [esi + 4]
push 0x4dc808
call 0x55a5a0
mov ecx, eax
call 0x559f10
mov ecx, dword [esp + 0x10]
mov edx, dword [ecx + 0x20]
push eax
push edx
push 0x4e07d8
push 0
push 1
push edi
call fcn.005178a0
mov ecx, dword [esi + 4]
add esp, 0x18
push 0x4df534
call 0x55a770
cmp eax, 0x50b128
je 0x519fd2
call fcn.00512cb0
mov eax, dword [eax + 4]
push 0x4db928
mov ebx, eax
call 0x55a5a0
mov ecx, eax
call 0x559f10
mov dword [esp + 0x28], eax
call fcn.00512cb0
cmp dword [eax + 8], 0
mov dword [esp + 0x1c], eax
jne 0x519fb7
mov eax, dword [eax + 4]
push 0x4de854
mov ebx, eax
call 0x55a5a0
mov eax, dword [eax]
push eax
call fcn.004e7980
mov ecx, dword [esp + 0x20]
mov dword [ecx + 8], eax
add esp, 4
mov eax, ecx
mov edx, dword [esp + 0x28]
mov eax, dword [eax + 8]
push edx
push eax
push 0x4e07f8
push 0
push 1
push edi
call fcn.005178a0
add esp, 0x18
mov esi, dword [esi + 4]
push 0x4dc808
mov ebx, esi
call 0x55a5a0
mov ecx, eax
call 0x559f10
mov esi, eax
mov dword [esp + 0x28], esi
call fcn.004f96b0
mov ecx, eax
call fcn.00501c50
add eax, esi
push eax
call fcn.004f96b0
mov ecx, eax
call fcn.004f8960
lea eax, [edi + 0xc20]
push eax
mov byte [0x50a74d], 1
call fcn.00503ca0
mov esi, dword [0x50a72c]
call 0x553660
mov eax, dword [eax + 4]
push 0x4dc808
mov ebx, eax
call 0x55a5a0
mov ecx, eax
call 0x559f10
mov ecx, dword [esp + 0x28]
mov esi, dword [0x50a72c]
lea ebx, [eax + ecx]
call 0x553660
mov ecx, ebx
mov edx, eax
call fcn.00512710
call fcn.0051fc20
mov edi, dword [esp + 0x10]
xor ecx, ecx
call fcn.00511a40
mov esi, dword [esp + 0x20]
call fcn.00512c10
mov edx, dword [ebp + 8]
push edx
mov ecx, eax
call fcn.0051fb80
mov edi, dword [esi + 4]
test edi, edi
je 0x51a093
mov eax, edi
call 0x559a70
push edi
call 0x5600be
add esp, 4
push esi
call 0x549770
push esi
call 0x5600be
add esp, 4
mov dword [esp + 0x38], 0xffffffff
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x51a0ca
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov esi, dword [esp + 0x18]
mov edi, dword [esp + 0x24]
inc esi
cmp esi, edi
mov dword [esp + 0x18], esi
jl 0x519e32
mov ecx, dword [esp + 0x30]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4