1
0
mirror of https://github.com/php/php-src.git synced 2026-04-21 15:08:16 +02:00
Commit Graph

255 Commits

Author SHA1 Message Date
Máté Kocsis 7c2d1fda4a Add missing SKIPIF section to new test 2022-06-06 12:05:49 +02:00
Stanislav Malyshev 70d03423c7 Merge branch 'PHP-8.1' 2022-06-06 01:11:49 -06:00
Stanislav Malyshev 98e1291b7e Merge branch 'PHP-8.0' into PHP-8.1 2022-06-06 01:11:44 -06:00
Stanislav Malyshev e864cb61a7 Merge branch 'PHP-7.4' into PHP-8.0 2022-06-06 01:11:13 -06:00
Christoph M. Becker 55f6895f4b Fix #81720: Uninitialized array in pg_query_params() leading to RCE
We must not free parameters which we haven't initialized yet.

We also fix the not directly related issue, that we checked for the
wrong value being `NULL`, potentially causing a segfault.
2022-06-06 00:34:23 -06:00
Christoph M. Becker 81d1a1b47b Update bug tracker links
The new php-src bugtracker is on Github.

Closes GH-8277.
2022-05-12 14:55:11 +02:00
Ilija Tovilo 9a90bd7054 Deprecate ${} string interpolation
https://wiki.php.net/rfc/deprecate_dollar_brace_string_interpolation
2022-05-05 10:14:56 +02:00
Ilija Tovilo 4dec645029 Merge branch 'PHP-8.1'
* PHP-8.1:
  Verify generated files are up to date in CI
2022-04-21 23:27:46 +02:00
Ilija Tovilo cf70047351 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Verify generated files are up to date in CI
2022-04-21 23:27:29 +02:00
Michael Voříšek 36de002cc6 Verify generated files are up to date in CI
Closes GH-8295
2022-04-21 23:25:47 +02:00
Christoph M. Becker c9c5ee3f48 Merge branch 'PHP-8.1'
* PHP-8.1:
  Fix GH-8253: pg_insert() fails for references
2022-03-29 10:54:32 +02:00
Christoph M. Becker 7e8dcda42c Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix GH-8253: pg_insert() fails for references
2022-03-29 10:53:56 +02:00
Christoph M. Becker 0e6d6f83cc Fix GH-8253: pg_insert() fails for references
We need to deref the values.

Closes GH-8262.
2022-03-29 10:51:19 +02:00
Matteo Beccati a476cc109d Merge branch 'PHP-8.1'
* PHP-8.1:
  Fix #81509 pg_end_copy still expects a resource
  Add test for pg_put_line() and pg_end_copy()
2021-10-05 18:14:06 +02:00
Matteo Beccati 202a099aee Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Add test for pg_put_line() and pg_end_copy()
2021-10-05 18:13:20 +02:00
Matteo Beccati 9af6882d28 Merge branch 'PHP-7.4' into PHP-8.0
* PHP-7.4:
  Add test for pg_put_line() and pg_end_copy()
2021-10-05 17:44:19 +02:00
Matteo Beccati be36bf5aca Add test for pg_put_line() and pg_end_copy() 2021-10-05 17:43:48 +02:00
Nikita Popov 7a411564f0 Fix some more CLEAN sections 2021-09-03 11:18:19 +02:00
George Peter Banyard 1f42777927 Deprecate using the implicit default PgSQL connection
The DB connection should be provided in all cases as the first argument.
The overloaded function signatures will be removed in the future.
Warn about this change.

Part of https://wiki.php.net/rfc/deprecations_php_8_1.
2021-07-09 23:12:37 +02:00
Nikita Popov a148ea2c50 Add missing dba extension requirement in pgsql test 2021-06-14 14:55:03 +02:00
Nikita Popov 6600ad6067 Add some missing EXTENSIONS sections to misc tests 2021-06-14 14:52:44 +02:00
Nikita Popov e378968c4f Fix EXTENSIONS section for pgsql
This should have been pgsql, not psql...
2021-06-14 14:40:38 +02:00
Nikita Popov b5a14e6c04 Port skipif.inc files to EXTENSIONS 2021-06-11 16:27:50 +02:00
Máté Kocsis 32aff25ceb Convert resources to objects in ext/pgsql
Closes GH-6791

Co-authored-by: Nikita Popov <nikita.ppv@gmail.com>
2021-05-11 00:09:30 +02:00
George Peter Banyard 6eb23e2b83 ValueError if lengths is less than 0 2021-04-19 20:27:34 +01:00
George Peter Banyard 7a1af523fa Fix test output due to float to string locale independent change
Also use de_DE locale instead
2021-04-19 20:27:33 +01:00
Nikita Popov 1b3b430f47 Add --repeat testing mode
This testing mode executes the test multiple times in the same
process (but in different requests). It is primarily intended to
catch tracing JIT bugs, but also catches state leaks across
requests.

