|
|
| version 1.9, 2004/06/20 02:57:47 | version 1.10, 2004/06/20 11:19:45 |
|---|---|
| Line 511 void milutf8_ncpy(char *dst, const char | Line 511 void milutf8_ncpy(char *dst, const char |
| for (i=0; i<maxlen && src[i]; i++) { | for (i=0; i<maxlen && src[i]; i++) { |
| dst[i] = src[i]; | dst[i] = src[i]; |
| } | } |
| while((i) && ((dst[i] & 0xc0) == 0x80)) { | while((i) && ((dst[i-1] & 0xc0) == 0x80)) { |
| i--; | i--; |
| } | } |
| dst[i] = '\0'; | dst[i] = '\0'; |
| Line 533 void milutf8_ncat(char *dst, const char | Line 533 void milutf8_ncat(char *dst, const char |
| for (j=0; i<maxlen && src[j]; i++, j++) { | for (j=0; i<maxlen && src[j]; i++, j++) { |
| dst[i] = src[j]; | dst[i] = src[j]; |
| } | } |
| while((i) && ((dst[i] & 0xc0) == 0x80)) { | while((i) && ((dst[i-1] & 0xc0) == 0x80)) { |
| i--; | i--; |
| } | } |
| dst[i] = '\0'; | dst[i] = '\0'; |