aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/ecpg/lib/connect.c
diff options
context:
space:
mode:
authorMichael Meskes <meskes@postgresql.org>2001-12-05 15:32:07 +0000
committerMichael Meskes <meskes@postgresql.org>2001-12-05 15:32:07 +0000
commitee14711ce889698dfc2b3357b1eb8aab04c53a6c (patch)
tree8515d1318835c50ac7887cda5a54388c004ae9b2 /src/interfaces/ecpg/lib/connect.c
parent15790465c2e05173e015e5cd37150aee97476c29 (diff)
downloadpostgresql-ee14711ce889698dfc2b3357b1eb8aab04c53a6c.tar.gz
postgresql-ee14711ce889698dfc2b3357b1eb8aab04c53a6c.zip
- Fixed variable handling in AT statement.
- Fixed bug that caused segfault when given incorrect DB name. - Fixed bug in ecpglib causing indicator to list the size of the variable instead of the size of the data.
Diffstat (limited to 'src/interfaces/ecpg/lib/connect.c')
-rw-r--r--src/interfaces/ecpg/lib/connect.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/interfaces/ecpg/lib/connect.c b/src/interfaces/ecpg/lib/connect.c
index 2f02e92da37..4520e1bf609 100644
--- a/src/interfaces/ecpg/lib/connect.c
+++ b/src/interfaces/ecpg/lib/connect.c
@@ -1,4 +1,4 @@
-/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/lib/Attic/connect.c,v 1.15 2001/11/14 11:11:49 meskes Exp $ */
+/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/lib/Attic/connect.c,v 1.16 2001/12/05 15:32:06 meskes Exp $ */
#include "postgres_fe.h"
@@ -387,6 +387,10 @@ ECPGconnect(int lineno, const char *name, const char *user, const char *passwd,
host = strdup(dbname + offset);
}
+ else
+ {
+ realname = strdup(dbname);
+ }
}
else
realname = strdup(dbname);