Function at 0x546350
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x5e4bc8
mov eax, dword fs:[0]
push eax
sub esp, 0x20
push ebx
push ebp
push esi
push edi
mov eax, dword [0x632da0]
xor eax, esp
push eax
lea eax, [esp + 0x34]
mov dword fs:[0], eax
mov esi, ecx
mov ebx, dword [esp + 0x44]
mov eax, dword [ebx]
mov ecx, dword [esi + 0x30]
mov edi, dword [esi + 0xc]
mov edx, eax
sub edx, ecx
add edx, eax
mov eax, dword [esi + 4]
mov dword [esi + 0x30], edx
movzx edx, word [esi + 0x20]
mov ebx, dword [ebx]
lea ecx, [edx*8 - 1]
imul ecx, edi
mov dword [esp + 0x1c], eax
mov eax, ebx
sub eax, dword [esp + 0x1c]
push edx
sub eax, ecx
add eax, ebx
add edi, eax
mov dword [esi + 4], edi
call sub.MSVCR90.dll_void____cdecl_operator_new___unsigned_int_
mov ebp, eax
xor eax, eax
add esp, 4
cmp dword [esi + 0x1c], eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], eax
jle 0x5464ab
movzx ecx, word [esi + 0x20]
mov edx, dword [esi + 0x18]
push ecx
add edx, eax
push edx
push ebp
call fcn.005bf848
add esp, 0xc
cmp byte [esi + 0x23], 2
jne 0x546402
mov eax, dword [esp + 0x1c]
and eax, 0x80000001
jns 0x5463fc
dec eax
or eax, 0xfffffffe
inc eax
jne 0x546402
xor ebx, ebx
jmp 0x546407
mov ebx, 1
movzx ecx, word [esi + 0x20]
lea eax, [ecx + ebp - 1]
mov cl, bl
shr byte [eax], cl
movzx edx, word [esi + 0x20]
xor al, al
sub edx, 1
mov dword [esp + 0x14], ebx
js 0x546490
cmp ebx, 8
jge 0x546448
mov cl, byte [edx + ebp]
mov edi, 8
sub edi, ebx
mov bl, cl
and bl, 1
add al, al
or al, bl
shr cl, 1
sub edi, 1
jne 0x546431
mov ebx, dword [esp + 0x14]
mov byte [edx + ebp], cl
test edx, edx
jne 0x546452
mov cl, bl
shl al, cl
jmp 0x546478
test ebx, ebx
jle 0x546478
mov cl, byte [edx + ebp - 1]
mov edi, ebx
lea esp, [esp]
mov bl, cl
and bl, 1
add al, al
or al, bl
shr cl, 1
sub edi, 1
jne 0x546460
mov ebx, dword [esp + 0x14]
mov byte [edx + ebp - 1], cl
movzx ecx, word [esi + 0x20]
mov edi, dword [esi + 0x18]
sub ecx, edx
add ecx, dword [esp + 0x18]
mov byte [ecx + edi - 1], al
xor al, al
sub edx, 1
jns 0x546422
movzx edx, word [esi + 0x20]
mov eax, dword [esp + 0x18]
inc dword [esp + 0x1c]
add eax, edx
cmp eax, dword [esi + 0x1c]
mov dword [esp + 0x18], eax
jl 0x5463d2
push ebp
call sub.MSVCR90.dll_void___cdecl_operator_delete_void__
fld qword [esi + 0x28]
fldz
add esp, 4
fld st(0)
fucomp st(2)
fnstsw ax
fstp st(1)
test ah, 0x44
jnp 0x5464ce
fld qword [esi + 0x28]
fchs
fstp qword [esi + 0x28]
fld qword [esi + 0x38]
fucompp
fnstsw ax
test ah, 0x44
jnp 0x5464e2
fld qword [esi + 0x38]
fchs
fstp qword [esi + 0x38]
mov eax, dword [esi + 0x4c]
test eax, eax
je 0x546536
mov ecx, dword [esi + 0x50]
push ecx
push eax
lea ecx, [esp + 0x28]
call fcn.00521170
mov edx, dword [esp + 0x44]
push edx
lea ecx, [esp + 0x24]
mov dword [esp + 0x40], 0
call fcn.00524e80
mov eax, dword [esi + 0x50]
mov ecx, dword [esp + 0x30]
mov edx, dword [esi + 0x4c]
shl eax, 4
push eax
push ecx
push edx
call fcn.005bf848
add esp, 0xc
lea ecx, [esp + 0x20]
mov dword [esp + 0x3c], 0xffffffff
call fcn.00526cc0
mov esi, dword [esi + 0x48]
test esi, esi
je 0x546549
mov eax, dword [esp + 0x44]
push eax
mov ecx, esi
call fcn.00546350
mov eax, 1
mov ecx, dword [esp + 0x34]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2c
ret 4