12#define RtlUTF8ToUnicodeN RtlUTF8ToUnicodeN_
19DEFINE_GUID(CLSID_WICImagingFactory, 0xcacaf262,0x9370,0x4615,0xa1,0x3b,0x9f,0x55,0x39,0xda,0x4c,0x0a);
30 ULONG utf8_trail_bytes;
36 if (!uni_bytes_written)
42 for (
i = 0;
i < utf8_bytes;
i++)
45 ch = (
BYTE)utf8_src[
i];
75 if (
i + utf8_trail_bytes < utf8_bytes)
77 for (
j = 0;
j < utf8_trail_bytes;
j++)
79 if ((utf8_src[
i + 1] & 0xc0) == 0x80)
82 ch |= utf8_src[
i + 1] & 0x3f;
103 if ((ch > 0x10ffff) ||
104 (ch >= 0xd800 && ch <= 0xdfff) ||
105 (utf8_trail_bytes == 2 && ch < 0x00800) ||
106 (utf8_trail_bytes == 3 && ch < 0x10000))
109 utf16_ch[0] = 0xfffd;
110 utf16_ch[1] = 0xfffd;
111 utf16_ch[2] = 0xfffd;
112 utf16_ch_len = utf8_trail_bytes;
115 else if (ch >= 0x10000)
119 utf16_ch[0] = 0xd800 + (ch >> 10 & 0x3ff);
120 utf16_ch[1] = 0xdc00 + (ch >> 0 & 0x3ff);
132 written += utf16_ch_len;
136 for (
j = 0;
j < utf16_ch_len;
j++)
138 if (uni_bytes_max >=
sizeof(
WCHAR))
140 *uni_dest++ = utf16_ch[
j];
141 uni_bytes_max -=
sizeof(
WCHAR);
152 *uni_bytes_written = written *
sizeof(
WCHAR);
196 if (FileInfoClass == -1)
204 dwBufferSize, FileInfoClass);
#define NT_SUCCESS(StatCode)
#define ERROR_INVALID_PARAMETER
@ FileEndOfFileInformation
@ FileCompressionInformation
@ FileIoPriorityHintInformation
@ FileAttributeTagInformation
@ FileIdBothDirectoryInformation
@ FileAllocationInformation
@ FileDispositionInformation
enum _FILE_INFORMATION_CLASS FILE_INFORMATION_CLASS
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
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 GLint GLint j
@ FileRemoteProtocolInformation
NTSYSAPI ULONG WINAPI RtlNtStatusToDosError(NTSTATUS)
static FILE_INFO_BY_HANDLE_CLASS
static OUT PIO_STATUS_BLOCK IoStatusBlock
static OUT PIO_STATUS_BLOCK OUT PVOID IN ULONG IN FILE_INFORMATION_CLASS FileInformationClass
NTSYSAPI NTSTATUS NTAPI NtSetInformationFile(IN HANDLE hFile, OUT PIO_STATUS_BLOCK pIoStatusBlock, IN PVOID FileInformationBuffer, IN ULONG FileInformationBufferLength, IN FILE_INFORMATION_CLASS FileInfoClass)
#define STATUS_INVALID_PARAMETER_4
#define STATUS_SOME_NOT_MAPPED
#define FileStandardInformation
#define DEFINE_GUID(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8)
DWORD BaseSetLastNTError(IN NTSTATUS Status)
FILE_INFORMATION_CLASS ConvertToFileInfo[MaximumFileInfoByHandleClass]
#define RtlUTF8ToUnicodeN
BOOL WINAPI SetFileInformationByHandle(HANDLE hFile, FILE_INFO_BY_HANDLE_CLASS FileInformationClass, LPVOID lpFileInformation, DWORD dwBufferSize)
#define STATUS_BUFFER_TOO_SMALL
#define STATUS_INVALID_PARAMETER