Hugh McMaster
ccbbb92888
reg: Avoid using strlenW to check if a string is valid.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-05-24 22:17:58 +09:00
Hugh McMaster
7b9a1a355f
reg: Output line break before displaying query output.
...
This matches Windows' behaviour.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-05-04 01:03:29 +09:00
Hugh McMaster
43875a7fae
reg: Output the number of matches when querying the registry recursively.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-05-04 01:03:29 +09:00
Hugh McMaster
dd5da0ae64
reg: Support recursion when querying a registry value.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-27 12:42:41 +09:00
Hugh McMaster
0c0d839aaa
reg: Add /v and /ve support to reg query.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-25 22:10:09 +09:00
Hugh McMaster
c81b0494ba
reg: Support recursion when querying a registry key.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-25 22:10:09 +09:00
Sebastian Lackner
7c774e9849
reg: Fix a heap corruption when printing specific REG_MULTI_SZ values.
...
Signed-off-by: Sebastian Lackner <sebastian@fds-team.de>
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-25 18:48:13 +09:00
Hugh McMaster
6433fee87e
reg: Output the data value when querying a registry key.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-22 21:04:37 +09:00
Hugh McMaster
bde6d0490e
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>
2016-04-22 21:04:37 +09:00
Hugh McMaster
9042759767
reg: Output the value name and type via a separate function.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-22 21:04:37 +09:00
Hugh McMaster
a9b76d0057
reg: Output the value type when querying a registry key.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-22 21:04:37 +09:00
Hugh McMaster
2bd12424c9
reg: Output a list of subkeys when querying a registry key.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-22 21:04:37 +09:00
Hugh McMaster
3035599ad8
reg: Output value names when querying a registry key.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-22 21:04:37 +09:00
Hugh McMaster
3f62729b6e
reg: Add initial 'query' support.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-22 21:04:36 +09:00
Hugh McMaster
dad56c7dc6
reg: Exit with an error message if RegQueryInfoKeyW fails.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-07 00:59:56 +09:00
Hugh McMaster
31f0d95283
reg: Clean-up and inform the user if RegDeleteValueW fails when deleting all values in a registry key.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-05 00:06:41 +09:00
Hugh McMaster
ead76c7e47
reg: Allow values to be added, deleted or modified in root keys.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-22 00:36:28 +09:00
Hugh McMaster
bd278b1983
reg: Fail if multiple /v switches are passed in.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-15 21:44:33 +09:00
Hugh McMaster
735dca6074
reg: Fail if /v is passed without an argument.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-15 21:42:50 +09:00
Hugh McMaster
84eed4cf22
reg: Correctly handle cases with no data argument.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-15 19:15:42 +09:00
Hugh McMaster
3762c294d9
reg: Fail if REG_DWORD_BIG_ENDIAN is passed with no data argument.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-04 18:42:10 +09:00
Hugh McMaster
9bfddcf76f
reg: Correctly handle /ve commands with no data.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-04 18:42:09 +09:00
Hugh McMaster
8220a32e0a
reg: Display the default value name when ask_confirm() is passed "" for reg_info.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-02 23:31:47 +09:00
Hugh McMaster
81a030b934
reg: Delete the default registry value instead of overwriting it.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-02 23:31:44 +09:00
Hugh McMaster
a573f237d0
reg: Fail if the data for REG_MULTI_SZ begins with a separator.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-01 17:45:01 +09:00
Hugh McMaster
afa5251b10
reg: Fail if the data for REG_MULTI_SZ contains two adjacent separators.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-01 17:44:59 +09:00
Hugh McMaster
b57b998354
reg: Ignore the slash zero character sequence if a custom separator is specified.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-25 21:59:42 +09:00
Hugh McMaster
47b2238b3d
reg: Add support for REG_MULTI_SZ.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-25 00:25:01 +09:00
Hugh McMaster
3c7b7ece37
reg: Fail if the data value passed with REG_DWORD will cause an overflow.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-23 20:22:21 +09:00
Hugh McMaster
5e6429520b
reg: Allow either lowercase or uppercase 'x' when used with REG_DWORD.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-23 20:22:21 +09:00
Hugh McMaster
8a902f3761
reg: Fail if the separator for REG_MULTI_SZ is not one character in length.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-18 00:22:05 +09:00
Hugh McMaster
46bdc153f1
reg: Fail if /s is used without an accompanying argument.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-18 00:22:04 +09:00
Hugh McMaster
acb4e3f63a
reg: Explicitly use base 10 or base 16 with strtoulW.
...
All Windows versions, except XP, parse the number 0123 as decimal.
(XP parses 0123 as octal).
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-16 23:26:29 +09:00
Hugh McMaster
474361ecb4
reg: Fail if the data argument for REG_DWORD begins with a minus sign.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-16 23:26:29 +09:00
Hugh McMaster
948888b950
reg: Use strtoulW during conversion so we can set any value in the DWORD range.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-16 23:26:29 +09:00
Hugh McMaster
2fd010110a
reg: Fail if strtolW cannot convert the entire data string into a DWORD.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-16 23:26:28 +09:00
Hugh McMaster
aa9d2a7c17
reg: Abort the process if get_regdata returns NULL.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-15 21:32:26 +09:00
Hugh McMaster
07c6b1392f
reg: Add case for REG_MULTI_SZ.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-15 21:32:01 +09:00
Hugh McMaster
b14e1ba801
reg: Handle data for REG_DWORD_LITTLE_ENDIAN and REG_DWORD_BIG_ENDIAN.
...
REG_DWORD_LITTLE_ENDIAN is #define'd as REG_DWORD, so the LITTLE_ENDIAN
case is just a comment added for clarity.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-15 21:31:20 +09:00
Hugh McMaster
03afd26eb1
reg: Handle data for REG_EXPAND_SZ.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-15 21:31:09 +09:00
Hugh McMaster
f1d45b5f44
reg: Handle data from REG_NONE.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-15 21:31:03 +09:00
Hugh McMaster
5061899c46
reg: Fail if REG_DWORD is passed with no data argument.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-15 21:30:19 +09:00
Hugh McMaster
e0492b27ac
reg: Call RegCloseKey before exiting if the user chooses to cancel the overwriting operation.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-15 21:30:17 +09:00
Hugh McMaster
3c340fda68
reg: Fail when /d is used without an accompanying argument.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-11 22:13:28 +09:00
Hugh McMaster
20a41d0339
reg: Ask the user if they want to delete the subkey, value, default value or all values.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-11 01:26:44 +09:00
Hugh McMaster
a365418ae2
reg: Add support for the default registry value in ask_confirm().
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-11 01:26:43 +09:00
Hugh McMaster
c0b26a649e
reg: Do not allow /v and /ve to be used together in the 'add' function.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-11 01:26:43 +09:00
Hugh McMaster
c59e3eae3b
reg: Do not allow combinations of /v, /ve or /va in the 'delete' function.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-11 01:26:43 +09:00
Hugh McMaster
ae48fbafa8
reg: Ask the user whether they want to overwrite an existing registry value.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-09 21:51:10 +09:00
Hugh McMaster
5654b91f7c
reg: Specify the data type that is unsupported.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-09 21:45:05 +09:00
Hugh McMaster
5f07f81ad1
reg: Output messages with a variable number of arguments and convert message arrays to strings.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-09 21:41:12 +09:00
Hugh McMaster
dfe1c2b57c
reg: Use FormatMessage for easier internationalization support.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-09 21:39:20 +09:00
Hugh McMaster
bfcee1f149
reg: Split reg_printfW into separate functions.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-09 21:39:16 +09:00
Hugh McMaster
dcd05e8e86
reg: Remove stub output from the 'add' and 'delete' functions.
...
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-08 20:05:24 +09:00
Jonathan Vollebregt
60f599f584
reg: Simplify root key search.
...
Signed-off-by: Michel Zou <xantares09@hotmail.com>
Signed-off-by: Stefan Dösinger <stefan@codeweavers.com>
2015-10-07 21:28:54 +09:00
Thomas Faller
5c9526cb6c
reg: Implement binary data add operation.
2015-09-07 15:04:49 +09:00
Jonathan Vollebregt
0898bd22bf
reg: Add wchar/type conversion functions.
2015-02-23 22:07:07 +09:00
Jonathan Vollebregt
513505d6c4
reg: Add a check for multiple backslashes at the end of the key.
2015-02-23 22:05:55 +09:00
Jonathan Vollebregt
208ca071dc
reg: Add sane_path function to do preliminary key validation.
2015-02-23 22:03:34 +09:00
Sebastian Lackner
f6b552324e
reg.exe: Fix incorrect usage of CompareString in get_rootkey.
2014-11-19 23:36:34 +09:00
Jonathan Vollebregt
b823337f65
reg.exe: Fix stack overflow on large registry keys.
2014-09-02 20:54:46 +02:00
Francois Gouget
f9c2e21fb1
reg: Use the CSTR_XXX macros instead of numeric literals.
2012-06-21 08:33:54 +02:00
Francois Gouget
5bc1aff578
programs: Document the reason for the WriteConsole() fall back.
2011-08-24 19:07:45 +02:00
Andrew Nguyen
060c8f0c6e
reg: Accept full names of the standard registry hives.
2011-01-04 14:51:39 +01:00
Dan Kegel
7de394d6ab
reg.exe: Handle setting DWORD registry values.
2010-02-03 15:50:34 +01:00
Marcus Meissner
552db89b06
reg: Fixed 2 functionality bugs in REG DELETE (Coverity).
2009-12-07 14:18:29 +01:00
Marcus Meissner
93dad930cd
reg: Remove wrong and useless check (Coverity).
2009-10-20 14:00:36 +02:00
Andrew Nguyen
7ec4ba32b2
reg: Support the /h flag as a synonymous help flag.
2009-07-01 11:39:38 +02:00
Andrew Nguyen
070d9f91ab
reg: Correct the sense of return values for registry operations.
2009-07-01 11:39:35 +02:00
Andrew Nguyen
a3dbe3cce1
reg: Fix behavior when specifying the help flag.
2009-06-30 14:59:02 +02:00
Andrew Nguyen
24c6f5cc35
reg: Report an error when an unknown operation is specified.
2009-06-30 14:58:55 +02:00
Nikolay Sivov
5276d886f9
reg: Don't close not open reg key (Coverity).
2009-02-09 13:21:27 +01:00
Aric Stewart
45824821ff
reg.exe: Implement DELETE.
2009-01-28 14:31:56 +01:00
Aric Stewart
647a087e8a
reg.exe: Implement ADD for REG_SZ.
2009-01-28 14:31:44 +01:00
Alexandre Julliard
5dcd3c4d1c
reg.exe: Fix broken usage of va_list.
2009-01-03 11:38:25 +01:00
Francois Gouget
3bb449468d
reg: Avoid wvsprintfW() so we can avoid loading user32.dll.
2008-11-21 10:01:57 +01:00
Andrew Riedi
103cfb90f2
reg: const WCHAR -> static const WCHAR.
2008-11-17 13:57:09 +01:00
Alexandre Julliard
90685fcf03
reg.exe: Get rid of remaining uses of Unicode macros.
2008-09-04 14:08:12 +02:00
Andrew Riedi
2087ad46a9
reg: Add stub 'reg' program.
2008-03-19 12:45:26 +01:00