Hello!

Please see this patch with several typos and mistakes in comments.

There are also typos in sgml files (duplicate "to"):
1. doc/src/sgml/logicaldecoding.sgml, ln 619
>> Logical decoding can be used to to build
2. doc/src/sgml/ref/pg_dumpall.sgml, ln 457
>> Specifies the name of the database to connect to to dump global

--
Dmitriy Olshevskiy

>From 2558366552ce00bff5c57a98dea72f959e3c72e7 Mon Sep 17 00:00:00 2001
From: olshevskiy87 <olshevski...@bk.ru>
Date: Sun, 26 Apr 2015 18:40:07 +0400
Subject: [PATCH] fix typos in comments

---
 src/backend/access/brin/brin_tuple.c          | 2 +-
 src/backend/access/nbtree/nbtree.c            | 2 +-
 src/backend/access/transam/twophase.c         | 2 +-
 src/backend/catalog/objectaddress.c           | 4 ++--
 src/backend/commands/indexcmds.c              | 2 +-
 src/backend/executor/nodeModifyTable.c        | 2 +-
 src/backend/libpq/pqcomm.c                    | 2 +-
 src/backend/optimizer/geqo/geqo_erx.c         | 2 +-
 src/backend/postmaster/bgworker.c             | 2 +-
 src/backend/replication/logical/snapbuild.c   | 2 +-
 src/backend/storage/lmgr/lwlock.c             | 4 ++--
 src/backend/utils/cache/inval.c               | 2 +-
 src/bin/pg_archivecleanup/pg_archivecleanup.c | 2 +-
 src/bin/pg_basebackup/pg_recvlogical.c        | 4 ++--
 src/bin/pg_upgrade/parallel.c                 | 2 +-
 src/bin/pg_upgrade/relfilenode.c              | 2 +-
 src/include/access/attnum.h                   | 6 +++---
 src/include/access/xact.h                     | 2 +-
 src/include/mb/pg_wchar.h                     | 2 +-
 src/include/storage/s_lock.h                  | 4 ++--
 src/interfaces/ecpg/pgtypeslib/datetime.c     | 2 +-
 src/interfaces/ecpg/pgtypeslib/numeric.c      | 2 +-
 src/port/pgmkdirp.c                           | 2 +-
 23 files changed, 29 insertions(+), 29 deletions(-)

diff --git a/src/backend/access/brin/brin_tuple.c b/src/backend/access/brin/brin_tuple.c
index 93f00f6..08fa998 100644
--- a/src/backend/access/brin/brin_tuple.c
+++ b/src/backend/access/brin/brin_tuple.c
@@ -304,7 +304,7 @@ brin_free_tuple(BrinTuple *tuple)
 }
 
 /*
- * Create an palloc'd copy of a BrinTuple.
+ * Create a palloc'd copy of a BrinTuple.
  */
 BrinTuple *
 brin_copy_tuple(BrinTuple *tuple, Size len)
diff --git a/src/backend/access/nbtree/nbtree.c b/src/backend/access/nbtree/nbtree.c
index 9a6dcdd..c2d52fa 100644
--- a/src/backend/access/nbtree/nbtree.c
+++ b/src/backend/access/nbtree/nbtree.c
@@ -40,7 +40,7 @@ typedef struct
 	BTSpool    *spool;
 
 	/*
-	 * spool2 is needed only when the index is an unique index. Dead tuples
+	 * spool2 is needed only when the index is a unique index. Dead tuples
 	 * are put into spool2 instead of spool in order to avoid uniqueness
 	 * check.
 	 */
diff --git a/src/backend/access/transam/twophase.c b/src/backend/access/transam/twophase.c
index 3ac339b..d9a3fab 100644
--- a/src/backend/access/transam/twophase.c
+++ b/src/backend/access/transam/twophase.c
@@ -291,7 +291,7 @@ AtAbort_Twophase(void)
 }
 
 /*
- * This is called after we have finished transfering state to the prepared
+ * This is called after we have finished transferring state to the prepared
  * PGXACT entry.
  */
 void
