ReactOS  0.4.15-dev-4921-g25fcdc5
nlsboot.c File Reference
#include <rtl.h>
Include dependency graph for nlsboot.c:

Go to the source code of this file.

Functions

WCHAR NTAPI RtlpDowncaseUnicodeChar (_In_ WCHAR Source)
 
WCHAR NTAPI RtlDowncaseUnicodeChar (_In_ WCHAR Source)
 
_Use_decl_annotations_ NTSTATUS NTAPI RtlMultiByteToUnicodeN (_Out_ PWCH UnicodeString, _In_ ULONG UnicodeSize, _Out_opt_ PULONG ResultSize, _In_ PCCH MbString, _In_ ULONG MbSize)
 
_Use_decl_annotations_ NTSTATUS NTAPI RtlMultiByteToUnicodeSize (_Out_ PULONG UnicodeSize, _In_ PCCH MbString, _In_ ULONG MbSize)
 
_Use_decl_annotations_ NTSTATUS NTAPI RtlUnicodeToMultiByteN (_Out_ PCHAR MbString, _In_ ULONG MbSize, _Out_opt_ PULONG ResultSize, _In_ PCWCH UnicodeString, _In_ ULONG UnicodeSize)
 
_Use_decl_annotations_ NTSTATUS NTAPI RtlUnicodeToMultiByteSize (_Out_ PULONG MbSize, _In_ PCWCH UnicodeString, _In_ ULONG UnicodeSize)
 
WCHAR NTAPI RtlpUpcaseUnicodeChar (_In_ WCHAR Source)
 
WCHAR NTAPI RtlUpcaseUnicodeChar (_In_ WCHAR Source)
 
_Use_decl_annotations_ NTSTATUS NTAPI RtlUpcaseUnicodeToMultiByteN (_Out_ PCHAR MbString, _In_ ULONG MbSize, _Out_opt_ PULONG ResultSize, _In_ PCWCH UnicodeString, _In_ ULONG UnicodeSize)
 
CHAR NTAPI RtlUpperChar (_In_ CHAR Source)
 
_Use_decl_annotations_ NTSTATUS NTAPI RtlUnicodeToOemN (_Out_ PCHAR OemString, _In_ ULONG OemSize, _Out_opt_ PULONG ResultSize, _In_ PCWCH UnicodeString, _In_ ULONG UnicodeSize)
 
_Use_decl_annotations_ NTSTATUS NTAPI RtlOemToUnicodeN (_Out_ PWCHAR UnicodeString, _In_ ULONG UnicodeSize, _Out_opt_ PULONG ResultSize, _In_ PCCH OemString, _In_ ULONG OemSize)
 
_Use_decl_annotations_ NTSTATUS NTAPI RtlUpcaseUnicodeToOemN (_Out_ PCHAR OemString, _In_ ULONG OemSize, _Out_opt_ PULONG ResultSize, _In_ PCWCH UnicodeString, _In_ ULONG UnicodeSize)
 

Variables

BOOLEAN NlsMbCodePageTag = FALSE
 
BOOLEAN NlsMbOemCodePageTag = FALSE
 
PUSHORT NlsOemToUnicodeTable = NULL
 
PCHAR NlsUnicodeToOemTable = NULL
 
PUSHORT NlsUnicodeToMbOemTable = NULL
 
PUSHORT NlsOemLeadByteInfo = NULL
 
USHORT NlsOemDefaultChar = '\0'
 
USHORT NlsUnicodeDefaultChar = 0
 

Function Documentation

◆ RtlDowncaseUnicodeChar()

WCHAR NTAPI RtlDowncaseUnicodeChar ( _In_ WCHAR  Source)

Definition at line 53 of file nlsboot.c.

55 {
57 }
WCHAR NTAPI RtlpDowncaseUnicodeChar(_In_ WCHAR Source)
Definition: nlsboot.c:32
_In_ UINT _In_ UINT _In_ PNDIS_PACKET Source
Definition: ndis.h:3167

◆ RtlMultiByteToUnicodeN()

