Function at 0x40f660
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x43d0aa
mov eax, dword fs:[0]
push eax
sub esp, 0x18
push ebx
push esi
push edi
mov eax, dword [0x44c00c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x14], ecx
mov eax, dword [ebp + 0x20]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0x24]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0x28]
mov dword [ebp - 0x10], eax
push 0x5c
mov dword [ebp - 4], 4
call fcn.0041df3c
mov edi, eax
add esp, 4
mov dword [ebp - 0x24], edi
push 0x402240
push fcn.00402b20
push 5
push 4
push edi
mov byte [ebp - 4], 5
call fcn.0041e186
lea ecx, [edi + 0x20]
mov byte [ebp - 4], 6
call fcn.0040cfd0
mov dword [edi + 0x14], 0
mov dword [edi + 0x18], 0
mov dword [edi + 0x1c], 0
mov dword [edi + 0x50], 0
mov dword [edi + 0x54], 0
mov dword [edi + 0x58], 0
mov byte [ebp - 4], 4
mov eax, dword [ebp + 8]
mov ebx, dword [edi]
sub ebx, 0x10
lea ecx, [eax - 0x10]
cmp ecx, ebx
je 0x40f743
cmp dword [ebx + 0xc], 0
jl 0x40f738
mov edx, dword [ecx]
cmp edx, dword [ebx]
jne 0x40f738
call fcn.00402ee0
mov ecx, ebx
mov esi, eax
call fcn.004038b0
lea eax, [esi + 0x10]
mov dword [edi], eax
jmp 0x40f743
push dword [eax - 0xc]
mov ecx, edi
push eax
call fcn.00402f50
mov eax, dword [ebp + 0xc]
mov ebx, dword [edi + 4]
sub ebx, 0x10
lea ecx, [eax - 0x10]
cmp ecx, ebx
je 0x40f781
cmp dword [ebx + 0xc], 0
jl 0x40f775
mov edx, dword [ecx]
cmp edx, dword [ebx]
jne 0x40f775
call fcn.00402ee0
mov ecx, ebx
mov esi, eax
call fcn.004038b0
lea eax, [esi + 0x10]
mov dword [edi + 4], eax
jmp 0x40f781
push dword [eax - 0xc]
lea ecx, [edi + 4]
push eax
call fcn.00402f50
mov eax, dword [ebp + 0x10]
mov ebx, dword [edi + 8]
sub ebx, 0x10
lea ecx, [eax - 0x10]
cmp ecx, ebx
je 0x40f7bf
cmp dword [ebx + 0xc], 0
jl 0x40f7b3
mov edx, dword [ecx]
cmp edx, dword [ebx]
jne 0x40f7b3
call fcn.00402ee0
mov ecx, ebx
mov esi, eax
call fcn.004038b0
lea eax, [esi + 0x10]
mov dword [edi + 8], eax
jmp 0x40f7bf
push dword [eax - 0xc]
lea ecx, [edi + 8]
push eax
call fcn.00402f50
mov eax, dword [ebp + 0x14]
mov ebx, dword [edi + 0xc]
sub ebx, 0x10
lea ecx, [eax - 0x10]
cmp ecx, ebx
je 0x40f7fd
cmp dword [ebx + 0xc], 0
jl 0x40f7f1
mov edx, dword [ecx]
cmp edx, dword [ebx]
jne 0x40f7f1
call fcn.00402ee0
mov ecx, ebx
mov esi, eax
call fcn.004038b0
lea eax, [esi + 0x10]
mov dword [edi + 0xc], eax
jmp 0x40f7fd
push dword [eax - 0xc]
lea ecx, [edi + 0xc]
push eax
call fcn.00402f50
mov eax, dword [ebp + 0x18]
mov ebx, dword [edi + 0x10]
sub ebx, 0x10
lea ecx, [eax - 0x10]
cmp ecx, ebx
je 0x40f83b
cmp dword [ebx + 0xc], 0
jl 0x40f82f
mov edx, dword [ecx]
cmp edx, dword [ebx]
jne 0x40f82f
call fcn.00402ee0
mov ecx, ebx
mov esi, eax
call fcn.004038b0
lea eax, [esi + 0x10]
mov dword [edi + 0x10], eax
jmp 0x40f83b
push dword [eax - 0xc]
lea ecx, [edi + 0x10]
push eax
call fcn.00402f50
mov eax, dword [ebp + 0x1c]
lea ebx, [edi + 0x20]
mov dword [edi + 0x1c], eax
mov eax, dword [ebp - 0x14]
mov dword [edi + 0x14], eax
mov eax, dword [ebp - 0x18]
mov dword [edi + 0x18], eax
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x40f85f
push eax
mov ecx, ebx
call fcn.0040d1d0
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x40f888
mov edx, ecx
lea esi, [edx + 2]
nop dword [eax + eax]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x40f870
sub edx, esi
sar edx, 1
push edx
push ecx
mov ecx, ebx
call fcn.00402f50
mov dword [0x44e724], 0
mov eax, 1
lock xadd dword [0x44e6b8], eax
inc eax
mov ecx, dword [ebp - 0x10]
mov dword [edi + 0x50], eax
test ecx, ecx
je 0x40f8ac
mov dword [ecx], eax
lea eax, [edi + 0x58]
push eax
push 0
push edi
push 0x40ea10
push 0
push 0
call fcn.0042e659
xor ebx, ebx
mov dword [edi + 0x54], eax
add esp, 0x18
mov byte [ebp - 4], 3
mov ecx, dword [ebp + 8]
test eax, eax
setne bl
or esi, 0xffffffff
add ecx, 0xfffffff0
mov eax, esi
lock xadd dword [ecx + 0xc], eax
dec eax
mov edi, dword [sym.imp.KERNEL32.dll_HeapFree]
test eax, eax
jg 0x40f913
mov edx, dword [ecx]
push ecx
mov eax, dword [edx]
mov edi, dword [eax + 4]
mov dword [ebp - 0x10], edi
mov edi, dword [sym.imp.KERNEL32.dll_HeapFree]
cmp eax, vtable.ATL::CAtlStringMgr.0
jne 0x40fa20
mov eax, dword [edx + 4]
push 0
push dword [eax + 4]
call edi
mov byte [ebp - 4], 2
mov eax, esi
mov ecx, dword [ebp + 0xc]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x40f94f
mov edx, dword [ecx]
push ecx
mov eax, dword [edx]
mov edi, dword [eax + 4]
mov dword [ebp - 0x10], edi
mov edi, dword [sym.imp.KERNEL32.dll_HeapFree]
cmp eax, vtable.ATL::CAtlStringMgr.0
jne 0x40fa2a
mov eax, dword [edx + 4]
push 0
push dword [eax + 4]
call edi
mov byte [ebp - 4], 1
mov eax, esi
mov ecx, dword [ebp + 0x10]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x40f98b
mov edx, dword [ecx]
push ecx
mov eax, dword [edx]
mov edi, dword [eax + 4]
mov dword [ebp - 0x10], edi
mov edi, dword [sym.imp.KERNEL32.dll_HeapFree]
cmp eax, vtable.ATL::CAtlStringMgr.0
jne 0x40fa34
mov eax, dword [edx + 4]
push 0
push dword [eax + 4]
call edi
mov byte [ebp - 4], 0
mov eax, esi
mov ecx, dword [ebp + 0x14]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x40f9c7
mov edx, dword [ecx]
push ecx
mov eax, dword [edx]
mov edi, dword [eax + 4]
mov dword [ebp - 0x10], edi
mov edi, dword [sym.imp.KERNEL32.dll_HeapFree]
cmp eax, vtable.ATL::CAtlStringMgr.0
jne 0x40fa3e
mov eax, dword [edx + 4]
push 0
push dword [eax + 4]
call edi
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 0x18]
add eax, 0xfffffff0
lock xadd dword [eax + 0xc], esi
dec esi
test esi, esi
jg 0x40fa0c
mov edx, dword [eax]
push eax
mov ecx, dword [edx]
mov esi, dword [ecx + 4]
cmp ecx, vtable.ATL::CAtlStringMgr.0
jne 0x40fa45
mov ecx, dword [edx + 4]
push 0
push dword [ecx + 4]
call edi
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, edx
call dword [ebp - 0x10]
jmp 0x40f913
mov ecx, edx
call dword [ebp - 0x10]
jmp 0x40f94f
mov ecx, edx
call dword [ebp - 0x10]
jmp 0x40f98b
mov ecx, edx
call dword [ebp - 0x10]
jmp 0x40f9c7
mov ecx, edx
call esi
jmp 0x40fa0c