Function at 0x41ad10
Capabilities:
Get thread local storage value

Disassembly:
sub esp, 0x3c
push ebx
mov ebx, dword [esp + 0x44]
push ebp
mov ebp, dword [esp + 0x54]
xor eax, eax
push esi
mov dword [ebp + 8], eax
mov esi, dword [ebx + 8]
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], eax
mov eax, dword [0x4c6060]
push edi
push eax
mov dword [esp + 0x48], bind
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, dword [eax + 0x20]
lea edx, [esi + esi + 0x10]
and edx, 0xfffffff0
lea edi, [ecx + edx]
cmp edi, dword [eax + 0x2c]
ja 0x41ad5c
mov dword [eax + 0x20], edi
mov eax, ecx
jmp 0x41ad66
mov edi, dword [eax]
push edx
mov edx, dword [edi + 0x14]
mov ecx, eax
call edx
mov dword [esp + 0x3c], eax
mov dword [esp + 0x48], eax
lea eax, [esp + 0x3c]
push eax
push ebp
push ecx
mov eax, esp
or esi, 0x80000000
mov dword [esp + 0x50], esi
push ebx
mov byte [eax], 1
call fcn.0041aad0
mov edx, dword [0x4c6060]
mov ecx, dword [esp + 0x64]
mov esi, dword [ecx + 8]
add esp, 0x10
xor eax, eax
push edx
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], bind
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, dword [eax + 0x20]
lea edx, [esi + esi + 0x10]
and edx, 0xfffffff0
lea edi, [ecx + edx]
cmp edi, dword [eax + 0x2c]
ja 0x41adcc
mov dword [eax + 0x20], edi
mov eax, ecx
jmp 0x41add6
mov edi, dword [eax]
mov ecx, eax
mov eax, dword [edi + 0x14]
push edx
call eax
mov edx, dword [esp + 0x54]
lea ecx, [esp + 0x2c]
push ecx
push ebp
push ecx
mov dword [esp + 0x38], eax
mov dword [esp + 0x44], eax
mov eax, esp
or esi, 0x80000000
mov dword [esp + 0x40], esi
push edx
mov byte [eax], 0
call fcn.0041aad0
mov edi, dword [esp + 0x68]
mov eax, dword [edi + 4]
mov ecx, dword [ebp + 0xc]
lea esi, [ebp + 4]
lea eax, [eax + eax*2]
add eax, dword [ebp + 8]
and ecx, 0x3fffffff
add esp, 0x10
cmp ecx, eax
jge 0x41ae2a
push 8
push eax
push esi
call fcn.004026b0
add esp, 0xc
xor eax, eax
cmp dword [edi + 4], eax
mov dword [esp + 0x20], eax
jle 0x41aed3
mov dword [esp + 0x54], eax
jmp 0x41ae44
mov ebx, dword [esp + 0x50]
mov eax, dword [edi]
add eax, dword [esp + 0x54]
mov ecx, dword [eax]
movzx edx, word [ecx]
mov word [eax + 8], dx
movzx edx, word [ecx + 4]
mov ebx, dword [ebx + 4]
movzx edx, word [ebx + edx*8]
mov word [eax + 0xc], dx
mov edx, dword [eax + 4]
mov bx, word [edx]
mov word [eax + 0xe], bx
movzx edx, word [edx + 2]
mov ebx, dword [esp + 0x50]
sub ecx, dword [ebx + 4]
mov ebx, dword [esp + 0x3c]
add edx, edx
add edx, edx
sar ecx, 3
movzx ecx, word [ebx + ecx*2]
add edx, edx
sar edx, 3
cmp ecx, 0xffff
jne 0x41ae97
xor ecx, ecx
jmp 0x41ae9c
mov ebx, dword [esi]
lea ecx, [ebx + ecx*8]
mov dword [eax], ecx
mov ecx, dword [esp + 0x2c]
movzx ecx, word [ecx + edx*2]
cmp ecx, 0xffff
jne 0x41aeb2
xor ecx, ecx
jmp 0x41aeb7
mov edx, dword [esi]
lea ecx, [edx + ecx*8]
add dword [esp + 0x54], 0x10
mov dword [eax + 4], ecx
mov eax, dword [esp + 0x20]
add eax, 1
cmp eax, dword [edi + 4]
mov dword [esp + 0x20], eax
jl 0x41ae40
mov eax, dword [esi]
mov ecx, dword [ebp + 8]
mov edx, dword [edi]
mov dword [esp + 0x54], eax
mov eax, dword [edi + 4]
xor ebx, ebx
sub eax, 1
mov dword [esp + 0x14], 0xffff
mov dword [esp + 0x28], ecx
mov dword [esp + 0x24], eax
js 0x41b0ba
mov ecx, eax
shl ecx, 4
mov dword [esp + 0x20], ecx
jmp 0x41af1c
mov ecx, dword [esp + 0x20]
mov edi, dword [esp + 0x58]
mov ebp, dword [esp + 0x5c]
mov eax, dword [edi]
add eax, ecx
mov ecx, dword [ebp + 8]
mov dword [esp + 0x10], ecx
mov ecx, dword [esi + 4]
lea edi, [ecx + 1]
mov dword [esi + 4], edi
mov edi, dword [esi]
lea edi, [edi + ecx*8]
mov ecx, dword [ebp + 8]
mov dword [esp + 0x1c], ecx
mov ecx, dword [esi + 4]
lea ebp, [ecx + 1]
mov dword [esi + 4], ebp
mov ebp, dword [esi]
lea ebp, [ebp + ecx*8]
mov ecx, dword [eax]
cmp ecx, dword [edx]
jne 0x41aff2
mov ecx, dword [eax + 4]
cmp word [ecx + 6], 2
sete dl
test dl, dl
mov byte [esp + 0x50], dl
je 0x41af6e
movzx edx, word [ecx + 2]
jmp 0x41af75
mov edx, dword [esp + 0x5c]
mov edx, dword [edx + 8]
cmp byte [esp + 0x50], 0
mov dword [esp + 0x18], edx
je 0x41af8a
movzx ecx, word [ecx + 2]
mov edx, dword [esp + 0x54]
jmp 0x41af95
mov ecx, dword [esi + 4]
lea edx, [ecx + 1]
mov dword [esi + 4], edx
mov edx, dword [esi]
test ebx, ebx
lea ecx, [edx + ecx*8]
mov edx, dword [eax + 4]
movzx edx, word [edx]
mov word [edi], dx
movzx edx, word [esp + 0x1c]
mov word [edi + 4], dx
movzx edx, word [esp + 0x14]
mov word [edi + 2], dx
je 0x41afc0
mov dx, word [esp + 0x10]
mov word [ebx + 2], dx
movzx edx, word [eax + 0xe]
mov word [ecx], dx
movzx edx, word [esp + 0x10]
mov word [ecx + 4], dx
mov edx, dword [eax + 4]
sub edx, dword [esp + 0x54]
sar edx, 3
mov word [ecx + 2], dx
mov edx, dword [eax + 4]
mov ecx, dword [esp + 0x18]
mov word [edx + 2], cx
movzx edx, word [eax + 8]
jmp 0x41b08a
cmp word [ecx + 6], 2
sete dl
test dl, dl
mov byte [esp + 0x50], dl
je 0x41b008
movzx edx, word [ecx + 2]
jmp 0x41b00f
mov edx, dword [esp + 0x5c]
mov edx, dword [edx + 8]
cmp byte [esp + 0x50], 0
mov dword [esp + 0x18], edx
je 0x41b024
movzx ecx, word [ecx + 2]
mov edx, dword [esp + 0x54]
jmp 0x41b02f
mov ecx, dword [esi + 4]
lea edx, [ecx + 1]
mov dword [esi + 4], edx
mov edx, dword [esi]
test ebx, ebx
lea ecx, [edx + ecx*8]
movzx edx, word [eax + 0xe]
mov word [edi], dx
movzx edx, word [esp + 0x18]
mov word [edi + 4], dx
movzx edx, word [esp + 0x14]
mov word [edi + 2], dx
je 0x41b058
mov dx, word [esp + 0x10]
mov word [ebx + 2], dx
movzx edx, word [eax + 0xc]
mov word [ecx], dx
movzx edx, word [esp + 0x1c]
mov word [ecx + 4], dx
mov edx, dword [eax]
sub edx, dword [esp + 0x54]
sar edx, 3
mov word [ecx + 2], dx
movzx edx, word [esp + 0x18]
mov ecx, dword [eax]
mov word [ecx + 2], dx
mov ecx, dword [eax]
movzx edx, word [ecx]
mov cx, word [esp + 0x10]
sub dword [esp + 0x20], 0x10
mov word [ebp], dx
mov edx, dword [esp + 0x1c]
mov dword [esp + 0x14], edx
mov edx, eax
mov eax, dword [esp + 0x24]
sub eax, 1
test eax, eax
mov word [ebp + 4], cx
mov ebx, ebp
mov dword [esp + 0x24], eax
jge 0x41af10
mov ecx, dword [esp + 0x28]
mov ax, word [esp + 0x14]
mov edx, dword [esp + 0x54]
mov edi, dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov word [ebx + 2], cx
mov word [edx + ecx*8 + 2], ax
mov eax, dword [0x4c6060]
mov esi, dword [esp + 0x38]
push eax
call edi
cmp esi, dword [eax + 0x28]
mov dword [eax + 0x20], esi
jne 0x41b0f0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0x18]
push esi
call eax
mov eax, dword [esp + 0x34]
test eax, eax
js 0x41b11a
mov ecx, dword [0x4c6060]
and eax, 0x3fffffff
push ecx
mov esi, eax
call edi
mov ecx, dword [esp + 0x2c]
push 0x17
lea edx, [esi + esi]
push edx
push ecx
mov ecx, eax
call fcn.004023e0
mov edx, dword [0x4c6060]
mov esi, dword [esp + 0x48]
push edx
call edi
cmp esi, dword [eax + 0x28]
mov dword [eax + 0x20], esi
jne 0x41b139
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0x18]
push esi
call eax
mov eax, dword [esp + 0x44]
test eax, eax
js 0x41b163
mov ecx, dword [0x4c6060]
and eax, 0x3fffffff
push ecx
mov esi, eax
call edi
mov ecx, dword [esp + 0x3c]
push 0x17
lea edx, [esi + esi]
push edx
push ecx
mov ecx, eax
call fcn.004023e0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x3c
ret