Function at 0x10137887
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x4a0
mov eax, dword [0x101b9540]
push ebp
mov ebp, ecx
mov dword [esp + reloc.WINMM.dll_midiStreamOut], eax
mov eax, dword [ebp + 0x14]
test eax, eax
je 0x101378be
mov eax, 0x40000
pop ebp
mov ecx, dword [esp + reloc.WINMM.dll_midiStreamOut]
call fcn.101a6cf4
add esp, 0x4a0
ret 0x10
mov al, byte [ebp + 0x2c]
test al, al
je 0x101378e0
mov eax, 0x50000
pop ebp
mov ecx, dword [esp + reloc.WINMM.dll_midiStreamOut]
call fcn.101a6cf4
add esp, 0x4a0
ret 0x10
cmp dword [ebp], 0
push esi
mov esi, dword [esp + reloc.WINMM.dll_midiStreamOut]
mov dword [esp + 0x10], 0
je 0x10137903
cmp esi, 4
je 0x10137903
mov dword [esp + 0x10], 0xc
mov eax, dword [esp + reloc.WINMM.dll_midiStreamOut]
lea edx, reloc.WINMM.dll_midiStreamOut
sub edx, eax
lea esp, [esp]
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x10137917
mov al, byte [esp + 0x3a0]
test al, al
jne 0x10137948
pop esi
mov eax, 0x10000
pop ebp
mov ecx, dword [esp + reloc.WINMM.dll_midiStreamOut]
call fcn.101a6cf4
add esp, 0x4a0
ret 0x10
lea eax, reloc.WINMM.dll_midiStreamOut
cmp byte [eax], 0x5c
jne 0x10137957
mov byte [eax], 0x2f
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x1013794f
cmp esi, 4
sete al
test al, al
push ebx
mov byte [esp + 0xf], al
je 0x1013798f
lea eax, reloc.WINMM.dll_midiStreamOut
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x10137978
sub eax, edx
cmp byte [esp + eax + 0x3a3], 0x2f
je 0x1013798f
mov bl, 1
jmp 0x10137991
xor bl, bl
mov al, byte [esp + 0xf]
test al, al
push edi
mov edi, 8
mov dword [esp + 0x14], edi
jne 0x101379b7
lea eax, reloc.WINMM.dll_midiStreamOut
push eax
call fcn.10135607
add esp, 4
test al, al
je 0x101379bd
xor edi, edi
mov dword [esp + 0x14], edi
cmp esi, 2
jne 0x101379d3
mov ecx, dword [esp + reloc.WINMM.dll_midiStreamOut]
push ecx
mov ecx, ebp
call fcn.10136a37
jmp 0x10137a1f
cmp esi, 1
jne 0x101379f1
mov edx, dword [esp + reloc.WINMM.dll_midiStreamOut]
mov eax, dword [esp + reloc.WINMM.dll_midiStreamOut]
push edx
push eax
mov ecx, ebp
call fcn.10135c97
jmp 0x10137a1f
cmp esi, 3
jne 0x10137a0f
mov ecx, dword [esp + reloc.WINMM.dll_midiStreamOut]
mov edx, dword [esp + reloc.WINMM.dll_midiStreamOut]
push ecx
push edx
mov ecx, ebp
call fcn.10135de7
jmp 0x10137a1f
cmp esi, 4
jne 0x10137f51
mov ecx, ebp
call fcn.10135ed7
xor esi, esi
cmp eax, esi
jne 0x10137f56
mov dword [esp + reloc.WINMM.dll_midiStreamOut], esi
mov byte [esp + 0x80], 0
xor eax, eax
jmp 0x10137a47
mov cl, byte [esp + eax + 0x3a8]
mov byte [esp + eax + 0x190], cl
inc eax
test cl, cl
jne 0x10137a47
lea eax, reloc.WINMM.dll_midiStreamOut
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x10137a67
sub eax, edx
test bl, bl
mov dword [esp + 0x60], eax
je 0x10137aa7
lea edi, reloc.WINMM.dll_midiStreamOut
dec edi
lea esp, [esp]
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x10137a87
mov ax, word [0x10169308]
mov word [edi], ax
mov eax, dword [esp + 0x60]
mov edi, dword [esp + 0x14]
inc eax
mov dword [esp + 0x60], eax
xor esi, esi
mov ecx, dword [ebp + 0x68]
mov dword [esp + 0x50], ecx
cmp dword [ebp], esi
mov ax, 8
mov byte [esp + 0x294], 0
mov dword [esp + reloc.WINMM.dll_midiStreamOut], esi
mov dword [esp + 0x6c], esi
mov dword [esp + reloc.WINMM.dll_midiStreamOut], 1
mov dword [esp + reloc.WINMM.dll_midiStreamOut], esi
mov word [esp + 0x72], si
mov word [esp + 0x48], 0xb17
mov word [esp + 0x4a], 0x14
mov dword [esp + 0x54], esi
mov word [esp + 0x4c], ax
je 0x10137b09
mov cl, byte [esp + 0x13]
test cl, cl
jne 0x10137b09
mov ax, 9
mov word [esp + 0x4c], ax
cmp edi, esi
mov word [esp + 0x74], ax
mov word [esp + 0x4e], di
jne 0x10137b2a
mov eax, dword [ebp + 0x70]
cmp eax, esi
jl 0x10137b2a
mov edx, dword [esp + 0x18]
add eax, edx
mov dword [esp + 0x58], eax
jmp 0x10137b2e
mov dword [esp + 0x58], esi
mov eax, dword [ebp + 0x70]
mov edx, dword [ebp + 0x10]
mov ecx, dword [ebp + 0x4c]
mov esi, dword [ebp + 0x58]
mov edi, dword [ebp + 0x5c]
mov dword [esp + 0x5c], eax
add edx, dword [ebp + 0x18]
mov dword [esp + 0x78], ecx
mov dword [esp + 0x7c], edx
mov dl, byte [ebp + 0x58]
lea ecx, [esp + 0x30]
lea eax, [esp + 0x1c]
mov dword [esp + reloc.WINMM.dll_midiStreamOut], eax
mov dword [esp + reloc.WINMM.dll_midiStreamOut], ecx
mov byte [esp + 0x21], dl
mov eax, esi
mov edx, edi
mov cl, 8
mov word [esp + 0x70], 0
mov dword [esp + 0x64], 0x11
mov dword [esp + 0x68], 9
mov byte [esp + 0x1c], 0x55
mov byte [esp + 0x1d], 0x54
mov byte [esp + 0x1e], 0xd
mov byte [esp + 0x1f], 0
mov byte [esp + 0x20], 7
call fcn.101aa287
mov byte [esp + 0x22], al
mov eax, esi
mov edx, edi
mov cl, 0x10
call fcn.101aa287
mov byte [esp + 0x23], al
mov eax, esi
mov edx, edi
mov cl, 0x18
call fcn.101aa287
mov esi, dword [ebp + 0x50]
mov edi, dword [ebp + 0x54]
mov bl, al
mov al, byte [ebp + 0x50]
mov byte [esp + 0x25], al
mov eax, esi
mov edx, edi
mov cl, 8
mov byte [esp + 0x24], bl
call fcn.101aa287
mov byte [esp + 0x26], al
mov eax, esi
mov edx, edi
mov cl, 0x10
call fcn.101aa287
mov byte [esp + 0x27], al
mov eax, esi
mov edx, edi
mov cl, 0x18
call fcn.101aa287
mov cl, byte [ebp + 0x60]
mov esi, dword [ebp + 0x60]
mov edi, dword [ebp + 0x64]
mov byte [esp + 0x28], al
mov byte [esp + 0x29], cl
mov eax, esi
mov edx, edi
mov cl, 8
call fcn.101aa287
mov byte [esp + 0x2a], al
mov eax, esi
mov edx, edi
mov cl, 0x10
call fcn.101aa287
mov byte [esp + 0x2b], al
mov eax, esi
mov edx, edi
mov cl, 0x18
call fcn.101aa287
mov edx, dword [esp + 0x1c]
mov byte [esp + 0x2c], al
mov eax, dword [esp + 0x20]
mov dword [esp + 0x30], edx
push ebp
lea ecx, [esp + 0x4c]
push 0x10090ad0
push ecx
mov dword [esp + 0x40], eax
mov byte [esp + 0x44], bl
mov byte [esp + 0x3e], 5
call fcn.10134b17
add esp, 0xc
test eax, eax
je 0x10137c7d
mov ecx, ebp
call fcn.10136077
mov eax, 0x400
jmp 0x10137f56
mov edx, dword [esp + 0x60]
mov eax, dword [esp + 0x64]
lea ecx, [eax + edx + 0x1e]
mov edx, dword [ebp + 0x18]
mov eax, dword [ebp + 0x14]
add edx, ecx
test eax, eax
mov dword [ebp + 0x18], edx
je 0x10137ca7
mov ecx, ebp
call fcn.10136077
mov eax, dword [ebp + 0x14]
jmp 0x10137f56
mov esi, dword [ebp]
test esi, esi
lea edi, [ebp + 0x30]
mov dword [edi], reloc.WINMM.dll_midiStreamOut
mov dword [ebp + 0x34], 0x23456789
mov dword [ebp + 0x38], 0x34567890
je 0x10137cdc
mov edi, edi
xor eax, eax
mov al, byte [esi]
test al, al
je 0x10137cdc
push eax
push edi
call fcn.10135527
add esp, 8
inc esi
jne 0x10137cc7
mov al, byte [0x101c83b8]
test al, al
jne 0x10137cfe
call dword [fcn.10167544]
mov esi, eax
call dword [fcn.101673c8]
xor esi, eax
push esi
call fcn.101aa251
add esp, 4
xor esi, esi
lea esp, [esp]
call fcn.101aa25e
sar eax, 7
mov byte [esp + esi + 0x3c], al
inc esi
cmp esi, 0xc
jl 0x10137d07
mov edx, dword [esp + 0x50]
shr edx, 8
mov byte [esp + 0x47], dl
xor esi, esi
nop
xor eax, eax
mov al, byte [esp + esi + 0x3c]
push eax
push edi
call fcn.10135587
add esp, 8
mov byte [esp + esi + 0x3c], al
inc esi
cmp esi, 0xc
jl 0x10137d27
cmp dword [ebp], 0
mov bl, byte [esp + 0x13]
je 0x10137d61
test bl, bl
jne 0x10137d61
push 0xc
lea ecx, [esp + 0x40]
push ecx
mov ecx, ebp
call fcn.10135b17
add dword [ebp + 0x18], 0xc
mov eax, dword [ebp]
xor esi, esi
cmp eax, esi
je 0x10137d75
test bl, bl
jne 0x10137d75
mov eax, 1
jmp 0x10137d77
xor eax, eax
test bl, bl
mov edi, dword [esp + 0x14]
mov byte [ebp + 0x2d], al
jne 0x10137da6
cmp edi, 8
jne 0x10137d97
lea edx, [esp + 0x48]
push edx
mov ecx, ebp
call fcn.10137777
mov esi, eax
jmp 0x10137dac
cmp edi, esi
jne 0x10137dac
mov ecx, ebp
call fcn.101360d7
mov esi, eax
jmp 0x10137dac
mov dword [ebp + 0x90], esi
mov al, byte [ebp + 0x80]
test al, al
mov byte [ebp + 0x2d], 0
je 0x10137dc8
mov eax, dword [ebp + 0x7c]
test eax, eax
je 0x10137dc8
push eax
call dword [fcn.101673b0]
mov eax, dword [ebp + 0x18]
mov edx, dword [ebp + 0x90]
mov ecx, dword [ebp + 0x74]
add eax, edx
mov dword [ebp + 0x18], eax
mov eax, dword [ebp + 0x14]
test eax, eax
mov dword [ebp + 0x7c], 0
mov dword [ebp + 0x70], ecx
jne 0x10137f56
test esi, esi
jne 0x10137c73
mov eax, dword [esp + 0x18]
mov esi, dword [ebp + 0x78]
add eax, edx
cmp dword [esp + 0x58], eax
mov dword [esp + 0x58], eax
mov al, byte [ebp + 0x1c]
sete dl
test al, al
mov dword [esp + 0x54], esi
mov dword [esp + 0x5c], ecx
je 0x10137e85
cmp dword [ebp], 0
je 0x10137e23
test bl, bl
je 0x10137e85
test byte [esp + 0x4c], 1
mov word [esp + 0x4e], di
jne 0x10137e34
and byte [esp + 0x4c], 0xf7
mov cx, word [esp + 0x4c]
mov edx, dword [esp + 0x7c]
sub edx, dword [ebp + 0x10]
mov word [esp + 0x74], cx
push edx
mov ecx, ebp
call fcn.10135c27
test al, al
je 0x10137e7b
push ebp
lea eax, [esp + 0x4c]
push 0x10090ad0
push eax
call fcn.10134b17
add esp, 0xc
test eax, eax
jne 0x10137c73
mov ecx, dword [ebp + 0x18]
push ecx
mov ecx, ebp
call fcn.10135c27
test al, al
jne 0x10137ec7
mov eax, 0x2000000
jmp 0x10137f56
cmp word [esp + 0x4e], di
je 0x10137e96
mov eax, 0x4000000
jmp 0x10137f56
test edi, edi
jne 0x10137e9e
test dl, dl
je 0x10137e8c
push ebp
lea edx, [esp + 0x4c]
push 0x10090ad0
push edx
call fcn.10134d77
add esp, 0xc
test eax, eax
jne 0x10137c73
add dword [ebp + 0x18], 0x10
mov ax, word [esp + 0x74]
mov word [esp + 0x4c], ax
mov eax, dword [ebp + 0x14]
test eax, eax
jne 0x10137f56
mov ecx, dword [esp + 0x68]
push ecx
call fcn.101f81ff
mov ecx, dword [esp + 0x6c]
mov esi, dword [esp + reloc.WINMM.dll_midiStreamOut]
mov edx, ecx
shr ecx, 2
mov edi, eax
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push 0x360
mov dword [esp + reloc.WINMM.dll_midiStreamOut], eax
call fcn.101f81cf
mov ecx, 0xd8
lea esi, [esp + 0x50]
mov edi, eax
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp + 0x44]
add esp, 8
test ecx, ecx
jne 0x10137f26
mov dword [ebp + 0x44], eax
xor eax, eax
jmp 0x10137f56
mov edx, dword [ecx + reloc.WINMM.dll_midiStreamOut]
test edx, edx
je 0x10137f47
lea esp, [esp]
mov ecx, dword [ecx + reloc.WINMM.dll_midiStreamOut]
mov edx, dword [ecx + reloc.WINMM.dll_midiStreamOut]
test edx, edx
jne 0x10137f37
mov dword [ecx + reloc.WINMM.dll_midiStreamOut], eax
xor eax, eax
jmp 0x10137f56
mov eax, 0x10000
mov ecx, dword [esp + reloc.WINMM.dll_midiStreamOut]
pop edi
pop ebx
pop esi
pop ebp
call fcn.101a6cf4
add esp, 0x4a0
ret 0x10