diff options
author | Oleksandr Shulgin <oleksandr.shulgin@zalando.de> | 2016-01-05 12:31:57 +0100 |
---|---|---|
committer | Oleksandr Shulgin <oleksandr.shulgin@zalando.de> | 2016-01-05 12:31:57 +0100 |
commit | 09a4bb70a168799a91f63f1c2039f456c485960f (patch) | |
tree | a6c08b7e079fe652dce69267928f030cb6c985c7 /psycopg/pqpath.c | |
parent | 4b9a6f48f33f9f80a1a12850f5029bf7ab97145b (diff) | |
download | psycopg2-09a4bb70a168799a91f63f1c2039f456c485960f.tar.gz |
Allow retrying start_replication after syntax or data error.
Diffstat (limited to 'psycopg/pqpath.c')
-rw-r--r-- | psycopg/pqpath.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/psycopg/pqpath.c b/psycopg/pqpath.c index 760fc97..6d6728c 100644 --- a/psycopg/pqpath.c +++ b/psycopg/pqpath.c @@ -1870,8 +1870,11 @@ pq_fetch(cursorObject *curs, int no_result) Dprintf("pq_fetch: data from a streaming replication slot (no tuples)"); curs->rowcount = -1; ex = 0; - /* nothing to do here: pq_copy_both will be called separately */ - CLEARPGRES(curs->pgres); + /* Nothing to do here: pq_copy_both will be called separately. + + Also don't clear the result status: it's checked in + consume_stream. */ + /*CLEARPGRES(curs->pgres);*/ break; case PGRES_TUPLES_OK: |