The RtlFreeUnicodeString routine releases storage that was allocated by RtlAnsiStringToUnicodeString or RtlUpcaseUnicodeString.
VOID
RtlFreeUnicodeString(
IN PUNICODE_STRING UnicodeString
);
None
Declared in wdm.h and ntddk.h. Include wdm.h or ntddk.h.
This routine does not release the ANSI string buffer passed to RtlAnsiStringToUnicodeString.
Callers of RtlFreeUnicodeString must be running at IRQL = PASSIVE_LEVEL.