Function at 0x4d04e0
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x20
mov ecx, dword [ebp + 0xc]
xor eax, eax
push ebx
mov ebx, dword [ecx + 8]
push esi
mov esi, dword [ebp + 0x10]
xor edx, edx
cmp ebx, eax
push edi
mov dword [ebp - 4], eax
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], edx
mov dword [esi], eax
mov dword [ebp - 0x18], eax
jbe 0x4d05c1
mov ecx, dword [ecx + 0xc]
mov edx, dword [ecx + eax*4]
mov eax, dword [edx + 8]
mov ecx, dword [edx + 0xc]
mov ebx, dword [ebp + 8]
mov esi, eax
and esi, 0x800
mov dword [ebp - 0x1c], ecx
xor edi, edi
mov ecx, esi
or ecx, edi
je 0x4d0575
test byte [ebx + 0x2998], 8
jne 0x4d0575
mov ecx, dword [edx + 0x10]
mov ecx, dword [ecx + 8]
and ecx, 0x40211028
xor ebx, ebx
or ecx, ebx
jne 0x4d0572
and eax, 0x100
or eax, ecx
je 0x4d056c
mov eax, dword [ebp + 8]
add dword [eax + 0x1a98], 1
cmp byte [eax + 0x1a90], bl
je 0x4d05a7
add dword [ebp - 0x14], 1
jmp 0x4d05a7
mov ebx, dword [ebp + 8]
or esi, edi
je 0x4d05a7
mov edx, dword [edx + 0x10]
mov ecx, dword [edx + 8]
and ecx, 0x44210008
xor edx, edx
or ecx, edx
jne 0x4d05a7
and eax, 0x100
or eax, ecx
je 0x4d05a3
add dword [ebx + 0x1a98], 1
cmp byte [ebx + 0x1a90], cl
je 0x4d05a7
add dword [ebp - 0x10], 1
mov eax, dword [ebp - 0x18]
mov ebx, dword [ebp - 0xc]
mov ecx, dword [ebp + 0xc]
add eax, 1
cmp eax, ebx
mov dword [ebp - 0x18], eax
jb 0x4d0514
mov edx, dword [ebp - 0x10]
mov eax, dword [ecx + 0x38]
and eax, 0xfff00000
cmp eax, 0x10000000
jne 0x4d05d4
cmp edx, ebx
je 0x4d05dd
mov esi, dword [ebp - 0x14]
add esi, edx
cmp esi, ebx
jae 0x4d063d
xor edi, edi
cmp eax, 0x10000000
jne 0x4d062f
test ebx, ebx
jbe 0x4d0621
mov esi, dword [ecx + 4]
lea ecx, [ecx]
mov ecx, dword [esi]
cmp ecx, 0xffffffff
je 0x4d0619
mov eax, dword [ecx + 0x10]
mov eax, dword [eax + 8]
and eax, 0x100
xor edx, edx
or eax, edx
je 0x4d0619
mov eax, dword [ecx + 8]
and eax, 0x800
xor ecx, ecx
or eax, ecx
je 0x4d0619
add edi, 1
add esi, 4
sub ebx, 1
jne 0x4d05f0
mov edx, dword [ebp - 0x10]
mov eax, dword [ebp - 0xc]
cmp edx, eax
jne 0x4d062f
cmp edi, eax
jne 0x4d063d
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov ebx, dword [ebp + 8]
add dword [ebx + 0x1a94], 1
test edx, edx
jbe 0x4d0771
mov eax, dword [0x776138]
test eax, eax
jge 0x4d065c
xor eax, eax
jmp 0x4d0663
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
cmp dword [eax + 0x10], 0
je 0x4d068e
mov ecx, dword [eax + 0x10]
xor ebx, ebx
cmp ecx, ebx
jne 0x4d0678
xor ecx, ecx
mov eax, ecx
jmp 0x4d069c
mov edx, dword [ecx]
cmp edx, ebx
mov dword [eax + 0x10], edx
jne 0x4d0684
mov dword [eax + 0x14], ebx
mov dword [ecx], 0xfefefefe
mov eax, ecx
jmp 0x4d069c
mov ecx, dword [eax + 0xc]
push 0x10
push 0x40
call fcn.007515ae
xor ebx, ebx
cmp eax, ebx
je 0x4d06d6
or ecx, 0xffffffff
mov dword [eax], ebx
mov dword [eax + 8], ebx
mov dword [eax + 0x10], ecx
mov dword [eax + 0x38], ebx
mov dword [eax + 4], ebx
mov word [eax + 0x3c], bx
mov dword [eax + 0xc], ebx
mov word [eax + 0x3e], bx
mov dword [eax + 0x14], ebx
mov dword [eax + 0x18], ebx
mov dword [eax + 0x1c], ebx
mov dword [eax + 0x20], ecx
mov dword [eax + 0x24], ebx
mov dword [eax + 0x30], ebx
mov dword [eax + 0x34], ebx
mov dword [ebp - 8], eax
jmp 0x4d06d9
mov dword [ebp - 8], ebx
mov ecx, dword [ebp - 0x10]
mov edx, dword [ebp - 8]
mov eax, ecx
push ebx
and eax, 0xfffff
push edx
or eax, 0x10000000
mov edx, ecx
call fcn.004cc5e0
cmp eax, ebx
mov dword [ebp - 4], eax
jl 0x4d07ee
cmp dword [ebp - 0xc], 0
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx + 0x30]
mov eax, dword [ebp - 8]
mov dword [eax + 0x30], edx
mov ecx, dword [ecx + 0x34]
mov dword [eax + 0x34], ecx
mov dword [ebp - 4], ebx
jbe 0x4d076e
xor edi, edi
mov edx, dword [ebp + 0xc]
mov eax, dword [edx + 0xc]
mov edx, dword [ebp + 8]
test byte [edx + 0x2998], 8
mov esi, dword [eax + ebx*4]
jne 0x4d0742
mov eax, dword [esi + 0x10]
mov eax, dword [eax + 8]
and eax, 0x1020
xor ecx, ecx
or eax, ecx
je 0x4d0766
mov eax, dword [ebp - 8]
mov ecx, dword [eax + 0xc]
mov dword [edi + ecx], esi
mov eax, dword [eax + 4]
add eax, edi
push eax
mov eax, edx
call fcn.004d0470
test eax, eax
mov dword [ebp - 4], eax
jl 0x4d07ec
add edi, 4
add ebx, 1
cmp ebx, dword [ebp - 0xc]
jb 0x4d071c
mov ebx, dword [ebp + 8]
test byte [ebx + 0x2998], 8
jne 0x4d07b5
xor edi, edi
cmp dword [ebp - 0xc], edi
jbe 0x4d07b5
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx + 0xc]
mov esi, dword [edx + edi*4]
mov eax, dword [esi + 0x10]
mov eax, dword [eax + 8]
and eax, 0x1020
xor ecx, ecx
or eax, ecx
jne 0x4d07ad
lea eax, [esi + 0x3c]
push eax
mov eax, ebx
call fcn.004d0470
test eax, eax
mov dword [ebp - 4], eax
jl 0x4d07ec
add edi, 1
cmp edi, dword [ebp - 0xc]
jb 0x4d0781
mov eax, dword [ebp - 8]
test eax, eax
je 0x4d07cb
push eax
mov esi, ebx
call fcn.004ca180
test eax, eax
mov dword [ebp - 4], eax
jl 0x4d07ec
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
xor ecx, ecx
mov dword [eax + 0x38], ecx
mov dword [eax], ecx
mov dword [eax + 8], ecx
mov ecx, dword [ebp - 8]
mov eax, dword [ebp - 4]
mov dword [edx], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
xor ebx, ebx
mov edi, dword [ebp - 8]
cmp edi, ebx
je 0x4d08d1
cmp word [edi + 0x3c], bx
je 0x4d0842
mov eax, dword [0x776138]
cmp eax, ebx
jge 0x4d080c
xor eax, eax
jmp 0x4d0813
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
movzx ecx, word [edi + 0x3c]
cmp ecx, dword [eax + 0x120]
ja 0x4d083b
mov edx, dword [edi + 4]
mov eax, dword [eax + 0x11c]
shl ecx, 4
cmp edx, ebx
lea ecx, [ecx + eax - 0x10]
je 0x4d083b
mov eax, dword [ecx + 4]
mov dword [edx], eax
mov dword [ecx + 4], edx
mov word [edi + 0x3c], bx
mov dword [edi + 4], ebx
cmp word [edi + 0x3e], bx
je 0x4d088b
mov eax, dword [0x776138]
cmp eax, ebx
jge 0x4d0855
xor eax, eax
jmp 0x4d085c
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
movzx ecx, word [edi + 0x3e]
cmp ecx, dword [eax + 0x120]
ja 0x4d0884
mov edx, dword [edi + 0xc]
mov eax, dword [eax + 0x11c]
shl ecx, 4
cmp edx, ebx
lea ecx, [ecx + eax - 0x10]
je 0x4d0884
mov eax, dword [ecx + 4]
mov dword [edx], eax
mov dword [ecx + 4], edx
mov word [edi + 0x3e], bx
mov dword [edi + 0xc], ebx
mov eax, dword [0x776138]
cmp eax, ebx
jl 0x4d08d1
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, eax
cmp esi, ebx
je 0x4d08d1
push 0x40
push 0xfe
push edi
call sub.msvcrt.dll_memset
mov dword [edi], ebx
mov eax, dword [esi + 0x14]
add esp, 0xc
cmp eax, ebx
je 0x4d08cb
mov dword [eax], edi
mov eax, dword [ebp - 4]
mov dword [esi + 0x14], edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov dword [esi + 0x10], edi
mov dword [esi + 0x14], edi
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc