mirror of
https://github.com/postgres/postgres.git
synced 2025-05-18 17:41:14 +03:00
Fix use of free in walsender error handling after a sysid mismatch.
Found via valgrind. The bug exists since the introduction of the walsender, so backpatch to 9.0. Andres Freund
This commit is contained in:
parent
b4eeb9d58e
commit
a7a3e71c85
@ -151,6 +151,7 @@ libpqrcv_identify_system(TimeLineID *primary_tli)
|
||||
GetSystemIdentifier());
|
||||
if (strcmp(primary_sysid, standby_sysid) != 0)
|
||||
{
|
||||
primary_sysid = pstrdup(primary_sysid);
|
||||
PQclear(res);
|
||||
ereport(ERROR,
|
||||
(errmsg("database system identifier differs between the primary and standby"),
|
||||
|
Loading…
x
Reference in New Issue
Block a user