[rpostgresql] r271 committed - A memory leak is removed

4 views
Skip to first unread message

rpost...@googlecode.com

unread,
Feb 9, 2014, 9:57:04 AM2/9/14
to rpostgr...@googlegroups.com
Revision: 271
Author: tomo...@kenroku.kanazawa-u.ac.jp
Date: Sun Feb 9 14:56:54 2014 UTC
Log: A memory leak is removed
http://code.google.com/p/rpostgresql/source/detail?r=271

Modified:
/trunk/RPostgreSQL/src/RS-PostgreSQL.c

=======================================
--- /trunk/RPostgreSQL/src/RS-PostgreSQL.c Sat Feb 8 09:29:04 2014 UTC
+++ /trunk/RPostgreSQL/src/RS-PostgreSQL.c Sun Feb 9 14:56:54 2014 UTC
@@ -244,7 +244,9 @@
sprintf(buf, "could not connect %s@%s on dbname \"%s\"\n",
PQuser(my_connection), host?host:"local", PQdb(my_connection));
PQfinish(my_connection);
my_connection = NULL;
+ RS_PostgreSQL_freeConParams(conParams); /*free BEFORE emitting err
message that do not come back */
RS_DBI_errorMessage(buf, RS_DBI_ERROR);
+ return R_NilValue; /* don't reach here as it goes back to R proc */
}

PROTECT(conHandle = RS_DBI_allocConnection(mgrHandle, (Sint) 1)); /*
The second argument (1) specifies the number of result sets allocated */
Reply all
Reply to author
Forward
0 new messages