diff --git a/src/backend/catalog/objectaddress.c b/src/backend/catalog/objectaddress.c
index 30cb699..816ab50 100644
--- a/src/backend/catalog/objectaddress.c
+++ b/src/backend/catalog/objectaddress.c
@@ -99,7 +99,7 @@ typedef struct
 	AclObjectKind acl_kind;		/* ACL_KIND_* of this object type */
 	bool		is_nsp_name_unique;		/* can the nsp/name combination (or
 										 * name alone, if there's no
-										 * namespace) be considered an unique
+										 * namespace) be considered a unique
 										 * identifier for an object of this
 										 * class? */
 } ObjectPropertyType;
@@ -3200,7 +3200,7 @@ pg_identify_object(PG_FUNCTION_ARGS)
 
 			/*
 			 * We only return the object name if it can be used (together with
-			 * the schema name, if any) as an unique identifier.
+			 * the schema name, if any) as a unique identifier.
 			 */
 			if (get_object_namensp_unique(address.classId))
 			{
diff --git a/src/backend/commands/indexcmds.c b/src/backend/commands/indexcmds.c
index 99acd4a..351d48e 100644
--- a/src/backend/commands/indexcmds.c
+++ b/src/backend/commands/indexcmds.c
@@ -1051,7 +1051,7 @@ ComputeIndexAttrs(IndexInfo *indexInfo,
 				 */
 
 				/*
-				 * A expression using mutable functions is probably wrong,
+				 * An expression using mutable functions is probably wrong,
 				 * since if you aren't going to get the same result for the
 				 * same data every time, it's not clear what the index entries
 				 * mean at all.
diff --git a/src/backend/executor/nodeModifyTable.c b/src/backend/executor/nodeModifyTable.c
index 06ec82e..31666ed 100644
--- a/src/backend/executor/nodeModifyTable.c
+++ b/src/backend/executor/nodeModifyTable.c
@@ -304,7 +304,7 @@ ExecInsert(TupleTableSlot *slot,
 	 * inserting the record into the heap and all indexes.
 	 *
 	 * ExecWithCheckOptions will elog(ERROR) if a violation is found, so
-	 * the tuple will never be seen, if it violates the the WITH CHECK
+	 * the tuple will never be seen, if it violates the WITH CHECK
 	 * OPTION.
 	 *
 	 * ExecWithCheckOptions() will skip any WCOs which are not of
diff --git a/src/backend/libpq/pqcomm.c b/src/backend/libpq/pqcomm.c
index 34efac4..fcdbfce 100644
--- a/src/backend/libpq/pqcomm.c
+++ b/src/backend/libpq/pqcomm.c
@@ -1561,7 +1561,7 @@ socket_endcopyout(bool errorAbort)
 /*
  * On Windows, we need to set both idle and interval at the same time.
  * We also cannot reset them to the default (setting to zero will
- * actually set them to zero, not default), therefor we fallback to
+ * actually set them to zero, not default), therefore we fallback to
  * the out-of-the-box default instead.
  */
 #if defined(WIN32) && defined(SIO_KEEPALIVE_VALS)
diff --git a/src/backend/optimizer/geqo/geqo_erx.c b/src/backend/optimizer/geqo/geqo_erx.c
index 69ac077..1a43ab7 100644
--- a/src/backend/optimizer/geqo/geqo_erx.c
+++ b/src/backend/optimizer/geqo/geqo_erx.c
@@ -138,7 +138,7 @@ gimme_edge_table(PlannerInfo *root, Gene *tour1, Gene *tour2,
  *	  registers edge from city1 to city2 in input edge table
  *
  *	  no assumptions about directionality are made;
- *	  therefor it is up to the calling routine to
+ *	  therefore it is up to the calling routine to
  *	  call gimme_edge twice to make a bi-directional edge
  *	  between city1 and city2;
  *	  uni-directional edges are possible as well (just call gimme_edge
diff --git a/src/backend/postmaster/bgworker.c b/src/backend/postmaster/bgworker.c
index 99f4b65..d493941 100644
--- a/src/backend/postmaster/bgworker.c
+++ b/src/backend/postmaster/bgworker.c
@@ -130,7 +130,7 @@ BackgroundWorkerShmemInit(void)
 		/*
 		 * Copy contents of worker list into shared memory.  Record the shared
 		 * memory slot assigned to each worker.  This ensures a 1-to-1
-		 * correspondence betwen the postmaster's private list and the array
+		 * correspondence between the postmaster's private list and the array
 		 * in shared memory.
 		 */
 		slist_foreach(siter, &BackgroundWorkerList)
diff --git a/src/backend/replication/logical/snapbuild.c b/src/backend/replication/logical/snapbuild.c
index 9b40bc8..c878f62 100644
--- a/src/backend/replication/logical/snapbuild.c
+++ b/src/backend/replication/logical/snapbuild.c
@@ -1597,7 +1597,7 @@ SnapBuildSerialize(SnapBuild *builder, XLogRecPtr lsn)
 
 	/*
 	 * We may overwrite the work from some other backend, but that's ok, our
-	 * snapshot is valid as well, we'll just have done some superflous work.
+	 * snapshot is valid as well, we'll just have done some superfluous work.
 	 */
 	if (rename(tmppath, path) != 0)
 	{
diff --git a/src/backend/storage/lmgr/lwlock.c b/src/backend/storage/lmgr/lwlock.c
index 5813e71..1acd2f0 100644
--- a/src/backend/storage/lmgr/lwlock.c
+++ b/src/backend/storage/lmgr/lwlock.c
@@ -848,7 +848,7 @@ LWLockDequeueSelf(LWLock *lock)
 
 		/*
 		 * Somebody else dequeued us and has or will wake us up. Deal with the
-		 * superflous absorption of a wakeup.
+		 * superfluous absorption of a wakeup.
 		 */
 
 		/*
@@ -1183,7 +1183,7 @@ LWLockAcquireOrWait(LWLock *lock, LWLockMode mode)
 		{
 			/*
 			 * Wait until awakened.  Like in LWLockAcquire, be prepared for bogus
-			 * wakups, because we share the semaphore with ProcWaitForSignal.
+			 * wakeups, because we share the semaphore with ProcWaitForSignal.
 			 */
 			LOG_LWDEBUG("LWLockAcquireOrWait", lock, "waiting");
 
diff --git a/src/backend/utils/cache/inval.c b/src/backend/utils/cache/inval.c
index 8826a5d..1907a87 100644
--- a/src/backend/utils/cache/inval.c
+++ b/src/backend/utils/cache/inval.c
@@ -516,7 +516,7 @@ RegisterRelcacheInvalidation(Oid dbId, Oid relId)
 /*
  * RegisterSnapshotInvalidation
  *
- * Register a invalidation event for MVCC scans against a given catalog.
+ * Register an invalidation event for MVCC scans against a given catalog.
  * Only needed for catalogs that don't have catcaches.
  */
 static void
diff --git a/src/bin/pg_archivecleanup/pg_archivecleanup.c b/src/bin/pg_archivecleanup/pg_archivecleanup.c
index 2ff2a27..ba6e242 100644
--- a/src/bin/pg_archivecleanup/pg_archivecleanup.c
+++ b/src/bin/pg_archivecleanup/pg_archivecleanup.c
@@ -46,7 +46,7 @@ char		exclusiveCleanupFileName[MAXPGPATH];		/* the oldest file we
  *	accessible directory. If you want to make other assumptions,
  *	such as using a vendor-specific archive and access API, these
  *	routines are the ones you'll need to change. You're
- *	enouraged to submit any changes to pgsql-hackers@postgresql.org
+ *	encouraged to submit any changes to pgsql-hackers@postgresql.org
  *	or personally to the current maintainer. Those changes may be
  *	folded in to later versions of this program.
  */
diff --git a/src/bin/pg_basebackup/pg_recvlogical.c b/src/bin/pg_basebackup/pg_recvlogical.c
index fa44d03..e4e16d7 100644
--- a/src/bin/pg_basebackup/pg_recvlogical.c
+++ b/src/bin/pg_basebackup/pg_recvlogical.c
@@ -603,7 +603,7 @@ main(int argc, char **argv)
 		{"verbose", no_argument, NULL, 'v'},
 		{"version", no_argument, NULL, 'V'},
 		{"help", no_argument, NULL, '?'},
-/* connnection options */
+/* connection options */
 		{"dbname", required_argument, NULL, 'd'},
 		{"host", required_argument, NULL, 'h'},
 		{"port", required_argument, NULL, 'p'},
@@ -670,7 +670,7 @@ main(int argc, char **argv)
 			case 'v':
 				verbose++;
 				break;
-/* connnection options */
+/* connection options */
 			case 'd':
 				dbname = pg_strdup(optarg);
 				break;
diff --git a/src/bin/pg_upgrade/parallel.c b/src/bin/pg_upgrade/parallel.c
index c6978b5..97fa0dc 100644
--- a/src/bin/pg_upgrade/parallel.c
+++ b/src/bin/pg_upgrade/parallel.c
@@ -175,7 +175,7 @@ win32_exec_prog(exec_thread_arg *args)
  *	parallel_transfer_all_new_dbs
  *
  *	This has the same API as transfer_all_new_dbs, except it does parallel execution
- *	by transfering multiple tablespaces in parallel
+ *	by transferring multiple tablespaces in parallel
  */
 void
 parallel_transfer_all_new_dbs(DbInfoArr *old_db_arr, DbInfoArr *new_db_arr,
diff --git a/src/bin/pg_upgrade/relfilenode.c b/src/bin/pg_upgrade/relfilenode.c
index fe05880..7b3215a 100644
--- a/src/bin/pg_upgrade/relfilenode.c
+++ b/src/bin/pg_upgrade/relfilenode.c
@@ -35,7 +35,7 @@ transfer_all_new_tablespaces(DbInfoArr *old_db_arr, DbInfoArr *new_db_arr,
 	  user_opts.transfer_mode == TRANSFER_MODE_LINK ? "Linking" : "Copying");
 
 	/*
-	 * Transfering files by tablespace is tricky because a single database can
+	 * Transferring files by tablespace is tricky because a single database can
 	 * use multiple tablespaces.  For non-parallel mode, we just pass a NULL
 	 * tablespace path, which matches all tablespaces.  In parallel mode, we
 	 * pass the default tablespace and all user-created tablespaces and let
diff --git a/src/include/access/attnum.h b/src/include/access/attnum.h
index 82e811d..300b682 100644
--- a/src/include/access/attnum.h
+++ b/src/include/access/attnum.h
@@ -29,14 +29,14 @@ typedef int16 AttrNumber;
  */
 /*
  * AttributeNumberIsValid
- *		True iff the attribute number is valid.
+ *		True if the attribute number is valid.
  */
 #define AttributeNumberIsValid(attributeNumber) \
 	((bool) ((attributeNumber) != InvalidAttrNumber))
 
 /*
  * AttrNumberIsForUserDefinedAttr
- *		True iff the attribute number corresponds to an user defined attribute.
+ *		True if the attribute number corresponds to a user defined attribute.
  */
 #define AttrNumberIsForUserDefinedAttr(attributeNumber) \
 	((bool) ((attributeNumber) > 0))
@@ -46,7 +46,7 @@ typedef int16 AttrNumber;
  *		Returns the attribute offset for an attribute number.
  *
  * Note:
- *		Assumes the attribute number is for an user defined attribute.
+ *		Assumes the attribute number is for a user defined attribute.
  */
 #define AttrNumberGetAttrOffset(attNum) \
 ( \
diff --git a/src/include/access/xact.h b/src/include/access/xact.h
index fdf3ea3..8da6aa9 100644
--- a/src/include/access/xact.h
+++ b/src/include/access/xact.h
@@ -168,7 +168,7 @@ typedef struct xl_xact_assignment
  * 'xl_xact_xinfo->xinfo'. The presence of the xinfo field itself is signalled
  * by a set XLOG_XACT_HAS_INFO bit in the xl_info field.
  *
- * NB: All the individual data chunks should be be sized to multiples of
+ * NB: All the individual data chunks should be sized to multiples of
  * sizeof(int) and only require int32 alignment.
  */
 
diff --git a/src/include/mb/pg_wchar.h b/src/include/mb/pg_wchar.h
index 254cf67..f7222fc 100644
--- a/src/include/mb/pg_wchar.h
+++ b/src/include/mb/pg_wchar.h
@@ -88,7 +88,7 @@ typedef unsigned int pg_wchar;
  * interoperable anyway).
  *
  * Note that XEmacs's implementation is different from what emacs does.
- * We follow emacs's implementaion, rathter than XEmacs's.
+ * We follow emacs's implementation, rather than XEmacs's.
  *----------------------------------------------------
  */
 
diff --git a/src/include/storage/s_lock.h b/src/include/storage/s_lock.h
index f4dc0db..b131412 100644
--- a/src/include/storage/s_lock.h
+++ b/src/include/storage/s_lock.h
@@ -356,8 +356,8 @@ tas(volatile slock_t *lock)
 /*
  * Solaris has always run sparc processors in TSO (total store) mode, but
  * linux didn't use to and the *BSDs still don't. So, be careful about
- * acquire/release semantics. The CPU will treat superflous membars as NOPs,
- * so it's just code space.
+ * acquire/release semantics. The CPU will treat superfluous membars as 
+ * NOPs, so it's just code space.
  */
 #define HAS_TEST_AND_SET
 
diff --git a/src/interfaces/ecpg/pgtypeslib/datetime.c b/src/interfaces/ecpg/pgtypeslib/datetime.c
index 49cb817..3b0855f 100644
--- a/src/interfaces/ecpg/pgtypeslib/datetime.c
+++ b/src/interfaces/ecpg/pgtypeslib/datetime.c
@@ -323,7 +323,7 @@ PGTYPESdate_fmt_asc(date dDate, const char *fmtstring, char *outbuf)
  * PGTYPESdate_defmt_asc
  *
  * function works as follows:
- *	 - first we analyze the paramters
+ *	 - first we analyze the parameters
  *	 - if this is a special case with no delimiters, add delimters
  *	 - find the tokens. First we look for numerical values. If we have found
  *	   less than 3 tokens, we check for the months' names and thereafter for
diff --git a/src/interfaces/ecpg/pgtypeslib/numeric.c b/src/interfaces/ecpg/pgtypeslib/numeric.c
index 84d73b7..0504f3c 100644
--- a/src/interfaces/ecpg/pgtypeslib/numeric.c
+++ b/src/interfaces/ecpg/pgtypeslib/numeric.c
@@ -1376,7 +1376,7 @@ PGTYPESnumeric_cmp(numeric *var1, numeric *var2)
 	if (var1->sign == NUMERIC_NEG && var2->sign == NUMERIC_NEG)
 	{
 		/*
-		 * instead of inverting the result, we invert the paramter ordering
+		 * instead of inverting the result, we invert the parameter ordering
 		 */
 		return cmp_abs(var2, var1);
 	}
diff --git a/src/port/pgmkdirp.c b/src/port/pgmkdirp.c
index d9c95b5..d943559 100644
--- a/src/port/pgmkdirp.c
+++ b/src/port/pgmkdirp.c
@@ -93,7 +93,7 @@ pg_mkdir_p(char *path, int omode)
 	/*
 	 * POSIX 1003.2: For each dir operand that does not name an existing
 	 * directory, effects equivalent to those caused by the following command
-	 * shall occcur:
+	 * shall occur:
 	 *
 	 * mkdir -p -m $(umask -S),u+wx $(dirname dir) && mkdir [-m mode] dir
 	 *
-- 
1.8.3.msysgit.0

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to