Function at 0x4758a0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x4d57b0
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push ebp
push esi
push edi
mov eax, dword [0x513330]
xor eax, esp
push eax
lea eax, [esp + 0x20]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x30]
lea ebx, [ebp + 0x34]
xor edi, edi
mov dword [esp + 0x14], edi
push ebx
mov dword [esp + 0x1c], ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov byte [esp + 0x1c], 1
mov dword [esp + 0x28], edi
mov eax, dword [0x51856c]
mov edx, dword [eax + 0xc]
mov ecx, 0x51856c
call edx
add eax, 0x10
mov dword [esp + 0x14], eax
mov byte [esp + 0x28], 1
xor eax, eax
cmp dword [ebp + 4], edi
je 0x475924
mov edx, dword [ebp + 8]
cmp edx, edi
jbe 0x475922
mov esi, dword [ebp]
mov ecx, esi
cmp dword [ecx], edi
jne 0x475945
inc eax
add ecx, 4
cmp eax, edx
jb 0x475916
xor eax, eax
mov edi, eax
test eax, eax
je 0x475a0a
xor eax, eax
test edi, edi
setne al
test eax, eax
je 0x475a67
mov ebx, edi
test edi, edi
jne 0x47594a
jmp 0x475979
mov eax, dword [esi + eax*4]
jmp 0x475924
mov ecx, dword [edi + 8]
test ecx, ecx
jne 0x475977
mov eax, dword [edi + 0xc]
mov esi, dword [ebp + 8]
xor edx, edx
div esi
inc edx
lea esp, [esp]
cmp edx, esi
jae 0x475977
mov eax, dword [ebp]
cmp dword [eax + edx*4], 0
lea eax, [eax + edx*4]
je 0x475972
mov ecx, dword [eax]
inc edx
test ecx, ecx
je 0x475960
mov edi, ecx
mov ecx, dword [ebx]
mov ebx, dword [esp + 0x14]
lea eax, [ecx - 0x10]
lea esi, [ebx - 0x10]
cmp eax, esi
je 0x4759d7
cmp dword [esi + 0xc], 0
lea ebx, [esi + 0xc]
jl 0x4759c6
mov edx, dword [eax]
cmp edx, dword [esi]
jne 0x4759c2
call fcn.00408230
mov ebp, eax
or eax, 0xffffffff
lock xadd dword [ebx], eax
dec eax
test eax, eax
jg 0x4759b5
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
add ebp, 0x10
mov dword [esp + 0x14], ebp
mov ebp, dword [esp + 0x30]
jmp 0x4759d3
mov ebp, dword [esp + 0x30]
mov ebx, dword [ecx - 0xc]
push ecx
lea eax, [esp + 0x18]
call fcn.00405e30
mov ebx, dword [esp + 0x14]
test ebx, ebx
je 0x4759fe
mov esi, dword [esp + 0x38]
mov eax, dword [esi]
cmp dword [eax - 0xc], 0
jl 0x4759fe
push ebx
push eax
call fcn.004a59da
add esp, 8
test eax, eax
je 0x4759fe
sub eax, dword [esi]
sar eax, 1
cmp eax, 0xffffffff
jne 0x475a71
test edi, edi
jne 0x47592e
mov ebx, dword [esp + 0x18]
mov edx, dword [0x51856c]
mov eax, dword [edx + 0xc]
mov ecx, 0x51856c
call eax
mov esi, dword [esp + 0x34]
add eax, 0x10
mov dword [esi], eax
mov byte [esp + 0x28], 0
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 0x475a48
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, esi
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret 0xc
push 0x80004005
call fcn.00405ef0
lea esi, [ebx - 0x10]
mov eax, esi
call fcn.00408230
mov edi, dword [esp + 0x34]
add eax, 0x10
mov dword [edi], eax
mov byte [esp + 0x28], 0
lea ecx, [esi + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x475aa2
mov ecx, dword [esi]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push esi
call edx
mov eax, dword [esp + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, edi
jmp 0x475a51