Function at 0x6f259400
Capabilities:
Get process heap flags

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff0
push dword [ecx - 4]
push ebp
mov ebp, esp
push edi
push esi
push ebx
push ecx
sub esp, 0x48
mov ebx, dword [ecx]
test byte [0x6f266648], 8
jne 0x6f2596f8
lea ecx, [ebp - 0x20]
lea edx, [ebp - 0x1c]
mov eax, ebx
call sym._MMSYSTEM_GetMidiStream
test eax, eax
je 0x6f2596e0
mov dword [esp], ebx
call sym.winmm.dll_midiStreamStop
mov eax, dword [ebp - 0x1c]
sub esp, 4
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0x12
mov eax, dword [eax + 8]
mov dword [esp], eax
call dword [sym.imp.user32.dll_PostThreadMessageA]
mov eax, dword [ebp - 0x1c]
mov esi, dword [sym.imp.kernel32.dll_CloseHandle]
sub esp, 0x10
mov eax, dword [eax + 0x4c]
mov dword [esp], eax
call esi
mov eax, dword [ebp - 0x1c]
sub esp, 4
mov edx, dword [eax + 4]
test edx, edx
je 0x6f2597a0
mov eax, dword [eax + 8]
mov ecx, dword fs:[0x18]
cmp dword [ecx + 0x24], eax
je 0x6f259728
mov dword [esp], edx
mov dword [esp + 4], 0xffffffff
call dword [sym.imp.kernel32.dll_WaitForSingleObject]
mov eax, dword [ebp - 0x1c]
sub esp, 8
mov eax, dword [eax + 4]
mov dword [esp], eax
call esi
mov eax, dword [ebp - 0x20]
mov edx, dword [ebp - 0x1c]
sub esp, 4
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov ecx, dword [eax + 0x24]
mov dword [esp + 0xc], 0x3c8
mov dword [esp + 0x10], ecx
mov ecx, dword [edx]
mov dword [esp + 8], ecx
movzx edx, word [edx + 0x48]
mov dword [esp + 4], edx
mov eax, dword [eax + 0x20]
mov dword [esp], eax
call sym.winmm.dll_DriverCallback
sub esp, 0x1c
mov eax, dword [ebp - 0x1c]
mov edx, dword [eax + 0xc]
add eax, 0xc
mov dword [edx + 0x18], 0
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_DeleteCriticalSection]
mov esi, dword [ebp - 0x1c]
sub esp, 4
mov dword [esp], 0x6f266580
call dword [sym.imp.kernel32.dll_EnterCriticalSection]
mov edx, dword [esi + 0x60]
lea eax, [esi + 0x58]
mov dword [ebp - 0x30], eax
sub esp, 4
test edx, edx
je 0x6f259820
mov ecx, dword [esi + 0x5c]
test ecx, ecx
je 0x6f259559
lea esi, [esi]
mov eax, edx
mov edx, dword [edx + 4]
test edx, edx
jne 0x6f259550
mov edi, dword [eax + 8]
mov dword [ebp - 0x2c], edi
mov edx, dword [eax]
mov edi, dword [ebp - 0x2c]
test edx, edx
je 0x6f259840
cmp dword [edx + 4], eax
je 0x6f2598d8
mov dword [edx + 8], edi
mov edx, dword [ebp - 0x2c]
test edx, edx
je 0x6f259586
mov edx, dword [eax]
mov edi, dword [ebp - 0x2c]
mov dword [edi], edx
mov edi, dword [eax + 0xc]
mov edx, dword [eax]
and edi, 1
mov dword [ebp - 0x34], edi
cmp dword [ebp - 0x30], eax
je 0x6f2595e1
mov edi, dword [esi + 0x58]
mov dword [eax], edi
mov ecx, edi
mov edi, dword [esi + 0x5c]
mov dword [eax + 4], edi
mov edi, dword [esi + 0x60]
mov dword [eax + 8], edi
mov edi, dword [esi + 0x64]
mov dword [eax + 0xc], edi
test ecx, ecx
je 0x6f2598c8
mov edi, dword [ebp - 0x30]
cmp edi, dword [ecx + 4]
je 0x6f259970
mov dword [ecx + 8], eax
mov edi, dword [eax + 8]
test edi, edi
je 0x6f2595cf
mov dword [edi], eax
mov edi, dword [eax + 4]
test edi, edi
je 0x6f2595d8
mov dword [edi], eax
cmp dword [ebp - 0x30], edx
je 0x6f2598b0
mov edi, dword [ebp - 0x34]
test edi, edi
jne 0x6f259690
mov ecx, dword [ebp - 0x2c]
test edx, edx
je 0x6f259a89
test ecx, ecx
je 0x6f259606
mov eax, dword [ecx + 0xc]
test al, 1
jne 0x6f259850
mov eax, dword [edx + 4]
cmp eax, ecx
je 0x6f259980
test eax, eax
je 0x6f265107
mov ecx, dword [eax + 0xc]
test cl, 1
jne 0x6f259868
mov edi, dword [eax + 4]
mov dword [ebp - 0x2c], edi
test edi, edi
je 0x6f2598e0
test byte [edi + 0xc], 1
je 0x6f2598e0
mov ecx, dword [eax + 0xc]
mov edi, dword [edx + 0xc]
and ecx, 0xfffffffe
and edi, 1
or ecx, edi
mov dword [eax + 0xc], ecx
and dword [edx + 0xc], 0xfffffffe
mov eax, dword [eax + 4]
test eax, eax
je 0x6f25965d
and dword [eax + 0xc], 0xfffffffe
mov ecx, dword [edx]
mov eax, dword [edx + 4]
test ecx, ecx
je 0x6f259ab0
cmp dword [ecx + 4], edx
je 0x6f259aba
mov dword [ecx + 8], eax
mov ecx, dword [eax + 8]
mov dword [edx + 4], ecx
test ecx, ecx
je 0x6f259682
mov dword [ecx], edx
mov dword [eax + 8], edx
mov ecx, dword [edx]
mov dword [eax], ecx
mov dword [edx], eax
lea esi, [esi]
nop
mov eax, dword [0x6f270488]
test eax, eax
je 0x6f25969d
and dword [eax + 0xc], 0xfffffffe
mov dword [esp + 8], esi
mov dword [esp + 4], 0
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_HeapFree]
sub esp, 0xc
mov dword [esp], 0x6f266580
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
sub esp, 4
jmp 0x6f25977e
lea esp, [ebp - 0x10]
mov eax, 5
pop ecx
pop ebx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret 4
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], str.__p___n
mov dword [esp + 8], str.midiStreamClose
mov dword [esp + 4], 0x6f266648
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_8
jmp 0x6f259423
test byte [0x6f266648], 1
jne 0x6f2597e8
mov dword [esp], edx
call esi
mov eax, dword [ebp - 0x20]
mov edx, dword [ebp - 0x1c]
sub esp, 4
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov ecx, dword [eax + 0x24]
mov dword [esp + 0xc], 0x3c8
mov dword [esp + 0x10], ecx
mov ecx, dword [edx]
mov dword [esp + 8], ecx
movzx edx, word [edx + 0x48]
mov dword [esp + 4], edx
mov eax, dword [eax + 0x20]
mov dword [esp], eax
call sym.winmm.dll_DriverCallback
sub esp, 0x1c
mov dword [esp], ebx
call sym.winmm.dll_midiOutClose
sub esp, 4
lea esp, [ebp - 0x10]
pop ecx
pop ebx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret 4
mov edx, dword [ebp - 0x20]
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov ecx, dword [edx + 0x24]
mov dword [esp + 0xc], 0x3c8
mov dword [esp + 0x10], ecx
mov ecx, dword [eax]
mov dword [esp + 8], ecx
movzx eax, word [eax + 0x48]
mov dword [esp + 4], eax
mov eax, dword [edx + 0x20]
mov dword [esp], eax
call sym.winmm.dll_DriverCallback
sub esp, 0x1c
jmp 0x6f259505
mov dword [esp + 0xc], str.leak_from_call_within_function_callback_n
mov dword [esp + 8], str.midiStreamClose
mov dword [esp + 4], 0x6f266648
mov dword [esp], 0
call sym._wine_dbg_log.constprop.0_8
mov eax, dword [ebp - 0x1c]
mov edx, dword [eax + 4]
jmp 0x6f259735
mov eax, dword [esi + 0x5c]
test eax, eax
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp - 0x30]
jne 0x6f25955f
jmp 0x6f259559
mov dword [0x6f270488], edi
jmp 0x6f259578
mov dword [ebp - 0x2c], ecx
mov edi, dword [ebp - 0x2c]
and eax, 0xfffffffe
mov dword [edi + 0xc], eax
jmp 0x6f259690
and ecx, 0xfffffffe
mov dword [eax + 0xc], ecx
mov ecx, dword [edx]
or dword [edx + 0xc], 1
mov eax, dword [edx + 4]
test ecx, ecx
je 0x6f259acd
cmp dword [ecx + 4], edx
je 0x6f259ae6
mov dword [ecx + 8], eax
mov ecx, dword [eax + 8]
mov dword [edx + 4], ecx
test ecx, ecx
je 0x6f259897
mov dword [ecx], edx
mov dword [eax + 8], edx
mov ecx, dword [edx]
mov dword [eax], ecx
mov dword [edx], eax
mov eax, dword [edx + 4]
jmp 0x6f259625
mov edx, dword [ebp - 0x34]
test edx, edx
jne 0x6f259690
mov ecx, dword [ebp - 0x2c]
mov edx, eax
jmp 0x6f2595f7
mov dword [0x6f270488], eax
jmp 0x6f2595c6
mov dword [edx + 4], edi
jmp 0x6f259578
mov edi, dword [eax + 8]
test edi, edi
je 0x6f259958
mov ecx, dword [edi + 0xc]
mov dword [ebp - 0x30], ecx
and ecx, 1
je 0x6f259958
mov ecx, dword [ebp - 0x2c]
test ecx, ecx
jne 0x6f259aa0
mov ecx, dword [ebp - 0x30]
and ecx, 0xfffffffe
mov dword [edi + 0xc], ecx
mov edi, dword [eax]
or dword [eax + 0xc], 1
mov ecx, dword [eax + 8]
test edi, edi
je 0x6f259ac2
cmp eax, dword [edi + 4]
je 0x6f259ad7
mov dword [edi + 8], ecx
mov edi, dword [ecx + 4]
mov dword [eax + 8], edi
test edi, edi
je 0x6f25992f
mov dword [edi], eax
mov dword [ecx + 4], eax
mov edi, dword [eax]
mov dword [ecx], edi
mov dword [eax], ecx
mov eax, dword [edx + 4]
jmp 0x6f25963d
mov ecx, dword [eax + 8]
test ecx, ecx
je 0x6f259958
test byte [ecx + 0xc], 1
jne 0x6f259a36
lea esi, [esi]
or dword [eax + 0xc], 1
mov eax, dword [edx]
mov ecx, edx
test eax, eax
je 0x6f259b1b
mov edx, eax
jmp 0x6f2595f7
mov dword [ecx + 4], eax
jmp 0x6f2595c6
mov eax, dword [edx + 8]
test eax, eax
je sym._midiStreamClose_4.cold
mov ecx, dword [eax + 0xc]
test cl, 1
je 0x6f2599ce
and ecx, 0xfffffffe
mov dword [eax + 0xc], ecx
mov ecx, dword [edx]
or dword [edx + 0xc], 1
mov eax, dword [edx + 8]
test ecx, ecx
je 0x6f259b01
cmp dword [ecx + 4], edx
je 0x6f259b13
mov dword [ecx + 8], eax
mov ecx, dword [eax + 4]
mov dword [edx + 8], ecx
test ecx, ecx
je 0x6f2599c2
mov dword [ecx], edx
mov dword [eax + 4], edx
mov ecx, dword [edx]
mov dword [eax], ecx
mov dword [edx], eax
mov eax, dword [edx + 8]
mov ecx, dword [eax + 4]
test ecx, ecx
je 0x6f259940
mov edi, dword [ecx + 0xc]
test edi, 1
je 0x6f259940
mov dword [ebp - 0x2c], ecx
mov ecx, dword [eax + 8]
test ecx, ecx
je 0x6f2599f8
test byte [ecx + 0xc], 1
jne 0x6f259a36
mov ecx, dword [ebp - 0x2c]
and edi, 0xfffffffe
mov dword [ecx + 0xc], edi
mov edi, dword [eax]
or dword [eax + 0xc], 1
mov ecx, dword [eax + 4]
test edi, edi
je 0x6f259af6
cmp eax, dword [edi + 4]
je 0x6f259b0b
mov dword [edi + 8], ecx
mov edi, dword [ecx + 8]
mov dword [eax + 4], edi
test edi, edi
je 0x6f259a2a
mov dword [edi], eax
mov dword [ecx + 8], eax
mov edi, dword [eax]
mov dword [ecx], edi
mov dword [eax], ecx
mov eax, dword [edx + 8]
mov ecx, dword [eax + 0xc]
mov edi, dword [edx + 0xc]
and ecx, 0xfffffffe
and edi, 1
or ecx, edi
mov dword [eax + 0xc], ecx
and dword [edx + 0xc], 0xfffffffe
mov eax, dword [eax + 8]
test eax, eax
je 0x6f259a56
and dword [eax + 0xc], 0xfffffffe
mov ecx, dword [edx]
mov eax, dword [edx + 8]
test ecx, ecx
je 0x6f259adf
cmp dword [ecx + 4], edx
je 0x6f259aee
mov dword [ecx + 8], eax
mov ecx, dword [eax + 4]
mov dword [edx + 8], ecx
test ecx, ecx
je 0x6f259a7b
mov dword [ecx], edx
mov dword [eax + 4], edx
mov ecx, dword [edx]
mov dword [eax], ecx
mov dword [edx], eax
jmp 0x6f259690
mov ecx, dword [ebp - 0x2c]
test ecx, ecx
je 0x6f259690
mov eax, dword [ebp - 0x2c]
mov eax, dword [eax + 0xc]
jmp 0x6f259853
test byte [ecx + 0xc], 1
je 0x6f2598fd
jmp 0x6f25963d
mov dword [0x6f270488], eax
jmp 0x6f259676
mov dword [ecx + 4], eax
jmp 0x6f259676
mov dword [0x6f270488], ecx
jmp 0x6f259923
mov dword [0x6f270488], eax
jmp 0x6f25988b
mov dword [edi + 4], ecx
jmp 0x6f259923
mov dword [0x6f270488], eax
jmp 0x6f259a6f
mov dword [ecx + 4], eax
jmp 0x6f25988b
mov dword [ecx + 4], eax
jmp 0x6f259a6f
mov dword [0x6f270488], ecx
jmp 0x6f259a1e
mov dword [0x6f270488], eax
jmp 0x6f2599b6
mov dword [edi + 4], ecx
jmp 0x6f259a1e
mov dword [ecx + 4], eax
jmp 0x6f2599b6
mov dword [ebp - 0x2c], edx
mov eax, dword [edx + 0xc]
jmp 0x6f259853
mov eax, dword [4]
ud2