summaryrefslogtreecommitdiff
path: root/ext/pgsql/pgsql.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/pgsql/pgsql.c')
-rw-r--r--ext/pgsql/pgsql.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/ext/pgsql/pgsql.c b/ext/pgsql/pgsql.c
index 4f119ab8de..4738a21a93 100644
--- a/ext/pgsql/pgsql.c
+++ b/ext/pgsql/pgsql.c
@@ -351,15 +351,13 @@ void php3_pgsql_do_connect(INTERNAL_FUNCTION_PARAMETERS,int persistent)
int php3_pgsql_get_default_link(INTERNAL_FUNCTION_PARAMETERS)
{
if (php3_pgsql_module.default_link==-1) { /* no link opened yet, implicitly open one */
- HashTable tmp;
-
- _php3_hash_init(&tmp,0,NULL,NULL,0);
+ ht = 0;
php3_pgsql_do_connect(INTERNAL_FUNCTION_PARAM_PASSTHRU,0);
- _php3_hash_destroy(&tmp);
}
return php3_pgsql_module.default_link;
}
+
/* {{{ proto int pg_connect([string connection_string] | [string host, string port, [string options, [string tty,]] string database)
Open a PostgreSQL connection */
PHP_FUNCTION(pgsql_connect)