Commit Graph

94 Commits

Author SHA1 Message Date
Hugh McMaster e9daef47e1 regedit: Null-terminate incomplete REG_EXPAND_SZ and REG_MULTI_SZ Unicode data.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-28 14:57:10 +02:00
Hugh McMaster 60e771e686 regedit: Close any open registry keys before starting the key deletion process.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-25 08:07:57 +02:00
Hugh McMaster 484f88080d regedit/tests: Add some mixed key creation and deletion tests.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-25 08:07:50 +02:00
Hugh McMaster d78767b63c regedit/tests: Add Unicode tests for importing invalid registry data.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-24 16:59:59 +02:00
Hugh McMaster cbe95347fc regedit/tests: Add Unicode tests for value deletion.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-24 16:59:57 +02:00
Hugh McMaster 0eab4519c0 regedit/tests: Add Unicode tests for registry key creation and deletion.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-24 16:59:55 +02:00
Hugh McMaster 634156b10a regedit/tests: Add Unicode tests for importing registry data with whitespace.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-24 16:59:53 +02:00
Hugh McMaster 13cbc36690 regedit/tests: Add Unicode tests for importing registry data with inter-mixed comments.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-24 16:59:51 +02:00
Hugh McMaster b46b698e82 regedit/tests: Delete the test registry key before starting each test.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-24 16:59:49 +02:00
Hugh McMaster d8cdafcc6f regedit/tests: Add Unicode import tests and remove the WCHAR support check.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-24 08:42:21 +09:00
Hugh McMaster 7f11a24fee regedit: Null-terminate REG_EXPAND_SZ and REG_MULTI_SZ hex data during concatenation if we reach EOF.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-10 20:51:11 +02:00
Hugh McMaster 6f24426692 regedit/tests: Test the effects of EOF on hex data during concatenation.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-07 19:48:32 +02:00
Hugh McMaster 3908296237 regedit: Null-terminate REG_EXPAND_SZ and REG_MULTI_SZ data if the parsed hex data does not end in a null-terminating character.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-06 18:50:48 +02:00
Hugh McMaster 7b95ddcb04 regedit: Hex data lines may be terminated by a semicolon.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-06 18:50:48 +02:00
Hugh McMaster 23c93d3026 regedit/tests: Add some more tests for importing hex data.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-06 18:50:48 +02:00
Hugh McMaster 3afa0e42c8 regedit/tests: Add another test for "0x" prefixes in the hex data type.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-06 18:50:47 +02:00
Hugh McMaster 499733f400 regedit/tests: Check if regedit.exe has elevated privileges before starting some tests.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-06 18:50:47 +02:00
Hugh McMaster b811b16694 regedit: Do not import the line if a hex data type has a "0x" prefix.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-05 18:21:37 +02:00
Hugh McMaster 5d8a1283f2 regedit: Do not remove lines beginning with '#' from the read buffer.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-04 19:49:57 +02:00
Hugh McMaster e336c86359 regedit: Skip blank and whitespace-only lines during hex data concatenation.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-04 19:49:49 +02:00
Hugh McMaster 6ffa89ebd3 regedit: Skip lines that do not begin with a hexadecimal character during hex data concatenation.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-04 19:49:42 +02:00
Hugh McMaster 50fee455c4 regedit/tests: Test whether the "0x" prefix is valid when importing hex data.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-04 19:49:25 +02:00
Hugh McMaster 506d4fd052 regedit/tests: Test whether registry keys ending with trailing backslashes are imported and created.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-04 19:49:21 +02:00
Hugh McMaster 032d32f940 regedit: Improve the parsing of multiline hex data during the registry import operation.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-03 15:57:44 +02:00
Hugh McMaster 2db2a7aeef regedit/tests: Test the effect of whitespace-only lines during hex data concatenation.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-03 15:57:44 +02:00
Hugh McMaster 55d43d13e4 regedit/tests: Fix another incorrectly named registry key.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-03 15:57:44 +02:00
Hugh McMaster 817cd2ac59 regedit/tests: Correct out of sequence test numbering.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-29 18:32:06 +02:00
Hugh McMaster a905b4d6ba regedit/tests: Test comma placement when parsing hex data.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-29 18:32:06 +02:00
Hugh McMaster ec0043f083 regedit/tests: Test whether EOF invalidates a hex data line ending in a backslash.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-27 19:13:54 +02:00
Hugh McMaster 82d3be8094 regedit/tests: Test whether a forward slash can be used as a concatenation marker.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-27 19:13:50 +02:00
Hugh McMaster 81fa517436 regedit/tests: Test the effects of comments and new lines that appear between valid hex data lines.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-27 19:13:48 +02:00
Hugh McMaster a9726d0b90 regedit/tests: Test whether a line beginning with a backslash can follow a line ending in a backslash.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-27 19:13:44 +02:00
Hugh McMaster a31f070ada regedit/tests: Test line concatenation with comments, new lines and comma variations before a new default registry value.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-27 19:13:41 +02:00
Hugh McMaster db9e4199e0 regedit/tests: Test line concatenation with comments, new lines and comma variations before a new registry value.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-27 19:13:38 +02:00
Hugh McMaster 82263293f6 regedit/tests: Test line concatenation with a new registry key on the next line.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-27 19:13:34 +02:00
Hugh McMaster 6b36ce329d regedit/tests: Test backslashes with whitespace variations and comma placement.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-27 19:13:32 +02:00
Hugh McMaster 73af2479c7 regedit/tests: Use the verify_key*() functions where possible.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-26 18:19:34 +02:00
Hugh McMaster f0e21863c9 regedit/tests: Use verify_key() for consistency with the verify_reg*() functions.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-26 18:19:32 +02:00
Hugh McMaster a76ce84fce regedit/tests: Add tests to determine the effects of backslashes in hex data.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-23 15:19:36 +02:00
Hugh McMaster a1b35b3bc4 regedit/tests: Add tests for parsing hex data.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-22 19:25:16 +02:00
Hugh McMaster 8803b9616b regedit: Fail when parsing any hex data type that is greater than ULONG_MAX on Windows.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-21 19:15:12 +02:00
Hugh McMaster e3234f6ede regedit: Use a generic data type to correctly process all data types.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-20 18:43:30 +02:00
Hugh McMaster 1f08ee2453 regedit: Allow the deletion of registry keys beginning with a lowercase 'H'.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-16 15:25:38 +02:00
Hugh McMaster f535341d2b regedit: Use a case insensitive comparison when parsing registry classes from registry file versions 4 and 5.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-16 15:25:37 +02:00
Hugh McMaster 191b81dbd3 regedit: Add data parsing operations to the state machine.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-15 21:54:38 +02:00
Hugh McMaster d60c31eadb regedit: Perform value name operations in the state machine.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-15 18:51:08 +02:00
Hugh McMaster ec87800856 regedit: Introduce a partial state machine for importing registry data.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-15 18:51:08 +02:00
Hugh McMaster 06b0a6d94d regedit/tests: Test whether "" is interpreted as the default registry value.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-15 15:02:10 +02:00
Hugh McMaster c414b2b570 regedit/tests: Output "(Default)" when referring to the default registry value.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-15 15:02:07 +02:00
Hugh McMaster 5058fa70a3 regedit/tests: Test the accepted range of the hex-based data types.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-13 20:56:19 +02:00