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
lea esi, [esi]
nop
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 0x40d969
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 0x40d7a2
cmp word [ebx], 0
je 0x40d9b3
lea esi, [esi]
mov edx, eax
lea eax, [eax + 1]
cmp word [ebx + edx*2 + 2], 0
jne 0x40d1d8
mov eax, 0x224c
lea esi, [ebp - 0x136]
lea edi, [ebp - 0x16]
mov word [ebp - 0x138], ax
jmp 0x40d235
cmp ax, 9
je 0x40d838
cmp ax, 0xa
jne 0x40d856
mov eax, 0x6e5c
add esi, 2
mov word [esi - 2], ax
lea eax, [edx - 1]
cmp esi, edi
ja 0x40d774
test edx, edx
jle 0x40d774
mov edx, eax
movzx eax, word [ebx]
add ebx, 2
cmp ax, 0xd
je 0x40d8c1
jbe 0x40d200
cmp ax, 0x22
je 0x40d8b0
cmp ax, 0x5c
jne 0x40d849
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 0x40d680
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 edx, dword [ebp - 0x184]
mov dword [ebp - 0x14c], ebx
mov dword [ebp - 0x180], eax
mov dword [esp], ecx
call edx
mov edx, dword [ebp - 0x170]
mov dword [ebp - 0x150], eax
test edx, edx
je 0x40d6a6
mov dword [ebp - 0x184], 0
mov eax, dword [ebp - 0x180]
shr eax, 0x10
mov dword [ebp - 0x194], eax
mov eax, ebx
jmp 0x40d32f
add dword [ebp - 0x184], 1
mov eax, dword [ebp - 0x184]
cmp dword [ebp - 0x170], eax
jbe 0x40d6a0
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 ebx, dword [ebp - 0x180]
test ebx, ebx
je 0x40d9d1
mov ecx, dword [ebp - 0x194]
test ecx, ecx
je 0x40d98d
mov ebx, dword [ebp - 0x180]
mov dword [esp + 4], 0xffffffff
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov ecx, eax
sub esp, 8
mov eax, str._invalid_
test ecx, ecx
jne 0x40d807
movzx eax, word [ebx]
test ax, ax
je 0x40d9db
lea esi, [esi]
mov edx, ecx
lea ecx, [ecx + 1]
cmp word [ebx + edx*2 + 2], 0
jne 0x40d5c0
mov dword [ebp - 0x198], edx
mov ebx, dword [ebp - 0x180]
mov edx, 0x224c
lea ecx, [ebp - 0x136]
mov word [ebp - 0x138], dx
lea edx, [ebp - 0x16]
mov dword [ebp - 0x19c], edx
mov edx, dword [ebp - 0x198]
mov dword [ebp - 0x1a0], edi
mov edi, dword [ebp - 0x19c]
mov dword [ebp - 0x198], esi
mov esi, ebx
jmp 0x40d648
cmp ax, 9
je 0x40d958
cmp ax, 0xa
jne 0x40d8df
mov eax, 0x6e5c
add ecx, 2
mov word [ecx - 2], ax
lea ebx, [edx - 1]
cmp ecx, edi
ja 0x40d7cf
test edx, edx
jle 0x40d7cf
movzx eax, word [esi]
mov edx, ebx
add esi, 2
cmp ax, 0xd
je 0x40d941
jbe 0x40d610
cmp ax, 0x22
je 0x40d930
cmp ax, 0x5c
jne 0x40d8d2
mov ebx, 0x5c5c
add ecx, 2
mov word [ecx - 2], bx
jmp 0x40d630
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 0x40d73f
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 0x40d750
test edi, edi
jne 0x40d708
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 0x40d73b
mov byte [esi], 0x22
test eax, eax
jle 0x40d9c9
mov ecx, 0x2e2e
mov byte [esi + 3], 0x2e
lea eax, [esi + 4]
mov word [esi + 1], cx
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], 0x412e98
mov dword [esp + 4], 0x4102e4
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_4
jmp 0x40d150
mov esi, dword [ebp - 0x198]
mov edi, dword [ebp - 0x1a0]
mov byte [ecx], 0x22
test ebx, ebx
jle 0x40d9f1
mov edx, 0x2e2e
mov byte [ecx + 3], 0x2e
lea eax, [ecx + 4]
mov word [ecx + 1], dx
mov byte [eax], 0
lea eax, [ebp - 0x138]
mov dword [esp], eax
call sym.___wine_dbg_strdup
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.New_subkey__s_n
mov dword [esp + 8], 0x412e98
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 0x40d983
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 ebx, [eax - 0x20]
cmp bx, 0x5e
jbe 0x40d9a9
mov ebx, eax
mov byte [ecx], 0x5c
add ecx, 5
shr bx, 0xc
movzx ebx, bx
movzx ebx, byte [ebx + str.0123456789abcdefRefreshTreeItem]
mov byte [ecx - 4], bl
mov ebx, eax
shr bx, 8
and ebx, 0xf
movzx ebx, byte [ebx + str.0123456789abcdefRefreshTreeItem]
mov byte [ecx - 3], bl
mov ebx, eax
and eax, 0xf
shr bx, 4
movzx eax, byte [eax + str.0123456789abcdefRefreshTreeItem]
and ebx, 0xf
movzx ebx, byte [ebx + str.0123456789abcdefRefreshTreeItem]
mov byte [ecx - 1], al
mov byte [ecx - 2], bl
jmp 0x40d630
mov eax, 0x225c
add ecx, 2
mov word [ecx - 2], ax
jmp 0x40d630
mov eax, 0x725c
add ecx, 2
mov word [ecx - 2], ax
jmp 0x40d630
mov eax, 0x745c
add ecx, 2
mov word [ecx - 2], ax
jmp 0x40d630
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 0x40d7a2
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
jmp 0x40d807
mov byte [ecx], al
add ecx, 1
jmp 0x40d630
mov word [ebp - 0x138], 0x224c
lea esi, [ebp - 0x136]
mov byte [ebp - 0x136], 0x22
lea eax, [esi + 1]
jmp 0x40d78f
mov eax, str._null_
jmp 0x40d807
mov word [ebp - 0x138], 0x224c
lea ecx, [ebp - 0x136]
mov byte [ebp - 0x136], 0x22
lea eax, [ecx + 1]
jmp 0x40d7f6