Function at 0x41a3f0
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov dword [ebp - 0xc], ebx
mov dword [ebp - 4], edi
mov dword [ebp - 8], esi
mov edi, edx
mov esi, eax
cmp esi, 0xfffffffb
jl 0x41a410
je 0x41a847
jmp 0x41a426
push 0x564
push str.for_lub_mgt.c
push 2
push 8
call fcn.00404de0
add esp, 0x10
lea ecx, [esi + 5]
cmp ecx, 0x69
jge 0x41a6b6
lea eax, [esi*4 + 0x14]
lea edx, [eax*8]
sub edx, eax
mov ebx, dword [edx + 0x4e4df8]
mov dword [ebp - 0x18], edx
test ebx, ebx
je 0x41a455
cmp dword [ebx + 0x18], 0
je 0x41a472
mov dword [ebp - 0x10], ecx
push 0
push esi
call fcn.00421430
add esp, 8
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
xor eax, eax
mov esp, ebp
pop ebp
ret
mov eax, dword [ebx + 0x64]
mov dword [ebx + 0x64], 0
test edi, edi
mov dword [ebp - 0x14], eax
je 0x41a588
mov dword [ebp - 0x10], ecx
test byte [ebx + 0x161], 0x18
jne 0x41a4f5
xor eax, eax
cmp dword [0x4e1720], 2
mov dword [edx + 0x4e4df8], eax
mov dword [edx + 0x4e4de8], 0xffffffff
mov dword [edx + 0x4e4dec], eax
jge 0x41a4c2
mov eax, edx
mov dword [eax + 0x4e4de4], 0
jmp 0x41a4e9
mov eax, edx
mov dword [eax + 0x4e4de4], 0
mov ecx, dword [ebp - 0x10]
lea edx, [ecx*4]
shl ecx, 5
sub ecx, edx
push dword [ecx + 0x4e4de0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push ebx
call fcn.00419310
pop ecx
jmp 0x41a697
push 0x178
push 0
mov esi, dword [ebx + 0xf8]
push ebx
call fcn.004a6330
add esp, 0xc
mov edx, dword [ebp - 0x18]
movzx eax, byte [ebx + 0x161]
or byte [ebx + 0x16a], 4
and eax, 0xffffffe7
or eax, 8
cmp dword [0x4e1720], 2
mov byte [ebx + 0x161], al
mov dword [ebx + 0xf8], esi
mov dword [edx + 0x4e4dec], 0
mov dword [edx + 0x4e4de8], 0xffffffff
jge 0x41a55c
mov eax, edx
mov dword [eax + 0x4e4de4], 0
jmp 0x41a697
mov eax, edx
mov dword [eax + 0x4e4de4], 0
mov ecx, dword [ebp - 0x10]
lea edx, [ecx*4]
shl ecx, 5
sub ecx, edx
push dword [ecx + 0x4e4de0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
jmp 0x41a697
movzx eax, byte [ebx + 0x16b]
test al, 1
je 0x41a5b5
movzx esi, byte [ebx + 0x163]
mov edx, esi
and edx, 0xffffffdf
and esi, 0x40
shr esi, 1
or edx, esi
mov byte [ebx + 0x163], dl
and eax, 0xfffffffe
mov byte [ebx + 0x16b], al
test al, 2
je 0x41a5cf
movzx edx, byte [ebx + 0x15a]
mov byte [ebx + 0x159], dl
and eax, 0xfffffffd
mov byte [ebx + 0x16b], al
test al, 4
je 0x41a5e9
movzx edx, byte [ebx + 0x152]
mov byte [ebx + 0x151], dl
and eax, 0xfffffffb
mov byte [ebx + 0x16b], al
test al, 8
je 0x41a60f
movzx esi, byte [ebx + 0x166]
mov edx, esi
and edx, 0xfffffffd
and esi, 4
shr esi, 1
or edx, esi
mov byte [ebx + 0x166], dl
and eax, 0xfffffff7
mov byte [ebx + 0x16b], al
test al, 0x10
je 0x41a629
movzx edx, byte [ebx + 0x158]
mov byte [ebx + 0x157], dl
and eax, 0xffffffef
mov byte [ebx + 0x16b], al
test al, 0x20
je 0x41a643
movzx edx, byte [ebx + 0x15c]
mov byte [ebx + 0x15b], dl
and eax, 0xffffffdf
mov byte [ebx + 0x16b], al
cmp dword [0x4e1720], 2
mov eax, dword [ebp - 0x18]
mov dword [eax + 0x4e4dec], 0
mov dword [eax + 0x4e4de8], 0xffffffff
jge 0x41a66f
mov dword [eax + 0x4e4de4], 0
jmp 0x41a697
mov dword [ebp - 0x10], ecx
mov dword [eax + 0x4e4de4], 0
mov ecx, dword [ebp - 0x10]
lea edx, [ecx*4]
shl ecx, 5
sub ecx, edx
push dword [ecx + 0x4e4de0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
cmp dword [ebp - 0x14], 0
je 0x41a6a7
mov eax, dword [ebp - 0x14]
mov dword [eax + 4], 0
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
xor eax, eax
mov esp, ebp
pop ebp
ret
mov eax, 0x3ee4f99d
imul ecx
mov ebx, ecx
sar ebx, 0x1f
sar edx, 7
sub edx, ebx
imul eax, edx, 0x209
sub ecx, eax
lea eax, [ecx + 0x69]
mov edx, dword [0x4e1720]
mov dword [ebp - 0x10], eax
cmp edx, 2
jge 0x41a710
lea ebx, [ecx*4 + 0x1a4]
lea ecx, [ebx*8]
sub ecx, ebx
mov ebx, dword [ecx + 0x4e4de4]
test ebx, ebx
jne 0x41a7a7
mov dword [ecx + 0x4e4de4], 1
mov eax, dword [ebp - 0x10]
jmp 0x41a7a7
lea eax, [ecx*4 + 0x1a4]
lea edx, [eax*8]
sub edx, eax
lea ecx, [edx + 0x4e4de4]
push ecx
call fcn.00410e10
pop ecx
test eax, eax
jne 0x41a79e
mov ecx, dword [ebp - 0x10]
lea eax, [ecx*4]
mov edx, ecx
shl edx, 5
sub edx, eax
cmp dword [edx + 0x4e4de0], 0
je 0x41ab28
lea eax, [ecx*4]
shl ecx, 5
sub ecx, eax
mov dword [ecx + 0x4e4de4], 0
mov edx, dword [ebp - 0x10]
push 0xffffffffffffffff
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x4e4de0]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [ebp - 0x10]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea ecx, [edx + 0x4e4de4]
push ecx
call fcn.00410e10
pop ecx
mov edx, dword [0x4e1720]
mov eax, dword [ebp - 0x10]
cmp edx, 1
je 0x41ab01
lea ecx, [eax*4]
mov ebx, eax
shl ebx, 5
sub ebx, ecx
mov dword [ebp - 0x18], ebx
mov ebx, dword [ebx + 0x4e4df8]
test ebx, ebx
je 0x41a7e2
xor ecx, ecx
cmp esi, dword [ebx + 0xf8]
jle 0x41a939
mov ecx, ebx
mov ebx, dword [ebx + 0x28]
test ebx, ebx
jne 0x41a7cd
cmp edx, 1
je 0x41a914
lea ecx, [eax*4]
shl eax, 5
sub eax, ecx
cmp edx, 2
jge 0x41a808
mov dword [eax + 0x4e4de4], 0
jmp 0x41a82d
mov dword [eax + 0x4e4de4], 0
mov edx, dword [ebp - 0x10]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x4e4de0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push 0
push esi
call fcn.00421430
add esp, 8
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
xor eax, eax
mov esp, ebp
pop ebp
ret
mov eax, dword [0x4e1720]
cmp eax, 2
jge 0x41a864
cmp eax, 1
je 0x41a8c9
mov dword [ebp - 0x18], 0x4e1680
mov edx, 0x4e1680
jmp 0x41a875
lea eax, [ebp - 0x18]
push eax
call fcn.00410b80
pop ecx
test eax, eax
jne 0x41a8bf
mov edx, dword [ebp - 0x18]
mov ebx, dword [edx]
test ebx, ebx
je 0x41a8ec
mov eax, dword [ebx + 0x28]
mov dword [edx], eax
mov edx, dword [ebx + 0x64]
mov eax, dword [ebx + 0x58]
mov dword [ebp - 0x14], edx
mov dword [ebx + 0x64], 0
test byte [eax + 0x4f], 2
je 0x41a8a2
push dword [eax + 4]
call fcn.00419310
pop ecx
mov eax, dword [ebx + 0x58]
push eax
call fcn.00419310
push ebx
call fcn.00419310
add esp, 8
cmp dword [0x4e1720], 1
je 0x41a8d6
jmp 0x41a697
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
push 0x4e16e4
call fcn.00410dc0
pop ecx
jmp 0x41a856
mov eax, dword [ebp - 0x18]
push dword [eax + 0x68]
push dword [eax + 0x64]
call fcn.00410df0
add esp, 8
jmp 0x41a697
cmp dword [0x4e1720], 1
je 0x41a904
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
xor eax, eax
mov esp, ebp
pop ebp
ret
push dword [edx + 0x68]
push dword [edx + 0x64]
call fcn.00410df0
add esp, 8
jmp 0x41a8f5
mov eax, dword [ebp - 0x18]
push dword [eax + 0x4e4df4]
push dword [eax + 0x4e4df0]
call fcn.00410df0
add esp, 8
mov eax, dword [ebp - 0x10]
mov edx, dword [0x4e1720]
jmp 0x41a7eb
jne 0x41a7e2
test edi, edi
je 0x41a951
test ecx, ecx
je 0x41aacb
mov esi, dword [ebx + 0x28]
mov dword [ecx + 0x28], esi
cmp edx, 1
je 0x41aadc
lea ecx, [eax*4]
shl eax, 5
sub eax, ecx
cmp edx, 2
jge 0x41a977
mov dword [eax + 0x4e4de4], 0
jmp 0x41a99c
mov dword [eax + 0x4e4de4], 0
mov edx, dword [ebp - 0x10]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x4e4de0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [ebx + 0x64]
mov dword [ebx + 0x64], 0
mov dword [ebp - 0x14], eax
movzx eax, byte [ebx + 0x16b]
test al, 1
je 0x41a9d6
movzx ecx, byte [ebx + 0x163]
mov edx, ecx
and edx, 0xffffffdf
and ecx, 0x40
shr ecx, 1
or edx, ecx
mov byte [ebx + 0x163], dl
and eax, 0xfffffffe
mov byte [ebx + 0x16b], al
test al, 2
je 0x41a9f0
movzx edx, byte [ebx + 0x15a]
mov byte [ebx + 0x159], dl
and eax, 0xfffffffd
mov byte [ebx + 0x16b], al
test al, 4
je 0x41aa0a
movzx edx, byte [ebx + 0x152]
mov byte [ebx + 0x151], dl
and eax, 0xfffffffb
mov byte [ebx + 0x16b], al
test al, 8
je 0x41aa30
movzx ecx, byte [ebx + 0x166]
mov edx, ecx
and edx, 0xfffffffd
and ecx, 4
shr ecx, 1
or edx, ecx
mov byte [ebx + 0x166], dl
and eax, 0xfffffff7
mov byte [ebx + 0x16b], al
test al, 0x10
je 0x41aa4a
movzx edx, byte [ebx + 0x158]
mov byte [ebx + 0x157], dl
and eax, 0xffffffef
mov byte [ebx + 0x16b], al
test al, 0x20
je 0x41aa64
movzx edx, byte [ebx + 0x15c]
mov byte [ebx + 0x15b], dl
and eax, 0xffffffdf
mov byte [ebx + 0x16b], al
cmp dword [0x4e1720], 2
mov dword [ebx + 0xc], 0
mov dword [ebx + 8], 0xffffffff
jge 0x41aa84
mov dword [ebx + 4], 0
jmp 0x41aa93
push dword [ebx]
mov dword [ebx + 4], 0
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
test edi, edi
je 0x41a697
cmp dword [0x4e1720], 2
jl 0x41aab1
mov eax, dword [ebx]
test eax, eax
je 0x41aab1
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebx + 8], 0xffffffff
push ebx
mov dword [ebx + 0xc], 0
call fcn.00419310
pop ecx
jmp 0x41a697
mov esi, dword [ebp - 0x18]
mov ecx, dword [ebx + 0x28]
mov dword [esi + 0x4e4df8], ecx
jmp 0x41a951
mov eax, dword [ebp - 0x18]
push dword [eax + 0x4e4df4]
push dword [eax + 0x4e4df0]
call fcn.00410df0
add esp, 8
mov eax, dword [ebp - 0x10]
mov edx, dword [0x4e1720]
jmp 0x41a95a
lea edx, [eax*4]
shl eax, 5
sub eax, edx
lea eax, [eax + 0x4e4df0]
push eax
call fcn.00410dc0
pop ecx
mov edx, dword [0x4e1720]
mov eax, dword [ebp - 0x10]
jmp 0x41a7b0
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov ecx, dword [ebp - 0x10]
lea edx, [ecx*4]
shl ecx, 5
sub ecx, edx
mov dword [ecx + 0x4e4de0], eax
mov dword [ecx + 0x4e4de4], 0
jmp 0x41a765