mirror of
https://github.com/timescale/timescaledb.git
synced 2025-05-19 04:03:06 +08:00
Fix libpq disconnect for PG15
Make sure the FATAL error message before the data node disconnects is not lost when using PG15. https://github.com/postgres/postgres/commit/618c1670
This commit is contained in:
parent
2defb2b0b3
commit
7600896a66
@ -917,8 +917,11 @@ remote_connection_exec(TSConnection *conn, const char *cmd)
|
|||||||
ResultEntry *entry = PQresultInstanceData(res, eventproc);
|
ResultEntry *entry = PQresultInstanceData(res, eventproc);
|
||||||
|
|
||||||
if (status == PGRES_FATAL_ERROR && entry == NULL)
|
if (status == PGRES_FATAL_ERROR && entry == NULL)
|
||||||
|
{
|
||||||
|
res = PQmakeEmptyPGresult(conn->pg_conn, PGRES_FATAL_ERROR);
|
||||||
PQfireResultCreateEvents(conn->pg_conn, res);
|
PQfireResultCreateEvents(conn->pg_conn, res);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user