mirror of
https://github.com/vxunderground/VX-API
synced 2024-06-30 18:51:17 +00:00
13 lines
267 B
C++
13 lines
267 B
C++
SIZE_T CharStringToWCharString(PWCHAR Destination, PCHAR Source, SIZE_T MaximumAllowed)
|
|
{
|
|
INT Length = (INT)MaximumAllowed;
|
|
|
|
while (--Length >= 0)
|
|
{
|
|
if (!(*Destination++ = *Source++))
|
|
return MaximumAllowed - Length - 1;
|
|
}
|
|
|
|
return MaximumAllowed - Length;
|
|
}
|