Function at 0x4d6188
Capabilities:
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov dword [ebp - 0x10], 0
mov eax, dword [ebp + 8]
mov dword [ebp - 0x14], eax
mov dword [esp], 0x560654
call sym._pthread_mutex_lock
mov eax, dword [ebp - 0x14]
add eax, 0x1c
mov dword [esp], eax
call sym._pthread_mutex_lock
mov dword [esp + 4], sym._pthread_tls_init
mov dword [esp], 0x5bd558
call sym.__pthread_once_raw
mov eax, dword [0x56064c]
mov edx, dword [ebp - 0x14]
mov dword [esp + 4], edx
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_TlsSetValue]
call eax
sub esp, 8
mov eax, dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
call eax
mov edx, dword [ebp - 0x14]
mov dword [edx + 0x3c], eax
mov eax, dword [ebp - 0x14]
add eax, 0x1c
mov dword [esp], eax
call sym._pthread_mutex_unlock
mov eax, dword [ebp - 0x14]
add eax, 0x70
mov dword [esp + 4], 0
mov dword [esp], eax
call sym.__setjmp3
test eax, eax
jne 0x4d6270
mov dword [ebp - 0xc], pe_nt_image_headers32
mov dword [esp], 0x560654
call sym._pthread_mutex_unlock
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 8]
test eax, eax
je 0x4d6248
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 8]
mov edx, dword [ebp - 0x14]
mov edx, dword [edx + 4]
mov dword [esp], edx
call eax
mov dword [ebp - 0xc], eax
mov dword [esp], 0x560654
call sym._pthread_mutex_lock
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x14]
mov dword [eax + 4], edx
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 0xb4]
mov dword [esp], eax
call sym.__pthread_cleanup_dest
jmp 0x4d627c
mov dword [esp], 0x560654
call sym._pthread_mutex_lock
mov eax, dword [ebp - 0x14]
add eax, 0x1c
mov dword [esp], eax
call sym._pthread_mutex_lock
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 4]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 0x18]
test eax, eax
je 0x4d62b0
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
call eax
sub esp, 4
mov eax, dword [ebp - 0x14]
mov dword [eax + 0x18], 0
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 0x14]
test eax, eax
jne 0x4d6316
mov eax, dword [ebp - 0x14]
mov dword [eax], 0xdeadbeef
mov eax, dword [ebp - 0x14]
add eax, 0x1c
mov dword [esp], eax
call sym._pthread_mutex_unlock
mov eax, dword [ebp - 0x14]
add eax, 0x1c
mov dword [esp], eax
call sym._pthread_mutex_destroy
mov eax, dword [ebp - 0x14]
mov dword [esp], eax
call sym._push_pthread_mem
mov dword [ebp - 0x14], 0
mov eax, dword [0x56064c]
mov edx, dword [ebp - 0x14]
mov dword [esp + 4], edx
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_TlsSetValue]
call eax
sub esp, 8
jmp 0x4d6359
mov eax, dword [ebp - 0x14]
add eax, 0x1c
mov dword [esp], eax
call sym._pthread_mutex_unlock
mov eax, dword [ebp - 0x14]
add eax, 0x1c
mov dword [esp], eax
call sym._pthread_mutex_destroy
mov eax, dword [ebp - 0x14]
mov dword [eax + 0x1c], 0xffffffff
mov eax, dword [ebp - 0x14]
mov dword [eax + 0x68], 1
jmp 0x4d6359
mov dword [esp], 0
mov eax, dword [sym.imp.KERNEL32.dll_Sleep]
call eax
sub esp, 4
mov dword [esp], 0x560654
call sym._pthread_mutex_unlock
test eax, eax
je 0x4d6348
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
mov eax, dword [sym.imp.msvcrt.dll__endthreadex]
call eax