Function at 0x660e94f2
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
and dword [ebp - 8], 0
push ebx
push esi
push edi
push dword [0x6610feb0]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, dword [ebp + 0xc]
add eax, 0x50
cmp dword [ebp + 0x10], 0
mov dword [ebp - 0xc], eax
mov ax, word [esi]
mov dword [ebp - 4], eax
je 0x660e95f3
push dword [ebp + 0x10]
mov edi, dword [ebp + 8]
lea eax, [ebp - 0x10]
push 2
push eax
push edi
call fcn.660e9f15
mov ebx, eax
test ebx, ebx
jne 0x660e97f2
cmp word [ebp - 0x10], 9
je 0x660e96d8
test byte [ebp - 3], 0x40
je 0x660e95e7
mov dword [ebp - 8], esi
mov esi, dword [ebp - 0xc]
and dword [esi + 8], 0
mov eax, dword [ebp - 0x10]
mov dword [ebp - 4], eax
mov edx, dword [ebp - 4]
movzx eax, dx
cmp eax, 0x24
jg 0x660e95ad
je 0x660e96d8
cmp eax, 9
jg 0x660e98b8
je 0x660e96d8
cmp eax, 4
jg 0x660e9884
cmp eax, 3
jge 0x660e98f5
test eax, eax
jl 0x660e95ad
cmp eax, 1
jle 0x660e972a
cmp eax, 2
je 0x660e98ee
test dh, 0x20
je 0x660e987a
and edx, 0xdfff
cmp dx, 9
mov dword [ebp - 0x10], edx
je 0x660e96d8
cmp dx, 0xc
jbe 0x660e9634
cmp dx, 0x11
je 0x660e9634
cmp dx, 0xe
je 0x660e9634
mov eax, 0x1ca
pop edi
pop esi
pop ebx
leave
ret 0xc
mov ecx, esi
call sym.MSVBVM60.DLL___vbaFreeVar
jmp 0x660e955b
test ah, 0x40
je 0x660e960c
lea eax, [ebp - 0x20]
push esi
push eax
call fcn.661001de
and dword [ebp - 4], 0xbfff
lea esi, [ebp - 0x20]
mov edi, dword [ebp + 8]
push 0
lea eax, [ebp - 4]
push 2
push eax
push edi
call fcn.660e9f15
mov ebx, eax
test ebx, ebx
je 0x660e9565
mov ecx, dword [ebp - 0xc]
call sym.MSVBVM60.DLL___vbaFreeVar
jmp 0x660e97f2
xor ecx, ecx
cmp dword [ebp + 0x10], ecx
je 0x660e97a3
cmp dword [ebp - 8], ecx
mov dword [ebp + 0xc], ecx
je 0x660e96e0
mov ecx, dword [ebp - 8]
mov di, word [ecx]
test di, 0x2000
je 0x660e96e0
mov ecx, dword [ecx + 8]
mov ebx, dword [ecx]
test ebx, ebx
je 0x660e96e0
mov cx, word [ebx + 2]
test cl, 0x16
je 0x660e96e0
movzx esi, di
and esi, 0xffffbfff
cmp esi, eax
jne 0x660e96d8
movzx eax, dx
push ecx
push dword [eax*4 + 0x660558b0]
lea eax, [ebp + 0xc]
push eax
push dword [ebp + 8]
call fcn.660e98fc
test eax, eax
jne 0x660e95e0
mov eax, dword [ebp + 0xc]
mov cx, word [eax]
cmp cx, word [ebx]
jne 0x660e96d1
movzx ecx, cx
shl ecx, 3
lea edi, [ebx + 0x10]
lea esi, [eax + 0x10]
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
jne 0x660e96d1
push eax
call dword [sym.imp.OLEAUT32.dll_SafeArrayDestroyData]
push dword [ebp + 0x10]
push 0
push ebx
push dword [ebp + 8]
call fcn.660e9a09
jmp 0x660e95e0
push eax
call dword [sym.imp.OLEAUT32.dll_SafeArrayDestroyData]
push 0xd
pop eax
jmp 0x660e95e0
cmp dx, 8
jne 0x660e978d
mov dword [ebp + 0xc], 0x100
push dword [ebp + 0xc]
lea edi, [esi + 8]
movzx eax, dx
push dword [eax*4 + 0x660558b0]
push edi
push dword [ebp + 8]
call fcn.660e98fc
test eax, eax
jne 0x660e95e0
mov ax, word [ebp - 4]
mov word [esi], ax
push dword [ebp + 0x10]
push 0
push dword [edi]
push dword [ebp + 8]
call fcn.660e9a09
mov ebx, eax
test ebx, ebx
jne 0x660e9627
cmp dword [ebp + 0x10], ebx
je 0x660e973e
mov ax, word [ebp - 4]
mov word [esi], ax
cmp dword [ebp - 8], 0
je 0x660e9627
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
lea ecx, [ebp - 0x40]
mov ax, word [esi]
push ecx
and eax, 0xbfff
push eax
push edi
mov dword [ebp - 4], eax
call fcn.660e5923
test eax, eax
jge 0x660e97c0
cmp eax, 0x80020009
je 0x660e9783
push eax
call fcn.66024c30
mov ebx, eax
cmp ebx, 0x1b8
jne 0x660e9627
mov ebx, 0x1bb
jmp 0x660e9627
cmp dx, 0xc
jne 0x660e96f1
mov dword [ebp + 0xc], 0x800
jmp 0x660e96f1
push dword [esi + 8]
lea edi, [esi + 8]
push dword [ebp + 8]
call fcn.660e99be
mov ebx, eax
test ebx, ebx
je 0x660e9719
jmp 0x660e9627
movzx eax, word [ebp - 4]
cmp eax, 8
jg 0x660e9813
je 0x660e97f9
cmp eax, 2
je 0x660e986b
jle 0x660e9822
cmp eax, 4
jle 0x660e9809
cmp eax, 7
jg 0x660e9822
mov eax, dword [esi + 8]
mov ecx, dword [edi + 8]
mov dword [eax], ecx
mov ecx, dword [edi + 0xc]
mov dword [eax + 4], ecx
and word [edi], 0
mov eax, ebx
jmp 0x660e95e0
mov eax, dword [esi + 8]
mov eax, dword [eax]
test eax, eax
je 0x660e9809
push eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [esi + 8]
mov ecx, dword [edi + 8]
mov dword [eax], ecx
jmp 0x660e97ee
cmp eax, 0xb
je 0x660e986b
cmp eax, 0xe
je 0x660e9859
cmp eax, 0x11
je 0x660e984f
test byte [ebp - 3], 0x20
je 0x660e9847
push 0
push dword [esi + 8]
call fcn.660e0f70
mov ebx, eax
test ebx, ebx
jne 0x660e9627
mov eax, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
mov eax, dword [eax + 8]
jmp 0x660e980c
push 0xd
pop ebx
jmp 0x660e9627
mov eax, dword [esi + 8]
mov cl, byte [edi + 8]
mov byte [eax], cl
jmp 0x660e97ee
mov eax, dword [ebp - 8]
mov esi, dword [ebp - 0xc]
mov edi, dword [eax + 8]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov edi, dword [ebp - 0xc]
jmp 0x660e97ee
mov eax, dword [esi + 8]
mov cx, word [edi + 8]
mov word [eax], cx
jmp 0x660e97ee
mov ebx, 0x1ca
jmp 0x660e9627
cmp eax, 5
jl 0x660e95ad
cmp eax, 7
jle 0x660e98ad
cmp eax, 8
jne 0x660e95ad
push dword [ebp + 0x10]
lea eax, [esi + 8]
push eax
push edi
call fcn.660e93f8
jmp 0x660e9728
push dword [ebp + 0x10]
push 8
lea eax, [esi + 8]
push eax
jmp 0x660e98e3
mov ecx, eax
sub ecx, 0xa
je 0x660e98f5
dec ecx
je 0x660e98ee
dec ecx
dec ecx
je 0x660e96d8
dec ecx
je 0x660e98dd
sub ecx, 3
jne 0x660e95ad
push dword [ebp + 0x10]
push 1
jmp 0x660e98b2
push dword [ebp + 0x10]
push 0x10
push esi
push edi
call fcn.660e9f15
jmp 0x660e9728
push dword [ebp + 0x10]
push 2
jmp 0x660e98b2
push dword [ebp + 0x10]
push 4
jmp 0x660e98b2