Function at 0x847880
Capabilities:
Access peb ldr_data
Check for peb beingdebugged flag

Disassembly:
push 0xffffffffffffffff
push 0x9469eb
mov eax, dword fs:[0]
push eax
sub esp, 0xcc
mov eax, dword [0x99986c]
xor eax, esp
mov dword [esp + 0xc8], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x99986c]
xor eax, esp
push eax
lea eax, [esp + 0xe0]
mov dword fs:[0], eax
mov edi, dword [esp + 0xf0]
mov ebx, dword [edi + 0x10]
sub ebx, dword [edi + 0xc]
mov eax, dword [esp + 0xf4]
mov esi, dword [esp + 0xf8]
sar ebx, 1
mov dword [esp + 0x30], eax
mov dword [esp + 0x28], esi
mov dword [esp + 0x14], ebx
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x8478e7
sub eax, edx
sar eax, 1
xor ebp, ebp
lea ecx, [esp + 0x38]
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], ebp
call fcn.0090a020
mov dword [esp + 0xe8], ebp
test esi, esi
je 0x84793d
mov eax, dword [esp + 0x30]
push 0xffffffffffffffff
push eax
lea ecx, [esp + 0x40]
call fcn.0090a030
push 0x3d
push 1
lea ecx, [esp + 0x40]
call fcn.00909400
push 0xffffffffffffffff
push esi
lea ecx, [esp + 0x40]
call fcn.0090a030
test ebx, ebx
ja 0x8479ea
test esi, esi
je 0x8479aa
mov eax, dword [edi + 0x10]
mov ebx, dword [edi + 0xc]
mov esi, eax
sub esi, ebx
sar esi, 1
cmp ebx, ebx
ja 0x84795d
cmp ebx, eax
jbe 0x847962
call fcn.0091bc53
mov eax, dword [edi]
push 1
lea ecx, [esp + 0x24]
push ecx
push esi
lea edx, [esp + 0x34]
push edx
lea ecx, [esp + 0x24]
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], ebx
call fcn.00847120
mov ecx, eax
call fcn.00847170
mov ecx, dword [esp + 0x38]
mov edx, dword [esp + 0x3c]
mov esi, dword [esp + 0x14]
push esi
lea edx, [ecx + edx*2 + 2]
push edx
mov edx, dword [eax]
push ecx
mov ecx, dword [eax + 4]
push ecx
push edx
mov ecx, edi
call fcn.00847410
mov dword [esp + 0xe8], 0xffffffff
lea ecx, [esp + 0x38]
call fcn.009098c0
mov ecx, dword [esp + 0xe0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0xc8]
xor ecx, esp
call fcn.0091b0aa
add esp, 0xd8
ret
mov ebp, dword [esp + 0x1c]
mov esi, dword [edi + 0xc]
cmp esi, dword [edi + 0x10]
jbe 0x8479f7
call fcn.0091bc53
mov eax, dword [edi]
test eax, eax
jne 0x847a8a
call fcn.0091bc53
xor eax, eax
cmp esi, dword [eax + 0x10]
jb 0x847a12
call fcn.0091bc53
mov eax, dword [esp + 0x20]
mov ecx, ebx
sub ecx, ebp
lea esi, [esi + ebp*2]
cmp ecx, eax
jbe 0x847a46
mov edx, dword [esp + 0x30]
lea ebx, [eax + eax]
push ebx
push edx
push esi
call fcn.0091c50b
add esp, 0xc
test eax, eax
jne 0x847a3e
cmp word [ebx + esi], 0x3d
je 0x847a91
mov ebx, dword [esp + 0x14]
mov eax, dword [esp + 0x20]
push eax
mov eax, dword [esp + 0x34]
push esi
push eax
call fcn.0091b27b
add esp, 0xc
test eax, eax
jl 0x847bef
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x847a62
sub eax, edx
sar eax, 1
lea eax, [eax + ebp + 1]
mov dword [esp + 0x1c], eax
cmp eax, ebx
jb 0x8479e6
mov esi, dword [esp + 0x28]
jmp 0x847945
mov eax, dword [eax]
jmp 0x847a08
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x847a96
mov ebx, dword [edi + 0xc]
sub eax, edx
sar eax, 1
mov dword [esp + 0x14], eax
cmp ebx, dword [edi + 0x10]
jbe 0x847ab6
call fcn.0091bc53
mov esi, dword [edi]
mov ebp, esi
mov dword [esp + 0x24], ebx
test esi, esi
jne 0x847add
call fcn.0091bc53
xor eax, eax
mov ecx, dword [esp + 0x1c]
lea ebx, [ebx + ecx*2]
cmp ebx, dword [eax + 0x10]
ja 0x847ae8
test esi, esi
je 0x847ae1
mov esi, dword [esi]
jmp 0x847ae3
mov eax, dword [esi]
jmp 0x847ac9
xor esi, esi
cmp ebx, dword [esi + 0xc]
jae 0x847aed
call fcn.0091bc53
mov dword [esp + 0x24], ebx
test ebp, ebp
jne 0x847b11
call fcn.0091bc53
xor eax, eax
mov edx, dword [esp + 0x14]
lea esi, [ebx + edx*2]
cmp esi, dword [eax + 0x10]
ja 0x847b1d
test ebp, ebp
je 0x847b16
mov eax, dword [ebp]
jmp 0x847b18
mov eax, dword [ebp]
jmp 0x847afc
xor eax, eax
cmp esi, dword [eax + 0xc]
jae 0x847b22
call fcn.0091bc53
mov dword [esp + 0x20], ebp
mov dword [esp + 0x24], esi
test ebp, ebp
jne 0x847b4a
call fcn.0091bc53
xor eax, eax
add esi, 2
mov dword [esp + 0x14], esi
cmp esi, dword [eax + 0x10]
ja 0x847b56
test ebp, ebp
je 0x847b4f
mov eax, dword [ebp]
jmp 0x847b51
mov eax, dword [ebp]
jmp 0x847b35
xor eax, eax
cmp esi, dword [eax + 0xc]
jae 0x847b5b
call fcn.0091bc53
mov ebx, dword [edi + 0xc]
cmp ebx, dword [edi + 0x10]
jbe 0x847b68
call fcn.0091bc53
mov esi, dword [edi]
mov dword [esp + 0x34], ebx
test esi, esi
jne 0x847b8d
call fcn.0091bc53
xor eax, eax
mov ecx, dword [esp + 0x1c]
lea ebx, [ebx + ecx*2]
cmp ebx, dword [eax + 0x10]
ja 0x847b98
test esi, esi
je 0x847b91
mov eax, dword [esi]
jmp 0x847b93
mov eax, dword [esi]
jmp 0x847b79
xor eax, eax
cmp ebx, dword [eax + 0xc]
jae 0x847b9d
call fcn.0091bc53
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x20]
push edx
push eax
push ebx
push esi
lea ecx, [esp + 0x24]
push ecx
mov ecx, edi
call fcn.00847320
cmp dword [esp + 0x28], 0
je 0x8479aa
mov esi, dword [edi + 0xc]
cmp esi, dword [edi + 0x10]
jbe 0x847bcd
call fcn.0091bc53
mov eax, dword [esp + 0x1c]
mov edx, dword [edi]
push eax
lea ecx, [esp + 0x24]
push ecx
lea ecx, [esp + 0x1c]
mov dword [esp + 0x1c], edx
mov dword [esp + 0x20], esi
call fcn.00847120
jmp 0x847989
cmp dword [esp + 0x28], 0
je 0x8479aa
mov esi, dword [edi + 0xc]
cmp esi, dword [edi + 0x10]
jbe 0x847c07
call fcn.0091bc53
mov eax, dword [edi]
push ebp
lea ecx, [esp + 0x24]
push ecx
lea ecx, [esp + 0x1c]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], esi
call fcn.00847120
jmp 0x847989