[WINESYNC] reg: Only call get_long_key() when operations require it.

Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>

wine commit id 07fdd5036ca40fd4f0475583b6e410192576d804 by Hugh McMaster <hugh.mcmaster@outlook.com>
This commit is contained in:
winesync 2022-01-16 21:06:05 +01:00 committed by Thomas Csovcsity
parent 091880d29b
commit a1c74056d1
7 changed files with 18 additions and 13 deletions

View file

@ -213,11 +213,11 @@ static int run_add(HKEY root, WCHAR *path, WCHAR *value_name, BOOL value_empty,
int reg_add(int argc, WCHAR *argvW[])
{
HKEY root;
WCHAR *path, *key_name, *value_name = NULL, *type = NULL, *data = NULL, separator = '\0';
WCHAR *path, *value_name = NULL, *type = NULL, *data = NULL, separator = '\0';
BOOL value_empty = FALSE, force = FALSE;
int i;
if (!parse_registry_key(argvW[2], &root, &path, &key_name))
if (!parse_registry_key(argvW[2], &root, &path))
return 1;
for (i = 3; i < argc; i++)