summaryrefslogtreecommitdiff
path: root/ext/pgsql
Commit message (Collapse)AuthorAgeFilesLines
...
* | Use RETURN_THROWS() after zend_throw_exception() in most of the extensionsMáté Kocsis2020-01-021-1/+1
| |
* | Use RETURN_THROWS() during ZPP in most of the extensionsMáté Kocsis2019-12-311-67/+67
| | | | | | | | Except for some bigger ones: reflection, sodium, spl
* | Fix #78880: Spelling error reportChristoph M. Becker2019-12-211-2/+2
| | | | | | | | | | | | | | 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>.
* | Clean DONE tags from testsFabien Villepinte2019-11-0710-20/+0
| | | | | | | | | | | | | | Remove most of the `===DONE===` tags and its variations. Keep `===DONE===` if the test output otherwise becomes empty. Closes GH-4872.
* | Cleanup return values when parameter parsing is unsuccessfulMáté Kocsis2019-10-301-1/+1
| |
* | Remove mention of PHP major version in Copyright headersGabriel Caruso2019-09-252-4/+0
| | | | | | | | Closes GH-4732.
* | Merge branch 'PHP-7.4'Nikita Popov2019-07-222-6/+6
|\ \ | |/
| * Report errors from stream read and write operationsNikita Popov2019-07-222-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The php_stream_read() and php_stream_write() functions now return an ssize_t value, with negative results indicating failure. Functions like fread() and fwrite() will return false in that case. As a special case, EWOULDBLOCK and EAGAIN on non-blocking streams should not be regarded as error conditions, and be reported as successful zero-length reads/writes instead. The handling of EINTR remains unclear and is internally inconsistent (e.g. some code-paths will automatically retry on EINTR, while some won't). I'm landing this now to make sure the stream wrapper ops API changes make it into 7.4 -- however, if the user-facing changes turn out to be problematic we have the option of clamping negative returns to zero in php_stream_read() and php_stream_write() to restore the old behavior in a relatively non-intrusive manner.
* | Merge branch 'PHP-7.4'Peter Kokot2019-07-222-2/+1
|\ \ | |/ | | | | | | * PHP-7.4: Remove HAVE_PQPUTCOPYEND
| * Remove HAVE_PQPUTCOPYENDPeter Kokot2019-07-222-2/+1
| | | | | | | | | | | | | | Symbol is not used anywhere in the code and also Postgresql 7.x is EOL anyway. Closes GH-4453
* | Merge branch 'PHP-7.4'Remi Collet2019-06-121-0/+3
|\ \ | |/ | | | | | | * PHP-7.4: add comment about pg_config/pkgconfig
| * add comment about pg_config/pkgconfigRemi Collet2019-06-121-0/+3
| |
* | Merge branch 'PHP-7.4'Joe Watkins2019-06-121-9/+62
|\ \ | |/ | | | | | | * PHP-7.4: Revert "ext/pgsql: Use PKG_CHECK_MODULES to detect the pq library"
| * Revert "ext/pgsql: Use PKG_CHECK_MODULES to detect the pq library"Joe Watkins2019-06-121-9/+62
| | | | | | | | This reverts commit 1e265174ed8b361c2d8b9c050f9e3b1f7034acc9.
* | Merge branch 'PHP-7.4'Joe Watkins2019-06-111-62/+9
|\ \ | |/ | | | | | | * PHP-7.4: ext/pgsql: Use PKG_CHECK_MODULES to detect the pq library
| * ext/pgsql: Use PKG_CHECK_MODULES to detect the pq libraryHugh McMaster2019-06-111-62/+9
| |
* | Merge branch 'PHP-7.4'Dmitry Stogov2019-06-061-6/+6
|\ \ | |/ | | | | | | * PHP-7.4: Cheaper checks for exceptions thrown from __toString()
| * Cheaper checks for exceptions thrown from __toString()Dmitry Stogov2019-06-061-6/+6
| |
* | Merge branch 'PHP-7.4'Nikita Popov2019-06-051-32/+32
|\ \ | |/
| * Allow exceptions in __toString()Nikita Popov2019-06-051-32/+32
| | | | | | | | | | | | | | | | | | | | RFC: https://wiki.php.net/rfc/tostring_exceptions And convert some object to string conversion related recoverable fatal errors into Error exceptions. Improve exception safety of internal code performing string conversions.
* | Merge branch 'PHP-7.4'Nikita Popov2019-06-042-4/+4
|\ \ | |/
| * Try to make 17result.php more robustNikita Popov2019-06-042-4/+4
| | | | | | | | | | | | 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...
* | Convert fetch_resource warnings into TypeErrorsNikita Popov2019-06-031-2/+6
| | | | | | | | | | More type checks that are not part of zpp and should generate a TypeError in PHP 8.
* | Merge branch 'PHP-7.4'Peter Kokot2019-05-131-82/+0
|\ \ | |/ | | | | | | * PHP-7.4: Remove example file for pgsql extension
| * Remove example file for pgsql extensionPeter Kokot2019-05-131-82/+0
| | | | | | | | | | | | | | | | This removes the example script in favour of the manual: https://www.php.net/manual/en/book.pgsql.php Patch for integrating these functions as an example has been submitted also to PHP manual via edit.php.net.
* | Merge branch 'PHP-7.4'Peter Kokot2019-05-122-16/+18
|\ \ | |/ | | | | | | * PHP-7.4: [ci skip] Migrate tests READMEs to Markdown
| * [ci skip] Migrate tests READMEs to MarkdownPeter Kokot2019-05-122-16/+18
| |
* | Merge branch 'PHP-7.4'Peter Kokot2019-05-121-2/+0
|\ \ | |/ | | | | | | * PHP-7.4: Normalize comments in *nix build system m4 files
| * Normalize comments in *nix build system m4 filesPeter Kokot2019-05-121-2/+0
| | | | | | | | | | | | | | | | | | Normalization include: - Use dnl for everything that can be ommitted when configure is built in favor of the shell comment character # which is visible in the output. - Line length normalized to 80 columns - Dots for most of the one line sentences - Macro definitions include similar pattern header comments now
* | Merge branch 'PHP-7.4'Peter Kokot2019-04-131-6/+0
|\ \ | |/ | | | | | | * PHP-7.4: Disable PACKAGE_* preprocessor symbols
| * Disable PACKAGE_* preprocessor symbolsPeter Kokot2019-04-131-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Autoconf defines PACKAGE_* symbols: - PACKAGE_NAME - PACKAGE_VERSION - PACKAGE_TARNAME - PACKAGE_STRING - PACKAGE_BUGREPORT - PACKAGE_URL and appends them to the generated config.h.in files. With AC_INIT change via afd52f9d9986d92dd0c63832a07ab1a16bf11d53 where package version, URL, bug report location and similar meta data are defined, these preprocessor macros are then non empty strings in the generated configuration header file. When using phpize, PHP shares the config files in extensions, warnings of redefined macros appear, such as: - `warning: 'PACKAGE_NAME' macro redefined` This patch now disables these non utilized symbols in the generated config header files. Better practice would be to include only API specific headers where needed but this would require even more refactorings. Some extensions such as pcre, pgsql, and pdo_pgsql solve this issue by undefining some of these symbols before including the library configuration headers in the code also. Because these symbols can be defined by any library which uses Autotools. Additionally, the unused PACKAGE_* symbols were cleaned for the bundled libmbfl library and with this patch not needed undef code removed.
* | Merge branch 'PHP-7.4'Nikita Popov2019-04-121-19/+13
|\ \ | |/
| * Don't use php_strtok_r in build_tablenameNikita Popov2019-04-121-19/+13
| | | | | | | | | | | | | | This is unnecessary convoluted... we just want to find the position of the dot. Using php_strtok_r requires a copy of the string, and the implementation also relied on the specific semantics of the scratch space that strtok_r uses.
* | Merge branch 'PHP-7.4'Christoph M. Becker2019-04-121-3/+1
|\ \ | |/ | | | | | | * PHP-7.4: Include libpq-fs.h on Windows, too
| * Include libpq-fs.h on Windows, tooChristoph M. Becker2019-04-121-3/+1
| | | | | | | | That's more future proof than defining hard-coded macros.
* | Merge branch 'PHP-7.4'Nikita Popov2019-04-101-3/+5
|\ \ | |/
| * Merge branch 'PHP-7.3' into PHP-7.4Nikita Popov2019-04-101-3/+5
| |\
| | * Merge branch 'PHP-7.2' into PHP-7.3Nikita Popov2019-04-101-3/+5
| | |\
| | | * Fix 29nb_async_connect.phptNikita Popov2019-04-101-3/+5
| | | | | | | | | | | | | | | | | | | | Intermediate states are unreliable across versions (I think), make sure we go through the whole connect procedure.
* | | | Merge branch 'PHP-7.4'Nikita Popov2019-04-103-8/+46
|\ \ \ \ | |/ / /
| * | | Merge branch 'PHP-7.3' into PHP-7.4Nikita Popov2019-04-103-8/+46
| |\ \ \ | | |/ /
| | * | Merge branch 'PHP-7.2' into PHP-7.3Nikita Popov2019-04-103-8/+46
| | |\ \ | | | |/
| | | * Fix pgsql use after free trying to reuse closed connectionNikita Popov2019-04-103-8/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a connection is closed, we also need to remove the hash entry from the regular_list, as it now points to freed memory. To do this store a reverse mapping from the connection to the hash string. It would be nicer to introduce a wrapping structure for the pgsql link resource that could store the hash (and notices), but that would require large changes to the extension, so I'm going for a more minimal fix here.
* | | | Merge branch 'PHP-7.4'Nikita Popov2019-04-102-5/+22
|\ \ \ \ | |/ / /
| * | | Merge branch 'PHP-7.3' into PHP-7.4Nikita Popov2019-04-102-5/+22
| |\ \ \ | | |/ /
| | * | Merge branch 'PHP-7.2' into PHP-7.3Nikita Popov2019-04-102-5/+22
| | |\ \ | | | |/
| | | * Fix use after free on pg_close() of default connectionNikita Popov2019-04-102-5/+22
| | | |
| | | * Merge branch 'PHP-7.1' into PHP-7.2Anatol Belski2018-11-182-1/+41
| | | |\ | | | | | | | | | | | | | | | | | | | | * PHP-7.1: Fixed bug #77047 pg_convert has a broken regex for the 'TIME WITHOUT TIMEZONE' data type
| | | | * Fixed bug #77047 pg_convert has a broken regex for the 'TIME WITHOUT ↵Anatol Belski2018-11-182-1/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TIMEZONE' data type Backport 369c991d and 282a63da to 7.1, closes #3634
| | | | * Sync leading and final newlines in *.phpt sectionsPeter Kokot2018-10-1513-14/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds missing newlines, trims multiple redundant final newlines into a single one, and trims redundant leading newlines in all *.phpt sections. According to POSIX, a line is a sequence of zero or more non-' <newline>' characters plus a terminating '<newline>' character. [1] Files should normally have at least one final newline character. C89 [2] and later standards [3] mention a final newline: "A source file that is not empty shall end in a new-line character, which shall not be immediately preceded by a backslash character." Although it is not mandatory for all files to have a final newline fixed, a more consistent and homogeneous approach brings less of commit differences issues and a better development experience in certain text editors and IDEs. [1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206 [2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2 [3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2