"will do what you want." Not exactly - I want it to appear according
to my log_line_prefix - 4 ex. ='%t|%p|%a|%d|%u|%h| '
I've used that patch on 9.5.19
In elog.c there's : const char *appname = application_name; // line 2357
other cases have : const char *username = MyProcPort->user_name;
After adding 'MyProcPort->' to %a case '|psql|' shows up like I
wanted .. but connection process Segfaults :/
I've tracked it to postinit.c - process_startup_options() - this loop
: while (gucopts) {...}
gucopts = list_head(port->guc_options);
ereport(LOG, (errmsg(" +++ process_startup_options : [%s] ",
gucopts))); // adding this line returns :
2019-10-15 14:28:03 CEST|9760|psql|postgres|postgres|[local]|
LOCATION: PerformAuthentication, postinit.c:257
2019-10-15 14:28:03 CEST|9760|psql|postgres|postgres|[local]| LOG:
00000: +++ process_startup_options : [local all
all trust]
2019-10-15 14:28:03 CEST|9760|psql|postgres|postgres|[local]|
LOCATION: process_startup_options, postinit.c:1066
Sorry 4 nagging , any pointers much appreciated
On 10/11/19, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>
> This was changed about a year ago, see
>
> https://www.postgresql.org/message-id/flat/CAHJZqBB_Pxv8HRfoh%2BAB4KxSQQuPVvtYCzMg7woNR3r7dfmopw%40mail.gmail.com
>
> so v12 will do what you want.
>
> regards, tom lane