Commit 31d250e0 authored by Noah Misch's avatar Noah Misch

Update stale comments, and fix comment typos.

parent 92c4abc7
...@@ -432,7 +432,7 @@ brin_inclusion_consistent(PG_FUNCTION_ARGS) ...@@ -432,7 +432,7 @@ brin_inclusion_consistent(PG_FUNCTION_ARGS)
* It is straightforward to support the equality strategies with * It is straightforward to support the equality strategies with
* the contains operator. Generally, inequality strategies do not * the contains operator. Generally, inequality strategies do not
* make much sense for the types which will be used with the * make much sense for the types which will be used with the
* inclusion BRIN family of opclasses, but is possible to * inclusion BRIN family of opclasses, but it is possible to
* implement them with logical negation of the left-of and * implement them with logical negation of the left-of and
* right-of operators. * right-of operators.
* *
......
...@@ -2208,7 +2208,7 @@ SetMultiXactIdLimit(MultiXactId oldest_datminmxid, Oid oldest_datoid, ...@@ -2208,7 +2208,7 @@ SetMultiXactIdLimit(MultiXactId oldest_datminmxid, Oid oldest_datoid,
* space, but that's not really true, because multixacts wrap differently * space, but that's not really true, because multixacts wrap differently
* from transaction IDs. Note that, separately from any concern about * from transaction IDs. Note that, separately from any concern about
* multixact IDs wrapping, we must ensure that multixact members do not * multixact IDs wrapping, we must ensure that multixact members do not
* wrap. Limits for that are set in DetermineSafeOldestOffset, not here. * wrap. Limits for that are set in SetOffsetVacuumLimit, not here.
*/ */
multiWrapLimit = oldest_datminmxid + (MaxMultiXactId >> 1); multiWrapLimit = oldest_datminmxid + (MaxMultiXactId >> 1);
if (multiWrapLimit < FirstMultiXactId) if (multiWrapLimit < FirstMultiXactId)
......
...@@ -390,9 +390,9 @@ PGSharedMemoryAttach(IpcMemoryId shmId, ...@@ -390,9 +390,9 @@ PGSharedMemoryAttach(IpcMemoryId shmId,
/* /*
* Try to attach to the segment and see if it matches our data directory. * Try to attach to the segment and see if it matches our data directory.
* This avoids shmid-conflict problems on machines that are running * This avoids key-conflict problems on machines that are running several
* several postmasters under the same userid and port number. (That would * postmasters under the same userid and port number. (That would not
* not ordinarily happen in production, but it can happen during parallel * ordinarily happen in production, but it can happen during parallel
* testing. Since our test setups don't open any TCP ports on Unix, such * testing. Since our test setups don't open any TCP ports on Unix, such
* cases don't conflict otherwise.) * cases don't conflict otherwise.)
*/ */
......
...@@ -4743,8 +4743,8 @@ retry: ...@@ -4743,8 +4743,8 @@ retry:
} }
/* /*
* Queue a waiter for to signal when this child dies. The wait will be * Queue a waiter to signal when this child dies. The wait will be handled
* handled automatically by an operating system thread pool. * automatically by an operating system thread pool.
* *
* Note: use malloc instead of palloc, since it needs to be thread-safe. * Note: use malloc instead of palloc, since it needs to be thread-safe.
* Struct will be free():d from the callback function that runs on a * Struct will be free():d from the callback function that runs on a
......
...@@ -211,7 +211,6 @@ Generic_Text_IC_like(text *str, text *pat, Oid collation) ...@@ -211,7 +211,6 @@ Generic_Text_IC_like(text *str, text *pat, Oid collation)
if (pg_database_encoding_max_length() > 1 || (locale && locale->provider == COLLPROVIDER_ICU)) if (pg_database_encoding_max_length() > 1 || (locale && locale->provider == COLLPROVIDER_ICU))
{ {
/* lower's result is never packed, so OK to use old macros here */
pat = DatumGetTextPP(DirectFunctionCall1Coll(lower, collation, pat = DatumGetTextPP(DirectFunctionCall1Coll(lower, collation,
PointerGetDatum(pat))); PointerGetDatum(pat)));
p = VARDATA_ANY(pat); p = VARDATA_ANY(pat);
......
...@@ -1681,12 +1681,7 @@ GenerateRecoveryConf(PGconn *conn) ...@@ -1681,12 +1681,7 @@ GenerateRecoveryConf(PGconn *conn)
initPQExpBuffer(&conninfo_buf); initPQExpBuffer(&conninfo_buf);
for (option = connOptions; option && option->keyword; option++) for (option = connOptions; option && option->keyword; option++)
{ {
/* /* Omit empty settings and those libpqwalreceiver overrides. */
* Do not emit this setting if: - the setting is "replication",
* "dbname" or "fallback_application_name", since these would be
* overridden by the libpqwalreceiver module anyway. - not set or
* empty.
*/
if (strcmp(option->keyword, "replication") == 0 || if (strcmp(option->keyword, "replication") == 0 ||
strcmp(option->keyword, "dbname") == 0 || strcmp(option->keyword, "dbname") == 0 ||
strcmp(option->keyword, "fallback_application_name") == 0 || strcmp(option->keyword, "fallback_application_name") == 0 ||
......
...@@ -26,11 +26,7 @@ package RewindTest; ...@@ -26,11 +26,7 @@ package RewindTest;
# still running. # still running.
# #
# The test script can use the helper functions master_psql and standby_psql # The test script can use the helper functions master_psql and standby_psql
# to run psql against the master and standby servers, respectively. The # to run psql against the master and standby servers, respectively.
# test script can also use the $connstr_master and $connstr_standby global
# variables, which contain libpq connection strings for connecting to the
# master and standby servers. The data directories are also available
# in paths $test_master_datadir and $test_standby_datadir
use strict; use strict;
use warnings; use warnings;
......
...@@ -36,7 +36,7 @@ Here are the steps needed to create a regression database dump file: ...@@ -36,7 +36,7 @@ Here are the steps needed to create a regression database dump file:
1) Create and populate the regression database in the old cluster. 1) Create and populate the regression database in the old cluster.
This database can be created by running 'make installcheck' from This database can be created by running 'make installcheck' from
src/test/regression. src/test/regress.
2) Use pg_dump to dump out the regression database. Use the new 2) Use pg_dump to dump out the regression database. Use the new
cluster's pg_dump on the old database to minimize whitespace cluster's pg_dump on the old database to minimize whitespace
......
...@@ -105,7 +105,7 @@ get_control_data(ClusterInfo *cluster, bool live_check) ...@@ -105,7 +105,7 @@ get_control_data(ClusterInfo *cluster, bool live_check)
#ifndef WIN32 #ifndef WIN32
pg_putenv("LANG", NULL); pg_putenv("LANG", NULL);
#else #else
/* On Windows the default locale cannot be English, so force it */ /* On Windows the default locale may not be English, so force it */
pg_putenv("LANG", "en"); pg_putenv("LANG", "en");
#endif #endif
pg_putenv("LANGUAGE", NULL); pg_putenv("LANGUAGE", NULL);
......
...@@ -541,8 +541,7 @@ appendShellStringNoError(PQExpBuffer buf, const char *str) ...@@ -541,8 +541,7 @@ appendShellStringNoError(PQExpBuffer buf, const char *str)
/* /*
* Append the given string to the buffer, with suitable quoting for passing * Append the given string to the buffer, with suitable quoting for passing
* the string as a value, in a keyword/pair value in a libpq connection * the string as a value in a keyword/value pair in a libpq connection string.
* string
*/ */
void void
appendConnStrVal(PQExpBuffer buf, const char *str) appendConnStrVal(PQExpBuffer buf, const char *str)
......
...@@ -383,7 +383,7 @@ tas(volatile slock_t *lock) ...@@ -383,7 +383,7 @@ tas(volatile slock_t *lock)
register slock_t _res; register slock_t _res;
/* /*
* See comment in /pg/backend/port/tas/solaris_sparc.s for why this * See comment in src/backend/port/tas/sunstudio_sparc.s for why this
* uses "ldstub", and that file uses "cas". gcc currently generates * uses "ldstub", and that file uses "cas". gcc currently generates
* sparcv7-targeted binaries, so "cas" use isn't possible. * sparcv7-targeted binaries, so "cas" use isn't possible.
*/ */
...@@ -598,7 +598,6 @@ tas(volatile slock_t *lock) ...@@ -598,7 +598,6 @@ tas(volatile slock_t *lock)
#if defined(__mips__) && !defined(__sgi) /* non-SGI MIPS */ #if defined(__mips__) && !defined(__sgi) /* non-SGI MIPS */
/* Note: on SGI we use the OS' mutex ABI, see below */
/* Note: R10000 processors require a separate SYNC */ /* Note: R10000 processors require a separate SYNC */
#define HAS_TEST_AND_SET #define HAS_TEST_AND_SET
......
...@@ -736,7 +736,7 @@ static void ...@@ -736,7 +736,7 @@ static void
destroy_ssl_system(void) destroy_ssl_system(void)
{ {
#if defined(ENABLE_THREAD_SAFETY) && defined(HAVE_CRYPTO_LOCK) #if defined(ENABLE_THREAD_SAFETY) && defined(HAVE_CRYPTO_LOCK)
/* Mutex is created in initialize_ssl_system() */ /* Mutex is created in pgtls_init() */
if (pthread_mutex_lock(&ssl_config_mutex)) if (pthread_mutex_lock(&ssl_config_mutex))
return; return;
......
...@@ -90,9 +90,9 @@ $killme_stdout = ''; ...@@ -90,9 +90,9 @@ $killme_stdout = '';
$killme_stderr = ''; $killme_stderr = '';
# Start longrunning query in second session, it's failure will signal # Start longrunning query in second session; its failure will signal that
# that crash-restart has occurred. The initial wait for the trivial # crash-restart has occurred. The initial wait for the trivial select is to
# select is to be sure that psql successfully connected to backend. # be sure that psql successfully connected to backend.
$monitor_stdin .= q[ $monitor_stdin .= q[
SELECT $$psql-connected$$; SELECT $$psql-connected$$;
SELECT pg_sleep(3600); SELECT pg_sleep(3600);
...@@ -171,10 +171,9 @@ ok(pump_until($killme, \$killme_stdout, qr/in-progress-before-sigkill/m), ...@@ -171,10 +171,9 @@ ok(pump_until($killme, \$killme_stdout, qr/in-progress-before-sigkill/m),
$killme_stdout = ''; $killme_stdout = '';
$killme_stderr = ''; $killme_stderr = '';
# Re-start longrunning query in second session, it's failure will # Re-start longrunning query in second session; its failure will signal that
# signal that crash-restart has occurred. The initial wait for the # crash-restart has occurred. The initial wait for the trivial select is to
# trivial select is to be sure that psql successfully connected to # be sure that psql successfully connected to backend.
# backend.
$monitor_stdin .= q[ $monitor_stdin .= q[
SELECT $$psql-connected$$; SELECT $$psql-connected$$;
SELECT pg_sleep(3600); SELECT pg_sleep(3600);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment