Function at 0x404980
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x492488
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x3c
mov eax, dword [esp + 0x4c]
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov edi, dword [esp + 0x60]
push ecx
xor ebp, ebp
mov ecx, esp
mov dword [esp + 0x60], esp
push edi
mov dword [esp + 0x50], esi
mov dword [esi], eax
mov dword [esi + 8], ebp
mov dword [esi + 4], ebp
mov dword [esi + 0x10], ebp
mov dword [esi + 0xc], ebp
mov dword [esi + 0x30], 1
call fcn.00485498
lea ecx, [esp + 0x20]
push ecx
call fcn.00401600
mov edx, dword [esp + 0x24]
push 0x4aa128
push edx
mov dword [esp + 0x64], ebp
call fcn.00464a16
add esp, 0x10
test eax, eax
jne 0x4049fc
push edi
mov ecx, esi
call fcn.00404ea0
jmp 0x404a21
mov eax, dword [esp + 0x1c]
push 0x4aa318
push eax
call fcn.00464a16
add esp, 8
mov ecx, esi
test eax, eax
push edi
jne 0x404a1c
call fcn.00405520
jmp 0x404a21
call fcn.00405350
mov ecx, dword [esi + 0x10]
shl ecx, 3
push ecx
call fcn.00485977
mov ecx, dword [esi + 0x10]
mov edi, eax
shl ecx, 3
mov edx, ecx
xor eax, eax
shr ecx, 2
mov dword [esi + 0x34], edi
add esp, 4
rep stosd dword es:[edi], eax
mov ecx, edx
mov dword [esp + 0x5c], ebp
and ecx, 3
mov dword [esp + 0x60], ebp
rep stosb byte es:[edi], al
mov edx, dword [esi + 8]
mov eax, dword [esi + 4]
neg edx
sbb edx, edx
mov dword [esp + 0x14], ebp
and edx, 0xfffffffd
mov dword [esp + 0x10], ebp
add edx, 4
lea ebx, [eax + edx - 1]
mov eax, dword [esi + 0x10]
test eax, eax
mov dword [esp + 0x18], ebx
jle 0x404b22
mov eax, dword [esi + 0xc]
xor edi, edi
test eax, eax
jle 0x404ad1
mov eax, dword [esi + 8]
test eax, eax
je 0x404a98
xor ecx, ecx
mov cl, byte [ebx]
mov al, byte [eax + ecx*4 + 3]
jmp 0x404a9a
mov al, byte [ebx]
cmp al, 0xfc
jae 0x404aa5
mov dword [esi + 0x30], 0
cmp al, 4
jb 0x404ac3
mov eax, dword [esi + 0x34]
mov ecx, dword [eax + ebp*8 + 4]
lea eax, [eax + ebp*8]
test ecx, ecx
jne 0x404ab9
mov dword [eax], edi
mov eax, dword [esi + 0x34]
lea ecx, [edi + 1]
mov dword [eax + ebp*8 + 4], ecx
mov eax, dword [esi + 0xc]
inc edi
add ebx, edx
cmp edi, eax
jl 0x404a87
mov dword [esp + 0x18], ebx
mov ecx, dword [esi + 0x34]
mov eax, dword [ecx + ebp*8]
lea ecx, [ecx + ebp*8]
mov ecx, dword [ecx + 4]
cmp eax, ecx
je 0x404b16
mov edi, dword [esp + 0x5c]
mov ebx, dword [esp + 0x60]
cmp edi, ebx
jne 0x404afb
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], ecx
mov dword [esp + 0x14], ebp
jmp 0x404b0b
cmp edi, eax
jl 0x404b03
mov dword [esp + 0x5c], eax
cmp ebx, ecx
jg 0x404b0b
mov dword [esp + 0x60], ecx
mov ebx, dword [esp + 0x18]
lea eax, [ebp + 1]
mov dword [esp + 0x10], eax
mov eax, dword [esi + 0x10]
inc ebp
cmp ebp, eax
jl 0x404a7e
mov edx, dword [esp + 0x5c]
mov eax, dword [esp + 0x14]
lea ecx, [esi + 0x1c]
fld dword [esp + 0x64]
mov dword [ecx], edx
mov edx, dword [esp + 0x60]
fcomp dword [0x499710]
mov dword [ecx + 4], eax
mov eax, dword [esp + 0x10]
mov dword [ecx + 8], edx
mov edx, dword [esi + 0x10]
mov dword [ecx + 0xc], eax
mov eax, dword [esp + 0x64]
mov ecx, dword [esi + 0xc]
mov dword [esi + 0x2c], eax
fnstsw ax
mov dword [esi + 0x14], ecx
mov dword [esi + 0x18], edx
test ah, 0x40
jne 0x404e52
mov ecx, esi
call fcn.00405aa0
fld dword [esi + 0x2c]
fcomp dword [0x49970c]
fnstsw ax
test ah, 1
je 0x404b84
fld dword [esi + 0x2c]
jmp 0x404b8a
fld dword [0x49970c]
fst dword [esi + 0x2c]
fld st(0)
fcomp dword [0x499708]
fnstsw ax
test ah, 0x41
jne 0x404b9e
jmp 0x404ba6
fstp st(0)
fld dword [0x499708]
fst dword [esi + 0x2c]
fild dword [esi + 0x14]
fmul st(1)
fadd dword [0x4996ec]
call fcn.00464e6c
fild dword [esi + 0x18]
mov edi, eax
mov dword [esi + 0xc], edi
fmul st(1)
fadd dword [0x4996ec]
call fcn.00464e6c
mov dword [esi + 0x10], eax
imul eax, edi
fstp st(0)
shl eax, 2
push eax
call fcn.00485977
fld dword [0x499704]
fdiv dword [esi + 0x2c]
add esp, 4
mov dword [esp + 0x3c], eax
call fcn.00464e6c
mov ebp, eax
mov eax, dword [esi + 0x10]
test eax, eax
mov dword [esp + 0x44], ebp
mov dword [esp + 0x18], 0
jle 0x404e3f
mov eax, ebp
cdq
sub eax, edx
sar eax, 1
add eax, 0x8000
mov dword [esp + 0x40], eax
mov dword [esp + 0x38], eax
sar eax, 8
mov edi, eax
mov ecx, dword [esi + 0x14]
sar edi, 8
xor ebx, ebx
lea edx, [edi - 1]
test edx, edx
setle bl
dec ebx
and ebx, edx
mov edx, dword [esi + 0x18]
imul ebx, ecx
dec edx
mov dword [esp + 0x20], ebx
cmp edi, edx
jge 0x404c4a
mov edx, edi
imul ecx, edx
mov dword [esp + 0x24], ecx
and eax, 0xff
mov ecx, 0x100
xor edi, edi
sub ecx, eax
mov dword [esp + 0x2c], eax
mov dword [esp + 0x28], ecx
mov ecx, dword [esi + 0xc]
test ecx, ecx
mov dword [esp + 0x30], edi
jle 0x404e21
mov edx, dword [esp + 0x40]
mov dword [esp + 0x34], edx
sar edx, 8
mov ebp, edx
xor ebx, ebx
sar ebp, 8
mov dword [esp + 0x64], ebp
lea eax, [ebp - 1]
test eax, eax
setle bl
dec ebx
and ebx, eax
mov eax, dword [esi + 0x14]
dec eax
cmp ebp, eax
jl 0x404ca3
mov dword [esp + 0x64], eax
imul ecx, dword [esp + 0x18]
add ecx, edi
mov edi, dword [esp + 0x3c]
and edx, 0xff
mov eax, 0x100
lea edi, [edi + ecx*4]
mov ecx, dword [esi + 4]
mov esi, dword [esp + 0x20]
sub eax, edx
add esi, ebx
lea ebp, [ecx + esi*4]
mov esi, dword [esp + 0x24]
add ebx, esi
lea esi, [ecx + ebx*4]
mov ebx, dword [esp + 0x20]
mov dword [esp + 0x5c], esi
mov esi, dword [esp + 0x64]
add ebx, esi
lea ebx, [ecx + ebx*4]
mov dword [esp + 0x64], ebx
mov ebx, dword [esp + 0x24]
add esi, ebx
lea ebx, [ecx + esi*4]
mov ecx, eax
imul eax, dword [esp + 0x2c]
imul ecx, dword [esp + 0x28]
mov esi, edx
imul edx, dword [esp + 0x2c]
imul esi, dword [esp + 0x28]
mov dword [esp + 0x60], eax
xor eax, eax
mov al, byte [ebx]
mov dword [esp + 0x10], ebx
mov ebx, dword [esp + 0x64]
imul eax, edx
mov dword [esp + 0x14], edx
xor edx, edx
mov dl, byte [ebx]
mov ebx, dword [esp + 0x5c]
imul edx, esi
add eax, edx
xor edx, edx
mov dl, byte [ebx]
mov ebx, dword [esp + 0x64]
imul edx, dword [esp + 0x60]
add eax, edx
xor edx, edx
mov dl, byte [ebp]
imul edx, ecx
add eax, edx
mov edx, dword [esp + 0x10]
sar eax, 0x10
mov byte [edi], al
xor eax, eax
mov al, byte [edx + 1]
xor edx, edx
mov dl, byte [ebx + 1]
imul eax, dword [esp + 0x14]
imul edx, esi
mov ebx, dword [esp + 0x5c]
add eax, edx
xor edx, edx
mov dl, byte [ebx + 1]
mov ebx, dword [esp + 0x64]
imul edx, dword [esp + 0x60]
add eax, edx
xor edx, edx
mov dl, byte [ebp + 1]
imul edx, ecx
add eax, edx
mov edx, dword [esp + 0x10]
sar eax, 0x10
mov byte [edi + 1], al
xor eax, eax
mov al, byte [edx + 2]
xor edx, edx
mov dl, byte [ebx + 2]
imul eax, dword [esp + 0x14]
imul edx, esi
add eax, edx
xor edx, edx
mov ebx, dword [esp + 0x5c]
mov dl, byte [ebx + 2]
mov ebx, dword [esp + 0x64]
imul edx, dword [esp + 0x60]
add eax, edx
xor edx, edx
mov dl, byte [ebp + 2]
imul edx, ecx
add eax, edx
mov edx, dword [esp + 0x10]
sar eax, 0x10
mov byte [edi + 2], al
xor eax, eax
mov al, byte [edx + 3]
xor edx, edx
mov dl, byte [ebx + 3]
imul eax, dword [esp + 0x14]
imul edx, esi
mov esi, dword [esp + 0x5c]
add eax, edx
xor edx, edx
mov dl, byte [esi + 3]
mov esi, dword [esp + 0x48]
imul edx, dword [esp + 0x60]
add eax, edx
xor edx, edx
mov dl, byte [ebp + 3]
mov ebp, dword [esp + 0x44]
imul edx, ecx
add eax, edx
mov edx, dword [esp + 0x34]
sar eax, 0x10
mov byte [edi + 3], al
mov edi, dword [esp + 0x30]
mov ecx, dword [esi + 0xc]
inc edi
add edx, ebp
cmp edi, ecx
mov dword [esp + 0x30], edi
mov dword [esp + 0x34], edx
jl 0x404c7e
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x38]
mov edx, dword [esi + 0x10]
inc ecx
add eax, ebp
cmp ecx, edx
mov dword [esp + 0x18], ecx
mov dword [esp + 0x38], eax
jl 0x404c21
mov eax, dword [esi + 4]
push eax
call fcn.004859a0
mov eax, dword [esp + 0x40]
add esp, 4
mov dword [esi + 4], eax
lea ecx, [esp + 0x1c]
mov dword [esp + 0x54], 0xffffffff
call fcn.0048542a
mov ecx, dword [esp + 0x4c]
mov eax, esi
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x48
ret 0xc