reg: Use RegCreateKeyExW() instead of RegCreateKeyW().

Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Hugh McMaster 2021-03-30 23:00:15 +11:00 committed by Alexandre Julliard
parent 08976b3ee0
commit aaf503e1de
1 changed files with 2 additions and 1 deletions

View File

@ -154,7 +154,8 @@ static int run_add(HKEY root, WCHAR *path, WCHAR *value_name, BOOL value_empty,
{
HKEY key;
if (RegCreateKeyW(root, path, &key) != ERROR_SUCCESS)
if (RegCreateKeyExW(root, path, 0, NULL, REG_OPTION_NON_VOLATILE,
KEY_READ|KEY_WRITE, NULL, &key, NULL))
{
output_message(STRING_INVALID_KEY);
return 1;