Function at 0x660d7d13
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x294
push esi
lea eax, [ebp - 0x294]
push edi
push eax
lea eax, [ebp - 0x94]
push eax
push 0x20
call fcn.66013369
xor edi, edi
push edi
push eax
call fcn.660133df
mov esi, eax
pop ecx
cmp esi, edi
pop ecx
je 0x660d7d51
call fcn.660138ac
mov eax, esi
pop edi
pop esi
leave
ret 4
push ebx
push dword [0x6610feb0]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, dword [ebp + 8]
mov ebx, eax
mov dword [ebp - 0x2c], ebx
mov eax, dword [esi + 0x1c]
mov ecx, eax
and ecx, 0x1fff0000
cmp ecx, 0xa0000
jne 0x660d7e26
and eax, 0xffff
mov dword [ebp - 8], eax
cmp dword [esi + 8], edi
jne 0x660d80aa
cmp dword [ebp - 8], 0x2ea
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x18], edi
ja 0x660d7daa
cmp dword [ebp - 8], 0x1b8
jne 0x660d8006
lea eax, [ebx + 0x78]
cmp esi, eax
jne 0x660d8006
mov eax, dword [ebx]
cmp eax, edi
je 0x660d8006
mov ecx, dword [eax]
lea edx, [ebp - 0x20]
push edx
push 0x6602f1f8
push eax
call dword [ecx]
test eax, eax
jl 0x660d8006
mov eax, dword [ebp - 0x20]
lea edx, [ebp - 4]
push edx
mov dword [ebp - 4], edi
mov ecx, dword [eax]
push 0x409
push edi
push eax
call dword [ecx + 0x10]
mov ecx, dword [ebp - 4]
cmp ecx, edi
je 0x660d7ffd
cmp dword [ebx + 4], edi
jne 0x660d7e32
mov esi, dword [ebx + 8]
mov eax, dword [ebp - 4]
push edi
push edi
lea edx, [ebp - 0x10]
mov ecx, dword [eax]
push edi
push edx
push esi
push eax
call dword [ecx + 0x30]
mov eax, dword [ebp - 4]
push edi
push edi
lea edx, [ebp - 0x18]
mov ecx, dword [eax]
push edi
push edx
push 0xffffffffffffffff
push eax
call dword [ecx + 0x30]
jmp 0x660d7f4f
mov dword [ebp - 8], 0x1b8
jmp 0x660d7d85
mov bx, word [ebx + 8]
mov edx, dword [ecx]
mov ax, bx
lea esi, [ebp - 0x1c]
sar ax, 2
movsx eax, ax
push esi
push eax
push ecx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0xc], eax
call dword [edx + 0x14]
test eax, eax
jne 0x660d7e70
mov eax, dword [ebp - 0x1c]
cmp word [eax + 0x1c], bx
jne 0x660d7f9b
mov ecx, dword [ebp - 4]
mov esi, dword [eax]
push eax
push ecx
mov edx, dword [ecx]
call dword [edx + 0x50]
jmp 0x660d7dfe
mov eax, dword [ebp - 4]
lea edx, [ebp - 0x34]
push edx
push 0x660545f0
mov ecx, dword [eax]
push eax
call dword [ecx]
test eax, eax
jl 0x660d7f9b
mov eax, dword [ebp - 4]
xor ebx, ebx
push eax
mov dword [ebp - 0x30], ebx
mov ecx, dword [eax]
call dword [ecx + 8]
mov ecx, dword [ebp - 0x34]
mov dword [ebp - 4], ecx
call fcn.660e6ad4
mov esi, dword [eax + 0x18]
mov ecx, dword [esi + 0x18]
mov dx, word [ecx + 0x1c]
cmp dx, di
je 0x660d7ff1
mov edi, dword [esi + 0xc]
mov eax, edi
inc eax
neg eax
sbb eax, eax
movzx edx, dx
and eax, edi
mov edi, dword [ebp - 0xc]
cmp edi, edx
mov eax, dword [eax + 0x18]
jae 0x660d7eee
mov edi, dword [eax + edi*4]
movsx ebx, word [ebp - 0x14]
mov di, word [edi + 2]
shr di, 2
shl edi, 2
movzx edi, di
cmp edi, ebx
je 0x660d7f8f
mov ebx, dword [ebp - 0x30]
mov edi, edx
dec edx
test edi, edi
mov dword [ebp - 0xc], edx
je 0x660d7f25
lea eax, [eax + edx*4]
mov edx, dword [eax]
test edx, edx
je 0x660d7f18
mov dx, word [edx + 2]
movsx edi, word [ebp - 0x14]
shr dx, 2
shl edx, 2
movzx edx, dx
cmp edx, edi
je 0x660d7f8f
nop
mov edx, dword [ebp - 0xc]
dec dword [ebp - 0xc]
sub eax, 4
test edx, edx
jne 0x660d7efb
test ebx, ebx
je 0x660d7fef
lea edx, [ebp - 0x10]
mov ecx, ebx
call fcn.66025647
test eax, eax
jl 0x660d7fef
mov eax, dword [esi + 0x18]
lea edx, [ebp - 0x18]
mov ecx, dword [eax + 0x18]
call fcn.66025647
xor edi, edi
cmp dword [ebp - 0x10], edi
je 0x660d7f7d
cmp dword [ebp - 0x18], edi
je 0x660d7f7d
push dword [ebp - 0x18]
mov esi, 0xdf07
push dword [ebp - 0x10]
push esi
call fcn.660d6916
mov eax, dword [ebp + 8]
lea ebx, [eax + 8]
push ebx
push esi
call fcn.660d6814
test eax, eax
jge 0x660d7f7d
mov dword [ebx], edi
push dword [ebp - 0x10]
mov esi, dword [sym.imp.OLEAUT32.dll_SysStringLen]
call esi
push dword [ebp - 0x18]
call esi
jmp 0x660d7ff1
movzx eax, word [ebp - 0xc]
mov ecx, dword [ecx + 0x20]
mov ebx, dword [ecx + eax*4]
jmp 0x660d7f25
mov eax, dword [ebp - 4]
lea edx, [ebp - 0x28]
push edx
push eax
mov ecx, dword [eax]
call dword [ecx + 0xc]
test eax, eax
jne 0x660d7ff1
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x28]
push eax
push ecx
mov edx, dword [ecx]
movzx esi, word [eax + 0x2c]
call dword [edx + 0x4c]
test esi, esi
jbe 0x660d7fef
mov eax, dword [ebp - 4]
lea edx, [ebp - 0x1c]
push edx
push edi
mov ecx, dword [eax]
push eax
call dword [ecx + 0x14]
test eax, eax
jne 0x660d7fef
mov eax, dword [ebp - 0x1c]
cmp word [eax + 0x1c], bx
je 0x660d8184
mov ecx, dword [ebp - 4]
push eax
push ecx
mov edx, dword [ecx]
call dword [edx + 0x50]
inc edi
cmp edi, esi
jb 0x660d7fc1
xor edi, edi
mov eax, dword [ebp - 4]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
mov esi, dword [ebp + 8]
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
add esi, 8
cmp dword [esi], edi
jne 0x660d80aa
cmp dword [ebp - 8], 0x2ea
mov ebx, 0x6601a650
ja 0x660d8092
push esi
push ebx
push dword [ebp - 8]
call fcn.660dfa18
push 0x800
call fcn.6600fdd3
cmp eax, edi
mov dword [ebp - 0x14], eax
je 0x660d811e
push edi
push 0x400
push eax
movzx eax, word [0x6610f698]
push eax
mov eax, dword [ebp + 8]
push dword [eax + 0x1c]
push edi
push 0x12ff
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
cmp eax, edi
je 0x660d811e
push eax
push dword [ebp - 0x14]
push esi
call fcn.660d7c6d
push dword [ebp - 0x14]
call fcn.660177d3
cmp dword [ebp - 8], 0x2ea
ja 0x660d8092
mov eax, dword [esi]
cmp eax, edi
jne 0x660d817a
xor eax, eax
cmp eax, edi
jne 0x660d80aa
push dword [esi]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
push esi
push ebx
push 0x5f
mov dword [esi], edi
pop esi
push esi
call fcn.660dfa18
mov dword [ebp - 8], esi
mov esi, dword [ebp - 0x2c]
mov eax, dword [esi]
cmp eax, edi
je 0x660d80bb
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov dword [esi], edi
mov ebx, dword [ebp + 8]
cmp dword [ebx + 4], edi
lea esi, [ebx + 4]
jne 0x660d80f1
push dword [0x6610feb0]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
cmp dword [eax + 0x24], edi
jne 0x660d80f1
cmp dword [esi], edi
jne 0x660d80f1
push eax
call fcn.66014520
cmp eax, edi
je 0x660d80f1
mov ecx, dword [eax + 0x40]
mov edx, esi
mov dword [esi], edi
call fcn.66025647
cmp dword [ebx + 0xc], edi
jne 0x660d80fe
call fcn.6602ee08
mov dword [ebx + 0xc], eax
cmp dword [ebx + 0x10], edi
jne 0x660d810e
mov eax, dword [ebp - 8]
add eax, 0xf4240
mov dword [ebx + 0x10], eax
mov dword [ebx + 0x18], edi
call fcn.660138ac
xor eax, eax
pop ebx
jmp 0x660d7d4b
cmp dword [ebp - 8], 0x1b8
jne 0x660d8071
mov eax, dword [ebp + 8]
push dword [eax + 0x1c]
call fcn.6600fd75
cmp eax, 0x1b8
je 0x660d8071
lea ecx, [ebp - 0x24]
push ecx
push ebx
push eax
call fcn.660dfa18
test eax, eax
jl 0x660d8071
mov ecx, dword [ebp - 0x24]
cmp ecx, edi
jne 0x660d8173
xor eax, eax
push eax
push ecx
push esi
call fcn.660d7c6d
push dword [ebp - 0x24]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
jmp 0x660d8071
mov eax, dword [ecx - 4]
shr eax, 1
jmp 0x660d815d
mov eax, dword [eax - 4]
shr eax, 1
jmp 0x660d808e
mov ecx, dword [ebp - 4]
mov esi, dword [eax]
push eax
push ecx
mov edx, dword [ecx]
call dword [edx + 0x50]
xor edi, edi
jmp 0x660d7dfe