Signed-off-by: Hugh McMaster hugh.mcmaster@outlook.com --- programs/reg/add.c | 2 +- programs/reg/reg.rc | 1 + programs/reg/resource.h | 1 + 3 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/programs/reg/add.c b/programs/reg/add.c index ff209bfc0ff..db909167f30 100644 --- a/programs/reg/add.c +++ b/programs/reg/add.c @@ -157,7 +157,7 @@ static int run_add(HKEY root, WCHAR *path, WCHAR *value_name, BOOL value_empty, if (RegCreateKeyExW(root, path, 0, NULL, REG_OPTION_NON_VOLATILE, KEY_READ|KEY_WRITE, NULL, &hkey, NULL)) { - output_message(STRING_INVALID_KEY); + output_message(STRING_ACCESS_DENIED); return 1; }
diff --git a/programs/reg/reg.rc b/programs/reg/reg.rc index 021734db0a7..0f8ff4a5bc4 100644 --- a/programs/reg/reg.rc +++ b/programs/reg/reg.rc @@ -176,4 +176,5 @@ STRINGTABLE \ Access the registry using the 32-bit view.\n\n\ \ /reg:64\n\ \ Access the registry using the 64-bit view.\n\n" + STRING_ACCESS_DENIED, "reg: Unable to access or create the specified registry key\n" } diff --git a/programs/reg/resource.h b/programs/reg/resource.h index b673e21883a..b569eb41d3d 100644 --- a/programs/reg/resource.h +++ b/programs/reg/resource.h @@ -62,3 +62,4 @@ #define STRING_KEY_NONEXIST 139 #define STRING_KEY_IMPORT_FAILED 140 #define STRING_REG_VIEW_USAGE 141 +#define STRING_ACCESS_DENIED 142