Function at 0x101fc9de
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
mov eax, dword [0x1065e7ec]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, ecx
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x38], ebx
test byte [ebx + 0x38], 2
mov dword [ebp - 0x54], esi
je 0x101fcc55
push edi
push 8
lea eax, [ebp - 0x24]
push eax
call fcn.101fbbb3
mov eax, dword [esi + 0xc]
add dword [ebp - 0x24], eax
add dword [ebp - 0x1c], eax
mov eax, dword [esi + 0x10]
add dword [ebp - 0x20], eax
add dword [ebp - 0x18], eax
lea eax, [ebp - 0x24]
push dword [esi]
push eax
lea eax, [ebp - 0x14]
push eax
call dword [sym.imp.USER32.dll_IntersectRect]
mov edi, dword [sym.imp.USER32.dll_IsRectEmpty]
lea eax, [ebp - 0x14]
push eax
call edi
test eax, eax
jne 0x101fcc54
lea eax, [ebp - 0x24]
push eax
call edi
test eax, eax
jne 0x101fcc54
mov ecx, dword [esi + 8]
test ecx, ecx
je 0x101fca69
test dword [ebx + 0x38], 0x80000000
je 0x101fcc54
mov eax, dword [esi]
xor edi, edi
test byte [ebx + 0x38], 8
mov dword [ebp - 0x4c], eax
mov eax, dword [esi + 4]
mov dword [ebp - 0x48], eax
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x44], ecx
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x30], edi
mov byte [ebp - 0x25], 0xff
je 0x101fcb26
mov ecx, ebx
call fcn.101fc698
mov al, byte [eax + 0xc]
mov byte [ebp - 0x25], al
test al, al
je 0x101fcc54
cmp al, 0xff
je 0x101fcb26
push dword [0x1065a1cc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
lea ecx, [ebp - 0x14]
push ecx
lea ecx, [eax + 0x68]
call fcn.1024d572
mov edi, eax
mov dword [ebp - 0x30], edi
test edi, edi
je 0x101fcc54
push dword [ebp - 0x10]
mov ecx, edi
push dword [ebp - 0x14]
call fcn.1019723f
lea eax, [ebp - 0x14]
mov ecx, edi
push eax
call fcn.101971fe
mov eax, dword [esi + 4]
mov dword [ebp - 0x48], edi
push 0xcc0020
mov ecx, dword [eax + 0x10]
mov byte [eax + 0x28], 1
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 0xc]
sub edx, dword [ebp - 0x10]
sub eax, dword [ebp - 0x14]
mov byte [edi + 0x28], 1
push dword [ebp - 0x10]
push dword [ebp - 0x14]
push ecx
push edx
push eax
push dword [ebp - 0x10]
push dword [ebp - 0x14]
push dword [edi + 0x10]
call dword [sym.imp.GDI32.dll_BitBlt]
and dword [ebp - 0x34], 0
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x24]
mov ecx, ebx
push eax
lea eax, [ebp - 0x4c]
push eax
call fcn.101fc580
cmp eax, 2
je 0x101fcb4b
cmp eax, 3
jne 0x101fcc54
mov esi, dword [ebp - 0x44]
test esi, esi
je 0x101fcb5b
test dword [ebx + 0x38], 0x100
je 0x101fcb6d
lea eax, [ebp - 0x24]
mov ecx, ebx
push eax
lea eax, [ebp - 0x4c]
push eax
call fcn.101fc951
mov esi, dword [ebp - 0x44]
test dword [ebx + 0x38], 0x200000
lea eax, [esi + 1]
mov dword [ebp - 0x2c], eax
je 0x101fcb8d
test dword [ebx + 0x38], 0x80000000
je 0x101fcb8d
push 2
pop eax
xor esi, esi
mov dword [ebp - 0x2c], eax
cmp esi, eax
jge 0x101fcbcd
lea eax, [ebx + 0x20]
mov ebx, dword [ebp - 0x2c]
mov dword [ebp - 0x50], eax
mov ecx, eax
mov dword [ebp - 0x44], esi
call fcn.101fa851
jmp 0x101fcbb9
lea eax, [ebp - 0x4c]
mov ecx, edi
push eax
call fcn.101fc9de
lea ecx, [edi + 0x20]
call fcn.101fa8c8
mov edi, eax
test edi, edi
jne 0x101fcba6
mov eax, dword [ebp - 0x50]
inc esi
cmp esi, ebx
jl 0x101fcb9a
mov ebx, dword [ebp - 0x38]
mov edi, dword [ebp - 0x30]
push dword [ebp - 0x34]
lea eax, [ebp - 0x4c]
mov ecx, ebx
push eax
call fcn.101fc527
test edi, edi
je 0x101fcc4d
mov ebx, dword [ebp - 8]
xor ecx, ecx
mov edx, dword [ebp - 0xc]
mov al, byte [ebp - 0x25]
sub ebx, dword [ebp - 0x10]
sub edx, dword [ebp - 0x14]
mov esi, dword [edi + 0x10]
mov byte [edi + 0x28], 1
mov edi, dword [ebp - 8]
sub edi, dword [ebp - 0x10]
mov word [ebp - 0x2c], cx
mov byte [ebp - 0x29], cl
mov ecx, dword [ebp - 0x54]
mov byte [ebp - 0x2a], al
push dword [ebp - 0x2c]
mov eax, dword [ebp - 0xc]
mov ecx, dword [ecx + 4]
sub eax, dword [ebp - 0x14]
push ebx
push edx
mov byte [ecx + 0x28], 1
push dword [ebp - 0x10]
push dword [ebp - 0x14]
push esi
push edi
push eax
push dword [ebp - 0x10]
push dword [ebp - 0x14]
push dword [ecx + 0x10]
call fcn.10257b58
push dword [0x1065a1cc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push dword [ebp - 0x30]
lea ecx, [eax + 0x68]
call fcn.1024d5a1
mov ebx, dword [ebp - 0x38]
and dword [ebx + 0x38], 0xdfffffff
pop edi
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.102790a9
mov esp, ebp
pop ebp
ret 4