Function at 0x40a235
Capabilities:
Allocate thread local storage

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x9c
push esi
movzx eax, byte [ebp + 0x38]
test eax, eax
je 0x40a439
mov eax, dword [ebp + 0x20]
mov dword [ebp - 0x80], eax
lea eax, [ebp + 8]
mov dword [ebp - 0x78], eax
mov eax, dword [ebp + 0x28]
mov dword [ebp - 0x70], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x30], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0x88], eax
mov eax, dword [ebp + 0x24]
mov dword [ebp - 0x50], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x90], eax
lea eax, [ebp + 0x2c]
mov dword [ebp - 0x48], eax
mov eax, dword [ebp - 0x78]
movzx eax, byte [eax]
test eax, eax
je 0x40a2b2
mov eax, dword [ebp - 0x80]
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x30]
mov dword [ebp - 0x68], eax
push dword [ebp - 0x68]
push dword [ebp - 0x38]
push 0
call fcn.0041a749
add esp, 0xc
jmp 0x40a437
mov eax, dword [ebp - 0x90]
mov dword [ebp - 0x60], eax
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 0x70]
mov dword [ebp - 0x94], eax
mov eax, dword [ebp - 0x48]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x88]
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp - 0x50]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x24]
movzx eax, byte [eax]
test eax, eax
je 0x40a431
mov eax, dword [ebp - 0x58]
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x94]
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 0x60]
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x34]
mov dword [ebp - 8], eax
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x44]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x4c]
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x74], eax
mov eax, dword [ebp - 0xc]
cmp dword [eax], 0
jne 0x40a3ae
mov eax, dword [ebp - 0xc]
cmp dword [eax], 1
jge 0x40a345
mov dword [ebp - 0x10], 1
jmp 0x40a349
and dword [ebp - 0x10], 0
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x10]
mov dword [eax], ecx
push 1
mov ecx, dword [ebp - 4]
call fcn.00431e5c
mov eax, dword [ebp - 8]
mov esi, dword [eax]
push 1
mov ecx, dword [ebp - 4]
call fcn.00431e5c
cmp esi, dword [eax]
jl 0x40a379
or eax, 0xffffffff
jne 0x40a379
and dword [ebp - 0x1c], 0
jmp 0x40a380
mov dword [ebp - 0x1c], 1
mov eax, dword [ebp - 0x5c]
mov esi, dword [ebp - 0x1c]
sub esi, dword [eax]
push 1
mov ecx, dword [ebp - 4]
call fcn.00431e5c
cmp esi, dword [eax]
jg 0x40a39f
mov dword [ebp - 0x64], 1
jmp 0x40a3a3
and dword [ebp - 0x64], 0
or eax, 0xffffffff
jne 0x40a3ae
and dword [ebp - 0x14], 0
jmp 0x40a3b5
mov dword [ebp - 0x14], 1
cmp dword [ebp - 0x14], 0xfffffff7
jae 0x40a3c4
mov dword [ebp - 0x18], 1
jmp 0x40a3c8
and dword [ebp - 0x18], 0
mov eax, dword [ebp - 8]
mov esi, dword [eax]
add esi, dword [ebp - 0x18]
push 0
mov ecx, dword [ebp - 4]
call fcn.00431e5c
cmp esi, dword [eax]
jne 0x40a3f3
push 1
mov ecx, dword [ebp - 4]
call fcn.00431e5c
cmp dword [eax], 0
jne 0x40a3f3
and dword [ebp - 0x20], 0
jmp 0x40a3fa
mov dword [ebp - 0x20], 1
cmp dword [ebp - 0x20], 0x4b05
jle 0x40a40c
mov dword [ebp - 0x6c], 1
jmp 0x40a410
and dword [ebp - 0x6c], 0
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov dword [ebp - 0x98], eax
mov eax, dword [ebp - 0x74]
mov eax, dword [eax]
mov dword [ebp - 0x9c], eax
mov eax, dword [ebp - 8]
mov dword [eax], 6
jmp 0x40a437
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
jmp 0x40a474
mov eax, dword [ebp + 0x30]
mov dword [ebp - 0x8c], eax
mov eax, dword [ebp + 0x34]
mov dword [ebp - 0x84], eax
mov eax, dword [ebp + 0x1c]
mov dword [ebp - 0x7c], eax
push dword [ebp - 0x7c]
push dword [ebp - 0x84]
push 0xde1
push dword [ebp - 0x8c]
push 0x61ba
push 0
call fcn.00410aab
add esp, 0x18
pop esi
mov esp, ebp
pop ebp
ret