return;
}
- wLength = GetWindowsDirectoryW(DestString, MaxStrLen);
+ wLength = GetSystemWindowsDirectoryW(DestString, MaxStrLen);
if ((wLength > 0) && (_wcsnicmp(ConsoleName, DestString, wLength) == 0))
{
StringCchCopyW(DestString, MaxStrLen, L"%SystemRoot%");
DPRINT1("This case must never happen, because selHeight is at least == 1\n");
}
- size += 1; /* Null-termination */
+ size++; /* Null-termination */
size *= sizeof(WCHAR);
/* Allocate some memory area to be given to the clipboard, so it will not be freed here */
/* Pressing the character key, with the control keys maintained pressed */
er.Event.KeyEvent.bKeyDown = TRUE;
er.Event.KeyEvent.wVirtualKeyCode = LOBYTE(VkKey);
- er.Event.KeyEvent.wVirtualScanCode = MapVirtualKeyW(LOBYTE(VkKey), MAPVK_VK_TO_CHAR);
+ er.Event.KeyEvent.wVirtualScanCode = MapVirtualKeyW(LOBYTE(VkKey), MAPVK_VK_TO_VSC);
er.Event.KeyEvent.uChar.UnicodeChar = CurChar;
er.Event.KeyEvent.dwControlKeyState = 0;
if (HIBYTE(VkKey) & 1)