mirror of
https://github.com/php/php-src.git
synced 2026-03-28 18:22:42 +01:00
This is a mix of more automated and manual migration. It should remove all applicable extension_loaded() checks outside of skipif.inc files.
21 lines
495 B
PHP
21 lines
495 B
PHP
--TEST--
|
|
Bug #49536 (mb_detect_encoding() returns incorrect results when strict_mode is turned on)
|
|
--EXTENSIONS--
|
|
mbstring
|
|
--FILE--
|
|
<?php
|
|
// non-strict mode
|
|
var_dump(mb_detect_encoding("A\x81", "SJIS", false));
|
|
// strict mode
|
|
var_dump(mb_detect_encoding("A\x81", "SJIS", true));
|
|
// non-strict mode
|
|
var_dump(mb_detect_encoding("\xc0\x00", "UTF-8", false));
|
|
// strict mode
|
|
var_dump(mb_detect_encoding("\xc0\x00", "UTF-8", true));
|
|
?>
|
|
--EXPECT--
|
|
string(4) "SJIS"
|
|
bool(false)
|
|
bool(false)
|
|
bool(false)
|