From e76221bd95f0428cc9b5872a4bcbf0b7e40b77b0 Mon Sep 17 00:00:00 2001 From: =?utf8?q?=C3=81lvaro=20Herrera?= Date: Fri, 30 Jan 2026 14:26:02 +0100 Subject: [PATCH] Minor cosmetic tweaks MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit These changes should have been done by 2f9661311b83, but were overlooked. I noticed while reviewing the code for commit b8926a5b4bb8. Author: Álvaro Herrera Discussion: https://postgr.es/m/18984-0f4778a6599ac3ae@postgresql.org --- src/backend/tcop/postgres.c | 2 +- src/backend/utils/mmgr/portalmem.c | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c index e54bf1e760f..b4a8d2f3a1c 100644 --- a/src/backend/tcop/postgres.c +++ b/src/backend/tcop/postgres.c @@ -1117,7 +1117,7 @@ exec_simple_query(const char *query_string) /* * Get the command name for use in status display (it also becomes the - * default completion tag, down inside PortalRun). Set ps_status and + * default completion tag, in PortalDefineQuery). Set ps_status and * do any special start-of-SQL-command processing needed by the * destination. */ diff --git a/src/backend/utils/mmgr/portalmem.c b/src/backend/utils/mmgr/portalmem.c index 4fa4d432021..c1a53e658cb 100644 --- a/src/backend/utils/mmgr/portalmem.c +++ b/src/backend/utils/mmgr/portalmem.c @@ -294,9 +294,8 @@ PortalDefineQuery(Portal portal, portal->prepStmtName = prepStmtName; portal->sourceText = sourceText; - portal->qc.commandTag = commandTag; - portal->qc.nprocessed = 0; portal->commandTag = commandTag; + SetQueryCompletion(&portal->qc, commandTag, 0); portal->stmts = stmts; portal->cplan = cplan; portal->status = PORTAL_DEFINED; -- 2.39.5