]> granicus.if.org Git - postgresql/commitdiff
libpq: Change "options" dispchar to normal
authorPeter Eisentraut <peter_e@gmx.net>
Fri, 7 Sep 2018 13:01:25 +0000 (15:01 +0200)
committerPeter Eisentraut <peter_e@gmx.net>
Fri, 7 Sep 2018 13:01:25 +0000 (15:01 +0200)
libpq connection options as returned by PQconndefaults() have a
"dispchar" field that determines (among other things) whether an option
is a "debug" option, which shouldn't be shown by default to clients.
postgres_fdw makes use of that to control which connection options to
accept from a foreign server configuration.

Curiously, the "options" option, which allows passing configuration
settings to the backend server, was listed as a debug option, which
prevented it from being used by postgres_fdw.  Maybe it was once meant
for debugging, but it's clearly in general use nowadays.

So change the dispchar for it to be the normal non-debug case.  Also
remove the "debug" reference from its label field.

Reported-by: Shinoda, Noriyoshi <noriyoshi.shinoda@hpe.com>
src/interfaces/libpq/fe-connect.c

index a8048ffad209dd810a19003fdf66749b120afec6..db5aacd0e9ef0e90e34fc789d88ceba2f0c57540 100644 (file)
@@ -236,7 +236,7 @@ static const internalPQconninfoOption PQconninfoOptions[] = {
        offsetof(struct pg_conn, pgtty)},
 
        {"options", "PGOPTIONS", DefaultOption, NULL,
-               "Backend-Debug-Options", "D", 40,
+               "Backend-Options", "", 40,
        offsetof(struct pg_conn, pgoptions)},
 
        {"application_name", "PGAPPNAME", NULL, NULL,