From ba2327eec62cfc0245ffa6853e0fa21e22ebd318 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 29 Sep 2022 15:13:42 +0300 Subject: [PATCH] Fixed a hangup when processing the COPY command in asynchronous mode. Fix problem https://github.com/bucardo/dbdpg/issues/98 --- dbdimp.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dbdimp.c b/dbdimp.c index 58e23161..7e572382 100644 --- a/dbdimp.c +++ b/dbdimp.c @@ -5318,6 +5318,9 @@ long pg_db_result (SV *h, imp_dbh_t *imp_dbh) TRACE_PQCLEAR; PQclear(result); } + if ( rows == -1 ) { + break; + } } if (NULL != imp_dbh->async_sth) {