Function at 0x41e870
Capabilities:
Check mutex on windows

Disassembly:
sub esp, 0x88
mov eax, dword [0x4b000c]
xor eax, esp
mov dword [esp + 0x84], eax
cmp dword [0x4d1ef0], 0
push ebx
push ebp
push esi
push edi
je 0x41ea3c
mov esi, dword [sym.imp.KERNEL32.dll_CreateMutexA]
push str.libmikmod_lists_
push 0
push 0
mov dword [0x4d1ef0], 0
call esi
mov dword [0xc0d844], eax
test eax, eax
je 0x41ea30
push str.libmikmod_vars_
push 0
push 0
call esi
mov dword [0xc0d848], eax
test eax, eax
je 0x41ea30
mov dword [0x4d1eec], 1
mov ecx, 0x4b1708
call fcn.00413960
mov ecx, 0x4b1690
call fcn.00413960
mov ecx, dword [0xc0d844]
test ecx, ecx
je 0x41e90c
push 0xffffffffffffffff
push ecx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov ecx, dword [0xc0d844]
mov dword [0x4d9b80], 0x4b1780
mov edx, 0x4b17a0
mov dword [0x4b17a0], 0
mov dword [0x4b1780], 0x4b17a0
mov dword [0x4b17c0], 0
nop dword [eax]
mov eax, dword [edx]
lea esi, [edx]
mov edx, eax
test eax, eax
jne 0x41e940
mov ebp, dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov dword [esi], 0x4b17c0
test ecx, ecx
je 0x41e963
push ecx
call ebp
mov ecx, dword [0xc0d844]
mov eax, 0x4844
xor ebx, ebx
mov word [0x4b0ac4], ax
xor edi, edi
mov eax, 0x20d
mov word [0x4b17e0], ax
test ecx, ecx
je 0x41e992
mov esi, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0xffffffffffffffff
push ecx
call esi
mov ecx, dword [0xc0d844]
mov esi, dword [0x7aa684]
mov byte [esp + 0x10], bl
test esi, esi
je 0x41eac0
mov ebp, str._s_2d__s
nop dword [eax]
push dword [esi + 8]
cmp dword [esi], edi
lea eax, [esp + 0x14]
push 0
push eax
mov eax, str._s_2d__s_n
cmove eax, ebp
push eax
lea eax, [esp + 0x20]
push eax
call fcn.00406d20
lea ecx, [esp + 0x24]
add esp, 0x14
lea edx, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x41e9e0
mov esi, dword [esi]
sub ecx, edx
add ebx, 8
add ebx, ecx
test esi, esi
jne 0x41e9b0
mov ebp, dword [sym.imp.KERNEL32.dll_ReleaseMutex]
test ebx, ebx
je 0x41eaba
mov edx, ebx
lea ecx, [esi + 2]
call fcn.00413520
mov edi, eax
test edi, edi
jne 0x41ea70
mov eax, dword [0x4d9b60]
mov dword [0x4d9b5c], 2
test eax, eax
je 0x41eaba
call eax
jmp 0x41eaba
mov dword [0x4d1eec], 0
jmp 0x41ea49
cmp dword [0x4d1eec], 0
jne 0x41e8df
push str._nUnable_to_initialise_Mikmod_thread_system.
call fcn.004014d0
add esp, 4
push 1
call fcn.00471829
add esp, 4
push eax
call fcn.00471c03
add esp, 4
xor eax, eax
jmp 0x41ebbd
push ebx
push 0
push edi
call fcn.0046e200
mov esi, dword [0x7aa684]
add esp, 0xc
mov byte [edi], 0
mov ebx, 1
test esi, esi
je 0x41eaba
mov ebp, str._s_2d__s
push dword [esi + 8]
cmp dword [esi], 0
mov eax, str._s_2d__s_n
push ebx
push edi
cmove eax, ebp
push eax
push edi
call fcn.00406d20
mov esi, dword [esi]
add esp, 0x14
inc ebx
test esi, esi
jne 0x41ea93
mov ebp, dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov ecx, dword [0xc0d844]
test ecx, ecx
je 0x41eacd
push ecx
call ebp
mov ecx, dword [0xc0d844]
mov eax, dword [0xc0d848]
mov ebx, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov dword [0xbfd420], edi
test eax, eax
je 0x41eaed
push 0xffffffffffffffff
push eax
call ebx
mov ecx, dword [0xc0d844]
test ecx, ecx
je 0x41eaf6
push 0xffffffffffffffff
push ecx
call ebx
mov ecx, edi
call fcn.00413b00
mov ecx, dword [0xc0d844]
mov edi, eax
test ecx, ecx
je 0x41eb0c
push ecx
call ebp
mov esi, dword [0xc0d848]
test esi, esi
je 0x41eb1f
push esi
call ebp
mov esi, dword [0xc0d848]
push 0x800
xor ebx, ebx
test edi, edi
push 0
push 0x7b4f50
sete bl
call fcn.0046e200
add esp, 0xc
test edi, edi
jne 0x41eba8
test esi, esi
je 0x41eb4f
push 0xffffffffffffffff
push esi
mov esi, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
call esi
jmp 0x41eb55
mov esi, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov ecx, 0x10
call fcn.00413cb0
mov eax, dword [0xc0d848]
test eax, eax
je 0x41eb79
push eax
call ebp
mov eax, dword [0xc0d848]
test eax, eax
je 0x41eb79
push 0xffffffffffffffff
push eax
call esi
cmp dword [0x7aa688], 0
jne 0x41eb9a
mov eax, dword [0x4d9b7c]
mov eax, dword [eax + 0x3c]
call eax
test eax, eax
jne 0x41eb9a
mov dword [0x7aa688], 1
mov eax, dword [0xc0d848]
test eax, eax
je 0x41ebbb
push eax
call ebp
jmp 0x41ebbb
push dword [0x4d9b5c]
push str._nErr_mikwin:_d
call fcn.004014d0
add esp, 8
mov eax, ebx
mov ecx, dword [esp + 0x94]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0046ad4d
add esp, 0x88
ret