Skip to content

Commit 75459bc

Browse files
committed
Fix misc typos, mostly in comments.
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.
1 parent 330cad2 commit 75459bc

File tree

13 files changed

+15
-15
lines changed

13 files changed

+15
-15
lines changed

contrib/bloom/blscan.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ blendscan(IndexScanDesc scan)
7676
}
7777

7878
/*
79-
* Insert all matching tuples into to a bitmap.
79+
* Insert all matching tuples into a bitmap.
8080
*/
8181
int64
8282
blgetbitmap(IndexScanDesc scan, TIDBitmap *tbm)

src/backend/access/transam/multixact.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2551,7 +2551,7 @@ SetOffsetVacuumLimit(void)
25512551

25522552
/*
25532553
* NB: Have to prevent concurrent truncation, we might otherwise try to
2554-
* lookup a oldestMulti that's concurrently getting truncated away.
2554+
* lookup an oldestMulti that's concurrently getting truncated away.
25552555
*/
25562556
LWLockAcquire(MultiXactTruncationLock, LW_SHARED);
25572557

@@ -2727,7 +2727,7 @@ find_multixact_start(MultiXactId multi, MultiXactOffset *result)
27272727
/*
27282728
* Flush out dirty data, so PhysicalPageExists can work correctly.
27292729
* SimpleLruFlush() is a pretty big hammer for that. Alternatively we
2730-
* could add a in-memory version of page exists, but find_multixact_start
2730+
* could add an in-memory version of page exists, but find_multixact_start
27312731
* is called infrequently, and it doesn't seem bad to flush buffers to
27322732
* disk before truncation.
27332733
*/

src/backend/commands/cluster.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1542,7 +1542,7 @@ finish_heap_swap(Oid OIDOldHeap, Oid OIDNewHeap,
15421542
* swap_relation_files()), thus relfrozenxid was not updated. That's
15431543
* annoying because a potential reason for doing a VACUUM FULL is a
15441544
* imminent or actual anti-wraparound shutdown. So, now that we can
1545-
* access the new relation using it's indices, update relfrozenxid.
1545+
* access the new relation using its indices, update relfrozenxid.
15461546
* pg_class doesn't have a toast relation, so we don't need to update the
15471547
* corresponding toast relation. Not that there's little point moving all
15481548
* relfrozenxid updates here since swap_relation_files() needs to write to

src/backend/executor/nodeModifyTable.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1067,7 +1067,7 @@ lreplace:;
10671067
* (but still lock row, even though it may not satisfy estate's
10681068
* snapshot).
10691069
*
1070-
* Returns true if if we're done (with or without an update), or false if
1070+
* Returns true if we're done (with or without an update), or false if
10711071
* the caller must retry the INSERT from scratch.
10721072
*/
10731073
static bool

src/backend/replication/logical/origin.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1404,7 +1404,7 @@ pg_show_replication_origin_status(PG_FUNCTION_ARGS)
14041404
int i;
14051405
#define REPLICATION_ORIGIN_PROGRESS_COLS 4
14061406

1407-
/* we we want to return 0 rows if slot is set to zero */
1407+
/* we want to return 0 rows if slot is set to zero */
14081408
replorigin_check_prerequisites(false, true);
14091409

14101410
if (rsinfo == NULL || !IsA(rsinfo, ReturnSetInfo))

src/bin/initdb/t/001_initdb.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# To test successful data directory creation with a additional feature, first
1+
# To test successful data directory creation with an additional feature, first
22
# try to elaborate the "successful creation" test instead of adding a test.
33
# Successful initdb consumes much time and I/O.
44

src/bin/pg_upgrade/tablespace.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ init_tablespaces(void)
3636
* get_tablespace_paths()
3737
*
3838
* Scans pg_tablespace and returns a malloc'ed array of all tablespace
39-
* paths. Its the caller's responsibility to free the array.
39+
* paths. It's the caller's responsibility to free the array.
4040
*/
4141
static void
4242
get_tablespace_paths(void)

