[NTOS:PNP] Handle arbitrary subkey name lengths in EnumerateDevices. CORE-15882
authorThomas Faber <thomas.faber@reactos.org>
Sat, 20 Apr 2019 08:48:43 +0000 (10:48 +0200)
committerThomas Faber <thomas.faber@reactos.org>
Wed, 10 Jul 2019 08:58:45 +0000 (10:58 +0200)
commitb8e091a44c9852fb759e9cb7f503bab74146a2d1
tree7c627f598865a3fa7f84c495037f1d6888af728d
parentb5423ba70b0a1e7022a04a7c7b3b7b0de447f6b8
[NTOS:PNP] Handle arbitrary subkey name lengths in EnumerateDevices. CORE-15882

This also makes it necessary to fix a bug in the previous code:
ZwEnumerateKey will not account for space for a null terminator, so to
ensure we have space, we must allocate the additional WCHAR, but not
include it in the buffer size passed to the function.
ntoskrnl/io/pnpmgr/pnproot.c