Function at 0x660d68c2
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.6601327c
xor edi, edi
push edi
push eax
call fcn.660132f2
mov esi, eax
pop ecx
cmp esi, edi
pop ecx
je 0x660d6900
call fcn.660137c9
mov eax, esi
pop edi
pop esi
leave
ret 4
push ebx
push dword [0x6610ee98]
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 0x660d69d5
and eax, 0xffff
mov dword [ebp - 8], eax
cmp dword [esi + 8], edi
jne 0x660d6c59
cmp dword [ebp - 8], 0x2ea
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x18], edi
ja 0x660d6959
cmp dword [ebp - 8], 0x1b8
jne 0x660d6bb5
lea eax, [ebx + 0x78]
cmp esi, eax
jne 0x660d6bb5
mov eax, dword [ebx]
cmp eax, edi
je 0x660d6bb5
mov ecx, dword [eax]
lea edx, [ebp - 0x20]
push edx
push 0x6602f1d0
push eax
call dword [ecx]
test eax, eax
jl 0x660d6bb5
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 0x660d6bac
cmp dword [ebx + 4], edi
jne 0x660d69e1
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 0x660d6afe
mov dword [ebp - 8], 0x1b8
jmp 0x660d6934
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 0x660d6a1f
mov eax, dword [ebp - 0x1c]
cmp word [eax + 0x1c], bx
jne 0x660d6b4a
mov ecx, dword [ebp - 4]
mov esi, dword [eax]
push eax
push ecx
mov edx, dword [ecx]
call dword [edx + 0x50]
jmp 0x660d69ad
mov eax, dword [ebp - 4]
lea edx, [ebp - 0x34]
push edx
push 0x660547d8
mov ecx, dword [eax]
push eax
call dword [ecx]
test eax, eax
jl 0x660d6b4a
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.660e5614
mov esi, dword [eax + 0x18]
mov ecx, dword [esi + 0x18]
mov dx, word [ecx + 0x1c]
cmp dx, di
je 0x660d6ba0
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 0x660d6a9d
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 0x660d6b3e
mov ebx, dword [ebp - 0x30]
mov edi, edx
dec edx
test edi, edi
mov dword [ebp - 0xc], edx
je 0x660d6ad4
lea eax, [eax + edx*4]
mov edx, dword [eax]
test edx, edx
je 0x660d6ac7
mov dx, word [edx + 2]
movsx edi, word [ebp - 0x14]
shr dx, 2
shl edx, 2
movzx edx, dx
cmp edx, edi
je 0x660d6b3e
nop
mov edx, dword [ebp - 0xc]
dec dword [ebp - 0xc]
sub eax, 4
test edx, edx
jne 0x660d6aaa
test ebx, ebx
je 0x660d6b9e
lea edx, [ebp - 0x10]
mov ecx, ebx
call fcn.66025091
test eax, eax
jl 0x660d6b9e
mov eax, dword [esi + 0x18]
lea edx, [ebp - 0x18]
mov ecx, dword [eax + 0x18]
call fcn.66025091
xor edi, edi
cmp dword [ebp - 0x10], edi
je 0x660d6b2c
cmp dword [ebp - 0x18], edi
je 0x660d6b2c
push dword [ebp - 0x18]
mov esi, 0xdf07
push dword [ebp - 0x10]
push esi
call fcn.660d54da
mov eax, dword [ebp + 8]
lea ebx, [eax + 8]
push ebx
push esi
call fcn.660d53d8
test eax, eax
jge 0x660d6b2c
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 0x660d6ba0
movzx eax, word [ebp - 0xc]
mov ecx, dword [ecx + 0x20]
mov ebx, dword [ecx + eax*4]
jmp 0x660d6ad4
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 0x660d6ba0
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 0x660d6b9e
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 0x660d6b9e
mov eax, dword [ebp - 0x1c]
cmp word [eax + 0x1c], bx
je 0x660d6d33
mov ecx, dword [ebp - 4]
push eax
push ecx
mov edx, dword [ecx]
call dword [edx + 0x50]
inc edi
cmp edi, esi
jb 0x660d6b70
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 0x660d6c59
cmp dword [ebp - 8], 0x2ea
mov ebx, 0x6601a430
ja 0x660d6c41
push esi
push ebx
push dword [ebp - 8]
call fcn.660de565
push 0x800
call fcn.6600fd50
cmp eax, edi
mov dword [ebp - 0x14], eax
je 0x660d6ccd
push edi
push 0x400
push eax
movzx eax, word [0x6610e698]
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 0x660d6ccd
push eax
push dword [ebp - 0x14]
push esi
call fcn.660d681c
push dword [ebp - 0x14]
call fcn.660175eb
cmp dword [ebp - 8], 0x2ea
ja 0x660d6c41
mov eax, dword [esi]
cmp eax, edi
jne 0x660d6d29
xor eax, eax
cmp eax, edi
jne 0x660d6c59
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.660de565
mov dword [ebp - 8], esi
mov esi, dword [ebp - 0x2c]
mov eax, dword [esi]
cmp eax, edi
je 0x660d6c6a
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 0x660d6ca0
push dword [0x6610ee98]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
cmp dword [eax + 0x24], edi
jne 0x660d6ca0
cmp dword [esi], edi
jne 0x660d6ca0
push eax
call fcn.66014435
cmp eax, edi
je 0x660d6ca0
mov ecx, dword [eax + 0x40]
mov edx, esi
mov dword [esi], edi
call fcn.66025091
cmp dword [ebx + 0xc], edi
jne 0x660d6cad
call fcn.6602ee14
mov dword [ebx + 0xc], eax
cmp dword [ebx + 0x10], edi
jne 0x660d6cbd
mov eax, dword [ebp - 8]
add eax, 0xf4240
mov dword [ebx + 0x10], eax
mov dword [ebx + 0x18], edi
call fcn.660137c9
xor eax, eax
pop ebx
jmp 0x660d68fa
cmp dword [ebp - 8], 0x1b8
jne 0x660d6c20
mov eax, dword [ebp + 8]
push dword [eax + 0x1c]
call fcn.6600fcf2
cmp eax, 0x1b8
je 0x660d6c20
lea ecx, [ebp - 0x24]
push ecx
push ebx
push eax
call fcn.660de565
test eax, eax
jl 0x660d6c20
mov ecx, dword [ebp - 0x24]
cmp ecx, edi
jne 0x660d6d22
xor eax, eax
push eax
push ecx
push esi
call fcn.660d681c
push dword [ebp - 0x24]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
jmp 0x660d6c20
mov eax, dword [ecx - 4]
shr eax, 1
jmp 0x660d6d0c
mov eax, dword [eax - 4]
shr eax, 1
jmp 0x660d6c3d
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 0x660d69ad