#ifndef _NTRTL_H
#ifndef PHNT_NO_INLINE_INIT_STRING
FORCEINLINE NTSTATUS RtlInitUnicodeStringEx(
_Out_ PUNICODE_STRING DestinationString,
_In_opt_z_ PCWSTR SourceString
)
{
size_t stringLength;
DestinationString->Length = 0;
DestinationString->Buffer = (PWCH)SourceString;
if (!SourceString)
return STATUS_SUCCESS;
stringLength = wcslen(SourceString);
if (stringLength <= UNICODE_STRING_MAX_CHARS - 1)
{
DestinationString->Length = (USHORT)stringLength * sizeof(WCHAR);
DestinationString->MaximumLength = DestinationString->Length + sizeof(UNICODE_NULL);
return STATUS_SUCCESS;
}
return STATUS_NAME_TOO_LONG;
}
View code on GitHub
#ifndef _NTRTL_H
#ifndef PHNT_NO_INLINE_INIT_STRING
// ...
#else
NTSYSAPI
NTSTATUS
NTAPI
RtlInitUnicodeStringEx(
_Out_ PUNICODE_STRING DestinationString,
_In_opt_z_ PCWSTR SourceString
);
View code on GitHub
No description available.