]> granicus.if.org Git - postgresql/commitdiff
Fix misc typos, mostly in comments.
authorHeikki Linnakangas <heikki.linnakangas@iki.fi>
Mon, 9 Jul 2018 13:10:44 +0000 (16:10 +0300)
committerHeikki Linnakangas <heikki.linnakangas@iki.fi>
Wed, 18 Jul 2018 13:54:54 +0000 (16:54 +0300)
A collection of typos I happened to spot while reading code, as well as
grepping for common mistakes.

Backpatch to all supported versions, as applicable, to avoid conflicts
when backporting other commits in the future.

12 files changed:
src/backend/access/transam/multixact.c
src/backend/commands/cluster.c
src/backend/executor/nodeModifyTable.c
src/backend/replication/logical/origin.c
src/bin/initdb/t/001_initdb.pl
src/bin/pg_upgrade/tablespace.c
src/interfaces/ecpg/ecpglib/execute.c
src/pl/tcl/pltcl.c
src/test/regress/expected/rowsecurity.out
src/test/regress/expected/rules.out
src/test/regress/sql/rowsecurity.sql
src/test/regress/sql/rules.sql

index fdf8e0c33a4ae3e29ab83b33178ef8d1c59943fd..12937c510b8d59664676e3b1e97919f46680b4e5 100644 (file)
@@ -2555,7 +2555,7 @@ SetOffsetVacuumLimit(void)
 
        /*
         * NB: Have to prevent concurrent truncation, we might otherwise try to
-        * lookup a oldestMulti that's concurrently getting truncated away.
+        * lookup an oldestMulti that's concurrently getting truncated away.
         */
        LWLockAcquire(MultiXactTruncationLock, LW_SHARED);
 
@@ -2731,7 +2731,7 @@ find_multixact_start(MultiXactId multi, MultiXactOffset *result)
        /*
         * Flush out dirty data, so PhysicalPageExists can work correctly.
         * SimpleLruFlush() is a pretty big hammer for that.  Alternatively we
-        * could add a in-memory version of page exists, but find_multixact_start
+        * could add an in-memory version of page exists, but find_multixact_start
         * is called infrequently, and it doesn't seem bad to flush buffers to
         * disk before truncation.
         */
index 9e39e2f648c1bac4cadd3af7e9a2a26a489eb659..9c91f2c31f7c1007089d6170021681b25909308a 100644 (file)
@@ -1542,7 +1542,7 @@ finish_heap_swap(Oid OIDOldHeap, Oid OIDNewHeap,
         * swap_relation_files()), thus relfrozenxid was not updated. That's
         * annoying because a potential reason for doing a VACUUM FULL is a
         * imminent or actual anti-wraparound shutdown.  So, now that we can
-        * access the new relation using it's indices, update relfrozenxid.
+        * access the new relation using its indices, update relfrozenxid.
         * pg_class doesn't have a toast relation, so we don't need to update the
         * corresponding toast relation. Not that there's little point moving all
         * relfrozenxid updates here since swap_relation_files() needs to write to
index ae2a147c62ff6ac02e50b793585c2d566a13b02c..252324910eaa63fa1370f9cc416d24895636d4ff 100644 (file)
@@ -1053,7 +1053,7 @@ lreplace:;
  * (but still lock row, even though it may not satisfy estate's
  * snapshot).
  *
- * Returns true if if we're done (with or without an update), or false if
+ * Returns true if we're done (with or without an update), or false if
  * the caller must retry the INSERT from scratch.
  */
 static bool
index 6fccdd8654439b8c83b61f304aa7472c8f8f50ef..4ecd6a9eae04d542a604d59446c4fa2a10fac0d1 100644 (file)
@@ -1404,7 +1404,7 @@ pg_show_replication_origin_status(PG_FUNCTION_ARGS)
        int                     i;
 #define REPLICATION_ORIGIN_PROGRESS_COLS 4
 
-       /* we we want to return 0 rows if slot is set to zero */
+       /* we want to return 0 rows if slot is set to zero */
        replorigin_check_prerequisites(false, true);
 
        if (rsinfo == NULL || !IsA(rsinfo, ReturnSetInfo))
index 299dcf5b3b98ee343343f974882cc81a6be12235..c4e514c7fbf7d12622f95d64b7e51d096e30ffc1 100644 (file)
@@ -1,4 +1,4 @@
-# To test successful data directory creation with a additional feature, first
+# To test successful data directory creation with an additional feature, first
 # try to elaborate the "successful creation" test instead of adding a test.
 # Successful initdb consumes much time and I/O.
 
index a20cbc60a4ac30bcd17c4ca9d7a7dc7571978b37..0122cf911c004b563f08c9d1a491d81f06ca172a 100644 (file)
@@ -36,7 +36,7 @@ init_tablespaces(void)
  * get_tablespace_paths()
  *
  * Scans pg_tablespace and returns a malloc'ed array of all tablespace
