Commit 89bba4a2 authored by James Hawkins's avatar James Hawkins Committed by Alexandre Julliard

Implement RtlAnsiCharToUnicodeChar.

parent 0489f9e4
......@@ -576,6 +576,35 @@ NTSTATUS WINAPI RtlEqualDomainName(const UNICODE_STRING *left,
}
/**************************************************************************
* RtlAnsiCharToUnicodeChar (NTDLL.@)
*
* Converts the first ansi character to a unicode character.
*
* PARAMS
* ansi [I/O] Pointer to the ansi string.
*
* RETURNS
* Unicode representation of the first character in the ansi string.
*
* NOTES
* Upon successful completion, the char pointer ansi points to is
* incremented by the size of the character.
*/
WCHAR WINAPI RtlAnsiCharToUnicodeChar(LPSTR *ansi)
{
WCHAR str;
DWORD charSize = sizeof(CHAR);
if (is_dbcs_leadbyte(ansi_table, **ansi))
charSize++;
RtlMultiByteToUnicodeN(&str, sizeof(WCHAR), NULL, *ansi, charSize);
*ansi += charSize;
return str;
}
/*
COPY BETWEEN ANSI_STRING or UNICODE_STRING
there is no parameter checking, it just crashes
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment