Function at 0x1005b4a0
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x101223c8
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x1016e750]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x10], ebx
mov eax, dword [ebx + 0x1c]
mov edi, 0xf8
cmp dword [ebx + 0x3c], 0
mov ecx, dword [ebx + 0x30]
mov dword [ebp - 0x1c], ecx
mov edx, dword [eax + 0xc]
mov esi, dword [eax + 8]
mov eax, 0x108
cmovne edi, eax
mov eax, dword [ebx + 0xc]
add edi, dword [eax + 0x3c]
add edi, ecx
mov dword [ebp - 0x14], edi
test edx, edx
je 0x1005b6ba
cmp dword [ebx + 0x34], 0
jne 0x1005b50a
mov eax, esi
jmp 0x1005b545
movzx ebx, word [ebx + 8]
xor eax, eax
xor edx, edx
mov ecx, edi
cmp ax, bx
jae 0x1005b539
lea esp, [esp]
mov edi, dword [ecx + 0xc]
cmp esi, edi
jb 0x1005b530
mov eax, dword [ecx + 8]
add eax, edi
cmp esi, eax
jb 0x1005b5a6
inc edx
add ecx, 0x28
cmp dx, bx
jb 0x1005b520
or eax, 0xffffffff
mov ecx, dword [ebp - 0x1c]
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x14]
add eax, ecx
cmp dword [ebx + 0x34], 0
mov dword [ebp - 0x1c], eax
je 0x1005b582
movzx ebx, word [ebx + 8]
xor eax, eax
xor edx, edx
mov ecx, edi
cmp ax, bx
jae 0x1005b579
nop
mov edi, dword [ecx + 0xc]
cmp esi, edi
jb 0x1005b570
mov eax, dword [ecx + 8]
add eax, edi
cmp esi, eax
jb 0x1005b5af
inc edx
add ecx, 0x28
cmp dx, bx
jb 0x1005b560
or esi, 0xffffffff
mov eax, dword [ebp - 0x1c]
mov ebx, dword [ebp - 0x10]
xor ecx, ecx
cmp ecx, dword [ebx + 0x2c]
jb 0x1005b5b8
ja 0x1005b590
cmp esi, dword [ebx + 0x28]
jb 0x1005b5b8
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [ecx + 0x14]
sub eax, edi
add eax, esi
jmp 0x1005b53c
mov eax, dword [ecx + 0x14]
sub eax, edi
add esi, eax
jmp 0x1005b57c
lea esi, [eax + 0xc]
mov dword [ebp - 0x18], esi
cmp dword [esi], ecx
je 0x1005b6ba
mov ecx, dword [ebx + 0x34]
mov edx, dword [esi]
mov dword [ebp - 0x20], ecx
test ecx, ecx
jne 0x1005b5d6
mov eax, edx
jmp 0x1005b60f
movzx ebx, word [ebx + 8]
xor eax, eax
mov ecx, dword [ebp - 0x14]
xor edi, edi
cmp ax, bx
jae 0x1005b603
mov esi, dword [ecx + 0xc]
cmp edx, esi
jb 0x1005b5fa
mov eax, dword [ecx + 8]
add eax, esi
cmp edx, eax
jb 0x1005b6d3
inc edi
add ecx, 0x28
cmp di, bx
jb 0x1005b5e6
or eax, 0xffffffff
mov ebx, dword [ebp - 0x10]
mov ecx, dword [ebp - 0x20]
mov esi, dword [ebp - 0x18]
xor edi, edi
cmp edi, dword [ebx + 0x2c]
ja 0x1005b590
jb 0x1005b625
cmp eax, dword [ebx + 0x28]
jae 0x1005b590
test ecx, ecx
je 0x1005b666
movzx ebx, word [ebx + 8]
xor ecx, ecx
mov eax, dword [ebp - 0x14]
xor esi, esi
cmp cx, bx
jae 0x1005b65d
lea esp, [esp]
mov edi, dword [eax + 0xc]
cmp edx, edi
jb 0x1005b654
mov ecx, dword [eax + 8]
add ecx, edi
cmp edx, ecx
jb 0x1005b6df
inc esi
add eax, 0x28
cmp si, bx
jb 0x1005b640
or edx, 0xffffffff
mov ebx, dword [ebp - 0x10]
mov esi, dword [ebp - 0x18]
mov eax, dword [ebx + 0x30]
lea ecx, [ebp - 0x1c]
add eax, edx
push eax
call fcn.100264e0
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x1c]
push eax
mov dword [ebp - 4], 0
call fcn.10039ca0
mov dword [ebp - 4], 0xffffffff
add esi, 0x14
mov edx, dword [ebp - 0x1c]
or ecx, 0xffffffff
add edx, 0xfffffff0
mov dword [ebp - 0x18], esi
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x1005b6b1
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
cmp dword [esi], 0
jne 0x1005b5c6
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [ecx + 0x14]
sub eax, esi
add eax, edx
jmp 0x1005b606
mov ecx, dword [eax + 0x14]
sub ecx, edi
add edx, ecx
jmp 0x1005b660