mirror of
https://github.com/php/php-src.git
synced 2026-04-20 22:41:20 +02:00
Set preg_options to 0 in php_pcre_get_compiled_regex(_ex). These options are intended to be passed to pcre2_match. However, we do not have any flags that actually need to be set during matching (all relevant flags are set during compilation), and the preg_flags value is used for PHP-specific flags instead. This parameter should be removed entirely in master to avoid confusion.
82 lines
1.3 KiB
PHP
82 lines
1.3 KiB
PHP
--TEST--
|
|
Bug #77338: get_browser with empty string
|
|
--INI--
|
|
browscap={PWD}/browscap.ini
|
|
--FILE--
|
|
<?php
|
|
|
|
var_dump(get_browser(""));
|
|
|
|
?>
|
|
--EXPECT--
|
|
object(stdClass)#1 (34) {
|
|
["browser_name_regex"]=>
|
|
string(6) "~^.*$~"
|
|
["browser_name_pattern"]=>
|
|
string(1) "*"
|
|
["browser"]=>
|
|
string(15) "Default Browser"
|
|
["version"]=>
|
|
string(1) "0"
|
|
["majorver"]=>
|
|
string(1) "0"
|
|
["minorver"]=>
|
|
string(1) "0"
|
|
["platform"]=>
|
|
string(7) "unknown"
|
|
["alpha"]=>
|
|
string(0) ""
|
|
["beta"]=>
|
|
string(0) ""
|
|
["win16"]=>
|
|
string(0) ""
|
|
["win32"]=>
|
|
string(0) ""
|
|
["win64"]=>
|
|
string(0) ""
|
|
["frames"]=>
|
|
string(1) "1"
|
|
["iframes"]=>
|
|
string(0) ""
|
|
["tables"]=>
|
|
string(1) "1"
|
|
["cookies"]=>
|
|
string(0) ""
|
|
["backgroundsounds"]=>
|
|
string(0) ""
|
|
["authenticodeupdate"]=>
|
|
string(1) "0"
|
|
["cdf"]=>
|
|
string(0) ""
|
|
["vbscript"]=>
|
|
string(0) ""
|
|
["javaapplets"]=>
|
|
string(0) ""
|
|
["javascript"]=>
|
|
string(0) ""
|
|
["activexcontrols"]=>
|
|
string(0) ""
|
|
["stripper"]=>
|
|
string(0) ""
|
|
["isbanned"]=>
|
|
string(0) ""
|
|
["wap"]=>
|
|
string(0) ""
|
|
["ismobiledevice"]=>
|
|
string(0) ""
|
|
["issyndicationreader"]=>
|
|
string(0) ""
|
|
["crawler"]=>
|
|
string(0) ""
|
|
["css"]=>
|
|
string(1) "0"
|
|
["cssversion"]=>
|
|
string(1) "0"
|
|
["supportscss"]=>
|
|
string(0) ""
|
|
["aol"]=>
|
|
string(0) ""
|
|
["aolversion"]=>
|
|
string(1) "0"
|
|
}
|