aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc G. Fournier <scrappy@hub.org>1998-04-21 04:00:06 +0000
committerMarc G. Fournier <scrappy@hub.org>1998-04-21 04:00:06 +0000
commit5bdda53f129789850218937dc1af48d3015139a9 (patch)
treeeea2c7b8c7580008c37e4d9abdd49a8f7864a880
parent72098f38031a0bdfae39ad9f39da1861b5b3f034 (diff)
downloadpostgresql-5bdda53f129789850218937dc1af48d3015139a9.tar.gz
postgresql-5bdda53f129789850218937dc1af48d3015139a9.zip
From: Bryan Henderson <bryanh@giraffe-data.com>
Here's a fix for a tiny memory leak in PQsetdb/PQfinish. (Analysis of a running program indicates there are several others, but this is the only obvious one I saw in the code).
-rw-r--r--src/interfaces/libpq/fe-connect.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c
index 8042a043986..136a5fb602b 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.64 1998/03/26 23:46:14 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.65 1998/04/21 04:00:06 scrappy Exp $
*
*-------------------------------------------------------------------------
*/
@@ -726,6 +726,8 @@ freePGconn(PGconn *conn)
free(conn->dbName);
if (conn->pguser)
free(conn->pguser);
+ if (conn->pgpass)
+ free(conn->pgpass);
if (conn->notifyList)
DLFreeList(conn->notifyList);
free(conn);