_Use_decl_annotations_ NTSTATUS NTAPI RtlMultiByteToUnicodeN ( _Out_ PWCH  UnicodeString,
_In_ ULONG  UnicodeSize,
_Out_opt_ PULONG  ResultSize,
_In_ PCCH  MbString,
_In_ ULONG  MbSize 
)

Definition at line 62 of file nlsboot.c.

68 {
69  ULONG Size = 0;
70  ULONG i;
71 
72  /* single-byte code page */
73  if (MbSize > (UnicodeSize / sizeof(WCHAR)))
74  Size = UnicodeSize / sizeof(WCHAR);
75  else
76  Size = MbSize;
77 
78  if (ResultSize)
79  *ResultSize = Size * sizeof(WCHAR);
80 
81  for (i = 0; i < Size; i++)
82  {
83  /* Trivially zero-extend */
84  UnicodeString[i] = (WCHAR)MbString[i];
85  }
86 
87  return STATUS_SUCCESS;
88 }
IN PVOID IN PVOID IN USHORT IN USHORT Size
Definition: pci.h:361
__wchar_t WCHAR
Definition: xmlstorage.h:180
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
unsigned int ULONG
Definition: retypes.h:1
#define STATUS_SUCCESS
Definition: shellext.h:65

Referenced by CreateAcceleratorTableA(), CreateColorSpaceA(), FilenameA2W_N(), HEAP_strdupA2W(), InfHostOpenBufferedFile(), InfHostOpenFile(), InfOpenBufferedFile(), InfOpenFile(), map_wparam_AtoW(), mbstowcs(), MBToWCSEx(), MsgiUnicodeToAnsiReply(), NtUserCreateAcceleratorTable(), parse_manifest(), RtlAnsiCharToUnicodeChar(), RtlAnsiStringToUnicodeString(), and User32CreateWindowEx().

◆ RtlMultiByteToUnicodeSize()

_Use_decl_annotations_ NTSTATUS NTAPI RtlMultiByteToUnicodeSize ( _Out_ PULONG  UnicodeSize,
_In_ PCCH  MbString,
_In_ ULONG  MbSize 
)

Definition at line 93 of file nlsboot.c.

97 {
98  /* single-byte code page */
99  *UnicodeSize = MbSize * sizeof(WCHAR);
100 
101  return STATUS_SUCCESS;
102 }
__wchar_t WCHAR
Definition: xmlstorage.h:180
#define STATUS_SUCCESS
Definition: shellext.h:65

Referenced by mbstowcs(), parse_manifest(), RtlxAnsiStringToUnicodeSize(), and RtlxOemStringToUnicodeSize().

◆ RtlOemToUnicodeN()

_Use_decl_annotations_ NTSTATUS NTAPI RtlOemToUnicodeN ( _Out_ PWCHAR  UnicodeString,
_In_ ULONG  UnicodeSize,
_Out_opt_ PULONG  ResultSize,
_In_ PCCH  OemString,
_In_ ULONG  OemSize 
)

Definition at line 282 of file nlsboot.c.

288 {
289  if (UnicodeString)
291 
292  if (ResultSize)
293  *ResultSize = 0;
294 
295  return STATUS_NOT_IMPLEMENTED;
296 }
return STATUS_NOT_IMPLEMENTED
#define UNICODE_NULL

Referenced by CdFindActiveVolDescriptor(), CdUpdateDirentName(), CdUpdatePathEntryName(), FilenameA2W_N(), FsRtlNotifyUpdateBuffer(), RtlOemStringToCountedUnicodeString(), and RtlOemStringToUnicodeString().

◆ RtlpDowncaseUnicodeChar()

WCHAR NTAPI RtlpDowncaseUnicodeChar ( _In_ WCHAR  Source)

Definition at line 32 of file nlsboot.c.

34 {
35  USHORT Offset = 0;
36 
37  if (Source < L'A')
38  return Source;
39 
40  if (Source <= L'Z')
41  return Source + (L'a' - L'A');
42 
43 #if 0
44  if (Source < 0x80)
45  return Source;
46 #endif
47 
48  return Source + (SHORT)Offset;
49 }
#define L(x)
Definition: ntvdm.h:50
short SHORT
Definition: pedump.c:59
_In_ ULONG _In_ ULONG Offset
Definition: ntddpcm.h:101
unsigned short USHORT
Definition: pedump.c:61
_In_ UINT _In_ UINT _In_ PNDIS_PACKET Source
Definition: ndis.h:3167

