Function at 0x4f5b40
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x57303c
mov eax, dword fs:[0]
push eax
sub esp, 0x8cc
mov eax, dword [0x5e56f0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
lea eax, [ebp + 8]
mov dword [ebp - 4], 1
push eax
lea eax, [ebp - 0x82c]
push str.Global_
push eax
call fcn.004f5f40
mov esi, eax
add esp, 0xc
lea eax, [ebp + 8]
cmp eax, esi
je 0x4f5bc2
cmp dword [ebp + 0x1c], 0x10
jb 0x4f5ba7
push dword [ebp + 8]
call fcn.0054a379
add esp, 4
push esi
lea ecx, [ebp + 8]
mov dword [ebp + 0x1c], 0xf
mov dword [ebp + 0x18], 0
mov byte [ebp + 8], 0
call fcn.004ead30
cmp dword [ebp - 0x818], 0x10
jb 0x4f5bd9
push dword [ebp - 0x82c]
call fcn.0054a379
add esp, 4
push str._MUTEX
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 0x878]
push eax
call fcn.004f0c10
add esp, 0xc
mov edx, eax
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x860]
call fcn.004f5a80
cmp dword [eax + 0x14], 8
jb 0x4f5c0a
mov eax, dword [eax]
push eax
push 0
push 0x1f0001
call dword [sym.imp.KERNEL32.dll_OpenMutexW]
cmp dword [ebp - 0x84c], 8
mov edi, eax
jb 0x4f5c31
push dword [ebp - 0x860]
call fcn.0054a379
add esp, 4
xor eax, eax
mov byte [ebp - 4], 1
cmp dword [ebp - 0x864], 0x10
mov dword [ebp - 0x84c], 7
mov dword [ebp - 0x850], 0
mov word [ebp - 0x860], ax
jb 0x4f5c69
push dword [ebp - 0x878]
call fcn.0054a379
add esp, 4
mov dword [ebp - 0x864], 0xf
mov dword [ebp - 0x868], 0
mov byte [ebp - 0x878], 0
test edi, edi
je 0x4f5d42
push str._EVENT
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 0x844]
push eax
call fcn.004f0c10
add esp, 0xc
mov edx, eax
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x890]
call fcn.004f5a80
cmp dword [eax + 0x14], 8
jb 0x4f5cbd
mov eax, dword [eax]
push eax
push 0
push 0x1f0003
call dword [sym.imp.KERNEL32.dll_OpenEventW]
cmp dword [ebp - 0x87c], 8
mov ebx, eax
jb 0x4f5ce4
push dword [ebp - 0x890]
call fcn.0054a379
add esp, 4
xor eax, eax
mov byte [ebp - 4], 1
cmp dword [ebp - 0x830], 0x10
mov dword [ebp - 0x87c], 7
mov dword [ebp - 0x880], 0
mov word [ebp - 0x890], ax
jb 0x4f5d1c
push dword [ebp - 0x844]
call fcn.0054a379
add esp, 4
mov dword [ebp - 0x830], 0xf
mov dword [ebp - 0x834], 0
mov byte [ebp - 0x844], 0
test ebx, ebx
jne 0x4f5d96
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor bl, bl
cmp dword [ebp + 0x1c], 0x10
jb 0x4f5d55
push dword [ebp + 8]
call fcn.0054a379
add esp, 4
cmp dword [ebp + 0x34], 0x10
mov dword [ebp + 0x1c], 0xf
mov dword [ebp + 0x18], 0
mov byte [ebp + 8], 0
jb 0x4f5d78
push dword [ebp + 0x20]
call fcn.0054a379
add esp, 4
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0054caf9
mov esp, ebp
pop ebp
ret
lea edx, [ebp + 8]
lea ecx, [ebp - 0x82c]
call fcn.004f5a80
cmp dword [eax + 0x14], 8
jb 0x4f5dac
mov eax, dword [eax]
push eax
push 0
push 0xf001f
call dword [sym.imp.KERNEL32.dll_OpenFileMappingW]
cmp dword [ebp - 0x818], 8
mov esi, eax
mov dword [ebp - 0x814], esi
jb 0x4f5dd9
push dword [ebp - 0x82c]
call fcn.0054a379
add esp, 4
xor eax, eax
mov dword [ebp - 0x818], 7
mov dword [ebp - 0x81c], 0
mov word [ebp - 0x82c], ax
test esi, esi
jne 0x4f5e0b
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call esi
push ebx
call esi
jmp 0x4f5d42
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0
push 0
push 0
push 0xf001f
push esi
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov esi, eax
mov edx, esi
lea eax, [edx + 1]
lea ecx, [ecx]
mov cl, byte [edx]
inc edx
test cl, cl
jne 0x4f5e30
sub edx, eax
je 0x4f5ee7
push 0x800
lea eax, [ebp - 0x810]
push 0
push eax
call fcn.0054cf60
mov ecx, esi
add esp, 0xc
lea edx, [ecx + 1]
lea ebx, [ebx]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4f5e60
sub ecx, edx
lea eax, [ecx + 1]
push eax
lea eax, [ebp - 0x810]
push esi
push eax
call fcn.0054bda0
add esp, 0xc
lea eax, [ebp - 0x810]
lea ecx, [ebp - 0x8c0]
push eax
call fcn.004e8f80
push 0x5cd2f0
push eax
lea eax, [ebp - 0x8d8]
mov byte [ebp - 4], 4
push eax
call fcn.004f6030
lea ecx, [ebp + 0x20]
mov byte [ebp - 4], 5
push ecx
push eax
lea eax, [ebp - 0x8a8]
push eax
call fcn.004f0d00
add esp, 0x18
lea ecx, [ebp + 0x20]
push eax
call fcn.004e9050
lea ecx, [ebp - 0x8a8]
call fcn.004e9090
lea ecx, [ebp - 0x8d8]
call fcn.004e9090
lea ecx, [ebp - 0x8c0]
call fcn.004e9090
cmp dword [ebp + 0x34], 0x10
lea ecx, [ebp + 0x20]
mov eax, dword [ebp + 0x30]
cmovae ecx, dword [ebp + 0x20]
inc eax
push eax
push ecx
push esi
call fcn.0054bda0
add esp, 0xc
push esi
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push dword [ebp - 0x814]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push edi
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push ebx
call dword [sym.imp.KERNEL32.dll_SetEvent]
push edi
call esi
push ebx
call esi
mov bl, 1
jmp 0x4f5d44