src/interfaces/ecpg/ecpglib/execute.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1310,8 +1310,8 @@ ecpg_build_params(struct statement * stmt)
13101310
if ((position = next_insert(stmt->command, position, stmt->questionmarks, std_strings) + 1) == 0)
13111311
{
13121312
/*
1313-
* We have an argument but we dont have the matched up placeholder
1314-
* in the string
1313+
* We have an argument but we don't have the matched up
1314+
* placeholder in the string
13151315
*/
13161316
ecpg_raise(stmt->lineno, ECPG_TOO_MANY_ARGUMENTS,
13171317
ECPG_SQLSTATE_USING_CLAUSE_DOES_NOT_MATCH_PARAMETERS,

src/pl/tcl/pltcl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2523,7 +2523,7 @@ pltcl_SPI_execute_plan(ClientData cdata, Tcl_Interp *interp,
25232523
}
25242524

25252525
/************************************************************
2526-
* If there was a argtype list on preparation, we need
2526+
* If there was an argtype list on preparation, we need
25272527
* an argument value list now
25282528
************************************************************/
25292529
if (qdesc->nargs > 0)

src/test/regress/expected/rowsecurity.out

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1614,7 +1614,7 @@ SET SESSION AUTHORIZATION regress_rls_bob;
16141614
INSERT INTO document VALUES (79, (SELECT cid from category WHERE cname = 'technology'), 1, 'regress_rls_bob', 'technology book, can only insert')
16151615
ON CONFLICT (did) DO UPDATE SET dtitle = EXCLUDED.dtitle RETURNING *;
16161616
ERROR: new row violates row-level security policy for table "document"
1617-
-- UPDATE path is taken here. Existing tuple passes, since it's cid
1617+
-- UPDATE path is taken here. Existing tuple passes, since its cid
16181618
-- corresponds to "novel", but default USING qual is enforced against
16191619
-- post-UPDATE tuple too (as always when updating with a policy that lacks an
16201620
-- explicit WCO), and so this fails:

src/test/regress/expected/rules.out

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2726,7 +2726,7 @@ Rules:
27262726
NOTIFY rules_src_deletion
27272727

27282728
--
2729-
-- Ensure a aliased target relation for insert is correctly deparsed.
2729+
-- Ensure an aliased target relation for insert is correctly deparsed.
27302730
--
27312731
create rule r4 as on insert to rules_src do instead insert into rules_log AS trgt SELECT NEW.* RETURNING trgt.f1, trgt.f2;
27322732
create rule r5 as on update to rules_src do instead UPDATE rules_log AS trgt SET tag = 'updated' WHERE trgt.f1 = new.f1;

src/test/regress/sql/rowsecurity.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -593,7 +593,7 @@ SET SESSION AUTHORIZATION regress_rls_bob;
593593
INSERT INTO document VALUES (79, (SELECT cid from category WHERE cname = 'technology'), 1, 'regress_rls_bob', 'technology book, can only insert')
594594
ON CONFLICT (did) DO UPDATE SET dtitle = EXCLUDED.dtitle RETURNING *;
595595

596-
-- UPDATE path is taken here. Existing tuple passes, since it's cid
596+
-- UPDATE path is taken here. Existing tuple passes, since its cid
597597
-- corresponds to "novel", but default USING qual is enforced against
598598
-- post-UPDATE tuple too (as always when updating with a policy that lacks an
599599
-- explicit WCO), and so this fails:

src/test/regress/sql/rules.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -997,7 +997,7 @@ create rule r3 as on delete to rules_src do notify rules_src_deletion;
997997
\d+ rules_src
998998

999999
--
1000-
-- Ensure a aliased target relation for insert is correctly deparsed.
1000+
-- Ensure an aliased target relation for insert is correctly deparsed.
10011001
--
10021002
create rule r4 as on insert to rules_src do instead insert into rules_log AS trgt SELECT NEW.* RETURNING trgt.f1, trgt.f2;
10031003
create rule r5 as on update to rules_src do instead UPDATE rules_log AS trgt SET tag = 'updated' WHERE trgt.f1 = new.f1;

0 commit comments

Comments
 (0)