Function at 0x4044d0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x2c
mov ebx, dword [0x49c308]
mov ebp, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebp
mov esi, dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, eax
mov dword [esp], ebx
call esi
mov ebx, eax
mov eax, dword [sym.imp.KERNEL32.dll_SetLastError]
sub esp, 4
mov dword [esp], edi
mov dword [esp + 0x18], eax
call eax
mov edi, dword [0x49c308]
mov dword [ebx + 0x24], 0x400000
sub esp, 4
mov dword [ebx + 0x28], 0x1f4
mov dword [ebx + 0x1600], 0
mov dword [ebx + 0x1604], 0
mov dword [ebx + 0x1608], 0
mov dword [ebx + 0x160c], 0
mov dword [ebx + 0x1610], 0
mov dword [ebx + 0x1614], 0
mov dword [ebx + 0x2c], 0
mov dword [ebx + 0x30], 0x400
call ebp
mov dword [esp], edi
mov dword [esp + 0x1c], eax
call esi
sub esp, 4
mov edi, eax
mov edx, dword [esp + 0x1c]
mov eax, dword [esp + 0x18]
mov dword [esp], edx
call eax
lea ecx, [edi + 0x54]
mov edx, 0x1008
sub esp, 4
call fcn.00404070
lea edx, [eax + 8]
lea edi, [eax + 0xc]
mov dword [eax + 8], 0
mov ecx, edx
and edi, 0xfffffffc
mov dword [eax + 0x1004], 0
sub ecx, edi
mov dword [eax + 4], 1
xor eax, eax
add ecx, 0x1000
shr ecx, 2
rep stosd dword es:[edi], eax
mov dword [ebx + 0x34], edx
mov dword [ebx + 0x44], 0
mov edi, dword [0x49c308]
mov dword [ebx + 0x48], 0x400
call ebp
mov dword [esp + 0x1c], eax
mov dword [esp], edi
call esi
sub esp, 4
mov edi, eax
mov edx, dword [esp + 0x1c]
mov dword [esp], edx
mov edx, dword [esp + 0x18]
call edx
lea ecx, [edi + 0x54]
mov edx, 0x1008
sub esp, 4
call fcn.00404070
lea edx, [eax + 8]
lea edi, [eax + 0xc]
mov dword [eax + 8], 0
mov ecx, edx
and edi, 0xfffffffc
mov dword [eax + 0x1004], 0
sub ecx, edi
mov dword [eax + 4], 1
xor eax, eax
add ecx, 0x1000
shr ecx, 2
rep stosd dword es:[edi], eax
mov dword [ebx + 0x4c], edx
mov dword [ebx + 0x38], 0
mov edi, dword [0x49c308]
mov dword [ebx + 0x3c], 0x400
call ebp
mov dword [esp + 0x1c], eax
mov dword [esp], edi
call esi
sub esp, 4
mov edi, eax
mov edx, dword [esp + 0x1c]
mov dword [esp], edx
mov edx, dword [esp + 0x18]
call edx
lea ecx, [edi + 0x54]
mov edx, 0x1008
sub esp, 4
call fcn.00404070
lea edx, [eax + 8]
lea edi, [eax + 0xc]
mov dword [eax + 8], 0
mov ecx, edx
and edi, 0xfffffffc
mov dword [eax + 0x1004], 0
sub ecx, edi
mov dword [eax + 4], 1
xor eax, eax
add ecx, 0x1000
shr ecx, 2
rep stosd dword es:[edi], eax
mov dword [ebx + 0x40], edx
mov edi, dword [0x49c308]
call ebp
mov dword [esp + 0x1c], eax
mov dword [esp], edi
call esi
sub esp, 4
mov edi, eax
mov edx, dword [esp + 0x1c]
mov dword [esp], edx
mov edx, dword [esp + 0x18]
call edx
lea ecx, [edi + 0x54]
mov edx, 0x1008
sub esp, 4
call fcn.00404070
lea edx, [eax + 8]
lea edi, [eax + 0xc]
mov dword [eax + 8], 0
and edi, 0xfffffffc
mov ecx, edx
mov dword [eax + 4], 1
mov dword [eax + 0x1004], 0
sub ecx, edi
xor eax, eax
add ecx, 0x1000
shr ecx, 2
rep stosd dword es:[edi], eax
mov dword [ebx + 0x162c], edx
mov dword [ebx + 0x1624], 0x3ff
mov edx, dword [0x49c308]
mov dword [ebx + 0x1620], 0
mov dword [ebx + 0x1628], 0
mov dword [esp + 0x1c], edx
mov dword [ebx + 0x1630], 0
mov dword [ebx + 0x1634], 0x400
call ebp
mov edx, dword [esp + 0x1c]
mov edi, eax
mov dword [esp], edx
call esi
sub esp, 4
mov esi, eax
mov dword [esp], edi
mov edx, dword [esp + 0x18]
call edx
lea ecx, [esi + 0x54]
mov edx, 0x1008
sub esp, 4
call fcn.00404070
lea edx, [eax + 8]
lea edi, [eax + 0xc]
mov dword [eax + 4], 1
and edi, 0xfffffffc
mov ecx, edx
mov dword [eax + 8], 0
mov dword [eax + 0x1004], 0
sub ecx, edi
xor eax, eax
add ecx, 0x1000
shr ecx, 2
rep stosd dword es:[edi], eax
mov dword [ebx + 0x1638], edx
lea ecx, [ebx + 0x163c]
call fcn.00401970
mov eax, 1
lock xadd dword [0x490104], eax
mov dword [ebx + 0x165c], eax
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret