hhctrl.ocx: Fix for writing outside allocated memory in HH_AddToolbar.
This commit is contained in:
parent
5cc671eec5
commit
0b64b866a4
|
@ -575,7 +575,7 @@ static BOOL HH_AddToolbar(HHInfo *pHHInfo)
|
|||
{
|
||||
LPWSTR szBuf = HH_LoadString(buttons[dwIndex].idCommand);
|
||||
DWORD dwLen = strlenW(szBuf);
|
||||
szBuf[dwLen + 2] = 0; /* Double-null terminate */
|
||||
szBuf[dwLen + 1] = 0; /* Double-null terminate */
|
||||
|
||||
buttons[dwIndex].iString = (DWORD)SendMessageW(hToolbar, TB_ADDSTRINGW, 0, (LPARAM)szBuf);
|
||||
heap_free(szBuf);
|
||||
|
|
Loading…
Reference in New Issue