Function at 0x4126e2
Capabilities:
Terminate thread

Disassembly:
mov eax, dword [0x456d8c]
cmp eax, 0xc
je 0x412749
cmp eax, 0x14
je 0x412749
cmp eax, 0x19
je 0x412749
cmp eax, 0xe
jne 0x412709
call fcn.00411ca3
test eax, eax
je 0x412748
jmp 0x412bff
mov eax, dword [0x456d94]
test eax, eax
je 0x412748
and dword [0x456d34], 0
push esi
mov esi, dword [sym.imp.WINMM.dll_mciSendCommandA]
push 0
push 2
push 0x808
push eax
call esi
push 0x456d34
push 2
push 0x804
push dword [0x456d94]
call esi
and dword [0x456d94], 0
pop esi
ret
call fcn.00411d9c
test eax, eax
je 0x412748
jmp 0x412df1
mov eax, dword [0x456cb4]
push ebx
xor ebx, ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp eax, ebx
je 0x41296f
push 2
push eax
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
mov eax, dword [0x456b54]
mov byte [eax + 8], 1
mov eax, dword [0x456b54]
mov esi, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0xffffffffffffffff
push dword [eax + 4]
call esi
mov eax, dword [0x456b54]
cmp byte [eax + 9], bl
jne 0x41295e
mov byte [eax + 8], 1
mov eax, dword [0x456b54]
push dword [eax + 4]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push 0x1388
push dword [0x456cb4]
call esi
cmp eax, 0x102
jne 0x412967
push ebx
push dword [0x456cb4]
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov eax, dword [0x456b4c]
push dword [eax]
call dword [sym.imp.WINMM.dll_waveOutReset]
mov eax, dword [0x456b4c]
push dword [eax]
call dword [sym.imp.WINMM.dll_waveOutClose]
jmp 0x412967
push dword [eax + 4]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push dword [0x456cb4]
call edi
mov eax, dword [0x456b54]
mov dword [0x456cb4], ebx
mov esi, dword [eax + 0x34]
cmp esi, ebx
je 0x412997
mov ecx, esi
call fcn.0040d86c
push esi
call fcn.0043a7a0
mov eax, dword [0x456b54]
pop ecx
mov dword [eax + 0x34], ebx
mov eax, dword [0x456b54]
mov esi, dword [eax + 0x38]
cmp esi, ebx
je 0x4129b9
mov ecx, esi
call fcn.0040d4a2
push esi
call fcn.0043a7a0
mov eax, dword [0x456b54]
pop ecx
mov dword [eax + 0x38], ebx
mov eax, dword [0x456b54]
mov eax, dword [eax + 4]
cmp eax, ebx
je 0x4129d0
push eax
call edi
mov eax, dword [0x456b54]
mov dword [eax + 4], ebx
pop edi
pop esi
pop ebx
ret
jmp 0x4128c9
mov eax, dword [0x456b40]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x412ca7
push esi
push edi
push 2
push eax
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
mov esi, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 1
pop edi
push 0xffffffffffffffff
mov dword [0x456b24], edi
push dword [0x456b20]
call esi
cmp dword [0x456b28], 0
jne 0x412c91
push dword [0x456b20]
mov dword [0x456b24], edi
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push 0x1388
push dword [0x456b40]
call esi
cmp eax, 0x102
jne 0x412c9d
push 0
push dword [0x456b40]
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov eax, dword [0x456a08]
test eax, eax
je 0x412c9d
mov eax, dword [eax]
test eax, eax
je 0x412c9d
push eax
call dword [sym.imp.WINMM.dll_waveOutReset]
jmp 0x412c9d
push dword [0x456b20]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push dword [0x456b40]
call ebx
pop edi
pop esi
mov eax, dword [0x456b20]
and dword [0x456b40], 0
test eax, eax
je 0x412cc1
push eax
call ebx
and dword [0x456b20], 0
pop ebx
ret
jmp 0x412c04