Referenced by RtlDowncaseUnicodeChar(), RtlDowncaseUnicodeString(), and RtlIsDosDeviceName_Ustr().

◆ RtlpUpcaseUnicodeChar()

WCHAR NTAPI RtlpUpcaseUnicodeChar ( _In_ WCHAR  Source)

Definition at line 160 of file nlsboot.c.

162 {
163  USHORT Offset = 0;
164 
165  if (Source < 'a')
166  return Source;
167 
168  if (Source <= 'z')
169  return (Source - ('a' - 'A'));
170 
171  return Source + (SHORT)Offset;
172 }
short SHORT
Definition: pedump.c:59
_In_ ULONG _In_ ULONG Offset
Definition: ntddpcm.h:101
unsigned short USHORT
Definition: pedump.c:61
_In_ UINT _In_ UINT _In_ PNDIS_PACKET Source
Definition: ndis.h:3167

Referenced by CompareUnicodeStrings(), RtlCompareUnicodeString(), RtlGenerate8dot3Name(), RtlGetFullPathName_Ustr(), RtlIsValidOemCharacter(), RtlpIsCharInUnicodeString(), RtlPrefixUnicodeString(), RtlUpcaseUnicodeChar(), RtlUpcaseUnicodeString(), RtlUpcaseUnicodeToMultiByteN(), and RtlUpperChar().

◆ RtlUnicodeToMultiByteN()

_Use_decl_annotations_ NTSTATUS NTAPI RtlUnicodeToMultiByteN ( _Out_ PCHAR  MbString,
_In_ ULONG  MbSize,
_Out_opt_ PULONG  ResultSize,
_In_ PCWCH  UnicodeString,
_In_ ULONG  UnicodeSize 
)

Definition at line 107 of file nlsboot.c.

113 {
114  ULONG Size = 0;
115  ULONG i;
116 
117  /* single-byte code page */
118  Size = (UnicodeSize > (MbSize * sizeof(WCHAR)))
119  ? MbSize : (UnicodeSize / sizeof(WCHAR));
120 
121  if (ResultSize)
122  *ResultSize = Size;
123 
124  for (i = 0; i < Size; i++)
125  {
126  /* Check for characters that cannot be trivially demoted to ANSI */
127  if (*((PCHAR)UnicodeString + 1) == 0)
128  {
129  *MbString++ = (CHAR)*UnicodeString++;
130  }
131  else
132  {
133  /* Invalid character, use default */
134  *MbString++ = NlsOemDefaultChar;
135  UnicodeString++;
136  }
137  }
138 
139  return STATUS_SUCCESS;
140 }
signed char * PCHAR
Definition: retypes.h:7
IN PVOID IN PVOID IN USHORT IN USHORT Size
Definition: pci.h:361
USHORT NlsOemDefaultChar
Definition: nlsboot.c:25
__wchar_t WCHAR
Definition: xmlstorage.h:180
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
unsigned int ULONG
Definition: retypes.h:1
#define STATUS_SUCCESS
Definition: shellext.h:65
#define CHAR(Char)

Referenced by CopyAcceleratorTableA(), FilenameW2A_N(), GetClassNameA(), GetInterfaceName(), LoadStringA(), MsgiAnsiToUnicodeReply(), PARSER_string_substA(), PathCreateFromUrlA(), pSetupDebugPrint(), RealGetWindowClassA(), RegEnumKeyExA(), RegEnumValueA(), RegQueryValueExA(), RtlIpv6AddressToStringA(), RtlIpv6AddressToStringExA(), RtlUnicodeStringToAnsiString(), SearchPathA(), UrlCreateFromPathA(), UrlEscapeA(), WCSToMBEx(), wcstombs(), and wctomb().

◆ RtlUnicodeToMultiByteSize()

