Fix bug with pcp_proc_info.
authorTatsuo Ishii <ishii@postgresql.org>
Tue, 15 Jul 2025 02:01:11 +0000 (11:01 +0900)
committerTatsuo Ishii <ishii@postgresql.org>
Tue, 15 Jul 2025 02:10:00 +0000 (11:10 +0900)
When pcp_proc_info was invoked without "-v" option, pcp_proc_info did
not print the "statement" field.  This was due to oversight in the
frontend side of the command: forgot to add one more format siring
"%s".

This bug was in only master branch: when some new fields were added to
pcp_proc_info.

Reported-by: Bo Peng <pengbo@sraoss.co.jp>
Author: Tatsuo Ishii <ishii@postgresql.org>

src/tools/pcp/pcp_frontend_client.c

index be192dd27e8d81acb8ef8ed862c28cf1e8eccca5..ecc922b930640b7668e711c749ea1e8817da06d4 100644 (file)
@@ -751,7 +751,7 @@ output_procinfo_result(PCPResultInfo * pcpResInfo, bool all, bool verbose)
                format = format_titles(titles, types, sizeof(titles)/sizeof(char *));
        else
        {
-               format = "%s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s\n";
+               format = "%s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s\n";
        }
 
        for (i = 0; i < array_size; i++)