mirror of
https://github.com/php/php-src.git
synced 2026-03-24 08:12:21 +01:00
Clean up code.
Removed PHP_PGSQL_API macro. Define pgsql_globals_id # Need a little more clean up
This commit is contained in:
@@ -139,7 +139,7 @@ function_entry pgsql_functions[] = {
|
||||
PHP_FALIAS(pg_locreate, pg_lo_create, NULL)
|
||||
PHP_FALIAS(pg_lounlink, pg_lo_unlink, NULL)
|
||||
PHP_FALIAS(pg_loopen, pg_lo_open, NULL)
|
||||
PHP_FALIAS(pg_loclose, pg_lo_close, NULL)
|
||||
PHP_FALIAS(pg_loclose, pg_lo_close, NULL)
|
||||
PHP_FALIAS(pg_loread, pg_lo_read, NULL)
|
||||
PHP_FALIAS(pg_lowrite, pg_lo_write, NULL)
|
||||
PHP_FALIAS(pg_loimport, pg_lo_import, NULL)
|
||||
@@ -148,7 +148,7 @@ function_entry pgsql_functions[] = {
|
||||
PHP_FALIAS(pg_clientencoding, pg_client_encoding, NULL)
|
||||
PHP_FALIAS(pg_setclientencoding, pg_set_client_encoding, NULL)
|
||||
#endif
|
||||
{NULL, NULL, NULL}
|
||||
{NULL, NULL, NULL}
|
||||
};
|
||||
/* }}} */
|
||||
|
||||
@@ -177,7 +177,7 @@ static int le_link, le_plink, le_result, le_lofp, le_string;
|
||||
#ifdef ZTS
|
||||
int pgsql_globals_id;
|
||||
#else
|
||||
PHP_PGSQL_API php_pgsql_globals pgsql_globals;
|
||||
php_pgsql_globals pgsql_globals;
|
||||
#endif
|
||||
|
||||
/* {{{ php_pgsql_set_default_link
|
||||
|
||||
@@ -38,12 +38,6 @@ extern zend_module_entry pgsql_module_entry;
|
||||
#include <libpq/libpq-fs.h>
|
||||
#endif
|
||||
|
||||
#ifdef PHP_WIN32
|
||||
#define PHP_PGSQL_API __declspec(dllexport)
|
||||
#else
|
||||
#define PHP_PGSQL_API
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_PGSQL_WITH_MULTIBYTE_SUPPORT
|
||||
const char * pg_encoding_to_char(int encoding);
|
||||
#endif
|
||||
@@ -158,9 +152,10 @@ typedef struct {
|
||||
|
||||
#ifdef ZTS
|
||||
# define PGG(v) TSRMG(pgsql_globals_id, php_pgsql_globals *, v)
|
||||
extern int pgsql_globals_id;
|
||||
#else
|
||||
# define PGG(v) (pgsql_globals.v)
|
||||
extern PHP_PGSQL_API php_pgsql_globals pgsql_globals;
|
||||
extern php_pgsql_globals pgsql_globals;
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user