summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/bin/psql/startup.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/bin/psql/startup.c b/src/bin/psql/startup.c
index ce180e1cd7b..392b96eb862 100644
--- a/src/bin/psql/startup.c
+++ b/src/bin/psql/startup.c
@@ -412,9 +412,7 @@ main(int argc, char *argv[])
if (options.single_txn)
{
- res = PSQLexec((successResult == EXIT_SUCCESS) ?
- "COMMIT" : "ROLLBACK");
- if (res == NULL)
+ if ((res = PSQLexec("COMMIT")) == NULL)
{
if (pset.on_error_stop)
{