1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-06 13:46:51 +03:00

Collection of typo fixes.

Use "a" and "an" correctly, mostly in comments. Two error messages were
also fixed (they were just elogs, so no translation work required). Two
function comments in pg_proc.h were also fixed. Etsuro Fujita reported one
of these, but I found a lot more with grep.

Also fix a few other typos spotted while grepping for the a/an typos.
For example, "consists out of ..." -> "consists of ...". Plus a "though"/
"through" mixup reported by Euler Taveira.

Many of these typos were in old code, which would be nice to backpatch to
make future backpatching easier. But much of the code was new, and I didn't
feel like crafting separate patches for each branch. So no backpatching.
This commit is contained in:
Heikki Linnakangas
2015-05-20 16:18:11 +03:00
parent f6a54fefc2
commit 4fc72cc7bb
62 changed files with 95 additions and 93 deletions

View File

@@ -50,7 +50,7 @@ char *BufferBlocks;
* refcount -- Counts the number of processes holding pins on a buffer.
* A buffer is pinned during IO and immediately after a BufferAlloc().
* Pins must be released before end of transaction. For efficiency the
* shared refcount isn't increased if a individual backend pins a buffer
* shared refcount isn't increased if an individual backend pins a buffer
* multiple times. Check the PrivateRefCount infrastructure in bufmgr.c.
*/

View File

@@ -101,13 +101,13 @@ static volatile BufferDesc *PinCountWaitBuf = NULL;
* Each buffer also has a private refcount that keeps track of the number of
* times the buffer is pinned in the current process. This is so that the
* shared refcount needs to be modified only once if a buffer is pinned more
* than once by a individual backend. It's also used to check that no buffers
* than once by an individual backend. It's also used to check that no buffers
* are still pinned at the end of transactions and when exiting.
*
*
* To avoid - as we used to - requiring an array with NBuffers entries to keep
* track of local buffers, we use a small sequentially searched array
* (PrivateRefCountArray) and a overflow hash table (PrivateRefCountHash) to
* (PrivateRefCountArray) and an overflow hash table (PrivateRefCountHash) to
* keep track of backend local pins.
*
* Until no more than REFCOUNT_ARRAY_ENTRIES buffers are pinned at once, all

View File

@@ -149,7 +149,7 @@ ClockSweepTick(void)
* allows other readers to read nextVictimBuffer and
* completePasses in a consistent manner which is required for
* StrategySyncStart(). In theory delaying the increment
* could lead to a overflow of nextVictimBuffers, but that's
* could lead to an overflow of nextVictimBuffers, but that's
* highly unlikely and wouldn't be particularly harmful.
*/
SpinLockAcquire(&StrategyControl->buffer_strategy_lock);

View File

@@ -287,7 +287,7 @@ ProcArrayAdd(PGPROC *proc)
/*
* Keep the procs array sorted by (PGPROC *) so that we can utilize
* locality of references much better. This is useful while traversing the
* ProcArray because there is a increased likelihood of finding the next
* ProcArray because there is an increased likelihood of finding the next
* PGPROC structure in the cache.
*
* Since the occurrence of adding/removing a proc is much lower than the
@@ -2061,7 +2061,7 @@ GetOldestSafeDecodingTransactionId(void)
* the result is somewhat indeterminate, but we don't really care. Even in
* a multiprocessor with delayed writes to shared memory, it should be certain
* that setting of delayChkpt will propagate to shared memory when the backend
* takes a lock, so we cannot fail to see an virtual xact as delayChkpt if
* takes a lock, so we cannot fail to see a virtual xact as delayChkpt if
* it's already inserted its commit record. Whether it takes a little while
* for clearing of delayChkpt to propagate is unimportant for correctness.
*/
@@ -3500,7 +3500,7 @@ KnownAssignedXidsRemovePreceding(TransactionId removeXid)
/*
* Mark entries invalid starting at the tail. Since array is sorted, we
* can stop as soon as we reach a entry >= removeXid.
* can stop as soon as we reach an entry >= removeXid.
*/
tail = pArray->tailKnownAssignedXids;
head = pArray->headKnownAssignedXids;

View File

@@ -33,7 +33,7 @@ uint64 SharedInvalidMessageCounter;
* through a cache reset exercise. This is done by sending
* PROCSIG_CATCHUP_INTERRUPT to any backend that gets too far behind.
*
* The signal handler will set a interrupt pending flag and will set the
* The signal handler will set an interrupt pending flag and will set the
* processes latch. Whenever starting to read from the client, or when
* interrupted while doing so, ProcessClientReadInterrupt() will call
* ProcessCatchupEvent().

View File

@@ -62,7 +62,7 @@
* an existing SIREAD lock for the same transaction, the SIREAD lock
* can be deleted.
*
* (7) A write from a serializable transaction must ensure that a xact
* (7) A write from a serializable transaction must ensure that an xact
* record exists for the transaction, with the same lifespan (until
* all concurrent transaction complete or the transaction is rolled
* back) so that rw-dependencies to that transaction can be
@@ -4745,7 +4745,7 @@ AtPrepare_PredicateLocks(void)
if (MySerializableXact == InvalidSerializableXact)
return;
/* Generate a xact record for our SERIALIZABLEXACT */
/* Generate an xact record for our SERIALIZABLEXACT */
record.type = TWOPHASEPREDICATERECORD_XACT;
xactRecord->xmin = MySerializableXact->xmin;
xactRecord->flags = MySerializableXact->flags;