On Fri, Dec 20, 2013 at 2:35 AM, Fujii Masao <masao.fu...@gmail.com> wrote: > On Thu, Dec 19, 2013 at 2:21 PM, Tatsuo Ishii <is...@postgresql.org> wrote: >>> I found that the psql tab-completion for ALTER SYSTEM SET has not been >>> implemented yet. >>> Attached patch does that. Barring any objections, I will commit this patch. >> >> Good catch! > > Committed.
I found the bug of ALTER SYSTEM SET patch. The procedure to reproduce it is here. $ psql =# ALTER SYSTEM SET shared_buffers = '512MB'; ALTER SYSTEM =# \q $ pg_ctl -D data reload server signaled 2013-12-22 18:24:13 JST LOG: received SIGHUP, reloading configuration files 2013-12-22 18:24:13 JST LOG: parameter "shared_buffers" cannot be changed without restarting the server 2013-12-22 18:24:13 JST LOG: configuration file "X??" contains errors; unaffected changes were applied The configuration file name in the last log message is broken. This problem was introduced by the ALTER SYSTEM SET patch. > FreeConfigVariables(head); > <snip> > else if (apply) > ereport(elevel, > (errcode(ERRCODE_CONFIG_FILE_ERROR), > errmsg("configuration file \"%s\" contains errors; > unaffected changes were applied", > ErrorConfFile))); The cause of the problem is that, in ProcessConfigFile(), the log message including the 'ErrorConfFile' is emitted after 'head' is free'd even though 'ErrorConfFile' points to one of entry of the 'head'. Regards, -- Fujii Masao -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers