diff options
Diffstat (limited to 'libpqpp/pq-selectcommand.cpp')
-rw-r--r-- | libpqpp/pq-selectcommand.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libpqpp/pq-selectcommand.cpp b/libpqpp/pq-selectcommand.cpp index f8f44fd..b049eea 100644 --- a/libpqpp/pq-selectcommand.cpp +++ b/libpqpp/pq-selectcommand.cpp @@ -24,7 +24,7 @@ PQ::SelectCommand::~SelectCommand() if (execRes) { PQclear(execRes); } - if (executed) { + if (executed && PQtransactionStatus(c->conn) != PQTRANS_INERROR) { c->checkResultFree((PQexec(c->conn, s_close.c_str())), PGRES_COMMAND_OK); } if (txOpened) { |