ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
June 2022
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
17 participants
236 discussions
Start a n
N
ew thread
[reactos] 68/158: [WINESYNC] reg/tests: Add tests for trailing backslashes after the system key.
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=a1330dea51475c1fea47e…
commit a1330dea51475c1fea47e4945f831e65735c0aaa Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:06:06 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:32 2022 +0200 [WINESYNC] reg/tests: Add tests for trailing backslashes after the system key. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id a47829e13d639831ab9f36ba4592b840259e6f80 by Hugh McMaster <hugh.mcmaster(a)outlook.com> --- modules/rostests/winetests/reg/add.c | 8 ++++++++ sdk/tools/winesync/reg.cfg | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/modules/rostests/winetests/reg/add.c b/modules/rostests/winetests/reg/add.c index e1e7a478502..2c5a8f34ce2 100644 --- a/modules/rostests/winetests/reg/add.c +++ b/modules/rostests/winetests/reg/add.c @@ -268,6 +268,14 @@ static void test_add(void) verify_key(hkey, "keytest4"); delete_key(hkey, "keytest4"); + run_reg_exe("reg add HKCU\\ /v Value1 /t REG_SZ /d foo /f", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %d, expected 1\n", r); + todo_wine verify_reg_nonexist(HKEY_CURRENT_USER, "Value1"); + + run_reg_exe("reg add HKEY_CURRENT_USER\\ /v Value2 /t REG_SZ /d bar /f", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %d, expected 1\n", r); + todo_wine verify_reg_nonexist(HKEY_CURRENT_USER, "Value2"); + /* REG_NONE */ run_reg_exe("reg add HKCU\\" KEY_BASE " /v none0 /d deadbeef /t REG_NONE /f", &r); ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index 545c4d312fb..540e93ecac6 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: fa24d458f5d9663fbefb1eb7406961b1c6ec3def + wine: a47829e13d639831ab9f36ba4592b840259e6f80
2 years, 6 months
1
0
0
0
[reactos] 67/158: [WINESYNC] reg: Remove unneeded ternary operator in RegDeleteValueW().
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=b6ad4f3d2767da97f5b0a…
commit b6ad4f3d2767da97f5b0a76a80d1553f2baf2930 Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:06:06 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:32 2022 +0200 [WINESYNC] reg: Remove unneeded ternary operator in RegDeleteValueW(). Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id fa24d458f5d9663fbefb1eb7406961b1c6ec3def by Hugh McMaster <hugh.mcmaster(a)outlook.com> --- base/applications/cmdutils/reg/delete.c | 2 +- sdk/tools/winesync/reg.cfg | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/base/applications/cmdutils/reg/delete.c b/base/applications/cmdutils/reg/delete.c index 626fcf3b341..239bbbc672b 100644 --- a/base/applications/cmdutils/reg/delete.c +++ b/base/applications/cmdutils/reg/delete.c @@ -93,7 +93,7 @@ static int run_delete(HKEY root, WCHAR *path, WCHAR *key_name, WCHAR *value_name } else if (value_name || value_empty) { - if (RegDeleteValueW(key, value_empty ? NULL : value_name) != ERROR_SUCCESS) + if (RegDeleteValueW(key, value_name)) { RegCloseKey(key); output_message(STRING_VALUE_NONEXIST); diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index 7ad3b0831f2..545c4d312fb 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: 495d9b5fb3ab5bab885f9fe80cd6952cc4bbca6c + wine: fa24d458f5d9663fbefb1eb7406961b1c6ec3def
2 years, 6 months
1
0
0
0
[reactos] 66/158: [WINESYNC] reg: Avoid non-portable Unicode character.
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=d472925c90f4d1207468f…
commit d472925c90f4d1207468fdd94b4989126bc23bdc Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:06:05 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:32 2022 +0200 [WINESYNC] reg: Avoid non-portable Unicode character. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id 495d9b5fb3ab5bab885f9fe80cd6952cc4bbca6c by Alexandre Julliard <julliard(a)winehq.org> --- base/applications/cmdutils/reg/export.c | 2 +- sdk/tools/winesync/reg.cfg | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/base/applications/cmdutils/reg/export.c b/base/applications/cmdutils/reg/export.c index eeb17a28753..8abecf1f595 100644 --- a/base/applications/cmdutils/reg/export.c +++ b/base/applications/cmdutils/reg/export.c @@ -301,7 +301,7 @@ static int export_registry_data(HANDLE hFile, HKEY key, WCHAR *path) static void export_file_header(HANDLE hFile) { - static const WCHAR *header = L"\uFEFFWindows Registry Editor Version 5.00\r\n"; + static const WCHAR header[] = L"\xFEFFWindows Registry Editor Version 5.00\r\n"; write_file(hFile, header); } diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index 29d9c7376af..7ad3b0831f2 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: 07fdd5036ca40fd4f0475583b6e410192576d804 + wine: 495d9b5fb3ab5bab885f9fe80cd6952cc4bbca6c
2 years, 6 months
1
0
0
0
[reactos] 65/158: [WINESYNC] reg: Only call get_long_key() when operations require it.
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=a1c74056d127f87087116…
commit a1c74056d127f87087116733fd4984dc73f236c9 Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:06:05 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:32 2022 +0200 [WINESYNC] reg: Only call get_long_key() when operations require it. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id 07fdd5036ca40fd4f0475583b6e410192576d804 by Hugh McMaster <hugh.mcmaster(a)outlook.com> --- base/applications/cmdutils/reg/add.c | 4 ++-- base/applications/cmdutils/reg/delete.c | 4 +++- base/applications/cmdutils/reg/export.c | 8 +++++--- base/applications/cmdutils/reg/query.c | 4 +++- base/applications/cmdutils/reg/reg.c | 6 ++---- base/applications/cmdutils/reg/reg.h | 3 ++- sdk/tools/winesync/reg.cfg | 2 +- 7 files changed, 18 insertions(+), 13 deletions(-) diff --git a/base/applications/cmdutils/reg/add.c b/base/applications/cmdutils/reg/add.c index f259f0a4100..d94789ad484 100644 --- a/base/applications/cmdutils/reg/add.c +++ b/base/applications/cmdutils/reg/add.c @@ -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++) diff --git a/base/applications/cmdutils/reg/delete.c b/base/applications/cmdutils/reg/delete.c index b23b14e8dab..626fcf3b341 100644 --- a/base/applications/cmdutils/reg/delete.c +++ b/base/applications/cmdutils/reg/delete.c @@ -113,7 +113,7 @@ int reg_delete(int argc, WCHAR *argvW[]) BOOL value_all = FALSE, 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++) @@ -158,6 +158,8 @@ int reg_delete(int argc, WCHAR *argvW[]) if ((value_name && value_empty) || (value_name && value_all) || (value_empty && value_all)) goto invalid; + key_name = get_long_key(root, path); + return run_delete(root, path, key_name, value_name, value_empty, value_all, force); invalid: diff --git a/base/applications/cmdutils/reg/export.c b/base/applications/cmdutils/reg/export.c index 0b6d9ad9cbe..eeb17a28753 100644 --- a/base/applications/cmdutils/reg/export.c +++ b/base/applications/cmdutils/reg/export.c @@ -347,14 +347,14 @@ static HANDLE get_file_handle(WCHAR *filename, BOOL overwrite_file) int reg_export(int argc, WCHAR *argvW[]) { HKEY root, hkey; - WCHAR *path, *long_key; + WCHAR *path, *key_name; BOOL overwrite_file = FALSE; HANDLE hFile; int i, ret; if (argc < 4) goto invalid; - if (!parse_registry_key(argvW[2], &root, &path, &long_key)) + if (!parse_registry_key(argvW[2], &root, &path)) return 1; for (i = 4; i < argc; i++) @@ -378,9 +378,11 @@ int reg_export(int argc, WCHAR *argvW[]) return 1; } + key_name = get_long_key(root, path); + hFile = get_file_handle(argvW[3], overwrite_file); export_file_header(hFile); - ret = export_registry_data(hFile, hkey, long_key); + ret = export_registry_data(hFile, hkey, key_name); export_newline(hFile); CloseHandle(hFile); diff --git a/base/applications/cmdutils/reg/query.c b/base/applications/cmdutils/reg/query.c index cc8f264e780..76f12b4a2d3 100644 --- a/base/applications/cmdutils/reg/query.c +++ b/base/applications/cmdutils/reg/query.c @@ -329,7 +329,7 @@ int reg_query(int argc, WCHAR *argvW[]) BOOL value_empty = FALSE, recurse = 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++) @@ -368,6 +368,8 @@ int reg_query(int argc, WCHAR *argvW[]) if (value_name && value_empty) goto invalid; + key_name = get_long_key(root, path); + return run_query(root, path, key_name, value_name, value_empty, recurse); invalid: diff --git a/base/applications/cmdutils/reg/reg.c b/base/applications/cmdutils/reg/reg.c index c275b4b8d27..1230d261d8e 100644 --- a/base/applications/cmdutils/reg/reg.c +++ b/base/applications/cmdutils/reg/reg.c @@ -203,7 +203,7 @@ WCHAR *build_subkey_path(WCHAR *path, DWORD path_len, WCHAR *subkey_name, DWORD return subkey_path; } -static WCHAR *get_long_key(HKEY root, WCHAR *path) +WCHAR *get_long_key(HKEY root, WCHAR *path) { DWORD i, array_size = ARRAY_SIZE(root_rels), len; WCHAR *long_key; @@ -229,7 +229,7 @@ static WCHAR *get_long_key(HKEY root, WCHAR *path) return long_key; } -BOOL parse_registry_key(const WCHAR *key, HKEY *root, WCHAR **path, WCHAR **long_key) +BOOL parse_registry_key(const WCHAR *key, HKEY *root, WCHAR **path) { if (!sane_path(key)) return FALSE; @@ -245,8 +245,6 @@ BOOL parse_registry_key(const WCHAR *key, HKEY *root, WCHAR **path, WCHAR **long return FALSE; } - *long_key = get_long_key(*root, *path); - return TRUE; } diff --git a/base/applications/cmdutils/reg/reg.h b/base/applications/cmdutils/reg/reg.h index c7719a6e4f0..3fc9e392d45 100644 --- a/base/applications/cmdutils/reg/reg.h +++ b/base/applications/cmdutils/reg/reg.h @@ -39,7 +39,8 @@ void WINAPIV output_string(const WCHAR *fmt, ...); BOOL ask_confirm(unsigned int msgid, WCHAR *reg_info); HKEY path_get_rootkey(const WCHAR *path); WCHAR *build_subkey_path(WCHAR *path, DWORD path_len, WCHAR *subkey_name, DWORD subkey_len); -BOOL parse_registry_key(const WCHAR *key, HKEY *root, WCHAR **path, WCHAR **long_key); +WCHAR *get_long_key(HKEY root, WCHAR *path); +BOOL parse_registry_key(const WCHAR *key, HKEY *root, WCHAR **path); BOOL is_char(const WCHAR s, const WCHAR c); BOOL is_switch(const WCHAR *s, const WCHAR c); diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index d8c00f2dab7..29d9c7376af 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: 2c7d74594f2bd421f6d904f334171a198a13c66e + wine: 07fdd5036ca40fd4f0475583b6e410192576d804
2 years, 6 months
1
0
0
0
[reactos] 64/158: [WINESYNC] reg: Abort 'query' operation when parsing command-line arguments that are not switches.
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=091880d29bd8bcbbe562f…
commit 091880d29bd8bcbbe562f949a33dfbc5f50f6aae Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:06:05 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:32 2022 +0200 [WINESYNC] reg: Abort 'query' operation when parsing command-line arguments that are not switches. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id 2c7d74594f2bd421f6d904f334171a198a13c66e by Hugh McMaster <hugh.mcmaster(a)outlook.com> --- base/applications/cmdutils/reg/query.c | 48 ++++++++++++++++++---------------- sdk/tools/winesync/reg.cfg | 2 +- 2 files changed, 26 insertions(+), 24 deletions(-) diff --git a/base/applications/cmdutils/reg/query.c b/base/applications/cmdutils/reg/query.c index 656ac875ec4..cc8f264e780 100644 --- a/base/applications/cmdutils/reg/query.c +++ b/base/applications/cmdutils/reg/query.c @@ -334,32 +334,34 @@ int reg_query(int argc, WCHAR *argvW[]) for (i = 3; i < argc; i++) { - if (argvW[i][0] == '/' || argvW[i][0] == '-') - { - WCHAR *str = &argvW[i][1]; + WCHAR *str; - if (!lstrcmpiW(str, L"ve")) - { - if (value_empty) goto invalid; - value_empty = TRUE; - continue; - } - else if (!str[0] || str[1]) - goto invalid; + if (argvW[i][0] != '/' && argvW[i][0] != '-') + goto invalid; - switch (towlower(*str)) - { - case 'v': - if (value_name || !(value_name = argvW[++i])) - goto invalid; - break; - case 's': - if (recurse) goto invalid; - recurse = TRUE; - break; - default: + str = &argvW[i][1]; + + if (!lstrcmpiW(str, L"ve")) + { + if (value_empty) goto invalid; + value_empty = TRUE; + continue; + } + else if (!str[0] || str[1]) + goto invalid; + + switch (towlower(*str)) + { + case 'v': + if (value_name || !(value_name = argvW[++i])) goto invalid; - } + break; + case 's': + if (recurse) goto invalid; + recurse = TRUE; + break; + default: + goto invalid; } } diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index 5454758d744..d8c00f2dab7 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: 51e83dec2959ce332264223832abc1a5f09dbf34 + wine: 2c7d74594f2bd421f6d904f334171a198a13c66e
2 years, 6 months
1
0
0
0
[reactos] 63/158: [WINESYNC] reg: Abort 'delete' operation when parsing command-line arguments that are not switches.
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=fa6d473e3dd8bafb074ca…
commit fa6d473e3dd8bafb074ca37c93eff3a13b5598f6 Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:06:05 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:32 2022 +0200 [WINESYNC] reg: Abort 'delete' operation when parsing command-line arguments that are not switches. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id 51e83dec2959ce332264223832abc1a5f09dbf34 by Hugh McMaster <hugh.mcmaster(a)outlook.com> --- base/applications/cmdutils/reg/delete.c | 60 +++++++++++++++++---------------- sdk/tools/winesync/reg.cfg | 2 +- 2 files changed, 32 insertions(+), 30 deletions(-) diff --git a/base/applications/cmdutils/reg/delete.c b/base/applications/cmdutils/reg/delete.c index 519d4b880ec..b23b14e8dab 100644 --- a/base/applications/cmdutils/reg/delete.c +++ b/base/applications/cmdutils/reg/delete.c @@ -118,38 +118,40 @@ int reg_delete(int argc, WCHAR *argvW[]) for (i = 3; i < argc; i++) { - if (argvW[i][0] == '/' || argvW[i][0] == '-') - { - WCHAR *str = &argvW[i][1]; + WCHAR *str; - if (!lstrcmpiW(str, L"va")) - { - if (value_all) goto invalid; - value_all = TRUE; - continue; - } - else if (!lstrcmpiW(str, L"ve")) - { - if (value_empty) goto invalid; - value_empty = TRUE; - continue; - } - else if (!str[0] || str[1]) - goto invalid; + if (argvW[i][0] != '/' && argvW[i][0] != '-') + goto invalid; - switch (towlower(*str)) - { - case 'v': - if (value_name || !(value_name = argvW[++i])) - goto invalid; - break; - case 'f': - if (force) goto invalid; - force = TRUE; - break; - default: + str = &argvW[i][1]; + + if (!lstrcmpiW(str, L"va")) + { + if (value_all) goto invalid; + value_all = TRUE; + continue; + } + else if (!lstrcmpiW(str, L"ve")) + { + if (value_empty) goto invalid; + value_empty = TRUE; + continue; + } + else if (!str[0] || str[1]) + goto invalid; + + switch (towlower(*str)) + { + case 'v': + if (value_name || !(value_name = argvW[++i])) goto invalid; - } + break; + case 'f': + if (force) goto invalid; + force = TRUE; + break; + default: + goto invalid; } } diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index 354fb6013b0..5454758d744 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: b2ead1ffcc8d28b488b561e8c5a9e3cc964699a3 + wine: 51e83dec2959ce332264223832abc1a5f09dbf34
2 years, 6 months
1
0
0
0
[reactos] 62/158: [WINESYNC] reg: Abort 'add' operation when parsing command-line arguments that are not switches.
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=0a5bdf825b7345410ce4f…
commit 0a5bdf825b7345410ce4f0236cf92ac2bd2af08c Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:06:05 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:32 2022 +0200 [WINESYNC] reg: Abort 'add' operation when parsing command-line arguments that are not switches. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id b2ead1ffcc8d28b488b561e8c5a9e3cc964699a3 by Hugh McMaster <hugh.mcmaster(a)outlook.com> --- base/applications/cmdutils/reg/add.c | 74 ++++++++++++++++++------------------ sdk/tools/winesync/reg.cfg | 2 +- 2 files changed, 39 insertions(+), 37 deletions(-) diff --git a/base/applications/cmdutils/reg/add.c b/base/applications/cmdutils/reg/add.c index e1fd2223716..f259f0a4100 100644 --- a/base/applications/cmdutils/reg/add.c +++ b/base/applications/cmdutils/reg/add.c @@ -222,46 +222,48 @@ int reg_add(int argc, WCHAR *argvW[]) for (i = 3; i < argc; i++) { - if (argvW[i][0] == '/' || argvW[i][0] == '-') + WCHAR *str; + + if (argvW[i][0] != '/' && argvW[i][0] != '-') + goto invalid; + + str = &argvW[i][1]; + + if (!lstrcmpiW(str, L"ve")) { - WCHAR *str = &argvW[i][1]; + if (value_empty) goto invalid; + value_empty = TRUE; + continue; + } + else if (!str[0] || str[1]) + goto invalid; - if (!lstrcmpiW(str, L"ve")) - { - if (value_empty) goto invalid; - value_empty = TRUE; - continue; - } - else if (!str[0] || str[1]) + switch (towlower(*str)) + { + case 'v': + if (value_name || !(value_name = argvW[++i])) goto invalid; - - switch (towlower(*str)) - { - case 'v': - if (value_name || !(value_name = argvW[++i])) - goto invalid; - break; - case 't': - if (type || !(type = argvW[++i])) - goto invalid; - break; - case 'd': - if (data || !(data = argvW[++i])) - goto invalid; - break; - case 's': - str = argvW[++i]; - if (separator || !str || lstrlenW(str) != 1) - goto invalid; - separator = str[0]; - break; - case 'f': - if (force) goto invalid; - force = TRUE; - break; - default: + break; + case 't': + if (type || !(type = argvW[++i])) goto invalid; - } + break; + case 'd': + if (data || !(data = argvW[++i])) + goto invalid; + break; + case 's': + str = argvW[++i]; + if (separator || !str || lstrlenW(str) != 1) + goto invalid; + separator = str[0]; + break; + case 'f': + if (force) goto invalid; + force = TRUE; + break; + default: + goto invalid; } } diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index c94f10bf936..354fb6013b0 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: b80da20656feda99f9c6e749f5cd6d6f3c242cd3 + wine: b2ead1ffcc8d28b488b561e8c5a9e3cc964699a3
2 years, 6 months
1
0
0
0
[reactos] 61/158: [WINESYNC] reg: Better indicate when a registry value is not found.
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=6c0f70db4dadf0a2fad42…
commit 6c0f70db4dadf0a2fad4270596ccce38eae48434 Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:04:41 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:31 2022 +0200 [WINESYNC] reg: Better indicate when a registry value is not found. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id b80da20656feda99f9c6e749f5cd6d6f3c242cd3 by Hugh McMaster <hugh.mcmaster(a)outlook.com> manual adjustment needed --- base/applications/cmdutils/reg/delete.c | 2 +- base/applications/cmdutils/reg/lang/en-US.rc | 2 +- base/applications/cmdutils/reg/query.c | 2 +- base/applications/cmdutils/reg/resource.h | 2 +- sdk/tools/winesync/reg.cfg | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/base/applications/cmdutils/reg/delete.c b/base/applications/cmdutils/reg/delete.c index c80b622bccb..519d4b880ec 100644 --- a/base/applications/cmdutils/reg/delete.c +++ b/base/applications/cmdutils/reg/delete.c @@ -96,7 +96,7 @@ static int run_delete(HKEY root, WCHAR *path, WCHAR *key_name, WCHAR *value_name if (RegDeleteValueW(key, value_empty ? NULL : value_name) != ERROR_SUCCESS) { RegCloseKey(key); - output_message(STRING_CANNOT_FIND); + output_message(STRING_VALUE_NONEXIST); return 1; } } diff --git a/base/applications/cmdutils/reg/lang/en-US.rc b/base/applications/cmdutils/reg/lang/en-US.rc index d137ce134c7..3457b10bc12 100644 --- a/base/applications/cmdutils/reg/lang/en-US.rc +++ b/base/applications/cmdutils/reg/lang/en-US.rc @@ -92,7 +92,7 @@ STRINGTABLE STRING_INVALID_KEY, "reg: Invalid registry key\n" STRING_INVALID_CMDLINE, "reg: Invalid command line parameters\n" STRING_NO_REMOTE, "reg: Unable to access remote machine\n" - STRING_CANNOT_FIND, "reg: The system was unable to find the specified registry key or value\n" + STRING_VALUE_NONEXIST, "reg: Unable to find the specified registry value\n" STRING_UNSUPPORTED_TYPE, "reg: Unsupported registry data type [%1]\n" STRING_MISSING_INTEGER, "reg: The option [/d] must be followed by a valid integer\n" STRING_MISSING_HEXDATA, "reg: The option [/d] must be followed by a valid hexadecimal value\n" diff --git a/base/applications/cmdutils/reg/query.c b/base/applications/cmdutils/reg/query.c index a82101a0a29..656ac875ec4 100644 --- a/base/applications/cmdutils/reg/query.c +++ b/base/applications/cmdutils/reg/query.c @@ -174,7 +174,7 @@ static int query_value(HKEY key, WCHAR *value_name, WCHAR *path, BOOL recurse) { if (value_name && *value_name) { - output_message(STRING_CANNOT_FIND); + output_message(STRING_VALUE_NONEXIST); return 1; } output_string(fmt, path); diff --git a/base/applications/cmdutils/reg/resource.h b/base/applications/cmdutils/reg/resource.h index ca42e59a744..6768aaf595e 100644 --- a/base/applications/cmdutils/reg/resource.h +++ b/base/applications/cmdutils/reg/resource.h @@ -31,7 +31,7 @@ #define STRING_INVALID_KEY 106 #define STRING_INVALID_CMDLINE 107 #define STRING_NO_REMOTE 108 -#define STRING_CANNOT_FIND 109 +#define STRING_VALUE_NONEXIST 109 #define STRING_UNSUPPORTED_TYPE 110 #define STRING_MISSING_INTEGER 111 #define STRING_MISSING_HEXDATA 112 diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index b137c92c31b..c94f10bf936 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: fbecd56db8889f9d349c2f807348cdddf397eab1 + wine: b80da20656feda99f9c6e749f5cd6d6f3c242cd3
2 years, 6 months
1
0
0
0
[reactos] 60/158: [WINESYNC] reg: Prepend 'reg:' to two message strings.
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=9a8e4a271aa1aba0b3f05…
commit 9a8e4a271aa1aba0b3f0546c60d0745e9933d6c1 Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:03:01 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:31 2022 +0200 [WINESYNC] reg: Prepend 'reg:' to two message strings. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id fbecd56db8889f9d349c2f807348cdddf397eab1 by Hugh McMaster <hugh.mcmaster(a)outlook.com> manual adjustment needed --- base/applications/cmdutils/reg/lang/en-US.rc | 4 ++-- sdk/tools/winesync/reg.cfg | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/base/applications/cmdutils/reg/lang/en-US.rc b/base/applications/cmdutils/reg/lang/en-US.rc index 11ae14280ff..d137ce134c7 100644 --- a/base/applications/cmdutils/reg/lang/en-US.rc +++ b/base/applications/cmdutils/reg/lang/en-US.rc @@ -88,7 +88,7 @@ STRINGTABLE \ /s\n\ \ List all registry entries under <key> and its subkeys.\n\n" - STRING_SUCCESS, "The operation completed successfully\n" + STRING_SUCCESS, "reg: The operation completed successfully\n" STRING_INVALID_KEY, "reg: Invalid registry key\n" STRING_INVALID_CMDLINE, "reg: Invalid command line parameters\n" STRING_NO_REMOTE, "reg: Unable to access remote machine\n" @@ -101,7 +101,7 @@ STRINGTABLE STRING_YESNO, " (Yes|No)" STRING_YES, "#msgctxt#Yes key#Y" STRING_NO, "#msgctxt#No key#N" - STRING_CANCELLED, "The registry operation was cancelled\n" + STRING_CANCELLED, "reg: The registry operation was cancelled\n" STRING_DEFAULT_VALUE, "(Default)" STRING_DELETE_VALUE, "Are you sure you want to delete the registry value '%1'?" STRING_DELETE_VALUEALL, "Are you sure you want to delete all registry values in '%1'?" diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index 821e260688b..b137c92c31b 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: 9b7a5cfb0e709e4434575daf960f803338bdf6bd + wine: fbecd56db8889f9d349c2f807348cdddf397eab1
2 years, 6 months
1
0
0
0
[reactos] 59/158: [WINESYNC] reg: Add a new message to indicate when a registry key fails to import.
by winesync
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=235d5af3afa58ff432c5e…
commit 235d5af3afa58ff432c5efa6ef0780aacbb7f066 Author: winesync <ros-dev(a)reactos.org> AuthorDate: Sun Jan 16 21:01:12 2022 +0100 Commit: Thomas Csovcsity <thc.fr13nd(a)gmail.com> CommitDate: Sun Jun 19 13:06:31 2022 +0200 [WINESYNC] reg: Add a new message to indicate when a registry key fails to import. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> wine commit id 9b7a5cfb0e709e4434575daf960f803338bdf6bd by Hugh McMaster <hugh.mcmaster(a)outlook.com> manual adjustment needed --- base/applications/cmdutils/reg/import.c | 4 ++-- base/applications/cmdutils/reg/lang/en-US.rc | 1 + base/applications/cmdutils/reg/resource.h | 1 + sdk/tools/winesync/reg.cfg | 2 +- 4 files changed, 5 insertions(+), 3 deletions(-) diff --git a/base/applications/cmdutils/reg/import.c b/base/applications/cmdutils/reg/import.c index 3ce8fce7394..223e7db0e48 100644 --- a/base/applications/cmdutils/reg/import.c +++ b/base/applications/cmdutils/reg/import.c @@ -523,7 +523,7 @@ static WCHAR *parse_win31_line_state(struct parser *parser, WCHAR *pos) if (open_key(parser, line) != ERROR_SUCCESS) { - output_message(STRING_OPEN_KEY_FAILED, line); + output_message(STRING_KEY_IMPORT_FAILED, line); return line; } @@ -584,7 +584,7 @@ static WCHAR *key_name_state(struct parser *parser, WCHAR *pos) return p + 1; } else if (open_key(parser, p) != ERROR_SUCCESS) - output_message(STRING_OPEN_KEY_FAILED, p); + output_message(STRING_KEY_IMPORT_FAILED, p); done: set_state(parser, LINE_START); diff --git a/base/applications/cmdutils/reg/lang/en-US.rc b/base/applications/cmdutils/reg/lang/en-US.rc index 038d7658dc0..11ae14280ff 100644 --- a/base/applications/cmdutils/reg/lang/en-US.rc +++ b/base/applications/cmdutils/reg/lang/en-US.rc @@ -147,4 +147,5 @@ STRINGTABLE STRING_INVALID_SYSTEM_KEY, "reg: Invalid system key [%1]\n" STRING_OVERWRITE_FILE, "The file '%1' already exists. Do you want to overwrite it?" STRING_KEY_NONEXIST, "reg: Unable to find the specified registry key\n" + STRING_KEY_IMPORT_FAILED, "reg: Unable to import the registry key '%1'\n" } diff --git a/base/applications/cmdutils/reg/resource.h b/base/applications/cmdutils/reg/resource.h index 508761d01ac..ca42e59a744 100644 --- a/base/applications/cmdutils/reg/resource.h +++ b/base/applications/cmdutils/reg/resource.h @@ -62,3 +62,4 @@ #define STRING_INVALID_SYSTEM_KEY 137 #define STRING_OVERWRITE_FILE 138 #define STRING_KEY_NONEXIST 139 +#define STRING_KEY_IMPORT_FAILED 140 diff --git a/sdk/tools/winesync/reg.cfg b/sdk/tools/winesync/reg.cfg index e01102a7d73..821e260688b 100644 --- a/sdk/tools/winesync/reg.cfg +++ b/sdk/tools/winesync/reg.cfg @@ -4,4 +4,4 @@ directories: files: programs/reg/resource.h: base/applications/cmdutils/reg/resource.h tags: - wine: fa2ed01352f8f027625d464915cd953e10766d73 + wine: 9b7a5cfb0e709e4434575daf960f803338bdf6bd
2 years, 6 months
1
0
0
0
← Newer
1
...
10
11
12
13
14
15
16
...
24
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
Results per page:
10
25
50
100
200