mirror of
https://github.com/postgres/postgres.git
synced 2025-04-22 23:02:54 +03:00
Fix incorrect assertion in libpqwalreceiver
Was supposed to check the length of the array, but was checking its size in bytes. Author: Jacob Brazeal <jacob.brazeal@gmail.com> Discussion: https://www.postgresql.org/message-id/CA%2BCOZaA_9afJxj9ZuO73U5P7WXP%2BZM9NGnZvTDCmBFz0FGP%2BwA@mail.gmail.com
This commit is contained in:
parent
2a943afcff
commit
03f8e9a7fe
@ -208,7 +208,7 @@ libpqrcv_connect(const char *conninfo, bool replication, bool logical,
|
||||
keys[++i] = NULL;
|
||||
vals[i] = NULL;
|
||||
|
||||
Assert(i < sizeof(keys));
|
||||
Assert(i < lengthof(keys));
|
||||
|
||||
conn = palloc0(sizeof(WalReceiverConn));
|
||||
conn->streamConn = PQconnectStartParams(keys, vals,
|
||||
|
Loading…
x
Reference in New Issue
Block a user