_Use_decl_annotations_ NTSTATUS NTAPI RtlUnicodeToMultiByteSize ( _Out_ PULONG  MbSize,
_In_ PCWCH  UnicodeString,
_In_ ULONG  UnicodeSize 
)

Definition at line 145 of file nlsboot.c.

149 {
150  ULONG UnicodeLength = UnicodeSize / sizeof(WCHAR);
151 
152  /* single-byte code page */
153  *MbSize = UnicodeLength;
154 
155  return STATUS_SUCCESS;
156 }
__wchar_t WCHAR
Definition: xmlstorage.h:180
unsigned int ULONG
Definition: retypes.h:1
#define STATUS_SUCCESS
Definition: shellext.h:65

Referenced by GetCurrentDirectoryA(), GetEnvironmentStringsA(), GetFullPathNameA(), GetSystemDirectoryA(), GetSystemWindowsDirectoryA(), IntDefWindowProc(), PARSER_string_substA(), PathCreateFromUrlA(), pSetupDebugPrint(), RealDefWindowProcA(), RealDefWindowProcW(), RegQueryValueExA(), RtlxUnicodeStringToAnsiSize(), RtlxUnicodeStringToOemSize(), SearchPathA(), UrlCreateFromPathA(), UrlEscapeA(), and wcstombs().

◆ RtlUnicodeToOemN()

_Use_decl_annotations_ NTSTATUS NTAPI RtlUnicodeToOemN ( _Out_ PCHAR  OemString,
_In_ ULONG  OemSize,
_Out_opt_ PULONG  ResultSize,
_In_ PCWCH  UnicodeString,
_In_ ULONG  UnicodeSize 
)

Stubbed OEM helpers that should not be used in the OS boot loader, but are necessary for linking with the rest of the RTL unicode.c.

Definition at line 263 of file nlsboot.c.

269 {
270  if (OemSize)
271  *OemString = ANSI_NULL;
272 
273  if (ResultSize)
274  *ResultSize = 0;
275 
276  return STATUS_NOT_IMPLEMENTED;
277 }
*BytesInOemString PCHAR OemString
Definition: rtlfuncs.h:1560
return STATUS_NOT_IMPLEMENTED
#define ANSI_NULL

Referenced by _IRQL_requires_max_(), FilenameW2A_N(), GetEnvironmentStringsA(), RtlUnicodeStringToOemString(), and START_TEST().

◆ RtlUpcaseUnicodeChar()

◆ RtlUpcaseUnicodeToMultiByteN()

_Use_decl_annotations_ NTSTATUS NTAPI RtlUpcaseUnicodeToMultiByteN ( _Out_ PCHAR  MbString,
_In_ ULONG  MbSize,
_Out_opt_ PULONG  ResultSize,
_In_ PCWCH  UnicodeString,
_In_ ULONG  UnicodeSize 
)

Definition at line 185 of file nlsboot.c.

191 {
192  WCHAR UpcaseChar;
193  ULONG Size = 0;
194  ULONG i;
195 
196  /* single-byte code page */
197  if (UnicodeSize > (MbSize * sizeof(WCHAR)))
198  Size = MbSize;
199  else
200  Size = UnicodeSize / sizeof(WCHAR);
201 
202  if (ResultSize)
203  *ResultSize = Size;
204 
205  for (i = 0; i < Size; i++)
206  {
207  UpcaseChar = RtlpUpcaseUnicodeChar(*UnicodeString);
208 
209  /* Check for characters that cannot be trivially demoted to ANSI */
210  if (*((PCHAR)&UpcaseChar + 1) == 0)
211  {
212  *MbString = (CHAR)UpcaseChar;
213  }
214  else
215  {
216  /* Invalid character, use default */
217  *MbString = NlsOemDefaultChar;
218  }
219 
220  MbString++;
221  UnicodeString++;
222  }
223 
224  return STATUS_SUCCESS;
225 }
signed char * PCHAR
Definition: retypes.h:7
IN PVOID IN PVOID IN USHORT IN USHORT Size
Definition: pci.h:361
USHORT NlsOemDefaultChar
Definition: nlsboot.c:25
__wchar_t WCHAR
Definition: xmlstorage.h:180
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
WCHAR NTAPI RtlpUpcaseUnicodeChar(_In_ WCHAR Source)
Definition: nlsboot.c:160
unsigned int ULONG
Definition: retypes.h:1
#define STATUS_SUCCESS
Definition: shellext.h:65
#define CHAR(Char)