- * paths. Its the caller's responsibility to free the array.
+ * paths. It's the caller's responsibility to free the array.
  */
 static void
 get_tablespace_paths(void)
index f74ed5e8002f0caa4881eb459fae6072fb87cce8..5b09233810d6ebffeac01079fe7336db6baf064e 100644 (file)
@@ -1310,8 +1310,8 @@ ecpg_build_params(struct statement * stmt)
                if ((position = next_insert(stmt->command, position, stmt->questionmarks, std_strings) + 1) == 0)
                {
                        /*
-                        * We have an argument but we dont have the matched up placeholder
-                        * in the string
+                        * We have an argument but we don't have the matched up
+                        * placeholder in the string
                         */
                        ecpg_raise(stmt->lineno, ECPG_TOO_MANY_ARGUMENTS,
                                           ECPG_SQLSTATE_USING_CLAUSE_DOES_NOT_MATCH_PARAMETERS,
index 92098570a6609c1119449fda3172a562ade51395..5dfbc6a3721156d5179aae0e5538b26c7c86e503 100644 (file)
@@ -2354,7 +2354,7 @@ pltcl_SPI_execute_plan(ClientData cdata, Tcl_Interp *interp,
        }
 
        /************************************************************
-        * If there was a argtype list on preparation, we need
+        * If there was an argtype list on preparation, we need
         * an argument value list now
         ************************************************************/
        if (qdesc->nargs > 0)
index c9a0abc7e71375f5645ace732381fa4f18930a2c..91ad2f2f87dc07875a3c8050432735b67dd8b87c 100644 (file)
@@ -1614,7 +1614,7 @@ SET SESSION AUTHORIZATION rls_regress_user1;
 INSERT INTO document VALUES (79, (SELECT cid from category WHERE cname = 'technology'), 1, 'rls_regress_user1', 'technology book, can only insert')
     ON CONFLICT (did) DO UPDATE SET dtitle = EXCLUDED.dtitle RETURNING *;
 ERROR:  new row violates row-level security policy for table "document"
--- UPDATE path is taken here.  Existing tuple passes, since it's cid
+-- UPDATE path is taken here.  Existing tuple passes, since its cid
 -- corresponds to "novel", but default USING qual is enforced against
 -- post-UPDATE tuple too (as always when updating with a policy that lacks an
 -- explicit WCO), and so this fails:
index 63094c03b99c4b42710b026a8c1e18f0237b270d..fa2f525e4d02941942d19b89206a0c33606dbaf3 100644 (file)
@@ -2685,7 +2685,7 @@ Rules:
  NOTIFY rules_src_deletion
 
 --
--- Ensure a aliased target relation for insert is correctly deparsed.
+-- Ensure an aliased target relation for insert is correctly deparsed.
 --
 create rule r4 as on insert to rules_src do instead insert into rules_log AS trgt SELECT NEW.* RETURNING trgt.f1, trgt.f2;
 create rule r5 as on update to rules_src do instead UPDATE rules_log AS trgt SET tag = 'updated' WHERE trgt.f1 = new.f1;
index b836ca999220457b51332190838b267ce9b97278..8e14cc0dca70fcc32029d3548c733cc8480a4800 100644 (file)
@@ -593,7 +593,7 @@ SET SESSION AUTHORIZATION rls_regress_user1;
 INSERT INTO document VALUES (79, (SELECT cid from category WHERE cname = 'technology'), 1, 'rls_regress_user1', 'technology book, can only insert')
     ON CONFLICT (did) DO UPDATE SET dtitle = EXCLUDED.dtitle RETURNING *;
 
--- UPDATE path is taken here.  Existing tuple passes, since it's cid
+-- UPDATE path is taken here.  Existing tuple passes, since its cid
 -- corresponds to "novel", but default USING qual is enforced against
 -- post-UPDATE tuple too (as always when updating with a policy that lacks an
 -- explicit WCO), and so this fails:
index 1d43c8b20584ba91cd882e05843e67f81019be34..8f628c2e836086fa7d5912ab4bfd81864c047d62 100644 (file)
@@ -997,7 +997,7 @@ create rule r3 as on delete to rules_src do notify rules_src_deletion;
 \d+ rules_src
 
 --
--- Ensure a aliased target relation for insert is correctly deparsed.
+-- Ensure an aliased target relation for insert is correctly deparsed.
 --
 create rule r4 as on insert to rules_src do instead insert into rules_log AS trgt SELECT NEW.* RETURNING trgt.f1, trgt.f2;
 create rule r5 as on update to rules_src do instead UPDATE rules_log AS trgt SET tag = 'updated' WHERE trgt.f1 = new.f1;