slavapestov/factor — pull request #1137 by bjourne (2014-09-22 18:36:47+00:00)
Title: db.postgresql.lib: if PQsetdbLogin fails, PQfinish must be called

See http://www.postgresql.org/docs/8.1/static/libpq.html#LIBPQ-CONNECT you just need to call PQfinish if the connect attempt fails, or else the connection lingers