[CMLIB]: Addendum to r63495: Fix the CmpCopyKeyValueList() helper to make it what...
authorHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Wed, 28 Jun 2017 00:04:13 +0000 (00:04 +0000)
committerHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Wed, 28 Jun 2017 00:04:13 +0000 (00:04 +0000)
commitb44faa47ed0d81be388127285e2473fdbc03c35d
tree99d821eeb8c397ed411f5333aca24e6b23dd0937
parent60dedbf232c3f03d0f48db622cffc29da360efd4
[CMLIB]: Addendum to r63495: Fix the CmpCopyKeyValueList() helper to make it what it is supposed to do: copy the list of values of a given key: this means, also copying the values themselves!!
For that aim I also introduce a CmpCopyValue() helper that allows copying the value data of a given registry value, taking into account whether the value is "small", normal or "big" (we don't support "big values" yet). This function allocates and copies the necessary hive cells corresponding to the given value. Only then, we add a new entry into the registry key value list that is grown dynamically.
Cleanup is performed in case of failure.
Now we can export registry sub-trees as registry hives, and successfully re-mount them in the registry.
CORE-13476 CORE-8259 CORE-10793

svn path=/trunk/; revision=75222
reactos/sdk/lib/cmlib/cmvalue.c