Function at 0x40d010
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
mov esi, eax
lea eax, [ebp - 0x17c]
push ebx
sub esp, 0x1c4
mov dword [ebp - 0x188], edx
mov dword [esp + 8], eax
mov dword [esp + 4], edx
mov dword [esp], esi
mov dword [ebp - 0x17c], 0
call sym._GetItemPath
test eax, eax
je 0x40d150
mov ebx, eax
mov eax, dword [ebp - 0x17c]
test eax, eax
je 0x40d150
cmp word [ebx], 0
jne 0x40d160
mov dword [ebp - 0x178], eax
mov eax, dword [sym.imp.ucrtbase.dll_free]
mov dword [esp], ebx
mov dword [ebp - 0x18c], eax
call eax
lea eax, [ebp - 0x16c]
mov dword [esp + 0x2c], 0
mov dword [esp + 0x14], eax
lea eax, [ebp - 0x170]
mov dword [esp + 0x10], eax
mov eax, dword [ebp - 0x178]
mov dword [esp + 0x28], 0
mov dword [esp], eax
mov eax, dword [sym.imp.advapi32.dll_RegQueryInfoKeyW]
mov dword [esp + 0x24], 0
mov dword [esp + 0x20], 0
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [ebp - 0x190], eax
call eax
sub esp, 0x30
test eax, eax
jne 0x40d150
mov eax, dword [ebp - 0x170]
mov ebx, dword [ebp - 0x188]
mov dword [esp], esi
mov dword [esp + 8], 0
mov edi, dword [0x4166fc]
mov dword [ebp - 0x140], eax
lea eax, [ebp - 0x160]
mov dword [ebp - 0x160], 0x40
mov dword [ebp - 0x15c], ebx
mov dword [esp + 0xc], eax
mov dword [esp + 4], 0x113f
call edi
sub esp, 0x10
test eax, eax
jne 0x40d270
mov esi, esi
lea edi, [edi]
xor eax, eax
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
lea edx, [ebp - 0x178]
mov dword [esp + 0xc], 0x20019
mov dword [esp + 0x10], edx
mov dword [esp + 8], 0
mov dword [esp + 4], ebx
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegOpenKeyExW]
sub esp, 0x14
test eax, eax
je 0x40d06c
test byte [0x4102e4], 8
je 0x40d150
mov eax, ebx
shr eax, 0x10
je 0x40d959
mov dword [esp + 4], 0xffffffff
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, str._invalid_
sub esp, 8
test eax, eax
jne 0x40d79a
cmp word [ebx], 0
je 0x40d9a5
lea esi, [esi]
mov edx, eax
lea eax, [eax + 1]
cmp word [ebx + edx*2 + 2], 0
jne 0x40d1d8
mov ecx, 0x224c
lea esi, [ebp - 0x136]
lea edi, [ebp - 0x16]
mov word [ebp - 0x138], cx
jmp 0x40d235
cmp ax, 9
je 0x40d830
cmp ax, 0xa
jne 0x40d84e
mov eax, 0x6e5c
add esi, 2
mov word [esi - 2], ax
lea eax, [edx - 1]
cmp esi, edi
ja 0x40d76c
test edx, edx
jle 0x40d76c
mov edx, eax
movzx eax, word [ebx]
add ebx, 2
cmp ax, 0xd
je 0x40d8b1
jbe 0x40d200
cmp ax, 0x22
je 0x40d8a0
cmp ax, 0x5c
jne 0x40d841
mov eax, 0x5c5c
add esi, 2
mov word [esi - 2], ax
jmp 0x40d220
mov dword [esp + 0xc], 0x20
mov dword [esp + 8], ebx
mov dword [esp + 4], 0x1127
mov dword [esp], esi
call edi
sub esp, 0x10
test eax, eax
je 0x40d678
mov eax, dword [ebp - 0x16c]
mov edx, dword [sym.imp.ucrtbase.dll_malloc]
lea ebx, [eax + 1]
mov dword [ebp - 0x184], edx
lea ecx, [ebx + ebx]
mov dword [ebp - 0x16c], ebx
mov dword [esp], ecx
mov dword [ebp - 0x194], ecx
call edx
mov ecx, dword [ebp - 0x194]
mov dword [ebp - 0x14c], ebx
mov dword [ebp - 0x180], eax
mov edx, dword [ebp - 0x184]
mov dword [esp], ecx
call edx
mov ecx, dword [ebp - 0x170]
mov dword [ebp - 0x150], eax
test ecx, ecx
je 0x40d69e
mov dword [ebp - 0x184], 0
mov eax, dword [ebp - 0x180]
shr eax, 0x10
mov dword [ebp - 0x198], eax
mov eax, ebx
jmp 0x40d32f
add dword [ebp - 0x184], 1
mov eax, dword [ebp - 0x184]
cmp dword [ebp - 0x170], eax
jbe 0x40d698
mov eax, dword [ebp - 0x16c]
mov dword [ebp - 0x168], eax
lea eax, [ebp - 0x168]
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x180]
mov dword [esp + 0x1c], 0
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x184]
mov dword [esp + 0x18], 0
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x178]
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegEnumKeyExW]
sub esp, 0x20
test eax, eax
jne 0x40d310
lea eax, [ebp - 0x174]
mov dword [esp + 0xc], 1
mov dword [esp + 0x10], eax
mov eax, dword [ebp - 0x180]
mov dword [ebp - 0x164], 0
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x178]
mov dword [esp + 8], 0
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegOpenKeyExW]
sub esp, 0x14
test eax, eax
je 0x40d4d0
mov eax, dword [ebp - 0x188]
mov dword [esp + 8], 4
mov dword [esp + 0xc], eax
jmp 0x40d452
mov dword [ebp - 0x15c], eax
lea eax, [ebp - 0x160]
mov dword [ebp - 0x160], 1
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], 0x113e
mov dword [esp], esi
call edi
sub esp, 0x10
test eax, eax
je 0x40d4a0
mov eax, dword [ebp - 0x180]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x150]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_lstrcmpiW]
sub esp, 8
test eax, eax
je 0x40d310
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 1
mov dword [esp + 4], 0x110a
mov dword [esp], esi
call edi
sub esp, 0x10
mov ebx, eax
test eax, eax
jne 0x40d3e8
test byte [0x4102e4], 8
jne 0x40d568
mov eax, dword [ebp - 0x164]
mov dword [esp], 0
mov ecx, dword [ebp - 0x180]
mov edx, dword [ebp - 0x188]
mov dword [esp + 4], eax
mov eax, esi
call sym._AddEntryToTree
jmp 0x40d310
mov dword [ebp - 0x184], eax
mov eax, dword [ebp - 0x180]
mov edi, dword [ebp - 0x18c]
mov dword [esp], eax
call edi
mov edx, dword [ebp - 0x150]
mov dword [esp], edx
call edi
mov eax, dword [ebp - 0x184]
jmp 0x40d152
lea eax, [ebp - 0x164]
mov dword [esp + 0x2c], 0
mov dword [esp + 0x10], eax
mov eax, dword [ebp - 0x174]
mov dword [esp + 0x28], 0
mov dword [esp], eax
mov eax, dword [ebp - 0x190]
mov dword [esp + 0x24], 0
mov dword [esp + 0x20], 0
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
call eax
sub esp, 0x30
test eax, eax
je 0x40d54c
mov dword [ebp - 0x164], 0
mov eax, dword [ebp - 0x174]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
sub esp, 4
jmp 0x40d3d1
mov edx, dword [ebp - 0x180]
test edx, edx
je 0x40d9c3
mov eax, dword [ebp - 0x198]
test eax, eax
je 0x40d97d
mov ebx, dword [ebp - 0x180]
mov dword [esp + 4], 0xffffffff
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, str._invalid_
sub esp, 8
test eax, eax
jne 0x40d801
cmp word [ebx], 0
je 0x40d9cd
mov ecx, ebx
mov esi, esi
lea edi, [edi]
mov edx, eax
lea eax, [eax + 1]
cmp word [ecx + edx*2 + 2], 0
jne 0x40d5c0
mov eax, 0x224c
mov ebx, dword [ebp - 0x180]
mov dword [ebp - 0x19c], esi
lea ecx, [ebp - 0x136]
mov word [ebp - 0x138], ax
lea eax, [ebp - 0x16]
mov dword [ebp - 0x194], ebx
mov esi, eax
mov dword [ebp - 0x1a0], edi
jmp 0x40d635
cmp ax, 9
je 0x40d948
cmp ax, 0xa
jne 0x40d8cf
mov eax, 0x6e5c
add ecx, 2
mov word [ecx - 2], ax
lea eax, [edx - 1]
cmp ecx, esi
ja 0x40d7c7
test edx, edx
jle 0x40d7c7
mov edx, eax
add dword [ebp - 0x194], 2
mov eax, dword [ebp - 0x194]
movzx eax, word [eax - 2]
cmp ax, 0xd
je 0x40d931
jbe 0x40d600
cmp ax, 0x22
je 0x40d920
cmp ax, 0x5c
jne 0x40d8c2
mov edi, 0x5c5c
add ecx, 2
mov word [ecx - 2], di
jmp 0x40d620
mov eax, dword [ebp - 0x178]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
mov eax, 1
sub esp, 4
jmp 0x40d152
mov eax, dword [ebp - 0x150]
mov dword [ebp - 0x184], eax
mov eax, dword [ebp - 0x180]
mov ebx, dword [ebp - 0x18c]
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x184]
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x178]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
mov eax, dword [ebp - 0x188]
sub esp, 4
mov dword [esp + 0xc], eax
mov dword [esp + 8], 4
mov dword [esp + 4], 0x110a
mov dword [esp], esi
call edi
sub esp, 0x10
test eax, eax
je 0x40d737
mov dword [ebp - 0x180], edi
mov edi, eax
mov dword [esp + 0xc], edi
mov ebx, edi
mov eax, dword [ebp - 0x180]
mov dword [esp + 8], 1
mov dword [esp + 4], 0x110a
mov dword [esp], esi
call eax
mov edx, ebx
sub esp, 0x10
mov edi, eax
mov eax, esi
call sym._RefreshTreeItem
test eax, eax
je 0x40d748
test edi, edi
jne 0x40d700
mov eax, 1
jmp 0x40d152
mov dword [esp + 0xc], ebx
mov eax, dword [ebp - 0x180]
mov dword [esp + 8], 0
mov dword [esp + 4], 0x1101
mov dword [esp], esi
call eax
sub esp, 0x10
jmp 0x40d733
mov byte [esi], 0x22
test eax, eax
jle 0x40d9bb
mov ebx, 0x2e2e
mov byte [esi + 3], 0x2e
lea eax, [esi + 4]
mov word [esi + 1], bx
mov byte [eax], 0
lea eax, [ebp - 0x138]
mov dword [esp], eax
call sym.___wine_dbg_strdup
mov edx, eax
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], str.RegOpenKeyEx_failed___s_was_probably_removed._n
mov dword [esp + 8], 0x411eb8
mov dword [esp + 4], 0x4102e4
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_4
jmp 0x40d150
mov esi, dword [ebp - 0x19c]
mov edi, dword [ebp - 0x1a0]
mov byte [ecx], 0x22
test eax, eax
jle 0x40d9e3
mov ebx, 0x2e2e
mov byte [ecx + 3], 0x2e
lea eax, [ecx + 4]
mov word [ecx + 1], bx
mov byte [eax], 0
lea eax, [ebp - 0x138]
mov dword [esp], eax
call sym.___wine_dbg_strdup
mov edx, eax
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], str.New_subkey__s_n
mov dword [esp + 8], 0x411eb8
mov dword [esp + 4], 0x4102e4
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_4
jmp 0x40d475
mov eax, 0x745c
add esi, 2
mov word [esi - 2], ax
jmp 0x40d220
lea ecx, [eax - 0x20]
cmp cx, 0x5e
jbe 0x40d973
mov ecx, eax
mov byte [esi], 0x5c
add esi, 5
shr cx, 0xc
movzx ecx, cx
movzx ecx, byte [ecx + str.0123456789abcdefRefreshTreeItem]
mov byte [esi - 4], cl
mov ecx, eax
shr cx, 8
and ecx, 0xf
movzx ecx, byte [ecx + str.0123456789abcdefRefreshTreeItem]
mov byte [esi - 3], cl
mov ecx, eax
and eax, 0xf
shr cx, 4
movzx eax, byte [eax + str.0123456789abcdefRefreshTreeItem]
and ecx, 0xf
movzx ecx, byte [ecx + str.0123456789abcdefRefreshTreeItem]
mov byte [esi - 1], al
mov byte [esi - 2], cl
jmp 0x40d220
mov eax, 0x225c
add esi, 2
mov word [esi - 2], ax
jmp 0x40d220
mov eax, 0x725c
add esi, 2
mov word [esi - 2], ax
jmp 0x40d220
lea edi, [eax - 0x20]
cmp di, 0x5e
jbe 0x40d99b
mov edi, eax
mov byte [ecx], 0x5c
add ecx, 5
shr di, 0xc
movzx edi, di
movzx ebx, byte [edi + str.0123456789abcdefRefreshTreeItem]
mov edi, eax
shr di, 8
and edi, 0xf
mov byte [ecx - 4], bl
movzx ebx, byte [edi + str.0123456789abcdefRefreshTreeItem]
mov edi, eax
and eax, 0xf
shr di, 4
movzx eax, byte [eax + str.0123456789abcdefRefreshTreeItem]
and edi, 0xf
mov byte [ecx - 3], bl
movzx ebx, byte [edi + str.0123456789abcdefRefreshTreeItem]
mov byte [ecx - 1], al
mov byte [ecx - 2], bl
jmp 0x40d620
mov eax, 0x225c
add ecx, 2
mov word [ecx - 2], ax
jmp 0x40d620
mov eax, 0x725c
add ecx, 2
mov word [ecx - 2], ax
jmp 0x40d620
mov eax, 0x745c
add ecx, 2
mov word [ecx - 2], ax
jmp 0x40d620
movzx ebx, bx
mov dword [esp], str._04x
mov dword [esp + 4], ebx
call sym._wine_dbg_sprintf.constprop.0_2
mov edx, eax
jmp 0x40d79a
mov byte [esi], al
add esi, 1
jmp 0x40d220
movzx eax, word [ebp - 0x180]
mov dword [esp], str._04x
mov dword [esp + 4], eax
call sym._wine_dbg_sprintf.constprop.0_2
mov edx, eax
jmp 0x40d801
mov byte [ecx], al
add ecx, 1
jmp 0x40d620
mov word [ebp - 0x138], 0x224c
lea esi, [ebp - 0x136]
mov byte [ebp - 0x136], 0x22
lea eax, [esi + 1]
jmp 0x40d787
mov edx, str._null_
jmp 0x40d801
mov word [ebp - 0x138], 0x224c
lea ecx, [ebp - 0x136]
mov byte [ebp - 0x136], 0x22
lea eax, [ecx + 1]
jmp 0x40d7ee