ID: 41147
Updated by: [EMAIL PROTECTED]
Reported By: teracci2002 at yahoo dot co dot jp
-Status: Analyzed
+Status: Assigned
Bug Type: mbstring related
Operating System: Linux
PHP Version: 5.2.1
Assigned To: hirokawa
New Comment:
Did you read it Rui? (why do your reports end up as 'Analyzed' all the
time? :)
Previous Comments:
------------------------------------------------------------------------
[2007-09-04 14:55:58] teracci2002 at yahoo dot co dot jp
> 0x00+0xa1 is valid byte sequence in Shift_JIS sequence.
I know it.
But 0x00+0x81 is invalid sequence in Shift_JIS.
Then, why below statement returns "bool(true)" ?
var_dump(mb_check_encoding("\x00\x81", "Shift_JIS"));
Read bug report again, please.
------------------------------------------------------------------------
[2007-09-04 14:30:06] [EMAIL PROTECTED]
> No one says 0x00,0xa1 is invalid character in ShiftJIS.
I didn't say that.
0x00+0xa1 is valid byte sequence in Shift_JIS sequence.
A character in Shift_JIS encoding is encoded in either single byte
or double byte.
In this case, the byte stream is reconigzed as two character,
a null byte and a comma character in Katakana(0xa1)
see: http://hp.vector.co.jp/authors/VA013241/misc/shiftjis.html
------------------------------------------------------------------------
[2007-08-19 20:10:06] [EMAIL PROTECTED]
Someone disagrees, Rui.. :)
------------------------------------------------------------------------
[2007-08-18 16:00:06] teracci2002 at yahoo dot co dot jp
Just read bug report again.
No one says 0x00,0xa1 is invalid character in ShiftJIS.
------------------------------------------------------------------------
[2007-08-18 14:45:13] [EMAIL PROTECTED]
It is expected behavior because
0x00,0xa1 is null byte + valid ShiftJIS character.
mb_check_encoding should be used to detect invalid
or corrupted multibyte characters.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/41147
--
Edit this bug report at http://bugs.php.net/?id=41147&edit=1