On Mon, Dec 9, 2013 at 2:25 AM, MauMau <maumau...@gmail.com> wrote: > From: "Magnus Hagander" <mag...@hagander.net> > >> Not having looked at it in detail yet, but this seems to completely remove >> the default value. What happens if the error that needs to be logged is >> the >> one saying that it couldn't exec postgres to find out the value in the >> config file? AFAICT it's going to try to register an eventsource with >> whatever random garbage happens to be in the variable. > > > Thank you for commenting, Magnus san. > The variable is global and contains an empty string, so even in the unlikely > situation where postgres -C fails, the event source simply becomes blank.
1. isn't it better to handle as it is done in write_eventlog() which means if string is empty then use PostgreSQL. "evtHandle = RegisterEventSource(NULL, event_source ? event_source : "PostgreSQL");" 2. What will happen if user doesn't change the name in "event_source" or kept the same name, won't it hit the same problem again? So shouldn't it try to generate different name by appending version string to it? With Regards, Amit Kapila. EnterpriseDB: http://www.enterprisedb.com -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers