--- trunk/reactos/lib/rtl/unicode.c 2005-07-01 03:03:06 UTC (rev 16361)
+++ trunk/reactos/lib/rtl/unicode.c 2005-07-01 03:14:40 UTC (rev 16362)
@@ -21,7 +21,6 @@
*/
#define __NTDRIVER__
#include "rtl.h"
-#include <rosrtl/string.h>
#define NDEBUG
#include <debug.h>
@@ -972,30 +971,7 @@
return Size+1; //NB: incl. nullterm
}
-
/*
- * @implemented
- *
-
- * NOTES
- * See RtlpUnicodeStringToAnsiString
- */
-NTSTATUS
-STDCALL
-RtlUnicodeStringToAnsiString(
- IN OUT PANSI_STRING AnsiDest,
- IN PUNICODE_STRING UniSource,
- IN BOOLEAN AllocateDestinationString)
-{
- return RtlpUnicodeStringToAnsiString(
- AnsiDest,
- UniSource,
- AllocateDestinationString,
- PagedPool);
-}
-
-
-/*
* private
*
* NOTES
@@ -1056,28 +1032,27 @@
return Status;
}
-
/*
* @implemented
*
+
* NOTES
- * See RtlpOemStringToUnicodeString
+ * See RtlpUnicodeStringToAnsiString
*/
NTSTATUS
STDCALL
-RtlOemStringToUnicodeString(
- IN OUT PUNICODE_STRING UniDest,
- IN POEM_STRING OemSource,
+RtlUnicodeStringToAnsiString(
+ IN OUT PANSI_STRING AnsiDest,
+ IN PUNICODE_STRING UniSource,
IN BOOLEAN AllocateDestinationString)
{
- return RtlpOemStringToUnicodeString(
- UniDest,
- OemSource,
+ return RtlpUnicodeStringToAnsiString(
+ AnsiDest,
+ UniSource,
AllocateDestinationString,
PagedPool);
}
-
/*
* private
*
@@ -1145,24 +1120,22 @@
* @implemented
*
* NOTES
- * See RtlpUnicodeStringToOemString.
+ * See RtlpOemStringToUnicodeString
*/
NTSTATUS
STDCALL
-RtlUnicodeStringToOemString(
- IN OUT POEM_STRING OemDest,
- IN PUNICODE_STRING UniSource,
- IN BOOLEAN AllocateDestinationString)
+RtlOemStringToUnicodeString(
+ IN OUT PUNICODE_STRING UniDest,
+ IN POEM_STRING OemSource,
+ IN BOOLEAN AllocateDestinationString)
{
- return RtlpUnicodeStringToOemString(
- OemDest,
- UniSource,
+ return RtlpOemStringToUnicodeString(
+ UniDest,
+ OemSource,
AllocateDestinationString,
PagedPool);
}
-
-
/*
* private
*
@@ -1224,8 +1197,26 @@
return Status;
}
+/*
+ * @implemented
+ *
+ * NOTES
+ * See RtlpUnicodeStringToOemString.
+ */
+NTSTATUS
+STDCALL
+RtlUnicodeStringToOemString(
+ IN OUT POEM_STRING OemDest,
+ IN PUNICODE_STRING UniSource,
+ IN BOOLEAN AllocateDestinationString)
+{
+ return RtlpUnicodeStringToOemString(
+ OemDest,
+ UniSource,
+ AllocateDestinationString,
+ PagedPool);
+}
-
#define ITU_IMPLEMENTED_TESTS (IS_TEXT_UNICODE_ODD_LENGTH|IS_TEXT_UNICODE_SIGNATURE)
@@ -1287,29 +1278,7 @@
return Length;
}
-
/*
- * @implemented
- *
- * NOTES
- * See RtlpOemStringToCountedUnicodeString
- */
-NTSTATUS
-STDCALL
-RtlOemStringToCountedUnicodeString(
- IN OUT PUNICODE_STRING UniDest,
- IN POEM_STRING OemSource,
- IN BOOLEAN AllocateDestinationString)
-{
- return RtlpOemStringToCountedUnicodeString(
- UniDest,
- OemSource,
- AllocateDestinationString,
- PagedPool);
-}
-
-
-/*
* private
*
* NOTES
@@ -1365,6 +1334,25 @@
return Status;
}
+/*
+ * @implemented
+ *
+ * NOTES
+ * See RtlpOemStringToCountedUnicodeString
+ */
+NTSTATUS
+STDCALL
+RtlOemStringToCountedUnicodeString(
+ IN OUT PUNICODE_STRING UniDest,
+ IN POEM_STRING OemSource,
+ IN BOOLEAN AllocateDestinationString)
+{
+ return RtlpOemStringToCountedUnicodeString(
+ UniDest,
+ OemSource,
+ AllocateDestinationString,
+ PagedPool);
+}
/*
* @implemented
@@ -1655,26 +1643,6 @@
}
/*
- * @implemented
- *
- * NOTES
- * See RtlpUnicodeStringToCountedOemString.
- */
-NTSTATUS
-STDCALL
-RtlUnicodeStringToCountedOemString(
- IN OUT POEM_STRING OemDest,
- IN PUNICODE_STRING UniSource,
- IN BOOLEAN AllocateDestinationString)
-{
- return RtlpUnicodeStringToCountedOemString(
- OemDest,
- UniSource,
- AllocateDestinationString,
- PagedPool);
-}
-
-/*
* private
*
* NOTES
@@ -1733,6 +1701,25 @@
return Status;
}
+/*
+ * @implemented
+ *
+ * NOTES
+ * See RtlpUnicodeStringToCountedOemString.
+ */
+NTSTATUS
+STDCALL
+RtlUnicodeStringToCountedOemString(
+ IN OUT POEM_STRING OemDest,
+ IN PUNICODE_STRING UniSource,
+ IN BOOLEAN AllocateDestinationString)
+{
+ return RtlpUnicodeStringToCountedOemString(
+ OemDest,
+ UniSource,
+ AllocateDestinationString,
+ PagedPool);
+}
/*
* @implemented
@@ -1783,31 +1770,7 @@
return STATUS_SUCCESS;
}
-
-
/*
- * @implemented
- *
- * NOTES
- * See RtlpUpcaseUnicodeString
- */
-NTSTATUS
-STDCALL
-RtlUpcaseUnicodeString(
- IN OUT PUNICODE_STRING UniDest,
- IN PCUNICODE_STRING UniSource,
- IN BOOLEAN AllocateDestinationString)
-{
-
- return RtlpUpcaseUnicodeString(
- UniDest,
- UniSource,
- AllocateDestinationString,
- PagedPool);
-}
-
-
-/*
* private
*
* NOTES
@@ -1851,23 +1814,22 @@
return STATUS_SUCCESS;
}
-
-
/*
* @implemented
*
* NOTES
- * See RtlpUpcaseUnicodeStringToAnsiString
+ * See RtlpUpcaseUnicodeString
*/
NTSTATUS
STDCALL
-RtlUpcaseUnicodeStringToAnsiString(
- IN OUT PANSI_STRING AnsiDest,
- IN PUNICODE_STRING UniSource,
+RtlUpcaseUnicodeString(
+ IN OUT PUNICODE_STRING UniDest,
+ IN PCUNICODE_STRING UniSource,
IN BOOLEAN AllocateDestinationString)
{
- return RtlpUpcaseUnicodeStringToAnsiString(
- AnsiDest,
+
+ return RtlpUpcaseUnicodeString(
+ UniDest,
UniSource,
AllocateDestinationString,
PagedPool);
@@ -1939,30 +1901,26 @@
return Status;
}
-
-
/*
* @implemented
*
* NOTES
- * See RtlpUpcaseUnicodeStringToCountedOemString
+ * See RtlpUpcaseUnicodeStringToAnsiString
*/
NTSTATUS
STDCALL
-RtlUpcaseUnicodeStringToCountedOemString(
- IN OUT POEM_STRING OemDest,
+RtlUpcaseUnicodeStringToAnsiString(
+ IN OUT PANSI_STRING AnsiDest,
IN PUNICODE_STRING UniSource,
- IN BOOLEAN AllocateDestinationString)
+ IN BOOLEAN AllocateDestinationString)
{
- return RtlpUpcaseUnicodeStringToCountedOemString(
- OemDest,
+ return RtlpUpcaseUnicodeStringToAnsiString(
+ AnsiDest,
UniSource,
AllocateDestinationString,
PagedPool);
}
-
-
/*
* private
*
@@ -2026,28 +1984,26 @@
return Status;
}
-
/*
* @implemented
+ *
* NOTES
- * See RtlpUpcaseUnicodeStringToOemString
+ * See RtlpUpcaseUnicodeStringToCountedOemString
*/
NTSTATUS
STDCALL
-RtlUpcaseUnicodeStringToOemString (
+RtlUpcaseUnicodeStringToCountedOemString(
IN OUT POEM_STRING OemDest,
IN PUNICODE_STRING UniSource,
- IN BOOLEAN AllocateDestinationString
-)
+ IN BOOLEAN AllocateDestinationString)
{
- return RtlpUpcaseUnicodeStringToOemString(
+ return RtlpUpcaseUnicodeStringToCountedOemString(
OemDest,
UniSource,
AllocateDestinationString,
PagedPool);
}
-
/*
* private
*
@@ -2114,6 +2070,25 @@
return Status;
}
+/*
+ * @implemented
+ * NOTES
+ * See RtlpUpcaseUnicodeStringToOemString
+ */
+NTSTATUS
+STDCALL
+RtlUpcaseUnicodeStringToOemString (
+ IN OUT POEM_STRING OemDest,
+ IN PUNICODE_STRING UniSource,
+ IN BOOLEAN AllocateDestinationString
+)
+{
+ return RtlpUpcaseUnicodeStringToOemString(
+ OemDest,
+ UniSource,
+ AllocateDestinationString,
+ PagedPool);
+}
/*
* @implemented
@@ -2309,26 +2284,7 @@
DestinationString->Length = copylen;
}
-
/*
- * @implemented
- *
- * NOTES
- * See RtlpCreateUnicodeString
- */
-BOOLEAN
-STDCALL
-RtlCreateUnicodeString(
- IN OUT PUNICODE_STRING UniDest,
- IN PCWSTR Source)
-{
-
- DPRINT("RtlCreateUnicodeString\n");
- return RtlpCreateUnicodeString(UniDest, Source, PagedPool);
-}
-
-
-/*
* private
*
* Creates a nullterminated UNICODE_STRING
@@ -2358,7 +2314,22 @@
return TRUE;
}
+/*
+ * @implemented
+ *
+ * NOTES
+ * See RtlpCreateUnicodeString
+ */
+BOOLEAN
+STDCALL
+RtlCreateUnicodeString(
+ IN OUT PUNICODE_STRING UniDest,
+ IN PCWSTR Source)
+{
+ DPRINT("RtlCreateUnicodeString\n");
+ return RtlpCreateUnicodeString(UniDest, Source, PagedPool);
+}
/*
* @implemented
@@ -2382,29 +2353,7 @@
return NT_SUCCESS(Status);
}
-
-
/*
- * @implemented
- *
- * NOTES
- * See RtlpDowncaseUnicodeString
- */
-NTSTATUS STDCALL
-RtlDowncaseUnicodeString(
- IN OUT PUNICODE_STRING UniDest,
- IN PUNICODE_STRING UniSource,
- IN BOOLEAN AllocateDestinationString)
-{
- return RtlpDowncaseUnicodeString(
- UniDest,
- UniSource,
- AllocateDestinationString,
- PagedPool);
-}
-
-
-/*
* private
*
* NOTES
@@ -2462,8 +2411,25 @@
return STATUS_SUCCESS;
}
+/*
+ * @implemented
+ *
+ * NOTES
+ * See RtlpDowncaseUnicodeString
+ */
+NTSTATUS STDCALL
+RtlDowncaseUnicodeString(
+ IN OUT PUNICODE_STRING UniDest,
+ IN PUNICODE_STRING UniSource,
+ IN BOOLEAN AllocateDestinationString)
+{
+ return RtlpDowncaseUnicodeString(
+ UniDest,
+ UniSource,
+ AllocateDestinationString,
+ PagedPool);
+}
-
/*
* @implemented
*
@@ -2492,30 +2458,7 @@
return(STATUS_SUCCESS);
}
-
/*
- * @implemented
- *
- * NOTES
- * See RtlpAnsiStringToUnicodeString
- */
-NTSTATUS
-STDCALL
-RtlAnsiStringToUnicodeString(
- IN OUT PUNICODE_STRING UniDest,
- IN PANSI_STRING AnsiSource,
- IN BOOLEAN AllocateDestinationString)
-{
- return RtlpAnsiStringToUnicodeString(
- UniDest,
- AnsiSource,
- AllocateDestinationString,
- PagedPool);
-}
-
-
-
-/*
* private
*
* NOTES
@@ -2577,8 +2520,26 @@
return Status;
}
+/*
+ * @implemented
+ *
+ * NOTES
+ * See RtlpAnsiStringToUnicodeString
+ */
+NTSTATUS
+STDCALL
+RtlAnsiStringToUnicodeString(
+ IN OUT PUNICODE_STRING UniDest,
+ IN PANSI_STRING AnsiSource,
+ IN BOOLEAN AllocateDestinationString)
+{
+ return RtlpAnsiStringToUnicodeString(
+ UniDest,
+ AnsiSource,
+ AllocateDestinationString,
+ PagedPool);
+}
-
/*
* @implemented
*
@@ -2684,31 +2645,10 @@
return RtlUnicodeStringToOemSize(UnicodeString);
}
-
/*
* @implemented
- *
- * NOTES
- * See RtlpDuplicateUnicodeString
*/
NTSTATUS STDCALL
-RtlDuplicateUnicodeString(
- INT AddNull,
- IN PUNICODE_STRING SourceString,
- PUNICODE_STRING DestinationString)
-{
- return RtlpDuplicateUnicodeString(
- AddNull,
- SourceString,
- DestinationString,
- PagedPool);
-}
-
-
-/*
- * @implemented
- */
-NTSTATUS STDCALL
RtlpDuplicateUnicodeString(
INT AddNull,
IN PUNICODE_STRING SourceString,
@@ -2747,6 +2687,24 @@
return STATUS_SUCCESS;
}
+/*
+ * @implemented
+ *
+ * NOTES
+ * See RtlpDuplicateUnicodeString
+ */
+NTSTATUS STDCALL
+RtlDuplicateUnicodeString(
+ INT AddNull,
+ IN PUNICODE_STRING SourceString,
+ PUNICODE_STRING DestinationString)
+{
+ return RtlpDuplicateUnicodeString(
+ AddNull,
+ SourceString,
+ DestinationString,
+ PagedPool);
+}
/*
* @implemented