Function at 0x1000c700
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x88
mov dword [ebp - 0x1c], esp
mov dword [ebp - 0x10], 0xffffffff
mov dword [ebp - 0x14], 0x100139a0
mov ebx, ecx
lea eax, [ebp - 0x18]
mov esi, 1
mov edi, edx
mov ecx, dword fs:[0]
mov dword [ebp - 0x18], ecx
mov dword fs:[0], eax
lock xadd dword [0x1005e120], esi
call fcn.1000d000
test eax, eax
jne 0x1000c76c
lea eax, [ebp - 0x40]
mov ecx, 0x1004f8f7
mov edx, 0x46
push 0x1004f9bc
push 0x1004f870
push eax
call fcn.100295a0
add esp, 0xc
ud2
mov ecx, dword [eax]
mov edx, dword [ebp + 0xc]
inc ecx
test esi, esi
mov dword [eax], ecx
js 0x1000c7ea
cmp ecx, 3
jae 0x1000c7ea
mov dword [ebp - 0x80], ecx
push 0x1005e11c
call dword [sym.imp.KERNEL32.dll_AcquireSRWLockShared]
mov dword [ebp - 0x8c], 0x1005e11c
mov dword [ebp - 0x10], 2
mov dword [ebp - 0x84], ebx
push ebx
mov dword [ebp - 0x88], edi
call dword [edi + 0x10]
add esp, 4
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x24], edx
call fcn.1000d000
mov edi, dword [ebp - 0x24]
test eax, eax
jne 0x1000c8f3
lea eax, [ebp - 0x40]
mov ecx, 0x1004f8f7
mov edx, 0x46
push 0x1004f9bc
push 0x1004f870
push eax
call fcn.100295a0
add esp, 0xc
jmp 0x1000cbfe
cmp ecx, 2
jbe 0x1000c847
lea ecx, [ebp - 0x78]
lea edx, [ebp - 0x40]
mov dword [ebp - 0x40], 0x10050224
mov dword [ebp - 0x3c], 1
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x30], 0x1004f570
mov byte [ebp - 0x74], 0
mov dword [ebp - 0x78], 0
mov dword [ebp - 0x2c], 0
call fcn.1000d0f0
cmp al, 3
jne 0x1000c8ef
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov dword [ebp - 0x10], 1
push eax
mov dword [ebp - 0x20], edx
call dword [ecx]
add esp, 4
jmp 0x1000c8bc
mov eax, dword [ebp + 8]
mov dword [ebp - 0x78], 0x1004f570
mov dword [ebp - 0x74], 0x1004f824
lea ecx, [ebp - 0x60]
mov dword [ebp - 0x40], 0x10050260
mov dword [ebp - 0x3c], 2
mov byte [ebp - 0x5c], 0
mov dword [ebp - 0x60], 0
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x70], eax
lea eax, [ebp - 0x78]
mov dword [ebp - 0x6c], edx
lea edx, [ebp - 0x40]
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x4c]
mov dword [ebp - 0x48], 0x10002470
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], 1
call fcn.1000d0f0
cmp al, 3
jne 0x1000c8ef
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov dword [ebp - 0x10], 0
push eax
mov dword [ebp - 0x20], edx
call dword [ecx]
add esp, 4
mov esi, dword [ebp - 0x20]
mov ecx, dword [esi + 4]
cmp dword [ecx + 4], 0
je 0x1000c8e1
mov eax, dword [esi]
cmp dword [ecx + 8], 9
jb 0x1000c8d3
mov eax, dword [eax - 4]
push eax
push 0
push dword [0x1005e128]
call sub.KERNEL32.dll_HeapFree
push esi
push 0
push dword [0x1005e128]
call sub.KERNEL32.dll_HeapFree
ud2
cmp dword [eax], 1
mov cl, 1
jbe 0x1000c9cb
mov edx, dword [ebp + 0xc]
mov dword [ebp - 0x90], edx
mov dword [ebp - 0x7c], ecx
mov eax, dword [edi + 0xc]
push dword [ebp - 0x20]
mov dword [ebp - 0x24], eax
call eax
add esp, 4
xor eax, 0xecc7bcf4
xor edx, 0x7ef2a91e
or edx, eax
jne 0x1000ca0a
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax]
mov eax, dword [eax + 4]
mov dword [ebp - 0x60], ecx
mov dword [ebp - 0x5c], eax
mov eax, dword [0x1005d044]
test eax, eax
jne 0x1000c94c
mov ecx, 0x1005d044
call fcn.10012960
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
cmp eax, 1
jbe 0x1000ca33
cmp dword [eax], 1
mov edi, eax
jne 0x1000ca33
add edi, 4
cmp dword [edi], 0
jne 0x1000cbde
mov dword [edi], 0xffffffff
mov esi, dword [edi + 4]
test esi, esi
jne 0x1000c9ab
mov dword [ebp - 0x20], edi
mov dword [ebp - 0x10], 8
call fcn.1000c4d0
mov edi, dword [ebp - 0x20]
mov esi, eax
mov eax, dword [edi + 4]
test eax, eax
je 0x1000c9a8
lock dec dword [eax]
jne 0x1000c9a8
mov ecx, dword [edi + 4]
call fcn.1000c640
mov dword [edi + 4], esi
lock inc dword [esi]
jle 0x1000c8ef
inc dword [edi]
test esi, esi
mov dword [ebp - 0x50], esi
mov dword [ebp - 0x20], esi
jne 0x1000cce0
xor eax, eax
jmp 0x1000ca70
mov eax, dword [0x1005e110]
mov edx, dword [ebp + 0xc]
cmp eax, 2
je 0x1000cbd7
cmp eax, 1
je 0x1000cbd0
test eax, eax
jne 0x1000c901
lea ecx, [ebp - 0x40]
call fcn.1000d380
mov edi, dword [ebp - 0x24]
mov eax, dword [ebp - 0x40]
test eax, eax
jne 0x1000cc45
mov bl, 5
jmp 0x1000cd22
push dword [ebp - 0x20]
call dword [ebp - 0x24]
add esp, 4
xor eax, 0xbae7a625
xor edx, 0xe43a67d8
or edx, eax
jne 0x1000cc00
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax]
mov eax, dword [eax + 8]
jmp 0x1000c933
mov eax, dword [0x1005d044]
test eax, eax
jne 0x1000ca46
mov ecx, 0x1005d044
call fcn.10012960
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x1000cc0f
mov esi, eax
cmp eax, 1
jne 0x1000cca2
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x20], 0
xor eax, eax
test eax, eax
mov edx, 0x100500e6
mov dword [ebp - 0x78], 0x1005010c
mov dword [ebp - 0x74], 4
mov dword [ebp - 0x44], 0
mov byte [ebp - 0x54], 0
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x70], 0
mov dword [ebp - 0x10], 3
cmovne edx, eax
mov eax, 9
cmovne eax, ecx
mov dword [ebp - 0x4c], edx
lea ecx, [ebp - 0x58]
lea edx, [ebp - 0x78]
mov dword [ebp - 0x48], eax
lea eax, [ebp - 0x4c]
mov dword [ebp - 0x40], eax
lea eax, [ebp - 0x60]
mov dword [ebp - 0x3c], 0x1000dca0
mov dword [ebp - 0x38], eax
lea eax, [ebp - 0x90]
mov dword [ebp - 0x34], 0x1000dca0
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0x2c], 0x1000dcc0
mov dword [ebp - 0x68], eax
mov dword [ebp - 0x64], 3
call fcn.1000d0f0
cmp al, 3
jne 0x1000cb44
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov dword [ebp - 0x10], 7
push eax
mov dword [ebp - 0x24], edx
call dword [ecx]
add esp, 4
mov esi, dword [ebp - 0x24]
mov ecx, dword [esi + 4]
cmp dword [ecx + 4], 0
je 0x1000cb36
mov eax, dword [esi]
cmp dword [ecx + 8], 9
jb 0x1000cb28
mov eax, dword [eax - 4]
push eax
push 0
push dword [0x1005e128]
call sub.KERNEL32.dll_HeapFree
push esi
push 0
push dword [0x1005e128]
call sub.KERNEL32.dll_HeapFree
mov ebx, dword [ebp - 0x7c]
xor eax, eax
mov ecx, ebx
add cl, 0xfd
movzx edx, cl
inc edx
cmp cl, 2
cmovb eax, edx
test eax, eax
je 0x1000cd46
cmp eax, 1
je 0x1000ce00
xor eax, eax
xchg byte [0x1005d040], al
test al, al
je 0x1000ce00
lea ecx, [ebp - 0x58]
lea edx, [ebp - 0x40]
mov dword [ebp - 0x40], 0x1005017c
mov dword [ebp - 0x3c], 1
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x30], 0x1004f570
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x10], 3
call fcn.1000d0f0
cmp al, 3
jne 0x1000ce00
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov dword [ebp - 0x24], edx
mov dword [ebp - 0x10], 4
push eax
call dword [ecx]
add esp, 4
jmp 0x1000cdc8
mov cl, 4
jmp 0x1000c901
xor ecx, ecx
jmp 0x1000c901
lea eax, [ebp - 0x40]
mov ecx, str.already_borrowedC:cmfltobzsqiwzwswifceeeiuunqkihdnyjizwfcsrqtsqkmwekwaanfzackndqagesnhktvjovmkrgyplrusstvgwloxgtnnoxmtpmkzzsudqjpdkuwbmncfcubd
mov edx, 0x10
push 0x1004ff30
push 0x1004f860
push eax
call fcn.100295a0
add esp, 0xc
ud2
mov ecx, 0x100500da
mov eax, 0xc
jmp 0x1000c933
mov eax, dword [0x1005e128]
test eax, eax
jne 0x1000cc26
call sub.KERNEL32.dll_GetProcessHeap
test eax, eax
je 0x1000cc34
mov dword [0x1005e128], eax
push 0x10
push 0
push eax
call sub.KERNEL32.dll_HeapAlloc
test eax, eax
jne 0x1000cc72
mov ecx, 0x10
mov edx, 4
call fcn.100292f0
ud2
mov edx, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x3c]
cmp edx, 4
je 0x1000ccf8
cmp edx, 1
jne 0x1000cd09
cmp byte [eax], 0x30
jne 0x1000cd09
mov bl, 4
mov esi, 1
jmp 0x1000cd10
mov dword [eax], 0
mov dword [eax + 0xc], 0x1005d044
mov esi, eax
mov eax, dword [0x1005d044]
test eax, eax
jne 0x1000cc9a
mov ecx, 0x1005d044
mov dword [ebp - 0x20], esi
call fcn.10012960
mov esi, dword [ebp - 0x20]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov ecx, dword [esi + 8]
cmp dword [esi], 0
lea edi, [esi + 4]
mov dword [esi], 1
mov dword [esi + 4], 0
mov dword [esi + 8], 0
je 0x1000c96a
test ecx, ecx
je 0x1000c96a
lock dec dword [ecx]
jne 0x1000c96a
call fcn.1000c640
jmp 0x1000c96a
mov eax, dword [esi + 0x10]
lea ecx, [esi + 0x10]
test eax, eax
cmove ecx, eax
jne 0x1000cea2
xor eax, eax
jmp 0x1000cea8
cmp dword [eax], 0x6c6c7566
jne 0x1000cd09
mov bl, 1
mov esi, 3
jmp 0x1000cd10
mov esi, 2
xor ebx, ebx
test ecx, ecx
je 0x1000cd22
push eax
push 0
push dword [0x1005e128]
call sub.KERNEL32.dll_HeapFree
cmp bl, 5
movzx eax, bl
mov ebx, 1
mov edx, dword [ebp + 0xc]
mov ecx, 4
cmovne ebx, esi
cmovne ecx, eax
xchg dword [0x1005e110], ebx
jmp 0x1000c901
push 0x1005e10c
call dword [sym.imp.KERNEL32.dll_AcquireSRWLockExclusive]
lea eax, [ebp - 0x25]
lea ecx, [ebp - 0x58]
lea edx, [ebp - 0x40]
mov dword [ebp - 0x40], 0x1004fad0
mov dword [ebp - 0x3c], 1
mov dword [ebp - 0x94], 0x1005e10c
mov byte [ebp - 0x25], bl
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x10], 6
mov dword [ebp - 0x78], eax
lea eax, [ebp - 0x78]
mov dword [ebp - 0x74], 0x1000dd30
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], 1
call fcn.1000d0f0
mov esi, edx
mov ebx, eax
push 0x1005e10c
call dword [sym.imp.KERNEL32.dll_ReleaseSRWLockExclusive]
cmp bl, 3
jne 0x1000ce00
mov eax, dword [esi]
mov ecx, dword [esi + 4]
mov dword [ebp - 0x10], 5
push eax
mov dword [ebp - 0x24], esi
call dword [ecx]
add esp, 4
mov eax, dword [ebp - 0x24]
mov ecx, dword [eax + 4]
cmp dword [ecx + 4], 0
je 0x1000cdf0
mov eax, dword [ebp - 0x24]
cmp dword [ecx + 8], 9
mov eax, dword [eax]
jb 0x1000cde2
mov eax, dword [eax - 4]
push eax
push 0
push dword [0x1005e128]
call sub.KERNEL32.dll_HeapFree
push dword [ebp - 0x24]
push 0
push dword [0x1005e128]
call sub.KERNEL32.dll_HeapFree
mov eax, dword [ebp - 0x20]
test eax, eax
je 0x1000ce14
lock dec dword [eax]
jne 0x1000ce14
mov ecx, dword [ebp - 0x50]
call fcn.1000c640
mov eax, dword [ebp - 0x44]
mov esi, dword [ebp - 0x88]
mov edi, dword [ebp - 0x84]
test eax, eax
je 0x1000ce34
lock dec dword [eax]
jne 0x1000ce34
mov ecx, dword [ebp - 0x44]
call fcn.1000da70
push 0x1005e11c
call dword [sym.imp.KERNEL32.dll_ReleaseSRWLockShared]
cmp dword [ebp - 0x80], 1
mov dword [ebp - 0x10], 0xffffffff
jbe 0x1000ce97
lea ecx, [ebp - 0x4c]
lea edx, [ebp - 0x40]
mov dword [ebp - 0x40], 0x1005029c
mov dword [ebp - 0x3c], 1
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x30], 0x1004f570
mov byte [ebp - 0x48], 0
mov dword [ebp - 0x4c], 0
mov dword [ebp - 0x2c], 0
call fcn.1000d0f0
lea ecx, [ebp - 0x78]
mov dword [ebp - 0x74], edx
mov dword [ebp - 0x78], eax
call fcn.1000d2b0
ud2
mov ecx, edi
mov edx, esi
call fcn.1000d290
ud2
mov eax, dword [ecx]
mov ecx, dword [ecx + 4]
dec ecx
mov dword [ebp - 0x10], 3
jmp 0x1000ca70