Function at 0x402be0
Capabilities:
Query or enumerate registry value

Disassembly:
push 0xffffffffffffffff
push 0x407198
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xe4
push ebx
push ebp
mov ebp, ecx
push esi
push edi
mov dword [esp + 0x18], ebp
mov edi, dword [esp + 0x104]
mov eax, dword [esp + 0x10c]
xor ebx, ebx
mov dword [ebp + 0x44], edi
mov dword [esp + 0x14], ebx
mov ecx, dword [eax - 8]
xor esi, esi
cmp ecx, ebx
mov dword [esp + 0xfc], ebx
jne 0x402c3d
push str.Andrea
lea ecx, [esp + 0x110]
call sub.MFC42.DLL_CString::operator_2
lea ecx, [esp + 0x20]
mov byte [esp + 0x90], 0
push ecx
push str.SoftwareMicrosoftMultimediaSound_Mapper
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
jne 0x402cb1
mov eax, dword [ebp + 0x44]
mov dword [esp + 0x1c], 0x64
cmp eax, ebx
mov eax, str.Record
je 0x402c77
mov eax, str.Playback
lea edx, [esp + 0x1c]
lea ecx, [esp + 0x90]
push edx
lea edx, [esp + 0x2c]
push ecx
push edx
push ebx
push eax
mov eax, dword [esp + 0x34]
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov ecx, dword [esp + 0x20]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, byte [esp + 0x90]
test al, al
je 0x402cb1
mov esi, 1
cmp edi, ebx
jne 0x402e34
mov ebx, dword [esp + 0x108]
cmp ebx, 1
je 0x402d2a
test ebx, ebx
je 0x402d2a
test esi, esi
mov esi, dword [sym.imp.WINMM.dll_waveInGetDevCapsA]
je 0x402dc8
call dword [sym.imp.WINMM.dll_waveInGetNumDevs]
mov edi, eax
xor eax, eax
test edi, edi
mov dword [esp + 0x10], eax
jle 0x402dcc
mov ebp, dword [sym.imp.KERNEL32.dll_lstrcmpA]
lea edx, [esp + 0x2c]
push 0x30
push edx
push eax
call esi
lea eax, [esp + 0x90]
lea ecx, [esp + 0x34]
push eax
push ecx
call ebp
test eax, eax
je 0x402df5
mov eax, dword [esp + 0x10]
inc eax
cmp eax, edi
mov dword [esp + 0x10], eax
jl 0x402cf3
mov ebp, dword [esp + 0x18]
jmp 0x402dcc
call dword [sym.imp.WINMM.dll_waveInGetNumDevs]
mov edi, eax
xor eax, eax
test edi, edi
mov dword [esp + 0x10], eax
jle 0x402da9
mov esi, dword [sym.imp.WINMM.dll_waveInGetDevCapsA]
lea edx, [esp + 0x2c]
push 0x30
push edx
push eax
call esi
cmp ebx, 1
jne 0x402d78
push 0
lea ecx, [esp + 0x110]
call sub.MFC42.DLL_CString::GetBuffer
push eax
lea eax, [esp + 0x38]
push eax
call dword [sym.imp.MSVCRT.dll_strstr]
add esp, 8
test eax, eax
jne 0x402df9
jmp 0x402d9c
test ebx, ebx
jne 0x402d9c
push ebx
lea ecx, [esp + 0x110]
call sub.MFC42.DLL_CString::GetBuffer
lea ecx, [esp + 0x34]
push eax
push ecx
call dword [sym.imp.MSVCRT.dll_strstr]
add esp, 8
test eax, eax
je 0x402df9
mov eax, dword [esp + 0x10]
inc eax
cmp eax, edi
mov dword [esp + 0x10], eax
jl 0x402d42
lea ecx, [esp + 0x10c]
mov dword [esp + 0xfc], 0xffffffff
call sub.MFC42.DLL_CString::CString
or eax, 0xffffffff
jmp 0x402f1a
mov edi, dword [esp + 0x1c]
cmp ebx, 0xffffffff
jne 0x402deb
lea edx, [esp + 0x24]
lea eax, [esp + 0x10]
push edx
push eax
push 0x2015
push ebx
call dword [sym.imp.WINMM.dll_waveInMessage]
test eax, eax
je 0x402df9
mov dword [esp + 0x10], 0
jmp 0x402df9
mov ebp, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x2c]
push 0x30
push ecx
push edx
call esi
lea eax, [esp + 0x34]
lea ecx, [ebp + 0x5c]
push eax
call sub.MFC42.DLL_CString::operator_2
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x14]
push 0x20000000
push ecx
push edx
call dword [sym.imp.WINMM.dll_mixerGetID]
push 0x20000000
push edi
jmp 0x402ee7
mov edi, dword [sym.imp.WINMM.dll_waveOutGetDevCapsA]
cmp esi, ebx
je 0x402ea7
call dword [sym.imp.WINMM.dll_waveOutGetNumDevs]
mov esi, eax
xor eax, eax
cmp esi, ebx
mov dword [esp + 0x10], eax
jle 0x402e86
mov ebp, dword [sym.imp.KERNEL32.dll_lstrcmpA]
lea edx, [esp + 0x5c]
push 0x34
push edx
push eax
call edi
lea eax, [esp + 0x90]
lea ecx, [esp + 0x64]
push eax
push ecx
call ebp
test eax, eax
je 0x402ead
mov eax, dword [esp + 0x10]
inc eax
cmp eax, esi
mov dword [esp + 0x10], eax
jl 0x402e56
mov ebp, dword [esp + 0x18]
xor ebx, ebx
lea edx, [esp + 0x24]
lea eax, [esp + 0x10]
push edx
push eax
push 0x2015
push 0xffffffffffffffff
call dword [sym.imp.WINMM.dll_waveOutMessage]
test eax, eax
je 0x402eb1
mov dword [esp + 0x10], ebx
jmp 0x402eb1
mov esi, dword [esp + 0x1c]
jmp 0x402e86
mov ebp, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x5c]
push 0x34
push ecx
push edx
call edi
lea eax, [esp + 0x64]
lea ecx, [ebp + 0x5c]
push eax
call sub.MFC42.DLL_CString::operator_2
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x14]
push 0x10000000
push ecx
push edx
call dword [sym.imp.WINMM.dll_mixerGetID]
push 0x10000000
push esi
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x18]
push eax
push ecx
mov ecx, ebp
call fcn.00402f40
lea ecx, [esp + 0x10c]
mov dword [esp + 0x14], eax
mov dword [ebp + 0x48], eax
mov esi, eax
mov dword [esp + 0xfc], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, esi
mov ecx, dword [esp + 0xf4]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0xf0
ret 0xc