亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來(lái)到蟲(chóng)蟲(chóng)下載站! | ?? 資源下載 ?? 資源專(zhuān)輯 ?? 關(guān)于我們
? 蟲(chóng)蟲(chóng)下載站

?? utf.c

?? 新版輕量級(jí)嵌入式數(shù)據(jù)庫(kù)
?? C
?? 第 1 頁(yè) / 共 2 頁(yè)
字號(hào):
/*** 2004 April 13**** The author disclaims copyright to this source code.  In place of** a legal notice, here is a blessing:****    May you do good and not evil.**    May you find forgiveness for yourself and forgive others.**    May you share freely, never taking more than you give.***************************************************************************** This file contains routines used to translate between UTF-8, ** UTF-16, UTF-16BE, and UTF-16LE.**** $Id: utf.c,v 1.38 2006/02/24 02:53:50 drh Exp $**** Notes on UTF-8:****   Byte-0    Byte-1    Byte-2    Byte-3    Value**  0xxxxxxx                                 00000000 00000000 0xxxxxxx**  110yyyyy  10xxxxxx                       00000000 00000yyy yyxxxxxx**  1110zzzz  10yyyyyy  10xxxxxx             00000000 zzzzyyyy yyxxxxxx**  11110uuu  10uuzzzz  10yyyyyy  10xxxxxx   000uuuuu zzzzyyyy yyxxxxxx****** Notes on UTF-16:  (with wwww+1==uuuuu)****      Word-0               Word-1          Value**  110110ww wwzzzzyy   110111yy yyxxxxxx    000uuuuu zzzzyyyy yyxxxxxx**  zzzzyyyy yyxxxxxx                        00000000 zzzzyyyy yyxxxxxx****** BOM or Byte Order Mark:**     0xff 0xfe   little-endian utf-16 follows**     0xfe 0xff   big-endian utf-16 follows****** Handling of malformed strings:**** SQLite accepts and processes malformed strings without an error wherever** possible. However this is not possible when converting between UTF-8 and** UTF-16.**** When converting malformed UTF-8 strings to UTF-16, one instance of the** replacement character U+FFFD for each byte that cannot be interpeted as** part of a valid unicode character.**** When converting malformed UTF-16 strings to UTF-8, one instance of the** replacement character U+FFFD for each pair of bytes that cannot be** interpeted as part of a valid unicode character.**** This file contains the following public routines:**** sqlite3VdbeMemTranslate() - Translate the encoding used by a Mem* string.** sqlite3VdbeMemHandleBom() - Handle byte-order-marks in UTF16 Mem* strings.** sqlite3utf16ByteLen()     - Calculate byte-length of a void* UTF16 string.** sqlite3utf8CharLen()      - Calculate char-length of a char* UTF8 string.** sqlite3utf8LikeCompare()  - Do a LIKE match given two UTF8 char* strings.***/#include "sqliteInt.h"#include <assert.h>#include "vdbeInt.h"/*** This table maps from the first byte of a UTF-8 character to the number** of trailing bytes expected. A value '255' indicates that the table key** is not a legal first byte for a UTF-8 character.*/static const u8 xtra_utf8_bytes[256]  = {/* 0xxxxxxx */0, 0, 0, 0, 0, 0, 0, 0,     0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0,     0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0,     0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0,     0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0,     0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0,     0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0,     0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0,     0, 0, 0, 0, 0, 0, 0, 0,/* 10wwwwww */255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,/* 110yyyyy */1, 1, 1, 1, 1, 1, 1, 1,     1, 1, 1, 1, 1, 1, 1, 1,1, 1, 1, 1, 1, 1, 1, 1,     1, 1, 1, 1, 1, 1, 1, 1,/* 1110zzzz */2, 2, 2, 2, 2, 2, 2, 2,     2, 2, 2, 2, 2, 2, 2, 2,/* 11110yyy */3, 3, 3, 3, 3, 3, 3, 3,     255, 255, 255, 255, 255, 255, 255, 255,};/*** This table maps from the number of trailing bytes in a UTF-8 character** to an integer constant that is effectively calculated for each character** read by a naive implementation of a UTF-8 character reader. The code** in the READ_UTF8 macro explains things best.*/static const int xtra_utf8_bits[4] =  {0,12416,          /* (0xC0 << 6) + (0x80) */925824,         /* (0xE0 << 12) + (0x80 << 6) + (0x80) */63447168        /* (0xF0 << 18) + (0x80 << 12) + (0x80 << 6) + 0x80 */};#define READ_UTF8(zIn, c) { \  int xtra;                                            \  c = *(zIn)++;                                        \  xtra = xtra_utf8_bytes[c];                           \  switch( xtra ){                                      \    case 255: c = (int)0xFFFD; break;                  \    case 3: c = (c<<6) + *(zIn)++;                     \    case 2: c = (c<<6) + *(zIn)++;                     \    case 1: c = (c<<6) + *(zIn)++;                     \    c -= xtra_utf8_bits[xtra];                         \  }                                                    \}int sqlite3ReadUtf8(const unsigned char *z){  int c;  READ_UTF8(z, c);  return c;}#define SKIP_UTF8(zIn) {                               \  zIn += (xtra_utf8_bytes[*(u8 *)zIn] + 1);            \}#define WRITE_UTF8(zOut, c) {                          \  if( c<0x00080 ){                                     \    *zOut++ = (c&0xFF);                                \  }                                                    \  else if( c<0x00800 ){                                \    *zOut++ = 0xC0 + ((c>>6)&0x1F);                    \    *zOut++ = 0x80 + (c & 0x3F);                       \  }                                                    \  else if( c<0x10000 ){                                \    *zOut++ = 0xE0 + ((c>>12)&0x0F);                   \    *zOut++ = 0x80 + ((c>>6) & 0x3F);                  \    *zOut++ = 0x80 + (c & 0x3F);                       \  }else{                                               \    *zOut++ = 0xF0 + ((c>>18) & 0x07);                 \    *zOut++ = 0x80 + ((c>>12) & 0x3F);                 \    *zOut++ = 0x80 + ((c>>6) & 0x3F);                  \    *zOut++ = 0x80 + (c & 0x3F);                       \  }                                                    \}#define WRITE_UTF16LE(zOut, c) {                                \  if( c<=0xFFFF ){                                              \    *zOut++ = (c&0x00FF);                                       \    *zOut++ = ((c>>8)&0x00FF);                                  \  }else{                                                        \    *zOut++ = (((c>>10)&0x003F) + (((c-0x10000)>>10)&0x00C0));  \    *zOut++ = (0x00D8 + (((c-0x10000)>>18)&0x03));              \    *zOut++ = (c&0x00FF);                                       \    *zOut++ = (0x00DC + ((c>>8)&0x03));                         \  }                                                             \}#define WRITE_UTF16BE(zOut, c) {                                \  if( c<=0xFFFF ){                                              \    *zOut++ = ((c>>8)&0x00FF);                                  \    *zOut++ = (c&0x00FF);                                       \  }else{                                                        \    *zOut++ = (0x00D8 + (((c-0x10000)>>18)&0x03));              \    *zOut++ = (((c>>10)&0x003F) + (((c-0x10000)>>10)&0x00C0));  \    *zOut++ = (0x00DC + ((c>>8)&0x03));                         \    *zOut++ = (c&0x00FF);                                       \  }                                                             \}#define READ_UTF16LE(zIn, c){                                         \  c = (*zIn++);                                                       \  c += ((*zIn++)<<8);                                                 \  if( c>=0xD800 && c<=0xE000 ){                                       \    int c2 = (*zIn++);                                                \    c2 += ((*zIn++)<<8);                                              \    c = (c2&0x03FF) + ((c&0x003F)<<10) + (((c&0x03C0)+0x0040)<<10);   \  }                                                                   \}#define READ_UTF16BE(zIn, c){                                         \  c = ((*zIn++)<<8);                                                  \  c += (*zIn++);                                                      \  if( c>=0xD800 && c<=0xE000 ){                                       \    int c2 = ((*zIn++)<<8);                                           \    c2 += (*zIn++);                                                   \    c = (c2&0x03FF) + ((c&0x003F)<<10) + (((c&0x03C0)+0x0040)<<10);   \  }                                                                   \}#define SKIP_UTF16BE(zIn){                                            \  if( *zIn>=0xD8 && (*zIn<0xE0 || (*zIn==0xE0 && *(zIn+1)==0x00)) ){  \    zIn += 4;                                                         \  }else{                                                              \    zIn += 2;                                                         \  }                                                                   \}#define SKIP_UTF16LE(zIn){                                            \  zIn++;                                                              \  if( *zIn>=0xD8 && (*zIn<0xE0 || (*zIn==0xE0 && *(zIn-1)==0x00)) ){  \    zIn += 3;                                                         \  }else{                                                              \    zIn += 1;                                                         \  }                                                                   \}#define RSKIP_UTF16LE(zIn){                                            \  if( *zIn>=0xD8 && (*zIn<0xE0 || (*zIn==0xE0 && *(zIn-1)==0x00)) ){  \    zIn -= 4;                                                         \  }else{                                                              \    zIn -= 2;                                                         \  }                                                                   \}#define RSKIP_UTF16BE(zIn){                                            \  zIn--;                                                              \  if( *zIn>=0xD8 && (*zIn<0xE0 || (*zIn==0xE0 && *(zIn+1)==0x00)) ){  \    zIn -= 3;                                                         \  }else{                                                              \    zIn -= 1;                                                         \  }                                                                   \}/*** If the TRANSLATE_TRACE macro is defined, the value of each Mem is** printed on stderr on the way into and out of sqlite3VdbeMemTranslate().*/ /* #define TRANSLATE_TRACE 1 */#ifndef SQLITE_OMIT_UTF16/*** This routine transforms the internal text encoding used by pMem to** desiredEnc. It is an error if the string is already of the desired** encoding, or if *pMem does not contain a string value.*/int sqlite3VdbeMemTranslate(Mem *pMem, u8 desiredEnc){  unsigned char zShort[NBFS]; /* Temporary short output buffer */  int len;                    /* Maximum length of output string in bytes */  unsigned char *zOut;                  /* Output buffer */  unsigned char *zIn;                   /* Input iterator */  unsigned char *zTerm;                 /* End of input */  unsigned char *z;                     /* Output iterator */  int c;  assert( pMem->flags&MEM_Str );  assert( pMem->enc!=desiredEnc );  assert( pMem->enc!=0 );  assert( pMem->n>=0 );#if defined(TRANSLATE_TRACE) && defined(SQLITE_DEBUG)  {    char zBuf[100];    sqlite3VdbeMemPrettyPrint(pMem, zBuf);    fprintf(stderr, "INPUT:  %s\n", zBuf);  }#endif  /* If the translation is between UTF-16 little and big endian, then   ** all that is required is to swap the byte order. This case is handled  ** differently from the others.  */  if( pMem->enc!=SQLITE_UTF8 && desiredEnc!=SQLITE_UTF8 ){    u8 temp;    int rc;    rc = sqlite3VdbeMemMakeWriteable(pMem);    if( rc!=SQLITE_OK ){      assert( rc==SQLITE_NOMEM );      return SQLITE_NOMEM;    }    zIn = (u8*)pMem->z;    zTerm = &zIn[pMem->n];    while( zIn<zTerm ){      temp = *zIn;      *zIn = *(zIn+1);      zIn++;      *zIn++ = temp;    }    pMem->enc = desiredEnc;    goto translate_out;  }  /* Set len to the maximum number of bytes required in the output buffer. */  if( desiredEnc==SQLITE_UTF8 ){    /* When converting from UTF-16, the maximum growth results from    ** translating a 2-byte character to a 3-byte UTF-8 character (i.e.    ** code-point 0xFFFC). A single byte is required for the output string    ** nul-terminator.    */    len = (pMem->n/2) * 3 + 1;  }else{    /* When converting from UTF-8 to UTF-16 the maximum growth is caused    ** when a 1-byte UTF-8 character is translated into a 2-byte UTF-16    ** character. Two bytes are required in the output buffer for the    ** nul-terminator.

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品盗摄一区二区三区| 99视频在线精品| 国产福利一区二区三区视频在线 | 欧美一级片在线看| 精品国产自在久精品国产| 久久久久高清精品| 亚洲精选一二三| 日韩国产欧美视频| 成人少妇影院yyyy| 精品视频在线免费观看| 精品国产亚洲在线| 亚洲色欲色欲www| 青青草国产成人av片免费| 丁香网亚洲国际| 欧美精品777| 欧美国产日本视频| 天天操天天干天天综合网| 国产精品18久久久久久久久| 色婷婷精品大在线视频| 日韩欧美国产一区在线观看| 中文字幕一区二区三区在线观看| 午夜精品福利视频网站 | 日韩理论电影院| 日本视频一区二区三区| 北岛玲一区二区三区四区| 91成人免费在线| 久久久久国产成人精品亚洲午夜| 亚洲午夜视频在线| 成人精品鲁一区一区二区| 91精品国产免费| 亚洲免费观看高清完整版在线| 黄网站免费久久| 在线播放亚洲一区| 亚洲欧美在线观看| 国产在线一区二区综合免费视频| 欧美在线观看18| 国产精品久久久久久久久久免费看| 日本女优在线视频一区二区| 色欧美日韩亚洲| 国产精品视频一二三区| 久久不见久久见免费视频1| 色狠狠桃花综合| 亚洲国产精华液网站w | 国产日韩欧美在线一区| 日日噜噜夜夜狠狠视频欧美人| 99国产精品久久久久久久久久| 久久在线观看免费| 麻豆成人91精品二区三区| 精品视频全国免费看| 亚洲色图一区二区三区| youjizz国产精品| 欧美激情一区二区| 国产精品一二三区| 日韩无一区二区| 日韩国产精品大片| 欧美日韩激情一区二区三区| 一区二区三区四区在线播放 | 亚洲激情综合网| youjizz久久| 亚洲欧洲精品天堂一级| www.日韩在线| 综合久久国产九一剧情麻豆| 成人精品视频网站| 国产精品久99| av一区二区久久| 国产精品传媒视频| 99视频超级精品| 日韩理论片在线| 色哦色哦哦色天天综合| 中文字幕在线一区二区三区| 成人激情电影免费在线观看| 国产精品久久国产精麻豆99网站 | 亚洲女人的天堂| 91亚洲资源网| 亚洲欧美aⅴ...| 一本到不卡免费一区二区| 亚洲精品国产无天堂网2021| 色狠狠综合天天综合综合| 夜夜精品视频一区二区| 日本高清无吗v一区| 亚洲大片免费看| 91精品国产欧美一区二区成人 | 欧美成人猛片aaaaaaa| 免费观看在线色综合| 日韩一二三四区| 韩国毛片一区二区三区| 久久久久国产精品麻豆ai换脸| 丁香六月综合激情| 亚洲精品日韩专区silk| 欧美色男人天堂| 日韩av不卡一区二区| 日韩精品综合一本久道在线视频| 久久66热偷产精品| 国产性做久久久久久| av一区二区三区黑人| 亚洲一区二区在线视频| 欧美高清www午色夜在线视频| 日韩中文字幕av电影| 欧美成人a视频| 国产黄色成人av| 亚洲精选视频在线| 欧美一区二区三级| 风流少妇一区二区| 亚洲中国最大av网站| 91精品国产综合久久久蜜臀图片| 国产一区二区三区在线观看精品 | 在线观看视频一区| 日本网站在线观看一区二区三区| 久久色中文字幕| 色综合天天狠狠| 人人狠狠综合久久亚洲| 欧美精品一区二区三区久久久| proumb性欧美在线观看| 日韩高清在线不卡| 欧美激情一区三区| 91精品国产手机| 成人免费观看av| 日韩高清不卡一区二区三区| 中文字幕欧美国产| 欧美日本一区二区| 懂色av一区二区三区免费看| 亚洲大片精品永久免费| 国产亲近乱来精品视频| 欧美日韩另类一区| 成人激情电影免费在线观看| 首页国产欧美久久| 一区二区中文字幕在线| 欧美一级免费大片| 色综合夜色一区| 狠狠色狠狠色综合| 亚洲国产色一区| 欧美激情一区在线| 欧美一级精品大片| 日本伦理一区二区| 国产高清精品久久久久| 天堂va蜜桃一区二区三区漫画版| 国产精品青草综合久久久久99| 欧美精品久久久久久久久老牛影院| 成人爽a毛片一区二区免费| 日韩和欧美的一区| 一区二区三区不卡在线观看| 久久久亚洲高清| 91精品国产一区二区三区香蕉| 97精品久久久午夜一区二区三区 | 国产欧美一区在线| 欧美一区二区三级| 欧美日韩小视频| 99精品在线免费| 国产成人免费在线观看不卡| 日产国产欧美视频一区精品| 亚洲黄色尤物视频| 国产精品嫩草99a| 精品成人一区二区三区四区| 欧美日韩一区二区三区视频| 不卡av电影在线播放| 国产在线一区二区| 免费三级欧美电影| 亚洲bt欧美bt精品777| 亚洲美女免费视频| 亚洲欧洲日韩在线| 亚洲国产成人自拍| 久久亚洲影视婷婷| 欧美精品一区二区蜜臀亚洲| 91精品国产欧美一区二区18| 欧美日韩国产精品自在自线| 91激情五月电影| 日本伦理一区二区| 色老综合老女人久久久| 99视频在线观看一区三区| 成人精品高清在线| 成人精品免费看| 成人av在线网| 成人avav在线| 成人高清伦理免费影院在线观看| 国产一区二区剧情av在线| 国产一区二区三区美女| 国产一区二区三区久久久| 国产一区二区久久| 国产很黄免费观看久久| 国产激情视频一区二区在线观看 | 国产亲近乱来精品视频| 26uuu色噜噜精品一区| 337p日本欧洲亚洲大胆精品| 精品久久久久久亚洲综合网| 日韩三级免费观看| 精品国产麻豆免费人成网站| 欧美sm极限捆绑bd| 精品国产乱码久久久久久牛牛| 精品蜜桃在线看| 久久久久久97三级| 国产精品家庭影院| 亚洲青青青在线视频| 亚洲人成影院在线观看| 亚洲资源中文字幕| 日本亚洲一区二区| 国内精品不卡在线| 成人免费高清在线| 欧美体内she精视频| 宅男在线国产精品| 精品久久人人做人人爰|