Function at 0x10155140
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x74
mov eax, dword [0x101f1014]
xor eax, ebp
mov dword [ebp - 0x10], eax
mov eax, dword [0x101f45d4]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_TlsGetValue]
sub esp, 4
mov esi, eax
test eax, eax
je 0x10155486
mov ebx, dword [ebp + 8]
mov eax, dword [0x101f45d4]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_TlsGetValue]
sub esp, 4
mov edi, eax
test eax, eax
je 0x1015549d
lea eax, [ebx + 0x20]
mov dword [ebp - 0x68], eax
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_EnterCriticalSection]
sub esp, 4
mov dword [ebx + 0xc], edi
mov eax, dword [ebx + 0x194]
test eax, eax
je 0x101554f5
cmp dword [ebx + 0x88], esi
jne 0x101554f5
dec eax
mov dword [ebx + 0x194], eax
jne 0x1015522a
mov dword [ebx + 0x88], 0
mov esi, dword [ebx + 0x198]
test esi, esi
jne 0x101553e0
mov eax, dword [0x101f45d4]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_TlsGetValue]
sub esp, 4
mov ecx, eax
test eax, eax
je 0x101554c9
mov eax, dword [ebx + 0x8c]
cmp dword [eax + 8], ecx
jne 0x1015522a
lea esi, [ebx + 0x100]
mov ecx, dword [eax + 0x34]
add eax, 0x34
xor edi, edi
test ecx, ecx
jg 0x10155431
lea edx, [edi + edi*2]
mov dword [eax + edx*4 + 8], 1
mov dword [eax + edx*4 + 4], esi
inc ecx
mov dword [eax], ecx
mov eax, dword [0x101f45d4]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_TlsGetValue]
sub esp, 4
test eax, eax
je 0x101554b4
xor esi, esi
cmp dword [ebx + 0xc], eax
jne 0x10155266
mov dword [ebx + 0xc], 0
cmp dword [ebx + 0x38], 0
jne 0x1015527a
mov eax, dword [ebp - 0x68]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
sub esp, 4
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.10157a00
mov eax, esi
add esp, 0x74
pop esi
pop edi
pop ebx
pop ebp
ret
mov dword [ebp - 0x64], esi
lea esi, [ebx + 0x38]
lea eax, [ebp - 0x60]
mov ecx, 0x14
mov edi, eax
rep movsd dword es:[edi], dword [esi]
xor ecx, ecx
mov dword [ebx + 0x38], ecx
mov dword [ebx + 0x84], ecx
cmp dword [eax], 0
jle 0x101552b9
xor ecx, ecx
lea esi, [ecx + ecx*2]
mov edx, dword [eax + esi*4 + 4]
mov ebx, dword [edx + 4]
test ebx, ebx
jne 0x10155309
mov dword [eax + esi*4 + 0xc], 0
inc ecx
cmp ecx, dword [eax]
jl 0x1015529e
mov eax, dword [eax + 0x4c]
test eax, eax
jne 0x10155297
mov eax, dword [ebp - 0x68]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
sub esp, 4
lea esi, [ebp - 0x60]
mov edi, esi
mov eax, dword [edi]
test eax, eax
jle 0x101552f0
xor ebx, ebx
lea ecx, [ebx + ebx*2]
mov ecx, dword [edi + ecx*4 + 0xc]
test ecx, ecx
jne 0x10155376
inc ebx
cmp ebx, eax
jl 0x101552dc
mov ebx, dword [edi + 0x4c]
cmp esi, edi
jne 0x10155512
mov edi, ebx
test ebx, ebx
jne 0x101552d4
mov esi, dword [ebp - 0x64]
jmp 0x10155266
mov edi, dword [eax + esi*4 + 8]
cmp edi, 0xffffffff
je 0x1015545b
test edi, edi
jle 0x101553bb
mov dword [ebp - 0x70], edi
mov dword [ebx + 0x104], 0
mov ebx, dword [ebx + 0x13c]
mov edi, dword [ebp - 0x70]
dec edi
test ebx, ebx
mov dword [ebp - 0x6c], edi
je 0x10155348
cmp dword [ebp - 0x70], 1
mov edi, dword [ebp - 0x6c]
mov dword [ebp - 0x70], edi
ja 0x10155321
mov edi, dword [edx + 4]
mov dword [eax + esi*4 + 0xc], edi
mov dword [edx + 4], ebx
test ebx, ebx
jne 0x10155520
lea ebx, [edx + 8]
mov edi, dword [ebp - 0x6c]
mov dword [ebx], 0
lea esi, [eax + esi*4]
add esi, 8
sub edi, dword [esi]
add dword [edx + 0xc], edi
jmp 0x101552b4
mov eax, dword [ecx + 0x100]
mov edx, dword [ecx + 0x13c]
mov dword [ebp - 0x68], edx
xor edx, edx
mov dword [ecx + 0x13c], edx
mov dword [ecx + 0x138], edx
mov dword [esp + 8], edx
mov dword [esp], eax
mov dword [esp + 4], 1
call dword [sym.imp.kernel32.dll_ReleaseSemaphore]
sub esp, 0xc
mov eax, dword [ebp - 0x68]
mov ecx, eax
test eax, eax
jne 0x10155376
mov eax, dword [edi]
jmp 0x101552eb
mov dword [eax + esi*4 + 0xc], ebx
mov dword [edx + 4], ebx
mov ebx, dword [ebx + 0x138]
test ebx, ebx
je 0x10155366
mov dword [ebx + 0x13c], 0
mov ebx, 0x138
add ebx, dword [edx + 4]
jmp 0x10155360
cmp esi, 0xffffffff
jne 0x10155528
mov eax, dword [0x101f45d4]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_TlsGetValue]
sub esp, 4
test eax, eax
je 0x101554e0
mov ecx, dword [ebx + 0x110]
cmp dword [ecx + 8], eax
jne 0x10155422
add ecx, 0x1c
lea eax, [ebx + 0x184]
mov dword [esp + 4], ecx
mov dword [esp], eax
call sym.nss3.dll__PR_MD_NOTIFYALL_CV
mov dword [ebx + 0x198], 0
jmp 0x101551dc
mov dword [ebp - 0x64], eax
add eax, 8
mov edx, ecx
cmp dword [eax - 4], esi
je 0x10155502
add eax, 0xc
dec edx
jne 0x10155439
cmp ecx, 6
jge 0x10155561
mov eax, dword [ebp - 0x64]
mov edi, ecx
jmp 0x10155218
mov dword [ebx + 0x104], 0
mov ebx, dword [ebx + 0x13c]
test ebx, ebx
jne 0x1015545b
mov edi, dword [edx + 4]
mov dword [eax + esi*4 + 0xc], edi
xor esi, esi
mov dword [edx + 8], esi
mov dword [edx + 4], esi
mov dword [edx + 0xc], esi
jmp 0x101552b4
movaps xmm0, xmmword [0x101b11e0]
movups xmmword [esp], xmm0
call fcn.1006e720
mov esi, eax
jmp 0x1015516e
movaps xmm0, xmmword [0x101b11e0]
movups xmmword [esp], xmm0
call fcn.1006e720
mov edi, eax
jmp 0x1015518c
movaps xmm0, xmmword [0x101b11e0]
movups xmmword [esp], xmm0
call fcn.1006e720
jmp 0x10155243
movaps xmm0, xmmword [0x101b11e0]
movups xmmword [esp], xmm0
call fcn.1006e720
mov ecx, eax
jmp 0x101551f7
movaps xmm0, xmmword [0x101b11e0]
movups xmmword [esp], xmm0
call fcn.1006e720
jmp 0x10155402
call fcn.10156040
xor esi, esi
dec esi
jmp 0x10155245
mov ecx, dword [eax]
cmp ecx, 0xffffffff
jne 0x10155227
jmp 0x1015522a
mov dword [esp], edi
call dword [sym.imp.mozglue.dll_free]
jmp 0x101552fb
mov edi, dword [ebp - 0x6c]
jmp 0x101553c2
test esi, esi
jle 0x10155422
lea edi, [ebx + 0x184]
inc esi
call fcn.10156040
mov ecx, dword [ebx + 0x110]
cmp dword [ecx + 8], eax
jne 0x10155556
add ecx, 0x1c
mov dword [esp + 4], ecx
mov dword [esp], edi
call sym.nss3.dll__PR_MD_NOTIFY_CV
dec esi
cmp esi, 1
ja 0x10155537
jmp 0x10155422
mov eax, dword [ebp - 0x64]
mov eax, dword [eax + 0x4c]
test eax, eax
jne 0x10155586
mov dword [esp + 4], 0x50
mov dword [esp], 1
call dword [sym.imp.mozglue.dll_calloc]
mov ecx, dword [ebp - 0x64]
mov dword [ecx + 0x4c], eax
mov ecx, dword [eax]
jmp 0x10155210