mirror of
https://github.com/reactos/reactos.git
synced 2025-04-21 12:40:33 +00:00
[WIN32K]
Change wcsncpy to safe functions (part 2/x) svn path=/trunk/; revision=51140
This commit is contained in:
parent
0b986764d4
commit
04d67b9ebd
1 changed files with 4 additions and 4 deletions
|
@ -309,11 +309,11 @@ UserEnumDisplayDevices(
|
||||||
ZwClose(hkey);
|
ZwClose(hkey);
|
||||||
|
|
||||||
/* Copy device name, device string and StateFlags */
|
/* Copy device name, device string and StateFlags */
|
||||||
wcsncpy(pdispdev->DeviceName, pGraphicsDevice->szWinDeviceName, 32);
|
RtlStringCbCopyW(pdispdev->DeviceName, sizeof(pdispdev->DeviceName), pGraphicsDevice->szWinDeviceName);
|
||||||
wcsncpy(pdispdev->DeviceString, pGraphicsDevice->pwszDescription, 128);
|
RtlStringCbCopyW(pdispdev->DeviceString, sizeof(pdispdev->DeviceString), pGraphicsDevice->pwszDescription);
|
||||||
pdispdev->StateFlags = pGraphicsDevice->StateFlags;
|
pdispdev->StateFlags = pGraphicsDevice->StateFlags;
|
||||||
|
|
||||||
// FIXME: fill in DEVICE ID
|
// FIXME: fill in DEVICE ID
|
||||||
|
pdispdev->DeviceID[0] = UNICODE_NULL;
|
||||||
|
|
||||||
return STATUS_SUCCESS;
|
return STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
|
@ -339,7 +339,7 @@ NtUserEnumDisplayDevices(
|
||||||
if (pustrDevice && iDevNum != 0)
|
if (pustrDevice && iDevNum != 0)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
dispdev.cb = sizeof(DISPLAY_DEVICEW);
|
dispdev.cb = sizeof(dispdev);
|
||||||
|
|
||||||
if (pustrDevice)
|
if (pustrDevice)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue