summaryrefslogtreecommitdiff
path: root/src/interfaces/libpq/fe-connect.c
diff options
context:
space:
mode:
authorMarc G. Fournier <scrappy@hub.org>1996-08-06 16:16:50 +0000
committerMarc G. Fournier <scrappy@hub.org>1996-08-06 16:16:50 +0000
commitc4e53a14110816d0d495bb7f00cb4e3bdee3f123 (patch)
treef814bdef83ef6a13b8c4bf62eab7a16e83dd2098 /src/interfaces/libpq/fe-connect.c
parentfd3b829959e1e2288e6fb58063aab498439fcd74 (diff)
Fixes for:
Here are a few minor fixes to Postgres95. Mostly I have added const to some of the char pointers. There was also a missing header file and a place where it looks like "==" was used when "=" was meant. I also changed some variables from Pfin and Pfout tp pfin and pfout because the latter shadow global variables and that just seems like an unsafe practice which I like to avoid. Submitted by: "D'Arcy J.M. Cain" <darcy@druid.druid.com>
Diffstat (limited to 'src/interfaces/libpq/fe-connect.c')
-rw-r--r--src/interfaces/libpq/fe-connect.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c
index 59856a6f93a..4b8fbecb48d 100644
--- a/src/interfaces/libpq/fe-connect.c
+++ b/src/interfaces/libpq/fe-connect.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.4 1996/07/23 03:35:12 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.5 1996/08/06 16:16:45 scrappy Exp $
*
*-------------------------------------------------------------------------
*/
@@ -31,7 +31,7 @@
standard function? (My, my. Touchy today, are we?) */
static
char *
-strdup(char *string)
+strdup(const char *string)
{
char *nstr;
@@ -64,10 +64,10 @@ static void closePGconn(PGconn *conn);
* ----------------
*/
PGconn*
-PQsetdb(char *pghost, char* pgport, char* pgoptions, char* pgtty, char* dbName)
+PQsetdb(const char *pghost, const char* pgport, const char* pgoptions, const char* pgtty, const char* dbName)
{
PGconn *conn;
- char *tmp;
+ const char *tmp;
conn = (PGconn*)malloc(sizeof(PGconn));