Hugh McMaster : reg: Correctly output the default value name when querying the registry.
Alexandre Julliard
julliard at wine.codeweavers.com
Fri Apr 22 09:55:14 CDT 2016
Module: wine
Branch: master
Commit: bde6d0490e77a443dcff9a82286175cb5100d5f3
URL: http://source.winehq.org/git/wine.git/?a=commit;h=bde6d0490e77a443dcff9a82286175cb5100d5f3
Author: Hugh McMaster <hugh.mcmaster at outlook.com>
Date: Thu Apr 21 11:46:05 2016 +0000
reg: Correctly output the default value name when querying the registry.
Signed-off-by: Hugh McMaster <hugh.mcmaster at outlook.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
programs/reg/reg.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/programs/reg/reg.c b/programs/reg/reg.c
index 99651f6..ff78e6c 100644
--- a/programs/reg/reg.c
+++ b/programs/reg/reg.c
@@ -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);
}
More information about the wine-cvs
mailing list