Function at 0x40cf50
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x480998
mov eax, dword fs:[0]
push eax
sub esp, 0xbd0
mov eax, dword [0x4a9d30]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
cmp byte [0x4ace83], 0
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0xbdc], esi
mov dword [ebp - 0xbd8], edi
jne 0x40d543
mov ecx, esi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40cfa1
sub ecx, edx
mov edx, edi
lea eax, [edx + 1]
mov dword [ebp - 0xbc0], eax
mov al, byte [edx]
inc edx
test al, al
jne 0x40cfb5
sub edx, dword [ebp - 0xbc0]
lea eax, [edx + 1]
add eax, ecx
push eax
push 1
call fcn.00453bae
add esp, 8
mov dword [ebp - 0xbc4], eax
mov edx, esi
sub eax, esi
lea esp, [esp]
mov cl, byte [edx]
lea edx, [edx + 1]
mov byte [eax + edx - 1], cl
test cl, cl
jne 0x40cfe0
mov edx, edi
mov esi, edi
mov al, byte [edx]
inc edx
test al, al
jne 0x40cff1
mov edi, dword [ebp - 0xbc4]
sub edx, esi
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x40d001
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [ebp - 0xbc4]
push edi
call fcn.00454840
mov edx, edi
add esp, 4
lea ecx, [edx + 1]
jmp 0x40d030
mov al, byte [edx]
inc edx
test al, al
jne 0x40d030
sub edx, ecx
xor eax, eax
xor ecx, ecx
mov dword [ebp - 0xbd0], edx
mov dword [ebp - 0xbc8], eax
mov dword [ebp - 0xbcc], ecx
test edx, edx
jle 0x40d11f
cmp edx, 8
jb 0x40d11f
cmp dword [0x4afe98], 2
jl 0x40d11f
movdqa xmm4, xmmword [0x486a40]
mov eax, edx
and eax, 0x80000007
jns 0x40d083
dec eax
or eax, 0xfffffff8
inc eax
movdqa xmm5, xmmword [0x486a30]
mov esi, edx
xorps xmm3, xmm3
sub esi, eax
movdqa xmm2, xmm3
mov eax, 4
jmp 0x40d0a0
movd xmm0, ecx
add ecx, 8
pshufd xmm1, xmm0, 0
movd xmm0, dword [edi + eax - 4]
paddd xmm1, xmm4
pmovsxbd xmm0, xmm0
paddd xmm1, xmm5
pmulld xmm0, xmm1
paddd xmm3, xmm0
movd xmm0, eax
pshufd xmm1, xmm0, 0
movd xmm0, dword [eax + edi]
paddd xmm1, xmm4
paddd xmm1, xmm5
add eax, 8
pmovsxbd xmm0, xmm0
pmulld xmm0, xmm1
paddd xmm2, xmm0
cmp ecx, esi
jl 0x40d0a0
paddd xmm2, xmm3
mov dword [ebp - 0xbcc], ecx
movdqa xmm0, xmm2
psrldq xmm0, 8
paddd xmm2, xmm0
movdqa xmm0, xmm2
psrldq xmm0, 4
paddd xmm2, xmm0
movd dword [ebp - 0xbc8], xmm2
xor esi, esi
mov dword [ebp - 0xbd4], esi
mov dword [ebp - 0xbc0], esi
cmp ecx, edx
jge 0x40d1d4
mov eax, edx
sub eax, ecx
cmp eax, 2
jl 0x40d19c
mov edi, edx
lea esi, [ecx + 1]
mov edx, dword [ebp - 0xbc4]
sub edi, ecx
sub edi, 2
shr edi, 1
inc edi
lea ecx, [ecx + edi*2]
mov dword [ebp - 0xbcc], ecx
lea ebx, [ebx]
movsx eax, byte [edx + esi - 1]
movsx ecx, byte [esi + edx]
imul eax, esi
add dword [ebp - 0xbd4], eax
lea eax, [esi + 1]
imul ecx, eax
add esi, 2
add dword [ebp - 0xbc0], ecx
dec edi
jne 0x40d160
mov edx, dword [ebp - 0xbd0]
mov ecx, dword [ebp - 0xbcc]
mov edi, dword [ebp - 0xbc4]
mov esi, dword [ebp - 0xbd4]
cmp ecx, edx
jge 0x40d1c2
movsx ecx, byte [ecx + edi]
mov eax, dword [ebp - 0xbcc]
mov edi, dword [ebp - 0xbc8]
inc eax
imul ecx, eax
mov eax, dword [ebp - 0xbc0]
add eax, esi
add edi, ecx
add edi, eax
jmp 0x40d1da
mov eax, dword [ebp - 0xbc0]
mov edi, dword [ebp - 0xbc8]
add eax, esi
add edi, eax
jmp 0x40d1da
mov edi, dword [ebp - 0xbc8]
mov eax, 0xeb074a77
imul edi
sar edx, 0xd
mov eax, edx
shr eax, 0x1f
add eax, edx
imul eax, eax, 0x186a0
add edi, eax
lea eax, [ebp - 0x5ec]
push edi
push 0x4acd38
push str._s_nfy_d.ind
push eax
call fcn.00453b2a
lea eax, [ebp - 0x9d4]
push str.XETEXINC_NOTIFY
push eax
call fcn.00423550
add esp, 0x18
lea eax, [ebp - 0x9d4]
push eax
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov edi, eax
push 0xffffffffffffffff
push edi
mov dword [ebp - 0xbd0], edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp - 0x5ec]
push eax
lea ecx, [ebp - 0xa24]
call fcn.004248f0
lea eax, [ebp - 0xa24]
mov dword [ebp - 4], 0
push eax
call fcn.0041f460
add esp, 4
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0xa24]
mov esi, eax
call fcn.004249b0
test esi, esi
je 0x40d2ba
lea eax, [ebp - 0x5ec]
push eax
lea ecx, [ebp - 0xa24]
call fcn.004248f0
lea eax, [ebp - 0xa24]
mov dword [ebp - 4], 1
push eax
call fcn.0041f430
add esp, 4
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0xa24]
call fcn.004249b0
lea eax, [ebp - 0x5ec]
push eax
lea ecx, [ebp - 0xa24]
call fcn.004248f0
lea eax, [ebp - 0xa24]
mov dword [ebp - 4], 2
push eax
call fcn.0041f460
add esp, 4
mov dword [ebp - 4], 0xffffffff
test eax, eax
lea ecx, [ebp - 0xa24]
sete byte [ebp - 0xbb9]
call fcn.004249b0
cmp byte [ebp - 0xbb9], 0
je 0x40d535
mov esi, dword [ebp - 0xbdc]
mov ecx, esi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40d315
sub ecx, edx
cmp ecx, 0x1f3
jbe 0x40d32c
mov byte [esi + 0x1f3], al
mov edi, dword [ebp - 0xbd8]
mov ecx, edi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40d337
sub ecx, edx
cmp ecx, 0x1f3
jbe 0x40d34e
mov byte [edi + 0x1f3], al
lea ecx, [ebp - 0xac8]
call fcn.0041f2b0
lea ecx, [ebp - 0xa74]
mov dword [ebp - 4], 3
call fcn.004249a0
push 0x4acd38
lea eax, [ebp - 0xa74]
mov byte [ebp - 4], 4
push str._sTEMPTnotify.prm
push eax
call fcn.00424be0
lea eax, [ebp - 0xa74]
push eax
call fcn.00425f40
add esp, 0x10
lea eax, [ebp - 0xa74]
lea ecx, [ebp - 0xac8]
push eax
call fcn.0041f410
test eax, eax
je 0x40d441
push 0x1f4
lea eax, [ebp - 0x204]
push 0
push eax
call fcn.00453c50
lea ecx, [ebp - 0x204]
add esp, 0xc
sub ecx, esi
lea esp, [esp]
mov al, byte [esi]
lea esi, [esi + 1]
mov byte [ecx + esi - 1], al
test al, al
jne 0x40d3d0
push 0x1f4
lea eax, [ebp - 0x204]
push eax
lea ecx, [ebp - 0xac8]
call fcn.0041f8e0
push 0x1f4
lea eax, [ebp - 0x204]
push 0
push eax
call fcn.00453c50
lea ecx, [ebp - 0x204]
add esp, 0xc
sub ecx, edi
mov al, byte [edi]
lea edi, [edi + 1]
mov byte [ecx + edi - 1], al
test al, al
jne 0x40d412
push 0x1f4
lea eax, [ebp - 0x204]
push eax
lea ecx, [ebp - 0xac8]
call fcn.0041f8e0
lea ecx, [ebp - 0xac8]
call fcn.0041f330
lea ecx, [ebp - 0xb18]
call fcn.004249a0
push 0x4acd38
lea eax, [ebp - 0xb18]
mov byte [ebp - 4], 5
push str._s_notify.exe
push eax
call fcn.00424be0
add esp, 0xc
lea ecx, [ebp - 0xb68]
call fcn.004249a0
lea eax, [ebp - 0xa74]
mov byte [ebp - 4], 6
push eax
lea ecx, [ebp - 0xb68]
call fcn.004255f0
push 0
push dword [ebp - 0xb28]
push dword [ebp - 0xad8]
call fcn.0041c8e0
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
add esp, 0xc
jmp 0x40d4b0
lea eax, [ebp - 0x5ec]
push eax
lea ecx, [ebp - 0xbb8]
call fcn.004248f0
lea eax, [ebp - 0xbb8]
mov byte [ebp - 4], 7
push eax
call fcn.0041f460
add esp, 4
mov byte [ebp - 4], 6
lea ecx, [ebp - 0xbb8]
mov esi, eax
call fcn.004249b0
test esi, esi
jne 0x40d4f0
push 0x64
call edi
jmp 0x40d4b0
lea ecx, [ebp - 0xb68]
mov byte [ebp - 4], 5
call fcn.004249b0
lea ecx, [ebp - 0xb18]
mov byte [ebp - 4], 4
call fcn.004249b0
lea ecx, [ebp - 0xa74]
mov byte [ebp - 4], 3
call fcn.004249b0
lea ecx, [ebp - 0xac8]
mov dword [ebp - 4], 0xffffffff
call fcn.0041f2d0
mov edi, dword [ebp - 0xbd0]
push edi
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00452f44
mov esp, ebp
pop ebp
ret