mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-25 09:55:41 +00:00
Compare commits
1
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
41f6096ab2 |
No files matched your search
@@ -1,34 +1,6 @@
|
||||
PHP NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
28 Nov 2013, PHP 5.4.23
|
||||
|
||||
- Core:
|
||||
. Fixed bug #66094 (unregister_tick_function tries to cast a Closure to a
|
||||
string). (Laruence)
|
||||
. Fixed bug #65947 (basename is no more working after fgetcsv in certain
|
||||
situation). (Laruence)
|
||||
|
||||
- JSON
|
||||
. Fixed whitespace part of bug #64874 ("json_decode handles whitespace and
|
||||
case-sensitivity incorrectly"). (Andrea Faulds)
|
||||
|
||||
- MySQLi:
|
||||
. Fixed bug #66043 (Segfault calling bind_param() on mysqli). (Laruence)
|
||||
|
||||
- mysqlnd:
|
||||
. Fixed bug #66124 (mysqli under mysqlnd loses precision when bind_param
|
||||
with 'i'). (Andrey)
|
||||
. Fixed bug #66141 (mysqlnd quote function is wrong with NO_BACKSLASH_ESCAPES
|
||||
after failed query). (Andrey)
|
||||
|
||||
- OpenSSL:
|
||||
. Fixed memory corruption in openssl_x509_parse() (CVE-2013-6420).
|
||||
(Stefan Esser).
|
||||
|
||||
- PDO
|
||||
. Fixed bug 65946 (sql_parser permanently converts values bound to strings)
|
||||
|
||||
14 Nov 2013, PHP 5.4.22
|
||||
31 Oct 2013, PHP 5.4.22 RC1
|
||||
|
||||
- Core:
|
||||
. Fixed bug #65911 (scope resolution operator - strange behavior with $this).
|
||||
@@ -44,14 +16,10 @@ PHP NEWS
|
||||
- FTP:
|
||||
. Fixed bug #65667 (ftp_nb_continue produces segfault). (Philip Hofstetter)
|
||||
|
||||
- ODBC:
|
||||
- ODBC
|
||||
. Fixed bug #65950 (Field name truncation if the field name is bigger than
|
||||
32 characters). (patch submitted by: michael dot y at zend dot com, Yasuo)
|
||||
|
||||
- PDO:
|
||||
. Fixed bug #66033 (Segmentation Fault when constructor of PDO statement
|
||||
throws an exception). (Laruence)
|
||||
|
||||
- Sockets:
|
||||
. Fixed bug #65808 (the socket_connect() won't work with IPv6 address).
|
||||
(Mike)
|
||||
|
||||
@@ -736,7 +736,6 @@ static zend_always_inline int fast_mul_function(zval *result, zval *op1, zval *o
|
||||
|
||||
static zend_always_inline int fast_div_function(zval *result, zval *op1, zval *op2 TSRMLS_DC)
|
||||
{
|
||||
#if 0
|
||||
if (EXPECTED(Z_TYPE_P(op1) == IS_LONG) && 0) {
|
||||
if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) {
|
||||
if (UNEXPECTED(Z_LVAL_P(op2) == 0)) {
|
||||
@@ -791,7 +790,6 @@ static zend_always_inline int fast_div_function(zval *result, zval *op1, zval *o
|
||||
return SUCCESS;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
return div_function(result, op1, op2 TSRMLS_CC);
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -119,8 +119,8 @@ int zend_sprintf(char *buffer, const char *format, ...);
|
||||
|
||||
PHP_MAJOR_VERSION=5
|
||||
PHP_MINOR_VERSION=4
|
||||
PHP_RELEASE_VERSION=23
|
||||
PHP_EXTRA_VERSION=""
|
||||
PHP_RELEASE_VERSION=22
|
||||
PHP_EXTRA_VERSION="RC1"
|
||||
PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION"
|
||||
PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION`
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ ftp_login($ftp, 'user', 'pass');
|
||||
if (!$ftp) die("Couldn't connect to the server");
|
||||
ftp_set_option($ftp, FTP_AUTOSEEK, false);
|
||||
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_fget_basic1.txt";
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt";
|
||||
$handle = fopen($local_file, 'w');
|
||||
|
||||
var_dump(ftp_fget($ftp, $handle, 'fget.txt', FTP_ASCII, FTP_AUTORESUME));
|
||||
@@ -24,7 +24,7 @@ var_dump(file_get_contents($local_file));
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_fget_basic1.txt");
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt");
|
||||
?>
|
||||
--EXPECT--
|
||||
bool(true)
|
||||
|
||||
@@ -15,7 +15,7 @@ $ftp = ftp_connect('127.0.0.1', $port);
|
||||
ftp_login($ftp, 'user', 'pass');
|
||||
if (!$ftp) die("Couldn't connect to the server");
|
||||
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_fget_basic2.txt";
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt";
|
||||
file_put_contents($local_file, 'ASCIIFoo');
|
||||
$handle = fopen($local_file, 'a');
|
||||
|
||||
@@ -24,7 +24,7 @@ var_dump(file_get_contents($local_file));
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_fget_basic2.txt");
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt");
|
||||
?>
|
||||
--EXPECT--
|
||||
bool(true)
|
||||
|
||||
@@ -15,7 +15,7 @@ $ftp = ftp_connect('127.0.0.1', $port);
|
||||
ftp_login($ftp, 'user', 'pass');
|
||||
if (!$ftp) die("Couldn't connect to the server");
|
||||
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_fget_basic3.txt";
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt";
|
||||
file_put_contents($local_file, 'ASCIIFoo');
|
||||
$handle = fopen($local_file, 'a');
|
||||
|
||||
@@ -24,7 +24,7 @@ var_dump(file_get_contents($local_file));
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_fget_basic3.txt");
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt");
|
||||
?>
|
||||
--EXPECT--
|
||||
bool(true)
|
||||
|
||||
@@ -16,7 +16,7 @@ ftp_login($ftp, 'user', 'pass');
|
||||
if (!$ftp) die("Couldn't connect to the server");
|
||||
ftp_set_option($ftp, FTP_AUTOSEEK, false);
|
||||
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_nb_fget_basic1.txt";
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt";
|
||||
$handle = fopen($local_file, 'w');
|
||||
|
||||
var_dump(ftp_nb_fget($ftp, $handle, 'fget.txt', FTP_ASCII, FTP_AUTORESUME));
|
||||
@@ -24,7 +24,7 @@ var_dump(file_get_contents($local_file));
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_nb_fget_basic1.txt");
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt");
|
||||
?>
|
||||
--EXPECT--
|
||||
int(2)
|
||||
|
||||
@@ -15,7 +15,7 @@ $ftp = ftp_connect('127.0.0.1', $port);
|
||||
ftp_login($ftp, 'user', 'pass');
|
||||
if (!$ftp) die("Couldn't connect to the server");
|
||||
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_nb_fget_basic2.txt";
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt";
|
||||
file_put_contents($local_file, 'ASCIIFoo');
|
||||
$handle = fopen($local_file, 'a');
|
||||
|
||||
@@ -24,7 +24,7 @@ var_dump(file_get_contents($local_file));
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_nb_fget_basic2.txt");
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt");
|
||||
?>
|
||||
--EXPECT--
|
||||
int(2)
|
||||
|
||||
@@ -15,7 +15,7 @@ $ftp = ftp_connect('127.0.0.1', $port);
|
||||
ftp_login($ftp, 'user', 'pass');
|
||||
if (!$ftp) die("Couldn't connect to the server");
|
||||
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_nb_fget_basic3.txt";
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt";
|
||||
file_put_contents($local_file, 'ASCIIFoo');
|
||||
$handle = fopen($local_file, 'a');
|
||||
|
||||
@@ -24,7 +24,7 @@ var_dump(file_get_contents($local_file));
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_nb_fget_basic3.txt");
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt");
|
||||
?>
|
||||
--EXPECT--
|
||||
int(2)
|
||||
|
||||
@@ -18,7 +18,7 @@ $ftp = ftp_connect('127.0.0.1', $port);
|
||||
ftp_login($ftp, 'user', 'pass');
|
||||
if (!$ftp) die("Couldn't connect to the server");
|
||||
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_nb_get_large.txt";
|
||||
$local_file = dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt";
|
||||
touch($local_file);
|
||||
ftp_nb_get($ftp, $local_file, 'fget_large.txt', FTP_BINARY, 5368709119);
|
||||
$fp = fopen($local_file, 'r');
|
||||
@@ -29,7 +29,7 @@ fclose($fp);
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "ftp_nb_get_large.txt");
|
||||
@unlink(dirname(__FILE__) . DIRECTORY_SEPARATOR . "localfile.txt");
|
||||
?>
|
||||
--EXPECT--
|
||||
string(1) "X"
|
||||
|
||||
+8
-22
@@ -684,35 +684,21 @@ PHP_JSON_API void php_json_decode_ex(zval *return_value, char *str, int str_len,
|
||||
double d;
|
||||
int type, overflow_info;
|
||||
long p;
|
||||
char *trim = str;
|
||||
int trim_len = str_len;
|
||||
|
||||
/* Increment trimmed string pointer to strip leading whitespace */
|
||||
/* JSON RFC says to consider as whitespace: space, tab, LF or CR */
|
||||
while (trim_len && (*trim == ' ' || *trim == '\t' || *trim == '\n' || *trim == '\r')) {
|
||||
trim++;
|
||||
trim_len--;
|
||||
}
|
||||
|
||||
/* Decrement trimmed string length to strip trailing whitespace */
|
||||
while (trim_len && (trim[trim_len - 1] == ' ' || trim[trim_len - 1] == '\t' || trim[trim_len - 1] == '\n' || trim[trim_len - 1] == '\r')) {
|
||||
trim_len--;
|
||||
}
|
||||
|
||||
RETVAL_NULL();
|
||||
if (trim_len == 4) {
|
||||
if (!strncasecmp(trim, "null", trim_len)) {
|
||||
if (str_len == 4) {
|
||||
if (!strcasecmp(str, "null")) {
|
||||
/* We need to explicitly clear the error because its an actual NULL and not an error */
|
||||
jp->error_code = PHP_JSON_ERROR_NONE;
|
||||
RETVAL_NULL();
|
||||
} else if (!strncasecmp(trim, "true", trim_len)) {
|
||||
} else if (!strcasecmp(str, "true")) {
|
||||
RETVAL_BOOL(1);
|
||||
}
|
||||
} else if (trim_len == 5 && !strncasecmp(trim, "false", trim_len)) {
|
||||
} else if (str_len == 5 && !strcasecmp(str, "false")) {
|
||||
RETVAL_BOOL(0);
|
||||
}
|
||||
|
||||
if ((type = is_numeric_string_ex(trim, trim_len, &p, &d, 0, &overflow_info)) != 0) {
|
||||
if ((type = is_numeric_string_ex(str, str_len, &p, &d, 0, &overflow_info)) != 0) {
|
||||
if (type == IS_LONG) {
|
||||
RETVAL_LONG(p);
|
||||
} else if (type == IS_DOUBLE) {
|
||||
@@ -725,10 +711,10 @@ PHP_JSON_API void php_json_decode_ex(zval *return_value, char *str, int str_len,
|
||||
int i;
|
||||
zend_bool is_float = 0;
|
||||
|
||||
for (i = (trim[0] == '-' ? 1 : 0); i < trim_len; i++) {
|
||||
for (i = (str[0] == '-' ? 1 : 0); i < str_len; i++) {
|
||||
/* Not using isdigit() because it's locale specific,
|
||||
* but we expect JSON input to always be UTF-8. */
|
||||
if (trim[i] < '0' || trim[i] > '9') {
|
||||
if (str[i] < '0' || str[i] > '9') {
|
||||
is_float = 1;
|
||||
break;
|
||||
}
|
||||
@@ -737,7 +723,7 @@ PHP_JSON_API void php_json_decode_ex(zval *return_value, char *str, int str_len,
|
||||
if (is_float) {
|
||||
RETVAL_DOUBLE(d);
|
||||
} else {
|
||||
RETVAL_STRINGL(trim, trim_len, 1);
|
||||
RETVAL_STRINGL(str, str_len, 1);
|
||||
}
|
||||
} else {
|
||||
RETVAL_DOUBLE(d);
|
||||
|
||||
@@ -1,117 +0,0 @@
|
||||
--TEST--
|
||||
Whitespace part of bug #64874 ("json_decode handles whitespace and case-sensitivity incorrectly")
|
||||
--SKIPIF--
|
||||
<?php if (!extension_loaded("json")) print "skip"; ?>
|
||||
--FILE--
|
||||
<?php
|
||||
function decode($json) {
|
||||
var_dump(json_decode($json));
|
||||
var_dump(json_last_error() !== 0);
|
||||
echo "\n";
|
||||
}
|
||||
|
||||
// Leading whitespace should be ignored
|
||||
decode(" true");
|
||||
decode("\ttrue");
|
||||
decode("\ntrue");
|
||||
decode("\rtrue");
|
||||
|
||||
// So should trailing whitespace
|
||||
decode("true ");
|
||||
decode("true\t");
|
||||
decode("true\n");
|
||||
decode("true\r");
|
||||
|
||||
// And so should the combination of both
|
||||
decode(" true ");
|
||||
decode(" true\t");
|
||||
decode(" true\n");
|
||||
decode(" true\r");
|
||||
decode("\ttrue ");
|
||||
decode("\ttrue\t");
|
||||
decode("\ttrue\n");
|
||||
decode("\ttrue\r");
|
||||
decode("\ntrue ");
|
||||
decode("\ntrue\t");
|
||||
decode("\ntrue\n");
|
||||
decode("\ntrue\r");
|
||||
decode("\rtrue ");
|
||||
decode("\rtrue\t");
|
||||
decode("\rtrue\n");
|
||||
decode("\rtrue\r");
|
||||
|
||||
echo "Done\n";
|
||||
--EXPECT--
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
Done
|
||||
@@ -384,7 +384,7 @@ mysqli_stmt_bind_result_do_bind(MY_STMT *stmt, zval ***args, unsigned int argc,
|
||||
/* Changed to my_bool in MySQL 5.1. See MySQL Bug #16144 */
|
||||
my_bool tmp;
|
||||
#else
|
||||
ulong tmp = 0;
|
||||
uint tmp = 0;
|
||||
#endif
|
||||
stmt->result.buf[ofs].type = IS_STRING;
|
||||
/*
|
||||
|
||||
@@ -1,24 +0,0 @@
|
||||
--TEST--
|
||||
Bug #66043 (Segfault calling bind_param() on mysqli)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
require_once('skipif.inc');
|
||||
require_once("connect.inc");
|
||||
if ($IS_MYSQLND) {
|
||||
die("skip libmysql only test");
|
||||
}
|
||||
require_once('skipifconnectfailure.inc');
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require 'connect.inc';
|
||||
$db = new mysqli($host, $user, $passwd, 'mysql');
|
||||
|
||||
$stmt = $db->stmt_init();
|
||||
$stmt->prepare("SELECT User FROM user WHERE password=\"\"");
|
||||
$stmt->execute();
|
||||
$stmt->bind_result($testArg);
|
||||
echo "Okey";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Okey
|
||||
@@ -1,101 +0,0 @@
|
||||
--TEST--
|
||||
Bug #66124 (mysqli under mysqlnd loses precision when bind_param with 'i')
|
||||
--SKIPIF--
|
||||
<?php
|
||||
require_once('skipif.inc');
|
||||
require_once('connect.inc');
|
||||
require_once('skipifconnectfailure.inc');
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
$table_drop = "DROP TABLE IF EXISTS `bug66124`";
|
||||
$table_create = "CREATE TABLE `bug66124` (
|
||||
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8";
|
||||
|
||||
$table_insert = "INSERT INTO `bug66124` SET `id`=?";
|
||||
$table_select = "SELECT * FROM `bug66124`";
|
||||
$table_delete = "DELETE FROM `bug66124`";
|
||||
$id = '1311200011005001566';
|
||||
|
||||
|
||||
require_once('connect.inc');
|
||||
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
$link->query($table_drop);
|
||||
$link->query($table_create);
|
||||
|
||||
$stmt = $link->prepare($table_insert);
|
||||
if (!$stmt) {
|
||||
printf("Can't prepare\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
echo "Using 'i':\n";
|
||||
$stmt->bind_param('i', $id);
|
||||
|
||||
if ($stmt->execute()){
|
||||
echo "insert id:{$id}=>{$stmt->insert_id}\n";
|
||||
} else {
|
||||
printf("Can't execute\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
||||
$result = $link->query($table_select);
|
||||
|
||||
if ($result){
|
||||
while ($row = $result->fetch_assoc()) {
|
||||
echo "fetch id:{$row['id']}\n";
|
||||
}
|
||||
} else {
|
||||
printf("Can't select\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
$stmt->close();
|
||||
|
||||
$link->query($table_drop);
|
||||
$link->query($table_create);
|
||||
|
||||
|
||||
$stmt = $link->prepare($table_insert);
|
||||
$stmt->bind_param('s', $id);
|
||||
|
||||
echo "Using 's':\n";
|
||||
|
||||
if ($stmt->execute()){
|
||||
echo "insert id:{$id}\n";
|
||||
} else{
|
||||
printf("Can't execute\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
$result = $link->query($table_select);
|
||||
|
||||
if ($result){
|
||||
while ($row = $result->fetch_assoc()) {
|
||||
echo "fetch id:{$row['id']}\n";
|
||||
}
|
||||
} else {
|
||||
printf("Can't select\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
$link->close();
|
||||
?>
|
||||
done
|
||||
--EXPECTF--
|
||||
Using 'i':
|
||||
insert id:1311200011005001566=>1311200011005001566
|
||||
fetch id:1311200011005001566
|
||||
Using 's':
|
||||
insert id:1311200011005001566
|
||||
fetch id:1311200011005001566
|
||||
done
|
||||
+6
-10
@@ -251,7 +251,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, simple_command_handle_response)(MYSQLND_CONN_D
|
||||
conn->persistent);
|
||||
|
||||
if (!ignore_upsert_status) {
|
||||
memset(conn->upsert_status, 0, sizeof(*conn->upsert_status));
|
||||
conn->upsert_status->warning_count = ok_response->warning_count;
|
||||
conn->upsert_status->server_status = ok_response->server_status;
|
||||
conn->upsert_status->affected_rows = ok_response->affected_rows;
|
||||
@@ -315,7 +314,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, simple_command)(MYSQLND_CONN_DATA * conn, enum
|
||||
|
||||
DBG_ENTER("mysqlnd_conn_data::simple_command");
|
||||
DBG_INF_FMT("command=%s ok_packet=%u silent=%u", mysqlnd_command_to_text[command], ok_packet, silent);
|
||||
DBG_INF_FMT("conn->server_status=%u", conn->upsert_status->server_status);
|
||||
|
||||
switch (CONN_GET_STATE(conn)) {
|
||||
case CONN_READY:
|
||||
@@ -330,6 +328,10 @@ MYSQLND_METHOD(mysqlnd_conn_data, simple_command)(MYSQLND_CONN_DATA * conn, enum
|
||||
DBG_RETURN(FAIL);
|
||||
}
|
||||
|
||||
/* clean UPSERT info */
|
||||
if (!ignore_upsert_status) {
|
||||
memset(conn->upsert_status, 0, sizeof(*conn->upsert_status));
|
||||
}
|
||||
SET_ERROR_AFF_ROWS(conn);
|
||||
SET_EMPTY_ERROR(*conn->error_info);
|
||||
|
||||
@@ -525,7 +527,7 @@ mysqlnd_connect_run_authentication(
|
||||
|
||||
if (!auth_plugin) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "The server requested authentication method unknown to the client [%s]", requested_protocol);
|
||||
SET_CLIENT_ERROR(*conn->error_info, CR_NOT_IMPLEMENTED, UNKNOWN_SQLSTATE, "The server requested authentication method unknown to the client");
|
||||
SET_CLIENT_ERROR(*conn->error_info, CR_NOT_IMPLEMENTED, UNKNOWN_SQLSTATE, "The server requested authentication method umknown to the client");
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -886,7 +888,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, connect)(MYSQLND_CONN_DATA * conn,
|
||||
conn->max_packet_size = MYSQLND_ASSEMBLED_PACKET_MAX_SIZE;
|
||||
/* todo: check if charset is available */
|
||||
conn->server_capabilities = greet_packet->server_capabilities;
|
||||
memset(conn->upsert_status, 0, sizeof(*conn->upsert_status));
|
||||
conn->upsert_status->warning_count = 0;
|
||||
conn->upsert_status->server_status = greet_packet->server_status;
|
||||
conn->upsert_status->affected_rows = 0;
|
||||
@@ -1063,7 +1064,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, send_query)(MYSQLND_CONN_DATA * conn, const ch
|
||||
enum_func_status ret = FAIL;
|
||||
DBG_ENTER("mysqlnd_conn_data::send_query");
|
||||
DBG_INF_FMT("conn=%llu query=%s", conn->thread_id, query);
|
||||
DBG_INF_FMT("conn->server_status=%u", conn->upsert_status->server_status);
|
||||
|
||||
if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) {
|
||||
ret = conn->m->simple_command(conn, COM_QUERY, (zend_uchar *) query, query_len,
|
||||
@@ -1074,7 +1074,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, send_query)(MYSQLND_CONN_DATA * conn, const ch
|
||||
}
|
||||
conn->m->local_tx_end(conn, this_func, ret TSRMLS_CC);
|
||||
}
|
||||
DBG_INF_FMT("conn->server_status=%u", conn->upsert_status->server_status);
|
||||
DBG_RETURN(ret);
|
||||
}
|
||||
/* }}} */
|
||||
@@ -1090,7 +1089,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, reap_query)(MYSQLND_CONN_DATA * conn TSRMLS_DC
|
||||
DBG_ENTER("mysqlnd_conn_data::reap_query");
|
||||
DBG_INF_FMT("conn=%llu", conn->thread_id);
|
||||
|
||||
DBG_INF_FMT("conn->server_status=%u", conn->upsert_status->server_status);
|
||||
if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) {
|
||||
if (state <= CONN_READY || state == CONN_QUIT_SENT) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Connection not opened, clear or has been closed");
|
||||
@@ -1101,7 +1099,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, reap_query)(MYSQLND_CONN_DATA * conn TSRMLS_DC
|
||||
|
||||
conn->m->local_tx_end(conn, this_func, ret TSRMLS_CC);
|
||||
}
|
||||
DBG_INF_FMT("conn->server_status=%u", conn->upsert_status->server_status);
|
||||
DBG_RETURN(ret);
|
||||
}
|
||||
/* }}} */
|
||||
@@ -1480,7 +1477,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, escape_string)(MYSQLND_CONN_DATA * const conn,
|
||||
DBG_INF_FMT("conn=%llu", conn->thread_id);
|
||||
|
||||
if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) {
|
||||
DBG_INF_FMT("server_status=%u", conn->upsert_status->server_status);
|
||||
if (conn->upsert_status->server_status & SERVER_STATUS_NO_BACKSLASH_ESCAPES) {
|
||||
ret = mysqlnd_cset_escape_quotes(conn->charset, newstr, escapestr, escapestr_len TSRMLS_CC);
|
||||
} else {
|
||||
@@ -2166,7 +2162,7 @@ MYSQLND_METHOD(mysqlnd_conn_data, change_user)(MYSQLND_CONN_DATA * const conn,
|
||||
|
||||
if (!auth_plugin) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "The server requested authentication method unknown to the client [%s]", requested_protocol);
|
||||
SET_CLIENT_ERROR(*conn->error_info, CR_NOT_IMPLEMENTED, UNKNOWN_SQLSTATE, "The server requested authentication method unknown to the client");
|
||||
SET_CLIENT_ERROR(*conn->error_info, CR_NOT_IMPLEMENTED, UNKNOWN_SQLSTATE, "The server requested authentication method umknown to the client");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -485,7 +485,6 @@ mysqlnd_stmt_execute_parse_response(MYSQLND_STMT * const s TSRMLS_DC)
|
||||
ret = mysqlnd_query_read_result_set_header(stmt->conn, s TSRMLS_CC);
|
||||
if (ret == FAIL) {
|
||||
COPY_CLIENT_ERROR(*stmt->error_info, *conn->error_info);
|
||||
memset(stmt->upsert_status, 0, sizeof(*stmt->upsert_status));
|
||||
stmt->upsert_status->affected_rows = conn->upsert_status->affected_rows;
|
||||
if (CONN_GET_STATE(conn) == CONN_QUIT_SENT) {
|
||||
/* close the statement here, the connection has been closed */
|
||||
@@ -914,7 +913,6 @@ mysqlnd_stmt_fetch_row_unbuffered(MYSQLND_RES *result, void *param, unsigned int
|
||||
DBG_INF("EOF");
|
||||
/* Mark the connection as usable again */
|
||||
result->unbuf->eof_reached = TRUE;
|
||||
memset(result->conn->upsert_status, 0, sizeof(*result->conn->upsert_status));
|
||||
result->conn->upsert_status->warning_count = row_packet->warning_count;
|
||||
result->conn->upsert_status->server_status = row_packet->server_status;
|
||||
/*
|
||||
@@ -1024,7 +1022,6 @@ mysqlnd_fetch_stmt_row_cursor(MYSQLND_RES *result, void *param, unsigned int fla
|
||||
|
||||
row_packet->skip_extraction = stmt->result_bind? FALSE:TRUE;
|
||||
|
||||
memset(stmt->upsert_status, 0, sizeof(*stmt->upsert_status));
|
||||
if (PASS == (ret = PACKET_READ(row_packet, result->conn)) && !row_packet->eof) {
|
||||
unsigned int i, field_count = result->field_count;
|
||||
|
||||
|
||||
@@ -636,8 +636,9 @@ mysqlnd_stmt_execute_store_params(MYSQLND_STMT * s, zend_uchar **buf, zend_uchar
|
||||
occur, and force resend for the next execution.
|
||||
*/
|
||||
for (i = 0; i < stmt->param_count; i++) {
|
||||
short current_type = stmt->param_bind[i].type;
|
||||
if (Z_TYPE_P(stmt->param_bind[i].zv) != IS_NULL && (current_type == MYSQL_TYPE_LONG || current_type == MYSQL_TYPE_LONGLONG)) {
|
||||
if (Z_TYPE_P(stmt->param_bind[i].zv) != IS_NULL &&
|
||||
(stmt->param_bind[i].type == MYSQL_TYPE_LONG || stmt->param_bind[i].type == MYSQL_TYPE_LONGLONG))
|
||||
{
|
||||
/* always copy the var, because we do many conversions */
|
||||
if (Z_TYPE_P(stmt->param_bind[i].zv) != IS_LONG &&
|
||||
PASS != mysqlnd_stmt_copy_it(&copies, stmt->param_bind[i].zv, stmt->param_count, i TSRMLS_CC))
|
||||
@@ -651,31 +652,10 @@ mysqlnd_stmt_execute_store_params(MYSQLND_STMT * s, zend_uchar **buf, zend_uchar
|
||||
*/
|
||||
if (Z_TYPE_P(stmt->param_bind[i].zv) != IS_LONG) {
|
||||
zval *tmp_data = (copies && copies[i])? copies[i]: stmt->param_bind[i].zv;
|
||||
/*
|
||||
Because converting to double and back to long can lead
|
||||
to losing precision we need second variable. Conversion to double is to see if
|
||||
value is too big for a long. As said, precision could be lost.
|
||||
*/
|
||||
zval *tmp_data_copy;
|
||||
MAKE_STD_ZVAL(tmp_data_copy);
|
||||
*tmp_data_copy = *tmp_data;
|
||||
Z_SET_REFCOUNT_P(tmp_data_copy, 1);
|
||||
zval_copy_ctor(tmp_data_copy);
|
||||
convert_to_double_ex(&tmp_data_copy);
|
||||
|
||||
/*
|
||||
if it doesn't fit in a long send it as a string.
|
||||
Check bug #52891 : Wrong data inserted with mysqli/mysqlnd when using bind_param, value > LONG_MAX
|
||||
We do transformation here, which will be used later when sending types. The code later relies on this.
|
||||
*/
|
||||
if (Z_DVAL_P(tmp_data_copy) > LONG_MAX || Z_DVAL_P(tmp_data_copy) < LONG_MIN) {
|
||||
convert_to_double_ex(&tmp_data);
|
||||
if (Z_DVAL_P(tmp_data) > LONG_MAX || Z_DVAL_P(tmp_data) < LONG_MIN) {
|
||||
stmt->send_types_to_server = resend_types_next_time = 1;
|
||||
convert_to_string_ex(&tmp_data);
|
||||
} else {
|
||||
convert_to_long_ex(&tmp_data);
|
||||
}
|
||||
|
||||
zval_ptr_dtor(&tmp_data_copy);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -718,11 +698,10 @@ mysqlnd_stmt_execute_store_params(MYSQLND_STMT * s, zend_uchar **buf, zend_uchar
|
||||
*/
|
||||
if (Z_TYPE_P(stmt->param_bind[i].zv) != IS_LONG) {
|
||||
zval *tmp_data = (copies && copies[i])? copies[i]: stmt->param_bind[i].zv;
|
||||
/*
|
||||
In case of IS_LONG we do nothing, it is ok, in case of string, we just need to set current_type.
|
||||
The actual transformation has been performed several dozens line above.
|
||||
*/
|
||||
if (Z_TYPE_P(tmp_data) == IS_STRING) {
|
||||
|
||||
convert_to_double_ex(&tmp_data);
|
||||
if (Z_DVAL_P(tmp_data) > LONG_MAX || Z_DVAL_P(tmp_data) < LONG_MIN) {
|
||||
convert_to_string_ex(&tmp_data);
|
||||
current_type = MYSQL_TYPE_VAR_STRING;
|
||||
/*
|
||||
don't change stmt->param_bind[i].type to MYSQL_TYPE_VAR_STRING
|
||||
@@ -730,6 +709,8 @@ mysqlnd_stmt_execute_store_params(MYSQLND_STMT * s, zend_uchar **buf, zend_uchar
|
||||
if the type is however not long, then we will do a goto in the next switch.
|
||||
We want to preserve the original bind type given by the user. Thus, we do these hacks.
|
||||
*/
|
||||
} else {
|
||||
convert_to_long_ex(&tmp_data);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -426,7 +426,6 @@ mysqlnd_query_read_result_set_header(MYSQLND_CONN_DATA * conn, MYSQLND_STMT * s
|
||||
DBG_INF("UPSERT");
|
||||
conn->last_query_type = QUERY_UPSERT;
|
||||
conn->field_count = rset_header->field_count;
|
||||
memset(conn->upsert_status, 0, sizeof(*conn->upsert_status));
|
||||
conn->upsert_status->warning_count = rset_header->warning_count;
|
||||
conn->upsert_status->server_status = rset_header->server_status;
|
||||
conn->upsert_status->affected_rows = rset_header->affected_rows;
|
||||
@@ -715,7 +714,6 @@ mysqlnd_fetch_row_unbuffered_c(MYSQLND_RES * result TSRMLS_DC)
|
||||
/* Mark the connection as usable again */
|
||||
DBG_INF_FMT("warnings=%u server_status=%u", row_packet->warning_count, row_packet->server_status);
|
||||
result->unbuf->eof_reached = TRUE;
|
||||
memset(result->conn->upsert_status, 0, sizeof(*result->conn->upsert_status));
|
||||
result->conn->upsert_status->warning_count = row_packet->warning_count;
|
||||
result->conn->upsert_status->server_status = row_packet->server_status;
|
||||
/*
|
||||
@@ -851,7 +849,6 @@ mysqlnd_fetch_row_unbuffered(MYSQLND_RES * result, void *param, unsigned int fla
|
||||
/* Mark the connection as usable again */
|
||||
DBG_INF_FMT("warnings=%u server_status=%u", row_packet->warning_count, row_packet->server_status);
|
||||
result->unbuf->eof_reached = TRUE;
|
||||
memset(result->conn->upsert_status, 0, sizeof(*result->conn->upsert_status));
|
||||
result->conn->upsert_status->warning_count = row_packet->warning_count;
|
||||
result->conn->upsert_status->server_status = row_packet->server_status;
|
||||
/*
|
||||
@@ -1209,7 +1206,6 @@ MYSQLND_METHOD(mysqlnd_res, store_result_fetch_data)(MYSQLND_CONN_DATA * const c
|
||||
|
||||
/* Finally clean */
|
||||
if (row_packet->eof) {
|
||||
memset(conn->upsert_status, 0, sizeof(*conn->upsert_status));
|
||||
conn->upsert_status->warning_count = row_packet->warning_count;
|
||||
conn->upsert_status->server_status = row_packet->server_status;
|
||||
}
|
||||
|
||||
@@ -763,7 +763,6 @@ php_mysqlnd_ok_read(void * _packet, MYSQLND_CONN_DATA * conn TSRMLS_DC)
|
||||
packet->error, sizeof(packet->error),
|
||||
&packet->error_no, packet->sqlstate
|
||||
TSRMLS_CC);
|
||||
DBG_INF_FMT("conn->server_status=%u", conn->upsert_status->server_status);
|
||||
DBG_RETURN(PASS);
|
||||
}
|
||||
/* Everything was fine! */
|
||||
@@ -1006,7 +1005,6 @@ php_mysqlnd_rset_header_read(void * _packet, MYSQLND_CONN_DATA * conn TSRMLS_DC)
|
||||
packet->error_info.error, sizeof(packet->error_info.error),
|
||||
&packet->error_info.error_no, packet->error_info.sqlstate
|
||||
TSRMLS_CC);
|
||||
DBG_INF_FMT("conn->server_status=%u", conn->upsert_status->server_status);
|
||||
DBG_RETURN(PASS);
|
||||
}
|
||||
|
||||
|
||||
+4
-14
@@ -645,28 +645,18 @@ static time_t asn1_time_to_time_t(ASN1_UTCTIME * timestr TSRMLS_DC) /* {{{ */
|
||||
char * thestr;
|
||||
long gmadjust = 0;
|
||||
|
||||
if (ASN1_STRING_type(timestr) != V_ASN1_UTCTIME) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "illegal ASN1 data type for timestamp");
|
||||
if (timestr->length < 13) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "extension author too lazy to parse %s correctly", timestr->data);
|
||||
return (time_t)-1;
|
||||
}
|
||||
|
||||
if (ASN1_STRING_length(timestr) != strlen(ASN1_STRING_data(timestr))) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "illegal length in timestamp");
|
||||
return (time_t)-1;
|
||||
}
|
||||
|
||||
if (ASN1_STRING_length(timestr) < 13) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to parse time string %s correctly", timestr->data);
|
||||
return (time_t)-1;
|
||||
}
|
||||
|
||||
strbuf = estrdup((char *)ASN1_STRING_data(timestr));
|
||||
strbuf = estrdup((char *)timestr->data);
|
||||
|
||||
memset(&thetime, 0, sizeof(thetime));
|
||||
|
||||
/* we work backwards so that we can use atoi more easily */
|
||||
|
||||
thestr = strbuf + ASN1_STRING_length(timestr) - 3;
|
||||
thestr = strbuf + timestr->length - 3;
|
||||
|
||||
thetime.tm_sec = atoi(thestr);
|
||||
*thestr = '\0';
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
-----BEGIN CERTIFICATE-----
|
||||
MIIEpDCCA4ygAwIBAgIJAJzu8r6u6eBcMA0GCSqGSIb3DQEBBQUAMIHDMQswCQYD
|
||||
VQQGEwJERTEcMBoGA1UECAwTTm9yZHJoZWluLVdlc3RmYWxlbjEQMA4GA1UEBwwH
|
||||
S8ODwrZsbjEUMBIGA1UECgwLU2VrdGlvbkVpbnMxHzAdBgNVBAsMFk1hbGljaW91
|
||||
cyBDZXJ0IFNlY3Rpb24xITAfBgNVBAMMGG1hbGljaW91cy5zZWt0aW9uZWlucy5k
|
||||
ZTEqMCgGCSqGSIb3DQEJARYbc3RlZmFuLmVzc2VyQHNla3Rpb25laW5zLmRlMHUY
|
||||
ZDE5NzAwMTAxMDAwMDAwWgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
|
||||
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
|
||||
AAAAAAAXDTE0MTEyODExMzkzNVowgcMxCzAJBgNVBAYTAkRFMRwwGgYDVQQIDBNO
|
||||
b3JkcmhlaW4tV2VzdGZhbGVuMRAwDgYDVQQHDAdLw4PCtmxuMRQwEgYDVQQKDAtT
|
||||
ZWt0aW9uRWluczEfMB0GA1UECwwWTWFsaWNpb3VzIENlcnQgU2VjdGlvbjEhMB8G
|
||||
A1UEAwwYbWFsaWNpb3VzLnNla3Rpb25laW5zLmRlMSowKAYJKoZIhvcNAQkBFhtz
|
||||
dGVmYW4uZXNzZXJAc2VrdGlvbmVpbnMuZGUwggEiMA0GCSqGSIb3DQEBAQUAA4IB
|
||||
DwAwggEKAoIBAQDDAf3hl7JY0XcFniyEJpSSDqn0OqBr6QP65usJPRt/8PaDoqBu
|
||||
wEYT/Na+6fsgPjC0uK9DZgWg2tHWWoanSblAMoz5PH6Z+S4SHRZ7e2dDIjPjdhjh
|
||||
0mLg2UMO5yp0V797Ggs9lNt6JRfH81MN2obXWs4NtztLMuD6egqpr8dDbr34aOs8
|
||||
pkdui5UawTZksy5pLPHq5cMhFGm06v65CLo0V2Pd9+KAokPrPcN5KLKebz7mLpk6
|
||||
SMeEXOKP4idEqxyQ7O7fBuHMedsQhu+prY3si3BUyKfQtP5CZnX2bp0wKHxX12DX
|
||||
1nfFIt9DbGvHTcyOuN+nZLPBm3vWxntyIIvVAgMBAAGjQjBAMAkGA1UdEwQCMAAw
|
||||
EQYJYIZIAYb4QgEBBAQDAgeAMAsGA1UdDwQEAwIFoDATBgNVHSUEDDAKBggrBgEF
|
||||
BQcDAjANBgkqhkiG9w0BAQUFAAOCAQEAG0fZYYCTbdj1XYc+1SnoaPR+vI8C8CaD
|
||||
8+0UYhdnyU4gga0BAcDrY9e94eEAu6ZqycF6FjLqXXdAboppWocr6T6GD1x33Ckl
|
||||
VArzG/KxQohGD2JeqkhIMlDomxHO7ka39+Oa8i2vWLVyjU8AZvWMAruHa4EENyG7
|
||||
lW2AagaFKFCr9TnXTfrdxGVEbv7KVQ6bdhg5p5SjpWH1+Mq03uR3ZXPBYdyV8319
|
||||
o0lVj1KFI2DCL/liWisJRoof+1cR35Ctd0wYBcpB6TZslMcOPl76dwKwJgeJo2Qg
|
||||
Zsfmc2vC1/qOlNuNq/0TzzkVGv8ETT3CgaU+UXe4XOVvkccebJn2dg==
|
||||
-----END CERTIFICATE-----
|
||||
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
--TEST--
|
||||
CVE-2013-6420
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (!extension_loaded("openssl")) die("skip");
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
$crt = substr(__FILE__, 0, -4).'.crt';
|
||||
$info = openssl_x509_parse("file://$crt");
|
||||
var_dump($info['issuer']['emailAddress'], $info["validFrom_time_t"]);
|
||||
?>
|
||||
Done
|
||||
--EXPECTF--
|
||||
%s openssl_x509_parse(): illegal ASN1 data type for timestamp in %s/cve-2013-6420.php on line 3
|
||||
string(27) "stefan.esser@sektioneins.de"
|
||||
int(-1)
|
||||
Done
|
||||
+2
-2
@@ -460,7 +460,7 @@ static void pdo_stmt_construct(pdo_stmt_t *stmt, zval *object, zend_class_entry
|
||||
if (dbstmt_ce->constructor) {
|
||||
zend_fcall_info fci;
|
||||
zend_fcall_info_cache fcc;
|
||||
zval *retval = NULL;
|
||||
zval *retval;
|
||||
|
||||
fci.size = sizeof(zend_fcall_info);
|
||||
fci.function_table = &dbstmt_ce->function_table;
|
||||
@@ -495,7 +495,7 @@ static void pdo_stmt_construct(pdo_stmt_t *stmt, zval *object, zend_class_entry
|
||||
zval_dtor(object);
|
||||
ZVAL_NULL(object);
|
||||
object = NULL; /* marks failure */
|
||||
} else if (retval) {
|
||||
} else {
|
||||
zval_ptr_dtor(&retval);
|
||||
}
|
||||
|
||||
|
||||
+11
-14
@@ -1,4 +1,4 @@
|
||||
/* Generated by re2c 0.13.5 on Thu Nov 7 18:02:29 2013 */
|
||||
/* Generated by re2c 0.13.5 on Tue Aug 20 18:02:48 2013 */
|
||||
#line 1 "ext/pdo/pdo_sql_parser.re"
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
@@ -586,9 +586,7 @@ safe:
|
||||
}
|
||||
plc->freeq = 1;
|
||||
} else {
|
||||
zval tmp_param = *param->parameter;
|
||||
zval_copy_ctor(&tmp_param);
|
||||
switch (Z_TYPE(tmp_param)) {
|
||||
switch (Z_TYPE_P(param->parameter)) {
|
||||
case IS_NULL:
|
||||
plc->quoted = "NULL";
|
||||
plc->qlen = sizeof("NULL")-1;
|
||||
@@ -596,20 +594,20 @@ safe:
|
||||
break;
|
||||
|
||||
case IS_BOOL:
|
||||
convert_to_long(&tmp_param);
|
||||
/* fall through */
|
||||
convert_to_long(param->parameter);
|
||||
|
||||
case IS_LONG:
|
||||
case IS_DOUBLE:
|
||||
convert_to_string(&tmp_param);
|
||||
plc->qlen = Z_STRLEN(tmp_param);
|
||||
plc->quoted = estrdup(Z_STRVAL(tmp_param));
|
||||
plc->freeq = 1;
|
||||
convert_to_string(param->parameter);
|
||||
plc->qlen = Z_STRLEN_P(param->parameter);
|
||||
plc->quoted = Z_STRVAL_P(param->parameter);
|
||||
plc->freeq = 0;
|
||||
break;
|
||||
|
||||
default:
|
||||
convert_to_string(&tmp_param);
|
||||
if (!stmt->dbh->methods->quoter(stmt->dbh, Z_STRVAL(tmp_param),
|
||||
Z_STRLEN(tmp_param), &plc->quoted, &plc->qlen,
|
||||
convert_to_string(param->parameter);
|
||||
if (!stmt->dbh->methods->quoter(stmt->dbh, Z_STRVAL_P(param->parameter),
|
||||
Z_STRLEN_P(param->parameter), &plc->quoted, &plc->qlen,
|
||||
param->param_type TSRMLS_CC)) {
|
||||
/* bork */
|
||||
ret = -1;
|
||||
@@ -618,7 +616,6 @@ safe:
|
||||
}
|
||||
plc->freeq = 1;
|
||||
}
|
||||
zval_dtor(&tmp_param);
|
||||
}
|
||||
} else {
|
||||
plc->quoted = Z_STRVAL_P(param->parameter);
|
||||
|
||||
+10
-13
@@ -228,9 +228,7 @@ safe:
|
||||
}
|
||||
plc->freeq = 1;
|
||||
} else {
|
||||
zval tmp_param = *param->parameter;
|
||||
zval_copy_ctor(&tmp_param);
|
||||
switch (Z_TYPE(tmp_param)) {
|
||||
switch (Z_TYPE_P(param->parameter)) {
|
||||
case IS_NULL:
|
||||
plc->quoted = "NULL";
|
||||
plc->qlen = sizeof("NULL")-1;
|
||||
@@ -238,20 +236,20 @@ safe:
|
||||
break;
|
||||
|
||||
case IS_BOOL:
|
||||
convert_to_long(&tmp_param);
|
||||
/* fall through */
|
||||
convert_to_long(param->parameter);
|
||||
|
||||
case IS_LONG:
|
||||
case IS_DOUBLE:
|
||||
convert_to_string(&tmp_param);
|
||||
plc->qlen = Z_STRLEN(tmp_param);
|
||||
plc->quoted = estrdup(Z_STRVAL(tmp_param));
|
||||
plc->freeq = 1;
|
||||
convert_to_string(param->parameter);
|
||||
plc->qlen = Z_STRLEN_P(param->parameter);
|
||||
plc->quoted = Z_STRVAL_P(param->parameter);
|
||||
plc->freeq = 0;
|
||||
break;
|
||||
|
||||
default:
|
||||
convert_to_string(&tmp_param);
|
||||
if (!stmt->dbh->methods->quoter(stmt->dbh, Z_STRVAL(tmp_param),
|
||||
Z_STRLEN(tmp_param), &plc->quoted, &plc->qlen,
|
||||
convert_to_string(param->parameter);
|
||||
if (!stmt->dbh->methods->quoter(stmt->dbh, Z_STRVAL_P(param->parameter),
|
||||
Z_STRLEN_P(param->parameter), &plc->quoted, &plc->qlen,
|
||||
param->param_type TSRMLS_CC)) {
|
||||
/* bork */
|
||||
ret = -1;
|
||||
@@ -260,7 +258,6 @@ safe:
|
||||
}
|
||||
plc->freeq = 1;
|
||||
}
|
||||
zval_dtor(&tmp_param);
|
||||
}
|
||||
} else {
|
||||
plc->quoted = Z_STRVAL_P(param->parameter);
|
||||
|
||||
@@ -1,32 +0,0 @@
|
||||
--TEST--
|
||||
Bug #65946 (pdo_sql_parser.c permanently converts values bound to strings)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (!extension_loaded('pdo')) die('skip');
|
||||
$dir = getenv('REDIR_TEST_DIR');
|
||||
if (false == $dir) die('skip no driver');
|
||||
require_once $dir . 'pdo_test.inc';
|
||||
PDOTest::skip();
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
if (getenv('REDIR_TEST_DIR') === false) putenv('REDIR_TEST_DIR='.dirname(__FILE__) . '/../../pdo/tests/');
|
||||
require_once getenv('REDIR_TEST_DIR') . 'pdo_test.inc';
|
||||
$db = PDOTest::factory();
|
||||
$db->setAttribute(PDO::ATTR_EMULATE_PREPARES, true);
|
||||
$db->exec('CREATE TABLE test(id int)');
|
||||
$db->exec('INSERT INTO test VALUES(1)');
|
||||
$stmt = $db->prepare('SELECT * FROM test LIMIT :limit');
|
||||
$stmt->bindValue('limit', 1, PDO::PARAM_INT);
|
||||
if(!($res = $stmt->execute())) var_dump($stmt->errorInfo());
|
||||
if(!($res = $stmt->execute())) var_dump($stmt->errorInfo());
|
||||
var_dump($stmt->fetchAll(PDO::FETCH_ASSOC));
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(1) {
|
||||
[0]=>
|
||||
array(1) {
|
||||
["id"]=>
|
||||
string(1) "1"
|
||||
}
|
||||
}
|
||||
@@ -1,38 +0,0 @@
|
||||
--TEST--
|
||||
Bug #66141 (mysqlnd quote function is wrong with NO_BACKSLASH_ESCAPES after failed query)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc');
|
||||
require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc');
|
||||
MySQLPDOTest::skip();
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
include __DIR__ . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc';
|
||||
$db = MySQLPDOTest::factory();
|
||||
|
||||
$input = 'Something\', 1 as one, 2 as two FROM dual; -- f';
|
||||
|
||||
$quotedInput0 = $db->quote($input);
|
||||
|
||||
$db->query('set session sql_mode="NO_BACKSLASH_ESCAPES"');
|
||||
|
||||
// injection text from some user input
|
||||
|
||||
$quotedInput1 = $db->quote($input);
|
||||
|
||||
$db->query('something that throws an exception');
|
||||
|
||||
$quotedInput2 = $db->quote($input);
|
||||
|
||||
var_dump($quotedInput0);
|
||||
var_dump($quotedInput1);
|
||||
var_dump($quotedInput2);
|
||||
?>
|
||||
done
|
||||
--EXPECTF--
|
||||
Warning: PDO::query(): SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'something that throws an exception' at line %d in %s on line %d
|
||||
string(50) "'Something\', 1 as one, 2 as two FROM dual; -- f'"
|
||||
string(50) "'Something'', 1 as one, 2 as two FROM dual; -- f'"
|
||||
string(50) "'Something'', 1 as one, 2 as two FROM dual; -- f'"
|
||||
done
|
||||
@@ -1,33 +0,0 @@
|
||||
--TEST--
|
||||
Bug #66033 (Segmentation Fault when constructor of PDO statement throws an exception)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (!extension_loaded('pdo_sqlite')) print 'skip not loaded';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
class DBStatement extends PDOStatement {
|
||||
public $dbh;
|
||||
protected function __construct($dbh) {
|
||||
$this->dbh = $dbh;
|
||||
throw new Exception("Blah");
|
||||
}
|
||||
}
|
||||
|
||||
$pdo = new PDO('sqlite::memory:', null, null);
|
||||
$pdo->setAttribute(PDO::ATTR_STATEMENT_CLASS, array('DBStatement',
|
||||
array($pdo)));
|
||||
$pdo->exec("CREATE TABLE IF NOT EXISTS messages (
|
||||
id INTEGER PRIMARY KEY,
|
||||
title TEXT,
|
||||
message TEXT,
|
||||
time INTEGER)");
|
||||
|
||||
try {
|
||||
$pdoStatement = $pdo->query("select * from messages");
|
||||
} catch (Exception $e) {
|
||||
var_dump($e->getMessage());
|
||||
}
|
||||
?>
|
||||
--EXPECTF--
|
||||
string(4) "Blah"
|
||||
@@ -168,7 +168,11 @@ static int phar_compare_dir_name(const void *a, const void *b TSRMLS_DC) /* {{{
|
||||
|
||||
f = *((Bucket **) a);
|
||||
s = *((Bucket **) b);
|
||||
#if (PHP_MAJOR_VERSION < 6)
|
||||
result = zend_binary_strcmp(f->arKey, f->nKeyLength, s->arKey, s->nKeyLength);
|
||||
#else
|
||||
result = zend_binary_strcmp(f->key.arKey.s, f->nKeyLength, s->key.arKey.s, s->nKeyLength);
|
||||
#endif
|
||||
|
||||
if (result < 0) {
|
||||
return -1;
|
||||
|
||||
@@ -7,16 +7,16 @@ Erwin Poeze <erwin.poeze@gmail.com>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
file_put_contents('SplFileObject_getflags_basic.csv', 'eerste;tweede;derde');
|
||||
file_put_contents('testdata.csv', 'eerste;tweede;derde');
|
||||
|
||||
$fo = new SplFileObject('SplFileObject_getflags_basic.csv');
|
||||
$fo = new SplFileObject('testdata.csv');
|
||||
|
||||
$fo->setFlags(SplFileObject::DROP_NEW_LINE);
|
||||
var_dump($fo->getFlags());
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
unlink('SplFileObject_getflags_basic.csv');
|
||||
unlink('testdata.csv');
|
||||
?>
|
||||
--EXPECT--
|
||||
int(1)
|
||||
@@ -7,10 +7,10 @@ Erwin Poeze <erwin.poeze@gmail.com>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
file_put_contents('SplFileObject_getflags_error001.csv', 'eerste;tweede;derde');
|
||||
file_put_contents('testdata.csv', 'eerste;tweede;derde');
|
||||
|
||||
|
||||
$fo = new SplFileObject('SplFileObject_getflags_error001.csv');
|
||||
$fo = new SplFileObject('testdata.csv');
|
||||
$fo->setFlags(SplFileObject::READ_CSV);
|
||||
|
||||
$fo->setFlags(SplFileObject::DROP_NEW_LINE);
|
||||
@@ -20,7 +20,7 @@ var_dump($fo->getFlags());
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
unlink('SplFileObject_getflags_error001.csv');
|
||||
unlink('testdata.csv');
|
||||
?>
|
||||
--EXPECT--
|
||||
int(1)
|
||||
@@ -5,9 +5,9 @@ Erwin Poeze <erwin.poeze@gmail.com>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
file_put_contents('SplFileObject_getflags_error002.csv', 'eerste;tweede;derde');
|
||||
file_put_contents('testdata.csv', 'eerste;tweede;derde');
|
||||
|
||||
$fo = new SplFileObject('SplFileObject_getflags_error002.csv');
|
||||
$fo = new SplFileObject('testdata.csv');
|
||||
$fo->setFlags(SplFileObject::READ_CSV);
|
||||
|
||||
$fo->getFlags('fake');
|
||||
@@ -15,7 +15,7 @@ $fo->getFlags('fake');
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
unlink('SplFileObject_getflags_error002.csv');
|
||||
unlink('testdata.csv');
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: SplFileObject::getFlags() expects exactly 0 parameters, 1 given in %s on line %d
|
||||
@@ -7,16 +7,12 @@ Erwin Poeze <erwin.poeze@gmail.com>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
file_put_contents('SplFileObject_rewind_error001.csv', 'eerste;tweede;derde');
|
||||
file_put_contents('testdata.csv', 'eerste;tweede;derde');
|
||||
|
||||
$fo = new SplFileObject('SplFileObject_rewind_error001.csv');
|
||||
$fo = new SplFileObject('testdata.csv');
|
||||
|
||||
$fo->rewind( "invalid" );
|
||||
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
unlink('SplFileObject_rewind_error001.csv');
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: SplFileObject::rewind() expects exactly 0 parameters, 1 given in %s on line %d
|
||||
@@ -5724,7 +5724,7 @@ PHP_FUNCTION(unregister_tick_function)
|
||||
return;
|
||||
}
|
||||
|
||||
if (Z_TYPE_P(function) != IS_ARRAY && Z_TYPE_P(function) != IS_OBJECT) {
|
||||
if (Z_TYPE_P(function) != IS_ARRAY) {
|
||||
convert_to_string(function);
|
||||
}
|
||||
|
||||
|
||||
@@ -156,7 +156,7 @@ PHPAPI char *php_strerror(int errnum);
|
||||
# define php_mblen(ptr, len) 1
|
||||
#else
|
||||
# if defined(_REENTRANT) && defined(HAVE_MBRLEN) && defined(HAVE_MBSTATE_T)
|
||||
# define php_mblen(ptr, len) ((ptr) == NULL ? memset(&BG(mblen_state), 0, sizeof(BG(mblen_state))): (int)mbrlen(ptr, len, &BG(mblen_state)))
|
||||
# define php_mblen(ptr, len) ((ptr) == NULL ? mbsinit(&BG(mblen_state)): (int)mbrlen(ptr, len, &BG(mblen_state)))
|
||||
# else
|
||||
# define php_mblen(ptr, len) mblen(ptr, len)
|
||||
# endif
|
||||
|
||||
@@ -5,17 +5,11 @@ Dave Kelsey <d_kelsey@uk.ibm.com>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://127.0.0.1:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
/* Setup socket server */
|
||||
$server = stream_socket_server('tcp://127.0.0.1:31337');
|
||||
|
||||
/* Connect to it */
|
||||
$client = fsockopen("tcp://127.0.0.1:$port");
|
||||
$client = fsockopen('tcp://127.0.0.1:31337');
|
||||
|
||||
if (!$client) {
|
||||
die("Unable to create socket");
|
||||
|
||||
@@ -16,17 +16,11 @@ for ($i = 0; $i < 1000; $i++) {
|
||||
}
|
||||
fclose($fd);
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://127.0.0.1:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
/* Setup socket server */
|
||||
$server = stream_socket_server('tcp://127.0.0.1:31337');
|
||||
|
||||
/* Connect to it */
|
||||
$client = fsockopen("tcp://127.0.0.1:$port");
|
||||
$client = fsockopen('tcp://127.0.0.1:31337');
|
||||
|
||||
if (!$client) {
|
||||
die("Unable to create socket");
|
||||
|
||||
@@ -17,10 +17,10 @@ if(substr(PHP_OS, 0, 3) == "WIN")
|
||||
|
||||
echo "*** Testing file_put_contents() : usage variation ***\n";
|
||||
|
||||
$filename = dirname(__FILE__).'/filePutContentsVar9.tmp';
|
||||
$softlink = dirname(__FILE__).'/filePutContentsVar9.SoftLink';
|
||||
$hardlink = dirname(__FILE__).'/filePutContentsVar9.HardLink';
|
||||
$chainlink = dirname(__FILE__).'/filePutContentsVar9.ChainLink';
|
||||
$filename = dirname(__FILE__).'/fileGetContentsVar9.tmp';
|
||||
$softlink = dirname(__FILE__).'/fileGetContentsVar9.SoftLink';
|
||||
$hardlink = dirname(__FILE__).'/fileGetContentsVar9.HardLink';
|
||||
$chainlink = dirname(__FILE__).'/fileGetContentsVar9.ChainLink';
|
||||
|
||||
|
||||
// link files even though it original file doesn't exist yet
|
||||
|
||||
@@ -3,20 +3,13 @@ Testing fread() on a TCP server socket
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://127.0.0.1:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
$tcp_socket = stream_socket_server('tcp://127.0.0.1:31337');
|
||||
|
||||
socket_set_timeout($server, 0, 1000);
|
||||
socket_set_timeout($tcp_socket, 0, 1000);
|
||||
|
||||
var_dump(fread($server, 1));
|
||||
var_dump(fread($tcp_socket, 1));
|
||||
|
||||
fclose($server);
|
||||
fclose($tcp_socket);
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
|
||||
@@ -3,7 +3,7 @@ Bug #41445 (parse_ini_file() function parses octal numbers in section names) - 2
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$file = dirname(__FILE__)."/bug41445_1.ini";
|
||||
$file = dirname(__FILE__)."/bug41445.ini";
|
||||
|
||||
$data = <<<DATA
|
||||
[2454.33]
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
--TEST--
|
||||
Bug #66094 (unregister_tick_function tries to cast a Closure to a string)
|
||||
--FILE--
|
||||
<?php
|
||||
declare(ticks=1);
|
||||
register_tick_function($closure = function () { echo "Tick!\n"; });
|
||||
unregister_tick_function($closure);
|
||||
echo "done";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Tick!
|
||||
done
|
||||
@@ -1,7 +1,7 @@
|
||||
--TEST--
|
||||
Test var_export() function with locale
|
||||
--INI--
|
||||
serialize_precision=17
|
||||
precision=14
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (!setlocale(LC_ALL, "german", "de","de_DE","de_DE.ISO8859-1","de_DE.ISO_8859-1","de_DE.UTF-8")) {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
--TEST--
|
||||
Test var_export() function with valid float values
|
||||
--INI--
|
||||
serialize_precision=17
|
||||
precision=14
|
||||
--FILE--
|
||||
<?php
|
||||
/* Prototype : mixed var_export(mixed var [, bool return])
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
--TEST--
|
||||
Test var_export() function with valid arrays
|
||||
--INI--
|
||||
serialize_precision=17
|
||||
--FILE--
|
||||
<?php
|
||||
/* Prototype : mixed var_export(mixed var [, bool return])
|
||||
|
||||
@@ -11,18 +11,12 @@ Test fsockopen() function : basic functionality
|
||||
echo "*** Testing fsockopen() : basic functionality ***\n";
|
||||
|
||||
echo "Open a server socket\n";
|
||||
$server = stream_socket_server('tcp://127.0.0.1:31337');
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://127.0.0.1:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// Initialise all required variables
|
||||
$hostname = 'tcp://127.0.0.1'; // loopback address
|
||||
$port = 31337;
|
||||
$errno = null;
|
||||
$errstr = null;
|
||||
$timeout = 1.5;
|
||||
|
||||
@@ -4,17 +4,11 @@ testing fsockopen without a protocol string
|
||||
<?php
|
||||
|
||||
echo "Open a server socket\n";
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://127.0.0.1:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
$server = stream_socket_server('tcp://127.0.0.1:31337');
|
||||
|
||||
echo "\nCalling fsockopen() without a protocol in the hostname string:\n";
|
||||
$hostname = '127.0.0.1';
|
||||
$port = '31337';
|
||||
$client = fsockopen($hostname, $port);
|
||||
var_dump($client);
|
||||
fclose($client);
|
||||
|
||||
@@ -6,22 +6,14 @@ stream_socket_shutdown() test on IPv4 TCP Loopback
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://127.0.0.1:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!$server) {
|
||||
/* Setup socket server */
|
||||
$server = stream_socket_server('tcp://127.0.0.1:31337');
|
||||
if (!$server) {
|
||||
die('Unable to create AF_INET socket [server]');
|
||||
}
|
||||
|
||||
/* Connect and send request 1 */
|
||||
$client1 = stream_socket_client("tcp://127.0.0.1:$port");
|
||||
$client1 = stream_socket_client('tcp://127.0.0.1:31337');
|
||||
if (!$client1) {
|
||||
die('Unable to create AF_INET socket [client]');
|
||||
}
|
||||
@@ -30,7 +22,7 @@ if (!$server) {
|
||||
@fwrite($client1, "Error 1\n");
|
||||
|
||||
/* Connect and send request 2 */
|
||||
$client2 = stream_socket_client("tcp://127.0.0.1:$port");
|
||||
$client2 = stream_socket_client('tcp://127.0.0.1:31337');
|
||||
if (!$client2) {
|
||||
die('Unable to create AF_INET socket [client]');
|
||||
}
|
||||
|
||||
@@ -3,17 +3,9 @@ Testing socket_get_status()
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://127.0.0.1:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
var_dump(socket_get_status($server));
|
||||
fclose($server);
|
||||
$tcp_socket = stream_socket_server('tcp://127.0.0.1:31337');
|
||||
var_dump(socket_get_status($tcp_socket));
|
||||
fclose($tcp_socket);
|
||||
|
||||
?>
|
||||
--EXPECTF--
|
||||
|
||||
@@ -2,21 +2,14 @@
|
||||
Streams Based IPv4 TCP Loopback test
|
||||
--FILE--
|
||||
<?php # vim:ft=php:
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://127.0.0.1:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
/* Setup socket server */
|
||||
$server = stream_socket_server('tcp://127.0.0.1:31337');
|
||||
if (!$server) {
|
||||
die('Unable to create AF_INET socket [server]');
|
||||
}
|
||||
|
||||
/* Connect to it */
|
||||
$client = stream_socket_client("tcp://127.0.0.1:$port");
|
||||
$client = stream_socket_client('tcp://127.0.0.1:31337');
|
||||
if (!$client) {
|
||||
die('Unable to create AF_INET socket [client]');
|
||||
}
|
||||
|
||||
@@ -10,22 +10,14 @@ Streams Based IPv6 TCP Loopback test
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://[::1]:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* Setup socket server */
|
||||
$server = stream_socket_server('tcp://[::1]:31337');
|
||||
if (!$server) {
|
||||
die('Unable to create AF_INET6 socket [server]');
|
||||
}
|
||||
|
||||
/* Connect to it */
|
||||
$client = stream_socket_client("tcp://[::1]:$port");
|
||||
$client = stream_socket_client('tcp://[::1]:31337');
|
||||
if (!$client) {
|
||||
die('Unable to create AF_INET6 socket [client]');
|
||||
}
|
||||
|
||||
@@ -16,22 +16,14 @@ Streams Based IPv6 UDP Loopback test
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("udp://[::1]:$port", $errno, $errstr, STREAM_SERVER_BIND);
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* Setup socket server */
|
||||
$server = stream_socket_server('udp://[::1]:31337', $errno, $errstr, STREAM_SERVER_BIND);
|
||||
if (!$server) {
|
||||
die('Unable to create AF_INET6 socket [server]');
|
||||
}
|
||||
|
||||
/* Connect to it */
|
||||
$client = stream_socket_client("udp://[::1]:$port");
|
||||
$client = stream_socket_client('udp://[::1]:31337');
|
||||
if (!$client) {
|
||||
die('Unable to create AF_INET6 socket [client]');
|
||||
}
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
--TEST--
|
||||
Test unserialize(): error is indistinguishable from deserialized boolean
|
||||
--FILE--
|
||||
<?php
|
||||
/* Prototype : proto string serialize(mixed variable)
|
||||
* Description: Returns a string representation of variable (which can later be unserialized)
|
||||
* Source code: ext/standard/var.c
|
||||
* Alias to functions:
|
||||
*/
|
||||
/* Prototype : proto mixed unserialize(string variable_representation)
|
||||
* Description: Takes a string representation of variable and recreates it
|
||||
* Source code: ext/standard/var.c
|
||||
* Alias to functions:
|
||||
*/
|
||||
|
||||
echo "*** Testing unserialize() error/boolean distinction ***\n";
|
||||
|
||||
$garbage = "obvious non-serialized data";
|
||||
$serialized_false = serialize(false);
|
||||
|
||||
var_dump($serialized_false);
|
||||
|
||||
$deserialized_garbage = unserialize($garbage);
|
||||
var_dump($deserialized_garbage);
|
||||
|
||||
$deserialized_false = unserialize($serialized_false);
|
||||
var_dump($deserialized_false);
|
||||
|
||||
echo "unserialize error and deserialized false are identical? " . (bool) ($deserialized_false == $deserialized_garbage) . "\n";
|
||||
|
||||
// candidate safe idiom for determining whether data is serialized
|
||||
function isSerialized($str) {
|
||||
return ($str == serialize(false) || @unserialize($str) !== false);
|
||||
}
|
||||
|
||||
// Test unserialize error idiom
|
||||
var_dump(isSerialized($garbage));
|
||||
var_dump(isSerialized($serialized_false));
|
||||
|
||||
echo "Done";
|
||||
?>
|
||||
--EXPECTF--
|
||||
*** Testing unserialize() error/boolean distinction ***
|
||||
string(4) "b:0;"
|
||||
|
||||
Notice: unserialize(): Error at offset 0 of 27 bytes in %s%eserialization_error_002.php on line 20
|
||||
bool(false)
|
||||
bool(false)
|
||||
unserialize error and deserialized false are identical? 1
|
||||
bool(false)
|
||||
bool(true)
|
||||
Done
|
||||
@@ -13,16 +13,10 @@ echo "*** Testing stream_set_timeout() : error conditions ***\n";
|
||||
//Test stream_set_timeout with one more than the expected number of arguments
|
||||
echo "\n-- Testing stream_set_timeout() function with more than expected no. of arguments --\n";
|
||||
|
||||
for ($i=0; $i<100; $i++) {
|
||||
$port = rand(10000, 65000);
|
||||
/* Setup socket server */
|
||||
$server = @stream_socket_server("tcp://127.0.0.1:$port");
|
||||
if ($server) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
/* Setup socket server */
|
||||
$server = stream_socket_server('tcp://127.0.0.1:31337');
|
||||
/* Connect to it */
|
||||
$client = fsockopen("tcp://127.0.0.1:$port");
|
||||
$client = fsockopen('tcp://127.0.0.1:31337');
|
||||
|
||||
$seconds = 10;
|
||||
$microseconds = 10;
|
||||
|
||||
@@ -1,17 +0,0 @@
|
||||
--TEST--
|
||||
Bug #65947 (basename is no more working after fgetcsv in certain situation)
|
||||
--SKIPIF--
|
||||
<?php if (!PHP_ZTS) { print "skip only for zts build"; }
|
||||
--FILE--
|
||||
<?php
|
||||
$filename = 'test.toto';
|
||||
// é in ISO-8859-1
|
||||
$csv = base64_decode('6Q==');
|
||||
$adata = str_getcsv($csv,";");
|
||||
$b2 = basename($filename);
|
||||
if ($filename != $b2)
|
||||
print "BUG";
|
||||
else
|
||||
print "OKEY";
|
||||
--EXPECTF--
|
||||
OKEY
|
||||
@@ -20,7 +20,7 @@ $arg3 = array("one","two","three");
|
||||
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic1.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ $arg2 = array(111,222);
|
||||
$arg3 = array(111,222,333);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic2.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ $arg2 = array(11.11,22.22);
|
||||
$arg3 = array(11.11,22.22,33.33);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic3.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ $arg2 = array(TRUE,FALSE);
|
||||
$arg3 = array(TRUE,FALSE,TRUE);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic4.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ $arg2 = array(65,66);
|
||||
$arg3 = array(65,66,67);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic5.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ $arg2 = array(1000,2000);
|
||||
$arg3 = array(1000,2000,3000);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic6.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ $arg2 = array(-1111,-1234567);
|
||||
$arg3 = array(-1111,-1234567,-2345432);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic7.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ $arg2 = array(-1111,-1234567);
|
||||
$arg3 = array(-1111,-1234567,-2345432);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic7_64bit.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ $arg2 = array(021,0347);
|
||||
$arg3 = array(021,0347,05678);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic8.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ $arg2 = array(11,132);
|
||||
$arg3 = array(11,132,177);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_basic9.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
Binary file not shown.
@@ -45,7 +45,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation11.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation11_64bit.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation12.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation12_64bit.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation13.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation13_64bit.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation14.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation14_64bit.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation15.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation15_64bit.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation16.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation16_64bit.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation17.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -57,7 +57,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation18.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ $args_array = array(
|
||||
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation19.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ $args_array = array(
|
||||
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation19_64bit.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -84,7 +84,7 @@ $values = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation20.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -81,7 +81,7 @@ $values = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation21.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ $args_array = array(
|
||||
// and with int values from the above $args_array array
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation3.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -62,7 +62,7 @@ $args_array = array(
|
||||
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation4.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -62,7 +62,7 @@ $args_array = array(
|
||||
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation4_64bit.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation5.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
@@ -57,7 +57,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation6.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
Binary file not shown.
@@ -60,7 +60,7 @@ $args_array = array(
|
||||
);
|
||||
|
||||
/* creating dumping file */
|
||||
$data_file = dirname(__FILE__) . '/vfprintf_variation8.txt';
|
||||
$data_file = dirname(__FILE__) . '/dump.txt';
|
||||
if (!($fp = fopen($data_file, 'wt')))
|
||||
return;
|
||||
|
||||
|
||||
Binary file not shown.
@@ -743,13 +743,6 @@ echo "Done";
|
||||
string(1) ":"
|
||||
}
|
||||
|
||||
--> http://::#: array(2) {
|
||||
["scheme"]=>
|
||||
string(4) "http"
|
||||
["host"]=>
|
||||
string(1) ":"
|
||||
}
|
||||
|
||||
--> x://::6.5: array(3) {
|
||||
["scheme"]=>
|
||||
string(1) "x"
|
||||
@@ -863,8 +856,6 @@ echo "Done";
|
||||
|
||||
--> http://?: bool(false)
|
||||
|
||||
--> http://#: bool(false)
|
||||
|
||||
--> http://?:: bool(false)
|
||||
|
||||
--> http://:?: bool(false)
|
||||
@@ -872,4 +863,4 @@ echo "Done";
|
||||
--> http://blah.com:123456: bool(false)
|
||||
|
||||
--> http://blah.com:abcdef: bool(false)
|
||||
Done
|
||||
Done
|
||||
@@ -96,7 +96,6 @@ echo "Done";
|
||||
--> x:/blah.com : string(1) "x"
|
||||
--> x://::abc/? : bool(false)
|
||||
--> http://::? : string(4) "http"
|
||||
--> http://::# : string(4) "http"
|
||||
--> x://::6.5 : string(1) "x"
|
||||
--> http://?:/ : string(4) "http"
|
||||
--> http://@?:/ : string(4) "http"
|
||||
@@ -119,9 +118,8 @@ echo "Done";
|
||||
--> http://@:/ : bool(false)
|
||||
--> http://:/ : bool(false)
|
||||
--> http://? : bool(false)
|
||||
--> http://# : bool(false)
|
||||
--> http://?: : bool(false)
|
||||
--> http://:? : bool(false)
|
||||
--> http://blah.com:123456 : bool(false)
|
||||
--> http://blah.com:abcdef : bool(false)
|
||||
Done
|
||||
Done
|
||||
@@ -95,7 +95,6 @@ echo "Done";
|
||||
--> x:/blah.com : NULL
|
||||
--> x://::abc/? : bool(false)
|
||||
--> http://::? : string(1) ":"
|
||||
--> http://::# : string(1) ":"
|
||||
--> x://::6.5 : string(1) ":"
|
||||
--> http://?:/ : string(1) "?"
|
||||
--> http://@?:/ : string(1) "?"
|
||||
@@ -118,9 +117,8 @@ echo "Done";
|
||||
--> http://@:/ : bool(false)
|
||||
--> http://:/ : bool(false)
|
||||
--> http://? : bool(false)
|
||||
--> http://# : bool(false)
|
||||
--> http://?: : bool(false)
|
||||
--> http://:? : bool(false)
|
||||
--> http://blah.com:123456 : bool(false)
|
||||
--> http://blah.com:abcdef : bool(false)
|
||||
Done
|
||||
Done
|
||||
@@ -95,7 +95,6 @@ echo "Done";
|
||||
--> x:/blah.com : NULL
|
||||
--> x://::abc/? : bool(false)
|
||||
--> http://::? : NULL
|
||||
--> http://::# : NULL
|
||||
--> x://::6.5 : int(6)
|
||||
--> http://?:/ : NULL
|
||||
--> http://@?:/ : NULL
|
||||
@@ -118,9 +117,8 @@ echo "Done";
|
||||
--> http://@:/ : bool(false)
|
||||
--> http://:/ : bool(false)
|
||||
--> http://? : bool(false)
|
||||
--> http://# : bool(false)
|
||||
--> http://?: : bool(false)
|
||||
--> http://:? : bool(false)
|
||||
--> http://blah.com:123456 : bool(false)
|
||||
--> http://blah.com:abcdef : bool(false)
|
||||
Done
|
||||
Done
|
||||
@@ -95,7 +95,6 @@ echo "Done";
|
||||
--> x:/blah.com : NULL
|
||||
--> x://::abc/? : bool(false)
|
||||
--> http://::? : NULL
|
||||
--> http://::# : NULL
|
||||
--> x://::6.5 : NULL
|
||||
--> http://?:/ : NULL
|
||||
--> http://@?:/ : string(0) ""
|
||||
@@ -118,9 +117,8 @@ echo "Done";
|
||||
--> http://@:/ : bool(false)
|
||||
--> http://:/ : bool(false)
|
||||
--> http://? : bool(false)
|
||||
--> http://# : bool(false)
|
||||
--> http://?: : bool(false)
|
||||
--> http://:? : bool(false)
|
||||
--> http://blah.com:123456 : bool(false)
|
||||
--> http://blah.com:abcdef : bool(false)
|
||||
Done
|
||||
Done
|
||||
@@ -95,7 +95,6 @@ echo "Done";
|
||||
--> x:/blah.com : NULL
|
||||
--> x://::abc/? : bool(false)
|
||||
--> http://::? : NULL
|
||||
--> http://::# : NULL
|
||||
--> x://::6.5 : NULL
|
||||
--> http://?:/ : NULL
|
||||
--> http://@?:/ : NULL
|
||||
@@ -118,9 +117,8 @@ echo "Done";
|
||||
--> http://@:/ : bool(false)
|
||||
--> http://:/ : bool(false)
|
||||
--> http://? : bool(false)
|
||||
--> http://# : bool(false)
|
||||
--> http://?: : bool(false)
|
||||
--> http://:? : bool(false)
|
||||
--> http://blah.com:123456 : bool(false)
|
||||
--> http://blah.com:abcdef : bool(false)
|
||||
Done
|
||||
Done
|
||||
@@ -95,7 +95,6 @@ echo "Done";
|
||||
--> x:/blah.com : string(9) "/blah.com"
|
||||
--> x://::abc/? : bool(false)
|
||||
--> http://::? : NULL
|
||||
--> http://::# : NULL
|
||||
--> x://::6.5 : NULL
|
||||
--> http://?:/ : string(1) "/"
|
||||
--> http://@?:/ : string(1) "/"
|
||||
@@ -118,9 +117,8 @@ echo "Done";
|
||||
--> http://@:/ : bool(false)
|
||||
--> http://:/ : bool(false)
|
||||
--> http://? : bool(false)
|
||||
--> http://# : bool(false)
|
||||
--> http://?: : bool(false)
|
||||
--> http://:? : bool(false)
|
||||
--> http://blah.com:123456 : bool(false)
|
||||
--> http://blah.com:abcdef : bool(false)
|
||||
Done
|
||||
Done
|
||||
@@ -95,7 +95,6 @@ echo "Done";
|
||||
--> x:/blah.com : NULL
|
||||
--> x://::abc/? : bool(false)
|
||||
--> http://::? : NULL
|
||||
--> http://::# : NULL
|
||||
--> x://::6.5 : NULL
|
||||
--> http://?:/ : NULL
|
||||
--> http://@?:/ : NULL
|
||||
@@ -118,9 +117,8 @@ echo "Done";
|
||||
--> http://@:/ : bool(false)
|
||||
--> http://:/ : bool(false)
|
||||
--> http://? : bool(false)
|
||||
--> http://# : bool(false)
|
||||
--> http://?: : bool(false)
|
||||
--> http://:? : bool(false)
|
||||
--> http://blah.com:123456 : bool(false)
|
||||
--> http://blah.com:abcdef : bool(false)
|
||||
Done
|
||||
Done
|
||||
Loaded 100 of 119 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user