Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 7ab1bc2

Browse files
Fix outdated references to guc.c
Commit 0a20ff5 split out the GUC variables from guc.c into a new file guc_tables.c. This updates comments referencing guc.c regarding variables which are now in guc_tables.c. Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us> Discussion: https://postgr.es/m/6B50C70C-8C1F-4F9A-A7C0-EEAFCC032406@yesql.se
1 parent 4ac30ba commit 7ab1bc2

File tree

7 files changed

+13
-12
lines changed

7 files changed

+13
-12
lines changed

src/backend/commands/variable.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -877,7 +877,7 @@ assign_session_authorization(const char *newval, void *extra)
877877
* a translation of "none" to InvalidOid. Otherwise this is much like
878878
* SET SESSION AUTHORIZATION.
879879
*/
880-
extern char *role_string; /* in guc.c */
880+
extern char *role_string; /* in guc_tables.c */
881881

882882
bool
883883
check_role(char **newval, void **extra, GucSource source)

src/backend/libpq/be-secure-openssl.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1557,7 +1557,8 @@ X509_NAME_to_cstring(X509_NAME *name)
15571557
* Convert TLS protocol version GUC enum to OpenSSL values
15581558
*
15591559
* This is a straightforward one-to-one mapping, but doing it this way makes
1560-
* guc.c independent of OpenSSL availability and version.
1560+
* the definitions of ssl_min_protocol_version and ssl_max_protocol_version
1561+
* independent of OpenSSL availability and version.
15611562
*
15621563
* If a version is passed that is not supported by the current OpenSSL
15631564
* version, then we return -1. If a nonnegative value is returned,

src/backend/storage/lmgr/predicate.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -364,9 +364,9 @@ static SERIALIZABLEXACT *OldCommittedSxact;
364364
* attempt to degrade performance (mostly as false positive serialization
365365
* failure) gracefully in the face of memory pressure.
366366
*/
367-
int max_predicate_locks_per_xact; /* set by guc.c */
368-
int max_predicate_locks_per_relation; /* set by guc.c */
369-
int max_predicate_locks_per_page; /* set by guc.c */
367+
int max_predicate_locks_per_xact; /* in guc_tables.c */
368+
int max_predicate_locks_per_relation; /* in guc_tables.c */
369+
int max_predicate_locks_per_page; /* in guc_tables.c */
370370

371371
/*
372372
* This provides a list of objects in order to track transactions

src/bin/pg_dump/dumputils.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -683,7 +683,7 @@ emitShSecLabels(PGconn *conn, PGresult *res, PQExpBuffer buffer,
683683
* currently known to guc.c, so that it'd be unsafe for extensions to declare
684684
* GUC_LIST_QUOTE variables anyway. Lacking a solution for that, it doesn't
685685
* seem worth the work to do more than have this list, which must be kept in
686-
* sync with the variables actually marked GUC_LIST_QUOTE in guc.c.
686+
* sync with the variables actually marked GUC_LIST_QUOTE in guc_tables.c.
687687
*/
688688
bool
689689
variable_is_guc_list_quote(const char *name)

src/include/miscadmin.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,7 @@ extern void PreventCommandIfReadOnly(const char *cmdname);
291291
extern void PreventCommandIfParallelMode(const char *cmdname);
292292
extern void PreventCommandDuringRecovery(const char *cmdname);
293293

294-
/* in utils/misc/guc.c */
294+
/* in utils/misc/guc_tables.c */
295295
extern PGDLLIMPORT int trace_recovery_messages;
296296
extern int trace_recovery(int trace_level);
297297

src/test/modules/test_misc/t/003_check_guc.pl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
# Grab the names of all the parameters that can be listed in the
1515
# configuration sample file. config_file is an exception, it is not
16-
# in postgresql.conf.sample but is part of the lists from guc.c.
16+
# in postgresql.conf.sample but is part of the lists from guc_tables.c.
1717
my $all_params = $node->safe_psql(
1818
'postgres',
1919
"SELECT name
@@ -82,7 +82,7 @@
8282
0, "no parameters missing from postgresql.conf.sample");
8383

8484
my @missing_from_list = grep(!$all_params_hash{$_}, @gucs_in_file);
85-
is(scalar(@missing_from_list), 0, "no parameters missing from guc.c");
85+
is(scalar(@missing_from_list), 0, "no parameters missing from guc_tables.c");
8686

8787
my @sample_intersect = grep($not_in_sample_hash{$_}, @gucs_in_file);
8888
is(scalar(@sample_intersect),
@@ -91,12 +91,12 @@
9191
# These would log some information only on errors.
9292
foreach my $param (@missing_from_file)
9393
{
94-
print("found GUC $param in guc.c, missing from postgresql.conf.sample\n");
94+
print("found GUC $param in guc_tables.c, missing from postgresql.conf.sample\n");
9595
}
9696
foreach my $param (@missing_from_list)
9797
{
9898
print(
99-
"found GUC $param in postgresql.conf.sample, with incorrect info in guc.c\n"
99+
"found GUC $param in postgresql.conf.sample, with incorrect info in guc_tables.c\n"
100100
);
101101
}
102102
foreach my $param (@sample_intersect)

src/timezone/pgtz.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ pg_timezone_initialize(void)
364364
* We may not yet know where PGSHAREDIR is (in particular this is true in
365365
* an EXEC_BACKEND subprocess). So use "GMT", which pg_tzset forces to be
366366
* interpreted without reference to the filesystem. This corresponds to
367-
* the bootstrap default for these variables in guc.c, although in
367+
* the bootstrap default for these variables in guc_tables.c, although in
368368
* principle it could be different.
369369
*/
370370
session_timezone = pg_tzset("GMT");

0 commit comments

Comments
 (0)