Function at 0x434d30
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov dword [ebp - 4], ebx
mov dword [ebp - 8], esi
cmp dword [ebp + 0xc], 5
jne 0x434d90
cmp dword [0x51293c], 0
je 0x434fd2
push 0x512938
call fcn.00410180
add esp, 4
mov eax, dword [0x51293c]
xor edx, edx
cmp dword [eax + edx*4], 0xffffffff
jne 0x434f81
inc edx
cmp edx, 0x10
jl 0x434d63
mov eax, dword [ebp + 8]
mov dword [0x512938], 0
mov dword [eax], 0xffff7fff
mov eax, 0x226
jmp 0x434f77
push 0x512938
call fcn.00410180
add esp, 4
mov ebx, dword [0x50ad6c]
cmp ebx, 0xffffc000
jge 0x434dba
mov dword [0x50ad6c], 0xffffff7f
mov ebx, 0xffffff7f
push ebx
call fcn.0043d9c0
add esp, 4
test eax, eax
je 0x434f5e
cmp ebx, 0xfffffffa
lea esi, [ebx + 5]
jg 0x434dd5
mov esi, ebx
mov eax, 0xfb93e673
mul esi
shr edx, 9
imul eax, edx, 0xfffffdf7
mov edx, dword [0x50acc0]
lea ecx, [esi + eax]
cmp edx, 2
lea eax, [esi + eax + 0x69]
mov dword [ebp - 0xc], eax
jge 0x434e35
lea esi, [ecx*4 + 0x1a4]
lea ecx, [esi*8]
sub ecx, esi
mov esi, dword [ecx + 0x50e4c4]
test esi, esi
jne 0x434edd
mov dword [ecx + 0x50e4c4], 1
mov ecx, eax
shl ecx, 5
lea esi, [eax*4]
sub ecx, esi
jmp 0x434edd
lea eax, [ecx*4 + 0x1a4]
lea edx, [eax*8]
sub edx, eax
lea ecx, [edx + 0x50e4c4]
push ecx
call fcn.00410180
add esp, 4
test eax, eax
jne 0x434ec6
mov eax, dword [ebp - 0xc]
mov ecx, eax
shl ecx, 5
lea edx, [eax*4]
sub ecx, edx
cmp dword [ecx + 0x50e4c0], 0
je 0x43506e
mov ecx, eax
lea edx, [eax*4]
shl ecx, 5
sub ecx, edx
mov dword [ecx + 0x50e4c4], 0
push 0xffffffffffffffff
lea edx, [eax*4]
shl eax, 5
sub eax, edx
push dword [eax + 0x50e4c0]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [ebp - 0xc]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea ecx, [edx + 0x50e4c4]
push ecx
call fcn.00410180
add esp, 4
mov eax, dword [ebp - 0xc]
mov ecx, eax
shl ecx, 5
mov edx, dword [0x50acc0]
lea esi, [eax*4]
sub ecx, esi
cmp edx, 1
je 0x435043
mov esi, dword [ecx + 0x50e4d8]
test esi, esi
je 0x434eff
cmp ebx, dword [esi + 0x108]
jbe 0x434eff
mov esi, dword [esi + 0x28]
test esi, esi
jne 0x434ef0
cmp edx, 1
je 0x435021
lea ecx, [eax*4]
shl eax, 5
sub eax, ecx
cmp edx, 2
jge 0x434f25
mov dword [eax + 0x50e4c4], 0
jmp 0x434f4a
mov edx, dword [ebp - 0xc]
mov dword [eax + 0x50e4c4], 0
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x50e4c0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
test esi, esi
je 0x435010
cmp ebx, dword [esi + 0x108]
jne 0x435010
dec ebx
cmp ebx, 0xffff8000
jg 0x434dba
mov dword [0x512938], 0
xor eax, eax
mov ebx, dword [ebp - 4]
mov esi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
mov eax, dword [eax + edx*4]
xor ecx, ecx
mov ebx, eax
shl ebx, cl
test ebx, 0x80000000
je 0x434f9d
inc ecx
cmp ecx, 0x20
jl 0x434f86
jmp 0x434d73
mov ebx, edx
neg ecx
shl ebx, 5
neg ebx
lea esi, [ebx + ecx - 1]
add ecx, 0x1f
mov ebx, dword [ebp + 8]
mov dword [ebx], esi
mov esi, 1
shl esi, cl
mov ecx, dword [0x51293c]
or eax, esi
mov dword [ecx + edx*4], eax
xor eax, eax
mov dword [0x512938], 0
jmp 0x434f77
push 0x51293c
push 0
push 0x40
call fcn.00431e20
add esp, 0xc
test eax, eax
je 0x434ff5
mov dword [0x512938], 0
mov esp, ebp
pop ebp
ret
mov eax, dword [0x51293c]
mov dword [eax], 0
mov eax, dword [0x51293c]
mov dword [eax], 0xf8000000
jmp 0x434d4f
mov eax, dword [ebp + 8]
mov dword [eax], ebx
dec ebx
mov dword [0x50ad6c], ebx
jmp 0x434f6b
push dword [ecx + 0x50e4d4]
push dword [ecx + 0x50e4d0]
call fcn.00410160
add esp, 8
mov eax, dword [ebp - 0xc]
mov edx, dword [0x50acc0]
jmp 0x434f08
lea eax, [ecx + 0x50e4d0]
push eax
call fcn.00410130
add esp, 4
mov eax, dword [ebp - 0xc]
mov ecx, eax
shl ecx, 5
mov edx, dword [0x50acc0]
lea esi, [eax*4]
sub ecx, esi
jmp 0x434ee6
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov esi, eax
mov eax, dword [ebp - 0xc]
mov ecx, eax
shl ecx, 5
lea edx, [eax*4]
sub ecx, edx
mov dword [ecx + 0x50e4c0], esi
mov dword [ecx + 0x50e4c4], 0
jmp 0x434e8e