aboutsummaryrefslogtreecommitdiff
path: root/src/backend/tcop/dest.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/tcop/dest.c')
-rw-r--r--src/backend/tcop/dest.c22
1 files changed, 4 insertions, 18 deletions
diff --git a/src/backend/tcop/dest.c b/src/backend/tcop/dest.c
index 4316137a9d3..1dfadfa8e1d 100644
--- a/src/backend/tcop/dest.c
+++ b/src/backend/tcop/dest.c
@@ -226,13 +226,8 @@ EndReplicationCommand(const char *commandTag)
/* ----------------
* NullCommand - tell dest that an empty query string was recognized
*
- * In FE/BE protocol version 1.0, this hack is necessary to support
- * libpq's crufty way of determining whether a multiple-command
- * query string is done. In protocol 2.0 it's probably not really
- * necessary to distinguish empty queries anymore, but we still do it
- * for backwards compatibility with 1.0. In protocol 3.0 it has some
- * use again, since it ensures that there will be a recognizable end
- * to the response to an Execute message.
+ * This ensures that there will be a recognizable end to the response
+ * to an Execute message in the extended query protocol.
* ----------------
*/
void
@@ -244,14 +239,8 @@ NullCommand(CommandDest dest)
case DestRemoteExecute:
case DestRemoteSimple:
- /*
- * tell the fe that we saw an empty query string. In protocols
- * before 3.0 this has a useless empty-string message body.
- */
- if (PG_PROTOCOL_MAJOR(FrontendProtocol) >= 3)
- pq_putemptymessage('I');
- else
- pq_putmessage('I', "", 1);
+ /* Tell the FE that we saw an empty query string */
+ pq_putemptymessage('I');
break;
case DestNone:
@@ -286,7 +275,6 @@ ReadyForQuery(CommandDest dest)
case DestRemote:
case DestRemoteExecute:
case DestRemoteSimple:
- if (PG_PROTOCOL_MAJOR(FrontendProtocol) >= 3)
{
StringInfoData buf;
@@ -294,8 +282,6 @@ ReadyForQuery(CommandDest dest)
pq_sendbyte(&buf, TransactionBlockStatusCode());
pq_endmessage(&buf);
}
- else
- pq_putemptymessage('Z');
/* Flush output at end of cycle in any case. */
pq_flush();
break;