Function at 0x4ee230
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
mov esi, ecx
mov eax, dword [0x599b44]
cmp eax, 0xffffffff
je 0x4ee255
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
and eax, 3
dec eax
cmp eax, 2
setb bl
jmp 0x4ee257
xor ebx, ebx
push esi
call dword [sym.imp.KERNEL32.dll_TryAcquireSRWLockExclusive]
test al, al
jne 0x4ee269
push esi
call dword [sym.imp.KERNEL32.dll_AcquireSRWLockExclusive]
mov edi, dword [ebp + 8]
test bl, bl
je 0x4ee28a
cmp dword [esi + 8], 0
jne 0x4ee3b7
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [esi + 8], eax
mov bl, 1
jmp 0x4ee403
mov ecx, esi
call fcn.004ee0d0
mov eax, dword [0x5abb78]
mov ecx, dword [0x59b038]
mov edx, dword fs:[0x2c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x4ee413
push dword [0x599b44]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, 0xffffffff
and eax, 0xfffffffc
je 0x4ee2eb
mov ebx, edi
mov edx, dword [0x5abb70]
mov edi, dword [eax + edx*8 + 4]
cmp edi, dword [0x5abb74]
jne 0x4ee2e9
mov eax, dword [eax + edx*8]
test eax, eax
mov edi, ebx
je 0x4ee2eb
mov ecx, dword [eax]
jmp 0x4ee2eb
mov edi, ebx
mov eax, dword [esi + 0xc]
cmp eax, 0xffffffff
je 0x4ee2fd
mov bl, 1
cmp eax, ecx
je 0x4ee403
cmp dword [esi + 0x10], 0xffffffff
je 0x4ee3b7
mov eax, dword [0x5abb68]
mov ecx, dword [0x59b038]
mov edx, dword fs:[0x2c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x4ee45f
push dword [0x599b44]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, 0xffffffff
and eax, 0xfffffffc
je 0x4ee361
mov ebx, edi
mov edx, dword [0x5abb60]
mov edi, dword [eax + edx*8 + 4]
cmp edi, dword [0x5abb64]
jne 0x4ee35f
mov eax, dword [eax + edx*8]
test eax, eax
mov edi, ebx
je 0x4ee361
mov ecx, dword [eax]
jmp 0x4ee361
mov edi, ebx
mov eax, dword [esi + 0x10]
cmp eax, 0xffffffff
je 0x4ee3c4
cmp eax, ecx
jne 0x4ee3c4
mov eax, dword [0x59d888]
mov ecx, dword [0x59b038]
mov edx, dword fs:[0x2c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x4ee4ab
push dword [0x599b44]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
and eax, 0xfffffffc
je 0x4ee3c4
mov ecx, dword [0x59d880]
mov edx, dword [eax + ecx*8 + 4]
cmp edx, dword [0x59d884]
jne 0x4ee3c4
cmp dword [eax + ecx*8], 0
je 0x4ee3c4
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov bl, 1
cmp dword [esi + 8], eax
je 0x4ee403
test edi, edi
je 0x4ee401
mov ebx, dword [esi + 4]
test ebx, ebx
je 0x4ee401
push 0x3ec
call fcn.005283f4
add esp, 4
mov edi, eax
push 0x3ec
push ebx
push eax
call fcn.0052bc90
add esp, 0xc
mov ecx, dword [ebp + 8]
mov eax, dword [ecx]
mov dword [ecx], edi
test eax, eax
je 0x4ee401
push eax
call fcn.00528424
add esp, 4
xor ebx, ebx
push esi
call dword [sym.imp.KERNEL32.dll_ReleaseSRWLockExclusive]
mov eax, ebx
pop esi
pop edi
pop ebx
pop ebp
ret 4
push 0x5abb78
call fcn.00528497
add esp, 4
cmp dword [0x5abb78], 0xffffffff
jne 0x4ee2b2
mov dword [0x5abb74], 0
mov dword [0x5abb70], 0xffffffff
mov ecx, 0x5abb70
push 0
call fcn.004624b0
push 0x5abb78
call fcn.0052850d
add esp, 4
jmp 0x4ee2b2
push 0x5abb68
call fcn.00528497
add esp, 4
cmp dword [0x5abb68], 0xffffffff
jne 0x4ee328
mov dword [0x5abb64], 0
mov dword [0x5abb60], 0xffffffff
mov ecx, 0x5abb60
push 0
call fcn.004624b0
push 0x5abb68
call fcn.0052850d
add esp, 4
jmp 0x4ee328
push 0x59d888
call fcn.00528497
add esp, 4
cmp dword [0x59d888], 0xffffffff
jne 0x4ee38e
mov dword [0x59d884], 0
mov dword [0x59d880], 0xffffffff
mov ecx, 0x59d880
push 0
call fcn.004624b0
push 0x59d888
call fcn.0052850d
add esp, 4
jmp 0x4ee38e