Function at 0x1004e450
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1011092d
mov eax, dword fs:[0]
push eax
sub esp, 0x24
push ebx
push esi
push edi
mov eax, dword [0x10163164]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x1c], edi
mov dword [ebp - 4], 0
lea eax, [ebp - 0xd]
mov esi, dword [ebp + 0x10]
mov dword [ebp - 0x24], eax
mov esi, dword [esi + 0x3c]
mov dword [ebp - 0x18], esi
mov byte [ebp - 4], 1
push dword [0x1017537c]
mov dword [ebp - 0x20], 0
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x1004e4b3
mov ecx, dword [eax + 4]
jmp 0x1004e4b5
xor ecx, ecx
push ecx
push dword [ebp - 0x1c]
mov edx, 0x9c
call fcn.1004f040
add esp, 8
mov ebx, eax
lea eax, [ebp + 0x10]
mov dword [ebp - 0x20], ebx
push eax
lea eax, [ebp + 8]
push eax
push ecx
mov ecx, ebx
call fcn.1004fa50
lea eax, [ebx + 0xc]
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x2c], eax
lea ecx, [ebx + 4]
mov dword [ebp - 0x14], ecx
test ebx, ebx
je 0x1004e4f3
lock inc dword [ecx]
jmp 0x1004e4f6
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x20], ebx
lea eax, [edi + 0x3c]
mov byte [ebp - 4], 3
push eax
lea eax, [ebp - 0x24]
push eax
lea ecx, [edi + 0x20]
call fcn.10051c90
mov ecx, dword [ebp - 0x20]
or edi, 0xffffffff
test ecx, ecx
je 0x1004e538
mov eax, edi
lock xadd dword [ecx + 4], eax
jne 0x1004e538
mov eax, dword [ecx]
call dword [eax]
mov ecx, dword [ebp - 0x20]
mov eax, edi
lock xadd dword [ecx + 8], eax
jne 0x1004e538
mov eax, dword [ecx]
call dword [eax + 4]
test ebx, ebx
je 0x1004e542
mov eax, dword [ebp - 0x14]
lock inc dword [eax]
lea eax, [ebx + 0xc]
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x24], eax
mov ecx, dword [ebp - 0x1c]
mov byte [ebp - 4], 4
lea eax, [ecx + 0x1c]
push eax
lea eax, [ebp - 0x24]
push eax
call fcn.10051e60
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x1004e588
mov eax, edi
lock xadd dword [ecx + 4], eax
jne 0x1004e588
mov eax, dword [ecx]
call dword [eax]
mov ecx, dword [ebp - 0x20]
mov eax, edi
lock xadd dword [ecx + 8], eax
jne 0x1004e588
mov eax, dword [ecx]
call dword [eax + 4]
lea edx, [ebx + 0xc]
mov ecx, 0xfffffffe
lea eax, [edx + 8]
lock xadd dword [eax], ecx
lea eax, [ecx - 2]
test eax, eax
je 0x1004e5d1
lea eax, [edx + 0x18]
lea edi, [edx + 0x10]
mov dword [ebp - 0x1c], eax
cmp edi, eax
je 0x1004e5ce
nop dword [eax + eax]
mov esi, dword [edx + 4]
mov ecx, dword [edi]
test ecx, ecx
je 0x1004e5c4
mov eax, dword [ecx]
push esi
call dword [eax]
mov eax, dword [ebp - 0x1c]
lea edx, [ebx + 0xc]
add edi, 4
cmp edi, eax
jne 0x1004e5b0
mov esi, dword [ebp - 0x18]
or edi, 0xffffffff
test esi, esi
je 0x1004e64e
push ecx
push 0x10
lea eax, [ebp - 0x24]
push eax
lea ecx, [ebp - 0x18]
call fcn.100279a0
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0x18], ecx
mov dword [ecx], 0x10148d7c
test ebx, ebx
je 0x1004e6d1
mov edx, dword [ebp - 0x14]
lock inc dword [edx]
lea eax, [ebx + 0xc]
mov dword [ecx + 8], 0
mov dword [ecx + 4], eax
lea eax, [ebx + 8]
mov dword [ecx + 8], ebx
lock inc dword [eax]
mov eax, edi
lock xadd dword [edx], eax
jne 0x1004e637
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax]
mov eax, edi
lea edx, [ebx + 8]
lock xadd dword [edx], eax
jne 0x1004e634
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 4]
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x20]
mov dword [ecx + 0xc], eax
mov dword [esi], ecx
lea ecx, [ebp - 0x24]
mov dword [ebp - 0x24], 0
call fcn.10027b30
lea esi, [ebx + 8]
test ebx, ebx
je 0x1004e674
mov ecx, dword [ebp - 0x14]
mov eax, edi
lock xadd dword [ecx], eax
jne 0x1004e674
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax]
lock xadd dword [esi], edi
dec edi
jne 0x1004e674
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 4]
mov dword [ebp - 4], 5
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x1004e6bf
push ecx
lea ecx, [eax + 0x18]
mov dword [ebp + 0x10], 0
lea edx, [ebp - 0x18]
mov dword [ebp - 0x18], eax
call fcn.1002a4d0
mov eax, dword [ebp - 0x18]
add esp, 4
test eax, eax
je 0x1004e6ad
mov eax, dword [eax]
push eax
mov eax, dword [eax + 4]
call eax
add esp, 4
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x1004e6bf
mov eax, dword [eax]
push eax
mov eax, dword [eax + 4]
call eax
add esp, 4
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 dword [ecx + 4], 0
mov dword [ecx + 8], 0
jmp 0x1004e637