pgsql: Fix another oversight in logging of changes in postgresql.conf s

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix another oversight in logging of changes in postgresql.conf s
Date: 2011-07-08 21:03:32
Message-ID: E1QfICy-0005zU-0k@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Fix another oversight in logging of changes in postgresql.conf settings.

We were using GetConfigOption to collect the old value of each setting,
overlooking the possibility that it didn't exist yet. This does happen
in the case of adding a new entry within a custom variable class, as
exhibited in bug #6097 from Maxim Boguk.

To fix, add a missing_ok parameter to GetConfigOption, but only in 9.1
and HEAD --- it seems possible that some third-party code is using that
function, so changing its API in a minor release would cause problems.
In 9.0, create a near-duplicate function instead.

Branch
------
REL9_1_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/7c884433992cce9f53d87ca3a5d0d629e21af300

Modified Files
--------------
src/backend/commands/extension.c | 6 +++---
src/backend/utils/misc/guc-file.l | 6 +++---
src/backend/utils/misc/guc.c | 16 ++++++++++++----
src/include/utils/guc.h | 3 ++-
4 files changed, 20 insertions(+), 11 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Robert Haas 2011-07-09 02:19:48 pgsql: Try to acquire relation locks in RangeVarGetRelid.
Previous Message Tom Lane 2011-07-08 21:03:31 pgsql: Fix another oversight in logging of changes in postgresql.conf s