Remove conditional usage of PQfreemem (#14559)

PQfreemem is available since PostgreSQL 7.4.
This commit is contained in:
Peter Kokot 2024-06-13 13:34:08 +02:00 committed by GitHub
parent dcd20da8a5
commit 5baef94d00
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 1 additions and 5 deletions

View file

@ -7,7 +7,7 @@ if (PHP_PGSQL != "no") {
CHECK_HEADER_ADD_INCLUDE("libpq-fe.h", "CFLAGS_PGSQL", PHP_PGSQL + "\\include;" + PHP_PHP_BUILD + "\\include\\pgsql;" + PHP_PHP_BUILD + "\\include\\libpq;" + PHP_PGSQL)) {
EXTENSION("pgsql", "pgsql.c", PHP_PGSQL_SHARED, "/DZEND_ENABLE_STATIC_TSRMLS_CACHE=1");
AC_DEFINE('HAVE_PGSQL', 1, 'Have PostgreSQL library');
ADD_FLAG("CFLAGS_PGSQL", "/D PGSQL_EXPORTS /D HAVE_PQFREEMEM /D HAVE_PGSQL_WITH_MULTIBYTE_SUPPORT" + (X64 ? " /D HAVE_PG_LO64" : "") + " ");
ADD_FLAG("CFLAGS_PGSQL", "/D PGSQL_EXPORTS /D HAVE_PGSQL_WITH_MULTIBYTE_SUPPORT" + (X64 ? " /D HAVE_PG_LO64" : "") + " ");
ADD_EXTENSION_DEP('pgsql', 'pcre');
} else {
WARNING("pgsql not enabled; libraries and headers not found");

View file

@ -112,10 +112,6 @@ char pgsql_libpq_version[16];
RETURN_THROWS(); \
}
#ifndef HAVE_PQFREEMEM
#define PQfreemem free
#endif
#ifndef HAVE_PQERRORS_SQLSTATE
#define PQERRORS_SQLSTATE 0
#endif