Closes GH-6365.
2020-10-30 17:29:33 +01:00
Nikita Popov 3171fec6da Update ext/pgsql parameter names
Closes GH-6294.
2020-10-13 12:30:44 +02:00
George Peter Banyard 053a5fc141 Promote E_NOTICE to Value/TypeError in PostgreSQL extension
Add some tests to cover related codepaths.
With the small caveat that the ones in build_assignment_string()
still don't seem to be tested as it looks the condtions are checked
beforehand, might need some more investigation.

Closes GH-6226
2020-09-29 15:13:01 +01:00
Nikita Popov 8ff2f2f84b Return empty array for no rows in pg_fetch_all()
This makes it line up with pg_fetch_all_columns(), as well as
similar functions in other exts, such as mysqli_fetch_all().
2020-09-21 17:22:02 +02:00
Nikita Popov 54f03d31e0 Promote invalid field to ValueError in pgsql
The same error condition is a ValueError in mysqli, be consistent.

Additionally, do not display the argument name for these errors.
As the signatures are overloaded, the argument name may not match
the meaning at all.
2020-09-21 17:00:23 +02:00
Nikita Popov 7300f6fc17 Deprecate pgsql function aliases
These have been documentation-deprecated for a very long time,
make it official.
2020-09-21 11:33:05 +02:00
George Peter Banyard d0111d785d Promote warnings to Errors in PostgreSQL extension
Do some drive by indentation fixes
Also fix pg_select() in regards to the $result_type arg which was missing from ZPP

Closes GH-6129
2020-09-14 17:01:35 +02:00
Nikita Popov 9a6c22da70 Remove deprecated pgsql signatures
As the comment indicates, these are deprecated in PHP 4.2...
2020-09-09 15:50:30 +02:00
Nikita Popov 8f415d4413 Promote pgsql no link to Error exception 2020-09-09 12:45:07 +02:00
Nikita Popov 3ab88831ae Remove deprecated multi-parameter form of pg_connect() 2020-09-09 12:31:00 +02:00
Nikita Popov 396b47061f Use zpp C in pg_fetch_object 2020-08-13 16:24:08 +02:00
Máté Kocsis 7aacc705d0 Add many missing closing PHP tags to tests
Closes GH-5958
2020-08-09 22:03:36 +02:00
Nikita Popov f8d795820e Reindent phpt files 2020-02-03 22:52:20 +01:00
Christoph M. Becker dabc28d182 Fix #78880: Spelling error report
We fix the most often occuring typos according to a recent codespell
report[1] in tests, code comments and documentation.

[1] <https://fossies.org/linux/test/php-src-master-f8f48ce.191129.tar.gz/codespell.html>.
2019-12-21 11:58:00 +01:00
Fabien Villepinte a555cc0b3d Clean DONE tags from tests
Remove most of the `===DONE===` tags and its variations.
Keep `===DONE===` if the test output otherwise becomes empty.

Closes GH-4872.
2019-11-07 21:31:47 +01:00
Nikita Popov b1bdae7621 Merge branch 'PHP-7.4' 2019-06-04 12:25:16 +02:00
Nikita Popov 3f7210efa8 Try to make 17result.php more robust
This is our most common intermittent failure. I don't understand
why it happens and can't reproduce it, but defining an explicit
sort order seems worth a shot...
2019-06-04 12:18:21 +02:00
Nikita Popov 1df8175b61 Convert fetch_resource warnings into TypeErrors
More type checks that are not part of zpp and should generate a
TypeError in PHP 8.
2019-06-03 09:17:12 +02:00
Peter Kokot 87cfcb0b7c Merge branch 'PHP-7.4'
* PHP-7.4:
  [ci skip] Migrate tests READMEs to Markdown
2019-05-12 22:03:35 +02:00
Peter Kokot 83e565e244 [ci skip] Migrate tests READMEs to Markdown 2019-05-12 22:03:10 +02:00
Nikita Popov 2e982e975c Merge branch 'PHP-7.4' 2019-04-10 13:07:06 +02:00
Nikita Popov c02a5931f4 Merge branch 'PHP-7.3' into PHP-7.4 2019-04-10 13:07:01 +02:00
Nikita Popov b67ca4f07c Merge branch 'PHP-7.2' into PHP-7.3 2019-04-10 13:06:55 +02:00
Nikita Popov 8f13599a64 Fix 29nb_async_connect.phpt
Intermediate states are unreliable across versions (I think), make
sure we go through the whole connect procedure.
2019-04-10 13:06:02 +02:00