reg: Correctly output the default value name when querying the registry.

Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Hugh McMaster 2016-04-21 11:46:05 +00:00 committed by Alexandre Julliard
parent 9042759767
commit bde6d0490e
1 changed files with 8 additions and 1 deletions

View File

@ -554,7 +554,14 @@ static void output_value(const WCHAR *value_name, DWORD type)
WCHAR fmt[] = {' ',' ',' ',' ','%','1',0};
WCHAR newlineW[] = {'\n',0};
output_string(fmt, value_name);
if (value_name && value_name[0])
output_string(fmt, value_name);
else
{
WCHAR defval[32];
LoadStringW(GetModuleHandleW(NULL), STRING_DEFAULT_VALUE, defval, ARRAY_SIZE(defval));
output_string(fmt, defval);
}
output_string(fmt, reg_type_to_wchar(type));
output_string(newlineW);
}