Author: dchapyshev
Date: Thu Sep 15 19:35:59 2016
New Revision: 72687
URL:
http://svn.reactos.org/svn/reactos?rev=72687&view=rev
Log:
[RTL] Add missed IN/OUT/OPTIONAL/PAGED_CODE_RTL
Modified:
trunk/reactos/sdk/lib/rtl/nls.c
Modified: trunk/reactos/sdk/lib/rtl/nls.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/sdk/lib/rtl/nls.c?rev=7268…
==============================================================================
--- trunk/reactos/sdk/lib/rtl/nls.c [iso-8859-1] (original)
+++ trunk/reactos/sdk/lib/rtl/nls.c [iso-8859-1] Thu Sep 15 19:35:59 2016
@@ -43,14 +43,16 @@
*/
NTSTATUS NTAPI
RtlCustomCPToUnicodeN(IN PCPTABLEINFO CustomCP,
- PWCHAR UnicodeString,
- ULONG UnicodeSize,
- PULONG ResultSize,
- PCHAR CustomString,
- ULONG CustomSize)
+ OUT PWCHAR UnicodeString,
+ IN ULONG UnicodeSize,
+ OUT PULONG ResultSize OPTIONAL,
+ IN PCHAR CustomString,
+ IN ULONG CustomSize)
{
ULONG Size = 0;
ULONG i;
+
+ PAGED_CODE_RTL();
if (CustomCP->DBCSCodePage == 0)
{
@@ -88,6 +90,8 @@
{
USHORT Offset;
+ PAGED_CODE_RTL();
+
if (Source < L'A')
return Source;
@@ -127,6 +131,8 @@
RtlGetDefaultCodePage(OUT PUSHORT AnsiCodePage,
OUT PUSHORT OemCodePage)
{
+ PAGED_CODE_RTL();
+
*AnsiCodePage = NlsAnsiCodePage;
*OemCodePage = NlsOemCodePage;
}
@@ -139,6 +145,8 @@
OUT PCPTABLEINFO CodePageTable)
{
PNLS_FILE_HEADER NlsFileHeader;
+
+ PAGED_CODE_RTL();
DPRINT("RtlInitCodePageTable() called\n");
@@ -191,6 +199,8 @@
IN PUSHORT CaseTableBase,
OUT PNLSTABLEINFO NlsTable)
{
+ PAGED_CODE_RTL();
+
DPRINT("RtlInitNlsTables()called\n");
if (AnsiTableBase && OemTableBase && CaseTableBase)
@@ -300,9 +310,9 @@
*/
NTSTATUS
NTAPI
-RtlMultiByteToUnicodeSize(PULONG UnicodeSize,
- PCSTR MbString,
- ULONG MbSize)
+RtlMultiByteToUnicodeSize(OUT PULONG UnicodeSize,
+ IN PCSTR MbString,
+ IN ULONG MbSize)
{
ULONG Length = 0;
@@ -348,14 +358,16 @@
* @unimplemented
*/
NTSTATUS NTAPI
-RtlOemToUnicodeN(PWCHAR UnicodeString,
- ULONG UnicodeSize,
- PULONG ResultSize,
- PCCH OemString,
- ULONG OemSize)
+RtlOemToUnicodeN(OUT PWCHAR UnicodeString,
+ IN ULONG UnicodeSize,
+ OUT PULONG ResultSize OPTIONAL,
+ IN PCCH OemString,
+ IN ULONG OemSize)
{
ULONG Size = 0;
ULONG i;
+
+ PAGED_CODE_RTL();
if (NlsMbOemCodePageTag == FALSE)
{
@@ -420,6 +432,8 @@
VOID NTAPI
RtlResetRtlTranslations(IN PNLSTABLEINFO NlsTable)
{
+ PAGED_CODE_RTL();
+
DPRINT("RtlResetRtlTranslations() called\n");
/* Set ANSI data */
@@ -454,14 +468,16 @@
*/
NTSTATUS NTAPI
RtlUnicodeToCustomCPN(IN PCPTABLEINFO CustomCP,
- PCHAR CustomString,
- ULONG CustomSize,
- PULONG ResultSize,
- PWCHAR UnicodeString,
- ULONG UnicodeSize)
+ OUT PCHAR CustomString,
+ IN ULONG CustomSize,
+ OUT PULONG ResultSize OPTIONAL,
+ IN PWCHAR UnicodeString,
+ IN ULONG UnicodeSize)
{
ULONG Size = 0;
ULONG i;
+
+ PAGED_CODE_RTL();
if (CustomCP->DBCSCodePage == 0)
{
@@ -495,11 +511,11 @@
* @unimplemented
*/
NTSTATUS NTAPI
-RtlUnicodeToMultiByteN(PCHAR MbString,
- ULONG MbSize,
- PULONG ResultSize,
- PCWCH UnicodeString,
- ULONG UnicodeSize)
+RtlUnicodeToMultiByteN(OUT PCHAR MbString,
+ IN ULONG MbSize,
+ OUT PULONG ResultSize OPTIONAL,
+ IN PCWCH UnicodeString,
+ IN ULONG UnicodeSize)
{
ULONG Size = 0;
ULONG i;
@@ -569,13 +585,15 @@
*/
NTSTATUS
NTAPI
-RtlUnicodeToMultiByteSize(PULONG MbSize,
- PCWCH UnicodeString,
- ULONG UnicodeSize)
+RtlUnicodeToMultiByteSize(OUT PULONG MbSize,
+ IN PCWCH UnicodeString,
+ IN ULONG UnicodeSize)
{
ULONG UnicodeLength = UnicodeSize / sizeof(WCHAR);
ULONG MbLength = 0;
+ PAGED_CODE_RTL();
+
if (!NlsMbCodePageTag)
{
/* single-byte code page */
@@ -611,14 +629,16 @@
* @unimplemented
*/
NTSTATUS NTAPI
-RtlUnicodeToOemN(PCHAR OemString,
- ULONG OemSize,
- PULONG ResultSize,
- PCWCH UnicodeString,
- ULONG UnicodeSize)
+RtlUnicodeToOemN(OUT PCHAR OemString,
+ IN ULONG OemSize,
+ OUT PULONG ResultSize OPTIONAL,
+ IN PCWCH UnicodeString,
+ IN ULONG UnicodeSize)
{
ULONG Size = 0;
ULONG i;
+
+ PAGED_CODE_RTL();
if (NlsMbOemCodePageTag == FALSE)
{
@@ -687,6 +707,8 @@
RtlUpcaseUnicodeChar(IN WCHAR Source)
{
USHORT Offset;
+
+ PAGED_CODE_RTL();
if (Source < 'a')
return Source;
@@ -721,6 +743,8 @@
ULONG Size = 0;
ULONG i;
+ PAGED_CODE_RTL();
+
if (!CustomCP->DBCSCodePage)
{
/* single-byte code page */
@@ -754,15 +778,17 @@
* @unimplemented
*/
NTSTATUS NTAPI
-RtlUpcaseUnicodeToMultiByteN(PCHAR MbString,
- ULONG MbSize,
- PULONG ResultSize,
- PCWCH UnicodeString,
- ULONG UnicodeSize)
+RtlUpcaseUnicodeToMultiByteN(OUT PCHAR MbString,
+ IN ULONG MbSize,
+ OUT PULONG ResultSize OPTIONAL,
+ IN PCWCH UnicodeString,
+ IN ULONG UnicodeSize)
{
WCHAR UpcaseChar;
ULONG Size = 0;
ULONG i;
+
+ PAGED_CODE_RTL();
if (NlsMbCodePageTag == FALSE)
{
@@ -797,15 +823,17 @@
* @unimplemented
*/
NTSTATUS NTAPI
-RtlUpcaseUnicodeToOemN(PCHAR OemString,
- ULONG OemSize,
- PULONG ResultSize,
- PCWCH UnicodeString,
- ULONG UnicodeSize)
+RtlUpcaseUnicodeToOemN(OUT PCHAR OemString,
+ IN ULONG OemSize,
+ OUT PULONG ResultSize OPTIONAL,
+ IN PCWCH UnicodeString,
+ IN ULONG UnicodeSize)
{
WCHAR UpcaseChar;
ULONG Size = 0;
ULONG i;
+
+ PAGED_CODE_RTL();
ASSERT(NlsUnicodeToOemTable != NULL);
@@ -879,6 +907,8 @@
WCHAR Unicode;
CHAR Destination;
+ PAGED_CODE_RTL();
+
/* Check for simple ANSI case */
if (Source <= 'z')
{