summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Henstridge <james@jamesh.id.au>2008-05-05 14:16:57 +0800
committerJames Henstridge <james@jamesh.id.au>2008-05-05 14:16:57 +0800
commit5beef38bfc6b53eca3675c31fc635e589d99132b (patch)
treef51021a4940d49e9284213180f2c50977091aaa4
parentec20fa8912c2819b8acc7ea6e961ca4d84d7aa61 (diff)
downloadpsycopg2-5beef38bfc6b53eca3675c31fc635e589d99132b.tar.gz
Fix double free in case where PGresult is NULL.
-rw-r--r--psycopg/pqpath.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/psycopg/pqpath.c b/psycopg/pqpath.c
index afab3b1..5c8d3c7 100644
--- a/psycopg/pqpath.c
+++ b/psycopg/pqpath.c
@@ -348,7 +348,6 @@ pq_complete_error(connectionObject *conn, PGresult **pgres, char **error)
pq_raise(conn, NULL, *pgres);
else if (*error != NULL) {
PyErr_SetString(OperationalError, *error);
- free(*error);
} else {
PyErr_SetString(OperationalError, "unknown error");
}