Fix misuse of PqMsg_Close.

EndCommand() and EndReplicationCommand() should use
PqMsg_CommandComplete instead.  Oversight in commit f4b54e1ed9.

Reported-by: Pavel Stehule, Tatsuo Ishii
Author: Pavel Stehule
Reviewed-by: Aleksander Alekseev, Michael Paquier
Discussion: https://postgr.es/m/CAFj8pRAMDCJXjnwiCkCB1yO1f7NPggFY8PwwAJDnugu-Z2G-Cg%40mail.gmail.com
This commit is contained in:
Nathan Bossart 2023-08-29 18:32:38 -07:00
parent 3c662643c4
commit 6475e663b3
1 changed files with 2 additions and 2 deletions

View File

@ -176,7 +176,7 @@ EndCommand(const QueryCompletion *qc, CommandDest dest, bool force_undecorated_o
len = BuildQueryCompletionString(completionTag, qc,
force_undecorated_output);
pq_putmessage(PqMsg_Close, completionTag, len + 1);
pq_putmessage(PqMsg_CommandComplete, completionTag, len + 1);
case DestNone:
case DestDebug:
@ -200,7 +200,7 @@ EndCommand(const QueryCompletion *qc, CommandDest dest, bool force_undecorated_o
void
EndReplicationCommand(const char *commandTag)
{
pq_putmessage(PqMsg_Close, commandTag, strlen(commandTag) + 1);
pq_putmessage(PqMsg_CommandComplete, commandTag, strlen(commandTag) + 1);
}
/* ----------------