mirror of
https://github.com/postgres/postgres.git
synced 2026-04-22 22:59:54 -04:00
Back out python change, needs delay.
This commit is contained in:
parent
3cd9399d86
commit
a770da9d8d
1 changed files with 3 additions and 3 deletions
|
|
@ -337,7 +337,7 @@ class pgdbCnx:
|
|||
### module interface
|
||||
|
||||
# connects to a database
|
||||
def connect(dsn = None, user = None, password = None, xhost = None, database = None):
|
||||
def connect(dsn = None, user = None, password = None, host = None, database = None):
|
||||
# first get params from DSN
|
||||
dbport = -1
|
||||
dbhost = ""
|
||||
|
|
@ -364,9 +364,9 @@ def connect(dsn = None, user = None, password = None, xhost = None, database = N
|
|||
dbpasswd = password
|
||||
if database != None:
|
||||
dbbase = database
|
||||
if xhost != None:
|
||||
if host != None:
|
||||
try:
|
||||
params = string.split(xhost, ":")
|
||||
params = string.split(host, ":")
|
||||
dbhost = params[0]
|
||||
dbport = int(params[1])
|
||||
except:
|
||||
|
|
|
|||
Loading…
Reference in a new issue