Referenced by RtlUpcaseUnicodeStringToAnsiString().

◆ RtlUpcaseUnicodeToOemN()

_Use_decl_annotations_ NTSTATUS NTAPI RtlUpcaseUnicodeToOemN ( _Out_ PCHAR  OemString,
_In_ ULONG  OemSize,
_Out_opt_ PULONG  ResultSize,
_In_ PCWCH  UnicodeString,
_In_ ULONG  UnicodeSize 
)

Definition at line 301 of file nlsboot.c.

307 {
308  if (OemSize)
309  *OemString = ANSI_NULL;
310 
311  if (ResultSize)
312  *ResultSize = 0;
313 
314  return STATUS_NOT_IMPLEMENTED;
315 }
*BytesInOemString PCHAR OemString
Definition: rtlfuncs.h:1560
return STATUS_NOT_IMPLEMENTED
#define ANSI_NULL

Referenced by RtlDnsHostNameToComputerName(), RtlUpcaseUnicodeStringToCountedOemString(), and RtlUpcaseUnicodeStringToOemString().

◆ RtlUpperChar()

CHAR NTAPI RtlUpperChar ( _In_ CHAR  Source)

Definition at line 229 of file nlsboot.c.

231 {
232  /* Check for simple ANSI case */
233  if (Source <= 'z')
234  {
235  /* Check for simple downcase a-z case */
236  if (Source >= 'a')
237  {
238  /* Just XOR with the difference */
239  return Source ^ ('a' - 'A');
240  }
241  else
242  {
243  /* Otherwise return the same char, it's already upcase */
244  return Source;
245  }
246  }
247  else
248  {
249  /* single-byte code page */
251  }
252 }
char CHAR
Definition: xmlstorage.h:175
__wchar_t WCHAR
Definition: xmlstorage.h:180
WCHAR NTAPI RtlpUpcaseUnicodeChar(_In_ WCHAR Source)
Definition: nlsboot.c:160
_In_ UINT _In_ UINT _In_ PNDIS_PACKET Source
Definition: ndis.h:3167

Referenced by DosChangeDirectory(), DosInitPsp(), DosInt21h(), DosKRNLInitialize(), RtlCompareString(), RtlPrefixString(), and RtlUpperString().

Variable Documentation

◆ NlsMbCodePageTag

BOOLEAN NlsMbCodePageTag = FALSE

Definition at line 17 of file nlsboot.c.

◆ NlsMbOemCodePageTag

BOOLEAN NlsMbOemCodePageTag = FALSE

Definition at line 19 of file nlsboot.c.

Referenced by FsRtlIsDbcsInExpression(), and RtlGenerate8dot3Name().

◆ NlsOemDefaultChar

USHORT NlsOemDefaultChar = '\0'

Definition at line 25 of file nlsboot.c.

Referenced by RtlUnicodeToMultiByteN(), and RtlUpcaseUnicodeToMultiByteN().

◆ NlsOemLeadByteInfo

PUSHORT NlsOemLeadByteInfo = NULL

Definition at line 23 of file nlsboot.c.

◆ NlsOemToUnicodeTable

PUSHORT NlsOemToUnicodeTable = NULL

Definition at line 20 of file nlsboot.c.

◆ NlsUnicodeDefaultChar

USHORT NlsUnicodeDefaultChar = 0

Definition at line 26 of file nlsboot.c.

◆ NlsUnicodeToMbOemTable

PUSHORT NlsUnicodeToMbOemTable = NULL

Definition at line 22 of file nlsboot.c.

◆ NlsUnicodeToOemTable

PCHAR NlsUnicodeToOemTable = NULL

Definition at line 21 of file nlsboot.c.