diff options
author | unknown <bar@mysql.com> | 2006-03-23 14:14:32 +0400 |
---|---|---|
committer | unknown <bar@mysql.com> | 2006-03-23 14:14:32 +0400 |
commit | 86f3d2d08a3c46830d3c555d13171dcd53ac8039 (patch) | |
tree | 53884b9ab5ed87409c40a2d1bb53db98dfacc7ef /strings/ctype-eucjpms.c | |
parent | c7df2c6a5819fe942ff68f90fe53a8e338ab9db6 (diff) | |
parent | 1b58717cd85ee6fcc461c919075106a7d4ebd83b (diff) | |
download | mariadb-git-86f3d2d08a3c46830d3c555d13171dcd53ac8039.tar.gz |
Merge mysql.com:/usr/home/bar/mysql-5.0
into mysql.com:/usr/home/bar/mysql-5.1-new
mysql-test/r/ctype_ujis.result:
Auto merged
mysql-test/t/ctype_ujis.test:
Auto merged
strings/ctype-big5.c:
Auto merged
strings/ctype-bin.c:
Auto merged
strings/ctype-cp932.c:
Auto merged
strings/ctype-euc_kr.c:
Auto merged
strings/ctype-eucjpms.c:
Auto merged
strings/ctype-gb2312.c:
Auto merged
strings/ctype-gbk.c:
Auto merged
strings/ctype-latin1.c:
Auto merged
strings/ctype-simple.c:
Auto merged
strings/ctype-sjis.c:
Auto merged
strings/ctype-tis620.c:
Auto merged
strings/ctype-ucs2.c:
Auto merged
strings/ctype-ujis.c:
Auto merged
strings/ctype-utf8.c:
Auto merged
include/m_ctype.h:
After merge fix.
Diffstat (limited to 'strings/ctype-eucjpms.c')
-rw-r--r-- | strings/ctype-eucjpms.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/strings/ctype-eucjpms.c b/strings/ctype-eucjpms.c index 4fb2bbbd0a7..0f59cc2b305 100644 --- a/strings/ctype-eucjpms.c +++ b/strings/ctype-eucjpms.c @@ -243,7 +243,7 @@ my_mb_wc_jisx0201(CHARSET_INFO *cs __attribute__((unused)), const uchar *e __attribute__((unused))) { wc[0]=tab_jisx0201_uni[*s]; - return (!wc[0] && s[0]) ? MY_CS_ILSEQ : 1; + return (!wc[0] && s[0]) ? -1 : 1; } @@ -8473,7 +8473,7 @@ my_mb_wc_euc_jp(CHARSET_INFO *cs,my_wc_t *pwc, const uchar *s, const uchar *e) int c1,c2,c3; if (s >= e) - return MY_CS_TOOFEW(0); + return MY_CS_TOOSMALL; c1=s[0]; @@ -8485,7 +8485,7 @@ my_mb_wc_euc_jp(CHARSET_INFO *cs,my_wc_t *pwc, const uchar *s, const uchar *e) } if (s+2>e) - return MY_CS_TOOFEW(0); + return MY_CS_TOOSMALL2; c2=s[1]; @@ -8500,7 +8500,7 @@ my_mb_wc_euc_jp(CHARSET_INFO *cs,my_wc_t *pwc, const uchar *s, const uchar *e) { pwc[0]=my_jisx0208_uni_onechar( ((c1-0x80) << 8) + (c2-0x80)); if (!pwc[0]) - return MY_CS_ILSEQ; + return -2; } else { @@ -8520,7 +8520,7 @@ my_mb_wc_euc_jp(CHARSET_INFO *cs,my_wc_t *pwc, const uchar *s, const uchar *e) ret = my_mb_wc_jisx0201(cs,pwc,s+1,e); if (ret!=1) - return ret; + return -2; return 2; } @@ -8531,7 +8531,7 @@ my_mb_wc_euc_jp(CHARSET_INFO *cs,my_wc_t *pwc, const uchar *s, const uchar *e) return MY_CS_ILSEQ; if (s+3>e) - return MY_CS_TOOFEW(0); + return MY_CS_TOOSMALL3; c3=s[2]; if (c3 < 0xA1 || c3>=0xFF) @@ -8540,8 +8540,8 @@ my_mb_wc_euc_jp(CHARSET_INFO *cs,my_wc_t *pwc, const uchar *s, const uchar *e) if (c2<0xF5) { pwc[0]=my_jisx0212_uni_onechar((c2-0x80)*256 + (c3-0x80)); - if (!pwc) - return MY_CS_ILSEQ; + if (!pwc[0]) + return -3; } else { @@ -8572,7 +8572,7 @@ my_wc_mb_euc_jp(CHARSET_INFO *c,my_wc_t wc, unsigned char *s, unsigned char *e) if ((jp=my_uni_jisx0208_onechar(wc))) { if (s+2>e) - return MY_CS_TOOSMALL; + return MY_CS_TOOSMALL2; jp+=0x8080; s[0]=jp>>8; @@ -8584,7 +8584,7 @@ my_wc_mb_euc_jp(CHARSET_INFO *c,my_wc_t wc, unsigned char *s, unsigned char *e) if (my_wc_mb_jisx0201(c,wc,s,e) == 1) { if (s+2>e) - return MY_CS_TOOSMALL; + return MY_CS_TOOSMALL2; s[1]= s[0]; s[0]= 0x8E; return 2; @@ -8594,7 +8594,7 @@ my_wc_mb_euc_jp(CHARSET_INFO *c,my_wc_t wc, unsigned char *s, unsigned char *e) if ((jp=my_uni_jisx0212_onechar(wc))) { if (s+3>e) - return MY_CS_TOOSMALL; + return MY_CS_TOOSMALL3; jp+=0x8080; s[0]=0x8F; @@ -8608,7 +8608,7 @@ my_wc_mb_euc_jp(CHARSET_INFO *c,my_wc_t wc, unsigned char *s, unsigned char *e) if (wc>=0xE000 && wc<0xE3AC) { if (s+2>e) - return MY_CS_TOOSMALL; + return MY_CS_TOOSMALL2; c1=((unsigned)(wc-0xE000)/94)+0xF5; s[0]=c1; @@ -8622,7 +8622,7 @@ my_wc_mb_euc_jp(CHARSET_INFO *c,my_wc_t wc, unsigned char *s, unsigned char *e) if (wc>=0xE3AC && wc<0xE758) { if (s+3>e) - return MY_CS_TOOSMALL; + return MY_CS_TOOSMALL3; s[0]=0x8F; c1=((unsigned)(wc-0xE3AC)/94)+0xF5; |