Function at 0x4801a0
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4ec8f0
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push esi
push edi
mov eax, dword [0x541100]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor edi, edi
mov dword [ebp - 4], edi
mov eax, dword [0x546f34]
cmp eax, edi
je 0x48039b
cmp eax, 0xffffffff
je 0x48039b
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [ebp + 0x10]
mov dword [ecx], eax
mov eax, dword [0x546f60]
cmp eax, edi
jne 0x480205
push edi
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov dword [0x546f60], eax
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov ecx, dword [0x5472b0]
sub ecx, dword [0x5472ac]
mov eax, 0x2aaaaaab
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add eax, edx
xor esi, esi
cmp eax, edi
jle 0x480289
xor ebx, ebx
cmp esi, eax
jb 0x48023b
call fcn.004cce91
mov ecx, dword [ebp + 8]
xor eax, eax
cmp ecx, edi
setne al
cmp eax, edi
je 0x480299
mov edx, dword [0x5472ac]
mov eax, dword [ebx + edx]
push ecx
push eax
call fcn.004ccf60
add esp, 8
cmp eax, edi
sete al
test al, al
jne 0x4802a3
mov ecx, dword [0x5472b0]
sub ecx, dword [0x5472ac]
mov eax, 0x2aaaaaab
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
inc esi
add eax, edx
add ebx, 0xc
cmp esi, eax
jl 0x480234
call fcn.004bdbe3
xor ecx, ecx
cmp eax, edi
setne cl
cmp ecx, edi
jne 0x4802d4
push 0x80004005
call fcn.00420000
mov ecx, dword [0x546f60]
mov eax, dword [ebp + 0xc]
push ecx
mov dword [eax], esi
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jmp 0x4803b5
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea esi, [eax + 0x10]
mov dword [ebp - 0x18], esi
mov byte [ebp - 4], 1
mov ecx, dword [ebp + 8]
lea eax, [ecx - 0x10]
lea ebx, [esi - 0x10]
cmp eax, ebx
je 0x48033d
cmp dword [ebx + 0xc], edi
lea esi, [ebx + 0xc]
jl 0x48032d
mov edx, dword [eax]
cmp edx, dword [ebx]
jne 0x48032d
push eax
call fcn.00423475
mov edi, eax
add esp, 4
or eax, 0xffffffff
lock xadd dword [esi], eax
dec eax
test eax, eax
jg 0x480323
mov ecx, dword [ebx]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push ebx
call eax
lea esi, [edi + 0x10]
mov dword [ebp - 0x18], esi
xor edi, edi
jmp 0x48033d
mov eax, dword [ecx - 0xc]
push eax
push ecx
lea ecx, [ebp - 0x18]
call fcn.00423404
mov esi, dword [ebp - 0x18]
lea ebx, [ebp - 0x18]
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x10], edi
call fcn.004807f0
mov ecx, dword [0x5472b0]
sub ecx, dword [0x5472ac]
mov eax, 0x2aaaaaab
imul ecx
mov eax, dword [ebp + 0xc]
sar edx, 1
mov ecx, edx
shr ecx, 0x1f
lea edx, [edx + ecx - 1]
mov ecx, dword [0x546f60]
push ecx
mov dword [eax], edx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
lea eax, [esi - 0x10]
mov byte [ebp - 4], 0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x48039b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4803c1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret