Matteo Beccati
d411ea26f1
Fixed test for MySQL < 5.6
...
Refs GH-6172.
2020-09-28 08:52:21 +02:00
Nikita Popov
8138ed73d7
Make mysqli_warning constructor private
...
The constructor was already effectively inaccessible (protected
on a final class). This just makes it more obvious and removes
the implementation in favor of directly throwing.
Per the removed test, this was an unfinished feature, and I don't
think it makes a lot of sense to finish it -- the
mysqli_stmt::get_warnings() interface makes more sense than
direct construction.
Closes GH-6208.
2020-09-27 22:08:24 +02:00
Larry Garfield
02dc9ce6e5
Rename mysqli parameters to be more logical
...
Closes GH-6172.
2020-09-27 21:28:29 +02:00
Máté Kocsis
41b096b392
Promote a few forgotten warnings to exceptions
...
Closes GH-6211
2020-09-25 12:08:15 +02:00
Nikita Popov
be4553b61a
More precise type in mysqli_result constructor
...
This ctor requires a mysqli object. Possibly there was some
confusion with the mysqli_warning constructor here.
2020-09-24 09:56:48 +02:00
Máté Kocsis
e950ca13ea
Consolidate the usage of "either" and "one of" in error messages
...
Closes GH-6173
2020-09-20 19:41:47 +02:00
Nikita Popov
9d1c7f8b13
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Fix mysqli build with mysqlnd and without PDO
2020-09-20 10:02:32 +02:00
Bob Weinand
a7544411df
Fix mysqli build with mysqlnd and without PDO
2020-09-20 10:02:09 +02:00
Bob Weinand
0741858ca7
Fix mysqli build with mysqlnd and without PDO
2020-09-20 02:57:39 +02:00
Nikita Popov
19314ff887
Fix some tests for libmysql
2020-09-18 18:01:04 +02:00
Nikita Popov
2d002258b8
Drop skipifemb.inc
...
And drop the last remaining uses of it.
2020-09-18 15:49:35 +02:00
Nikita Popov
b40ffa9bfd
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Fix #78179 : mysqli/mysqlnd transaction extensions
2020-09-18 15:30:13 +02:00
Nikita Popov
f23164584e
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Fix #78179 : mysqli/mysqlnd transaction extensions
2020-09-18 15:30:06 +02:00
Daniel Black
740f0f6165
Fix #78179 : mysqli/mysqlnd transaction extensions
...
MariaDB versioning created a mess with regarding testing
features based on version. We sidestep the problem here
by assuming the extensions are present, and if a syntax
error occurs with a SQL mode TRANS_START_READ_WRITE |
TRANS_START_READ_ONLY enabled, then output the same
warning as before.
2020-09-18 15:29:44 +02:00
Nikita Popov
9962ad6444
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Support NO_BACKSLASH_ESCAPES with newer libmysqlclient
2020-09-18 15:26:04 +02:00
Nikita Popov
e6dc9abdb7
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Support NO_BACKSLASH_ESCAPES with newer libmysqlclient
2020-09-18 15:25:35 +02:00
Nikita Popov
70cba36fc9
Support NO_BACKSLASH_ESCAPES with newer libmysqlclient
...
Requires the use of mysql_real_escape_string_quote().
2020-09-18 15:24:57 +02:00
Dharman
74d16999fc
mysqli_set_charset now throws an mysqli_sql_exception when incorrect charset is provided
...
Closes GH-6142.
2020-09-18 14:57:59 +02:00
Nikita Popov
64547664cb
Assert that all switch cases are covered
2020-09-18 14:53:02 +02:00
Nikita Popov
2abea9c3bb
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Use MyISAM engine for new test
2020-09-18 14:50:11 +02:00
Nikita Popov
d87c393a18
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Use MyISAM engine for new test
2020-09-18 14:50:02 +02:00
Nikita Popov
77f43e48ff
Use MyISAM engine for new test
...
Travis on 7.3 is showing this error:
> The size of BLOB/TEXT data inserted in one transaction is greater
> than 10% of redo log size. Increase the redo log size using
> innodb_log_file_size.
Force MyISAM engine to avoid this.
2020-09-18 14:49:43 +02:00
Nikita Popov
c5401854fc
Run tidy
...
This should fix most of the remaining issues with tabs and spaces
being mixed in tests.
2020-09-18 14:28:32 +02:00
Nikita Popov
0582c40907
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Fix bug #80107 : Handling of large compressed packets
Bug #80107 Add test for mysqli_query() fails for ~16 MB long query when compression is enabled
2020-09-18 12:59:10 +02:00
Nikita Popov
5e7c5a82a5
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Fix bug #80107 : Handling of large compressed packets
Bug #80107 Add test for mysqli_query() fails for ~16 MB long query when compression is enabled
2020-09-18 12:57:50 +02:00
Nikita Popov
ecd9c42f9e
Fix bug #80107 : Handling of large compressed packets
...
There's two layers of packet splitting going on. First, packets
need to be split into having a payload of exactly 2^24-1 bytes or
being the last packet. If the split packet has size between 2^24-5
and 2^24-1 bytes, the compressed packets also needs to be split,
though the choice of split doesn't matter here. I'm splitting off
the first 8192 bytes, as that's what I observe libmysqlclient to be
doing.
2020-09-18 12:55:44 +02:00
Máté Kocsis
c7ceebc42c
Bug #80107 Add test for mysqli_query() fails for ~16 MB long query when compression is enabled
2020-09-18 12:42:08 +02:00
Nikita Popov
a03c1ed7aa
Remove vestiges of embedded mysql from tests
2020-09-17 19:02:20 +02:00
Nikita Popov
e9ac7d27ba
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Fix mysqli_release_savepoint() on mysqlnd
2020-09-17 16:09:41 +02:00
Nikita Popov
33069575d5
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Fix mysqli_release_savepoint() on mysqlnd
2020-09-17 16:03:26 +02:00
Nikita Popov
c3944c4c4f
Fix mysqli_release_savepoint() on mysqlnd
...
mysqli_release_savepoint() was not actually releasing a savepoint...
2020-09-17 15:59:09 +02:00
Nikita Popov
86e002729f
Fix some tests for libmysql
2020-09-17 15:27:02 +02:00
Nikita Popov
e2b3c0e291
Remove checks for old libmysqlclient versions in tests
2020-09-17 15:02:35 +02:00
Nikita Popov
b0661a9667
Fix warnings when building against libmysqlclient
...
At least for version 8.0 this is warning free now.
2020-09-17 15:02:35 +02:00
Nikita Popov
5cb8b04646
Drop support for libmysqlclient < 5.5
...
Given how little maintenance the libmysqlclient driver sees, be
more aggressive in dropping old version support here.
2020-09-17 12:05:30 +02:00
Nikita Popov
e7f98f82ac
Add missing mysqlnd checks to stubs
2020-09-17 11:40:14 +02:00
Nikita Popov
3ad57f9f31
Merge branch 'PHP-7.4'
...
* PHP-7.4:
pdo_mysql/mysqli (native) libmysqlclient_r no-longer used
mysql: native mysql-8.0 uses _Bool
mysqli: use native api
2020-09-17 11:35:03 +02:00
Nikita Popov
d591e1c4f5
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
pdo_mysql/mysqli (native) libmysqlclient_r no-longer used
mysql: native mysql-8.0 uses _Bool
mysqli: use native api
2020-09-17 11:32:01 +02:00
Daniel Black
1aab7db6c8
pdo_mysql/mysqli (native) libmysqlclient_r no-longer used
...
The mysqlclient_r library exists in mysql-5.6 for compatibility only.
Later versions have it removed.
2020-09-17 11:27:31 +02:00
Daniel Black
c9abb0c0ac
mysql: native mysql-8.0 uses _Bool
...
MySQL-8.0 removes option MYSQLI_OPT_SSL_VERIFY_SERVER_CERT
2020-09-17 11:27:31 +02:00
Daniel Black
202a0697f3
mysqli: use native api
...
Tested with:
* mysql-5.6.49-linux-glibc2.12-x86_64
* mysql-5.7.31-linux-glibc2.12-x86_64
* mysql-8.0.21-linux-glibc2.17-x86_64
* mariadb-10.5.6
configure --with-mysqli=/usr/local/$version/bin/mysql_config --with-pdo-mysql=/usr/local/$version
MySQL-8.0 removed my_bool
Some options where deprecated in mysql-8.0
MY_CHARSET_INFO used with exposed api mysql_get_character_set_info
rather than internal structures.
2020-09-17 11:27:31 +02:00
Dharman
8f56b7a755
mysqli: Promote warning in field_seek
...
Aligning the behaviour of fetch_field and field_seek.
2020-09-17 09:42:42 +02:00
Dharman
0d99a5618f
Changed the wording of the error message
...
"cannot be used in MYSQLI_USE_RESULT mode" sounds more correct than "cannot be used with MYSQLI_USE_RESULT"
Closes GH-6137.
2020-09-16 11:10:11 +02:00
Matteo Beccati
3b2410ebf6
Fix test
...
follow-up to 7a95e94
for MySQL < 5.6
2020-09-16 10:06:19 +02:00
George Peter Banyard
7a95e943d6
Promote warnings to Error in MySQLi extension
...
Closes GH-5803
2020-09-15 19:12:02 +02:00
Máté Kocsis
2408991fc5
Remove unintendedly committed test
2020-09-15 14:49:30 +02:00
Máté Kocsis
c37a1cd650
Promote a few remaining errors in ext/standard
...
Closes GH-6110
2020-09-15 14:26:16 +02:00
Nikita Popov
950ea89fb0
Convert E_ERROR to Error exception in mysqli_result iterator
...
The same condition uses Error exceptions in lots of other classes.
2020-09-14 12:15:24 +02:00
Máté Kocsis
9975986b7e
Improve error messages mentioning parameters instead of arguments
...
Closes GH-5999
2020-09-09 10:47:43 +02:00
Nikita Popov
4a98b64413
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Remove bogus REGISTER_LONG_CONSTANT
2020-08-25 12:36:06 +02:00