Do not write beyond the buffer.

svn path=/trunk/; revision=26708
This commit is contained in:
Dmitry Gorbachev 2007-05-11 23:15:53 +00:00
parent 14f97db8a4
commit acd6160248

View file

@ -763,7 +763,7 @@ CRegKeySecurity_fnConstructor(LPTSTR lpRegKey,
obj = (PCRegKeySecurity)HeapAlloc(GetProcessHeap(),
HEAP_ZERO_MEMORY,
FIELD_OFFSET(CRegKeySecurity,
szRegKey[_tcslen(lpRegKey)]));
szRegKey[_tcslen(lpRegKey)+1]));
if (obj != NULL)
{
obj->ref = 1;