From 9f2e211386931f7aee48ffbc2fcaef1632d8329f Mon Sep 17 00:00:00 2001
From: Magnus Hagander
Date: Mon, 20 Sep 2010 22:08:53 +0200
Subject: Remove cvs keywords from all files.
---
src/backend/access/gist/gistxlog.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
(limited to 'src/backend/access/gist/gistxlog.c')
diff --git a/src/backend/access/gist/gistxlog.c b/src/backend/access/gist/gistxlog.c
index 7f5dd990c8..a90303e547 100644
--- a/src/backend/access/gist/gistxlog.c
+++ b/src/backend/access/gist/gistxlog.c
@@ -8,7 +8,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/access/gist/gistxlog.c,v 1.35 2010/01/02 16:57:34 momjian Exp $
+ * src/backend/access/gist/gistxlog.c
*-------------------------------------------------------------------------
*/
#include "postgres.h"
--
cgit v1.2.3
From 9de3aa65f01fb51cbc725e8508ea233e4e92c46c Mon Sep 17 00:00:00 2001
From: Heikki Linnakangas
Date: Thu, 23 Dec 2010 16:03:08 +0200
Subject: Rewrite the GiST insertion logic so that we don't need the
post-recovery cleanup stage to finish incomplete inserts or splits anymore.
There was two reasons for the cleanup step:
1. When a new tuple was inserted to a leaf page, the downlink in the parent
needed to be updated to contain (ie. to be consistent with) the new key.
Updating the parent in turn might require recursively updating the parent of
the parent. We now handle that by updating the parent while traversing down
the tree, so that when we insert the leaf tuple, all the parents are already
consistent with the new key, and the tree is consistent at every step.
2. When a page is split, we need to insert the downlink for the new right
page(s), and update the downlink for the original page to not include keys
that moved to the right page(s). We now handle that by setting a new flag,
F_FOLLOW_RIGHT, on the non-rightmost pages in the split. When that flag is
set, scans always follow the rightlink, regardless of the NSN mechanism used
to detect concurrent page splits. That way the tree is consistent right after
split, even though the downlink is still missing. This is very similar to the
way B-tree splits are handled. When the downlink is inserted in the parent,
the flag is cleared. To keep the insertion algorithm simple, when an
insertion sees an incomplete split, indicated by the F_FOLLOW_RIGHT flag, it
finishes the split before doing anything else.
These changes allow removing the whole "invalid tuple" mechanism, but I
retained the scan code to still follow invalid tuples correctly. While we
don't create any such tuples anymore, we want to handle them gracefully in
case you pg_upgrade a GiST index that has them. If we encounter any on an
insert, though, we just throw an error saying that you need to REINDEX.
The issue that got me into doing this is that if you did a checkpoint while
an insert or split was in progress, and the checkpoint finishes quickly so
that there is no WAL record related to the insert between RedoRecPtr and the
checkpoint record, recovery from that checkpoint would not know to finish
the incomplete insert. IOW, we have the same issue we solved with the
rm_safe_restartpoint mechanism during normal operation too. It's highly
unlikely to happen in practice, and this fix is far too large to backpatch,
so we're just going to live with in previous versions, but this refactoring
fixes it going forward.
With this patch, you don't get the annoying
'index "FOO" needs VACUUM or REINDEX to finish crash recovery' notices
anymore if you crash at an unfortunate moment.
---
doc/src/sgml/gist.sgml | 29 -
src/backend/access/gist/README | 181 +++---
src/backend/access/gist/gist.c | 1009 ++++++++++++++++++++++------------
src/backend/access/gist/gistget.c | 10 +-
src/backend/access/gist/gistsplit.c | 60 --
src/backend/access/gist/gistutil.c | 28 +-
src/backend/access/gist/gistvacuum.c | 57 +-
src/backend/access/gist/gistxlog.c | 797 ++++++---------------------
src/backend/access/transam/rmgr.c | 2 +-
src/include/access/gist.h | 11 +-
src/include/access/gist_private.h | 81 +--
11 files changed, 1030 insertions(+), 1235 deletions(-)
(limited to 'src/backend/access/gist/gistxlog.c')
diff --git a/doc/src/sgml/gist.sgml b/doc/src/sgml/gist.sgml
index b8cb291467..f6e31092aa 100644
--- a/doc/src/sgml/gist.sgml
+++ b/doc/src/sgml/gist.sgml
@@ -709,33 +709,4 @@ my_distance(PG_FUNCTION_ARGS)
-
- Crash Recovery
-
-
- Usually, replay of the WAL log is sufficient to restore the integrity
- of a GiST index following a database crash. However, there are some
- corner cases in which the index state is not fully rebuilt. The index
- will still be functionally correct, but there might be some performance
- degradation. When this occurs, the index can be repaired by
- VACUUM>ing its table, or by rebuilding the index using
- REINDEX>. In some cases a plain VACUUM> is
- not sufficient, and either VACUUM FULL> or REINDEX>
- is needed. The need for one of these procedures is indicated by occurrence
- of this log message during crash recovery:
-
-LOG: index NNN/NNN/NNN needs VACUUM or REINDEX to finish crash recovery
-
- or this log message during routine index insertions:
-
-LOG: index "FOO" needs VACUUM or REINDEX to finish crash recovery
-
- If a plain VACUUM> finds itself unable to complete recovery
- fully, it will return a notice:
-
-NOTICE: index "FOO" needs VACUUM FULL or REINDEX to finish crash recovery
-
-
-
-
diff --git a/src/backend/access/gist/README b/src/backend/access/gist/README
index 03069f0268..2d78dcb0df 100644
--- a/src/backend/access/gist/README
+++ b/src/backend/access/gist/README
@@ -108,43 +108,71 @@ Penalty is used for choosing a subtree to insert; method PickSplit is used for
the node splitting algorithm; method Union is used for propagating changes
upward to maintain the tree properties.
-NOTICE: We modified original INSERT algorithm for performance reason. In
-particularly, it is now a single-pass algorithm.
-
-Function findLeaf is used to identify subtree for insertion. Page, in which
-insertion is proceeded, is locked as well as its parent page. Functions
-findParent and findPath are used to find parent pages, which could be changed
-because of concurrent access. Function pageSplit is recurrent and could split
-page by more than 2 pages, which could be necessary if keys have different
-lengths or more than one key are inserted (in such situation, user defined
-function pickSplit cannot guarantee free space on page).
-
-findLeaf(new-key)
- push(stack, [root, 0]) //page, LSN
- while(true)
- ptr = top of stack
- latch( ptr->page, S-mode )
- ptr->lsn = ptr->page->lsn
- if ( exists ptr->parent AND ptr->parent->lsn < ptr->page->nsn )
- unlatch( ptr->page )
- pop stack
- else if ( ptr->page is not leaf )
- push( stack, [get_best_child(ptr->page, new-key), 0] )
- unlatch( ptr->page )
- else
- unlatch( ptr->page )
- latch( ptr->page, X-mode )
- if ( ptr->page is not leaf )
- //the only root page can become a non-leaf
- unlatch( ptr->page )
- else if ( ptr->parent->lsn < ptr->page->nsn )
- unlatch( ptr->page )
- pop stack
- else
- return stack
- end
- end
- end
+To insert a tuple, we first have to find a suitable leaf page to insert to.
+The algorithm walks down the tree, starting from the root, along the path
+of smallest Penalty. At each step:
+
+1. Has this page been split since we looked at the parent? If so, it's
+possible that we should be inserting to the other half instead, so retreat
+back to the parent.
+2. If this is a leaf node, we've found our target node.
+3. Otherwise use Penalty to pick a new target subtree.
+4. Check the key representing the target subtree. If it doesn't already cover
+the key we're inserting, replace it with the Union of the old downlink key
+and the key being inserted. (Actually, we always call Union, and just skip
+the replacement if the Unioned key is the same as the existing key)
+5. Replacing the key in step 4 might cause the page to be split. In that case,
+propagate the change upwards and restart the algorithm from the first parent
+that didn't need to be split.
+6. Walk down to the target subtree, and goto 1.
+
+This differs from the insertion algorithm in the original paper. In the
+original paper, you first walk down the tree until you reach a leaf page, and
+then you adjust the downlink in the parent, and propagating the adjustment up,
+all the way up to the root in the worst case. But we adjust the downlinks to
+cover the new key already when we walk down, so that when we reach the leaf
+page, we don't need to update the parents anymore, except to insert the
+downlinks if we have to split the page. This makes crash recovery simpler:
+after inserting a key to the page, the tree is immediately self-consistent
+without having to update the parents. Even if we split a page and crash before
+inserting the downlink to the parent, the tree is self-consistent because the
+right half of the split is accessible via the rightlink of the left page
+(which replaced the original page).
+
+Note that the algorithm can walk up and down the tree before reaching a leaf
+page, if internal pages need to split while adjusting the downlinks for the
+new key. Eventually, you should reach the bottom, and proceed with the
+insertion of the new tuple.
+
+Once we've found the target page to insert to, we check if there's room
+for the new tuple. If there is, the tuple is inserted, and we're done.
+If it doesn't fit, however, the page needs to be split. Note that it is
+possible that a page needs to be split into more than two pages, if keys have
+different lengths or more than one key is being inserted at a time (which can
+happen when inserting downlinks for a page split that resulted in more than
+two pages at the lower level). After splitting a page, the parent page needs
+to be updated. The downlink for the new page needs to be inserted, and the
+downlink for the old page, which became the left half of the split, needs to
+be updated to only cover those tuples that stayed on the left page. Inserting
+the downlink in the parent can again lead to a page split, recursing up to the
+root page in the worst case.
+
+gistplacetopage is the workhorse function that performs one step of the
+insertion. If the tuple fits, it inserts it to the given page, otherwise
+it splits the page, and constructs the new downlink tuples for the split
+pages. The caller must then call gistplacetopage() on the parent page to
+insert the downlink tuples. The parent page that holds the downlink to
+the child might have migrated as a result of concurrent splits of the
+parent, gistfindCorrectParent() is used to find the parent page.
+
+Splitting the root page works slightly differently. At root split,
+gistplacetopage() allocates the new child pages and replaces the old root
+page with the new root containing downlinks to the new children, all in one
+operation.
+
+
+findPath is a subroutine of findParent, used when the correct parent page
+can't be found by following the rightlinks at the parent level:
findPath( stack item )
push stack, [root, 0, 0] // page, LSN, parent
@@ -165,9 +193,13 @@ findPath( stack item )
pop stack
end
+
+gistFindCorrectParent is used to re-find the parent of a page during
+insertion. It might have migrated to the right since we traversed down the
+tree because of page splits.
+
findParent( stack item )
parent = item->parent
- latch( parent->page, X-mode )
if ( parent->page->lsn != parent->lsn )
while(true)
search parent tuple on parent->page, if found the return
@@ -181,9 +213,13 @@ findParent( stack item )
end
newstack = findPath( item->parent )
replace part of stack to new one
+ latch( parent->page, X-mode )
return findParent( item )
end
+pageSplit function decides how to distribute keys to the new pages after
+page split:
+
pageSplit(page, allkeys)
(lkeys, rkeys) = pickSplit( allkeys )
if ( page is root )
@@ -204,39 +240,44 @@ pageSplit(page, allkeys)
return newkeys
-placetopage(page, keysarray)
- if ( no space left on page )
- keysarray = pageSplit(page, [ extract_keys(page), keysarray])
- last page in chain gets old NSN,
- original and others - new NSN equals to LSN
- if ( page is root )
- make new root with keysarray
- end
- else
- put keysarray on page
- if ( length of keysarray > 1 )
- keysarray = [ union(keysarray) ]
- end
- end
-insert(new-key)
- stack = findLeaf(new-key)
- keysarray = [new-key]
- ptr = top of stack
- while(true)
- findParent( ptr ) //findParent latches parent page
- keysarray = placetopage(ptr->page, keysarray)
- unlatch( ptr->page )
- pop stack;
- ptr = top of stack
- if (length of keysarray == 1)
- newboundingkey = union(oldboundingkey, keysarray)
- if (newboundingkey == oldboundingkey)
- unlatch ptr->page
- break loop
- end
- end
- end
+Concurrency control
+-------------------
+As a rule of thumb, if you need to hold a lock on multiple pages at the
+same time, the locks should be acquired in the following order: child page
+before parent, and left-to-right at the same level. Always acquiring the
+locks in the same order avoids deadlocks.
+
+The search algorithm only looks at and locks one page at a time. Consequently
+there's a race condition between a search and a page split. A page split
+happens in two phases: 1. The page is split 2. The downlink is inserted to the
+parent. If a search looks at the parent page between those steps, before the
+downlink is inserted, it will still find the new right half by following the
+rightlink on the left half. But it must not follow the rightlink if it saw the
+downlink in the parent, or the page will be visited twice!
+
+A split initially marks the left page with the F_FOLLOW_RIGHT flag. If a scan
+sees that flag set, it knows that the right page is missing the downlink, and
+should be visited too. When split inserts the downlink to the parent, it
+clears the F_FOLLOW_RIGHT flag in the child, and sets the NSN field in the
+child page header to match the LSN of the insertion on the parent. If the
+F_FOLLOW_RIGHT flag is not set, a scan compares the NSN on the child and the
+LSN it saw in the parent. If NSN < LSN, the scan looked at the parent page
+before the downlink was inserted, so it should follow the rightlink. Otherwise
+the scan saw the downlink in the parent page, and will/did follow that as
+usual.
+
+A scan can't normally see a page with the F_FOLLOW_RIGHT flag set, because
+a page split keeps the child pages locked until the downlink has been inserted
+to the parent and the flag cleared again. But if a crash happens in the middle
+of a page split, before the downlinks are inserted into the parent, that will
+leave a page with F_FOLLOW_RIGHT in the tree. Scans handle that just fine,
+but we'll eventually want to fix that for performance reasons. And more
+importantly, dealing with pages with missing downlink pointers in the parent
+would complicate the insertion algorithm. So when an insertion sees a page
+with F_FOLLOW_RIGHT set, it immediately tries to bring the split that
+crashed in the middle to completion by adding the downlink in the parent.
+
Authors:
Teodor Sigaev
diff --git a/src/backend/access/gist/gist.c b/src/backend/access/gist/gist.c
index b34830bb42..7cd144e2f0 100644
--- a/src/backend/access/gist/gist.c
+++ b/src/backend/access/gist/gist.c
@@ -31,6 +31,12 @@ typedef struct
MemoryContext tmpCtx;
} GISTBuildState;
+/* A List of these is used represent a split-in-progress. */
+typedef struct
+{
+ Buffer buf; /* the split page "half" */
+ IndexTuple downlink; /* downlink for this half. */
+} GISTPageSplitInfo;
/* non-export function prototypes */
static void gistbuildCallback(Relation index,
@@ -43,8 +49,13 @@ static void gistdoinsert(Relation r,
IndexTuple itup,
Size freespace,
GISTSTATE *GISTstate);
-static void gistfindleaf(GISTInsertState *state,
- GISTSTATE *giststate);
+static void gistfixsplit(GISTInsertState *state, GISTSTATE *giststate);
+static bool gistinserttuples(GISTInsertState *state, GISTInsertStack *stack,
+ GISTSTATE *giststate,
+ IndexTuple *tuples, int ntup, OffsetNumber oldoffnum,
+ Buffer leftchild);
+static void gistfinishsplit(GISTInsertState *state, GISTInsertStack *stack,
+ GISTSTATE *giststate, List *splitinfo);
#define ROTATEDIST(d) do { \
@@ -251,41 +262,52 @@ gistinsert(PG_FUNCTION_ARGS)
/*
- * Workhouse routine for doing insertion into a GiST index. Note that
- * this routine assumes it is invoked in a short-lived memory context,
- * so it does not bother releasing palloc'd allocations.
+ * Place tuples from 'itup' to 'buffer'. If 'oldoffnum' is valid, the tuple
+ * at that offset is atomically removed along with inserting the new tuples.
+ * This is used to replace a tuple with a new one.
+ *
+ * If 'leftchildbuf' is valid, we're inserting the downlink for the page
+ * to the right of 'leftchildbuf', or updating the downlink for 'leftchildbuf'.
+ * F_FOLLOW_RIGHT flag on 'leftchildbuf' is cleared and NSN is set.
+ *
+ * If there is not enough room on the page, it is split. All the split
+ * pages are kept pinned and locked and returned in *splitinfo, the caller
+ * is responsible for inserting the downlinks for them. However, if
+ * 'buffer' is the root page and it needs to be split, gistplacetopage()
+ * performs the split as one atomic operation, and *splitinfo is set to NIL.
+ * In that case, we continue to hold the root page locked, and the child
+ * pages are released; note that new tuple(s) are *not* on the root page
+ * but in one of the new child pages.
*/
-static void
-gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
+static bool
+gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
+ Buffer buffer,
+ IndexTuple *itup, int ntup, OffsetNumber oldoffnum,
+ Buffer leftchildbuf,
+ List **splitinfo)
{
- GISTInsertState state;
-
- memset(&state, 0, sizeof(GISTInsertState));
-
- state.itup = (IndexTuple *) palloc(sizeof(IndexTuple));
- state.itup[0] = (IndexTuple) palloc(IndexTupleSize(itup));
- memcpy(state.itup[0], itup, IndexTupleSize(itup));
- state.ituplen = 1;
- state.freespace = freespace;
- state.r = r;
- state.key = itup->t_tid;
- state.needInsertComplete = true;
-
- state.stack = (GISTInsertStack *) palloc0(sizeof(GISTInsertStack));
- state.stack->blkno = GIST_ROOT_BLKNO;
+ Page page = BufferGetPage(buffer);
+ bool is_leaf = (GistPageIsLeaf(page)) ? true : false;
+ XLogRecPtr recptr;
+ int i;
+ bool is_split;
- gistfindleaf(&state, giststate);
- gistmakedeal(&state, giststate);
-}
+ /*
+ * Refuse to modify a page that's incompletely split. This should
+ * not happen because we finish any incomplete splits while we walk
+ * down the tree. However, it's remotely possible that another
+ * concurrent inserter splits a parent page, and errors out before
+ * completing the split. We will just throw an error in that case,
+ * and leave any split we had in progress unfinished too. The next
+ * insert that comes along will clean up the mess.
+ */
+ if (GistFollowRight(page))
+ elog(ERROR, "concurrent GiST page split was incomplete");
-static bool
-gistplacetopage(GISTInsertState *state, GISTSTATE *giststate)
-{
- bool is_splitted = false;
- bool is_leaf = (GistPageIsLeaf(state->stack->page)) ? true : false;
+ *splitinfo = NIL;
/*
- * if (!is_leaf) remove old key: This node's key has been modified, either
+ * if isupdate, remove old key: This node's key has been modified, either
* because a child split occurred or because we needed to adjust our key
* for an insert in a child node. Therefore, remove the old version of
* this node's key.
@@ -293,77 +315,134 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate)
* for WAL replay, in the non-split case we handle this by setting up a
* one-element todelete array; in the split case, it's handled implicitly
* because the tuple vector passed to gistSplit won't include this tuple.
- *
- * XXX: If we want to change fillfactors between node and leaf, fillfactor
- * = (is_leaf ? state->leaf_fillfactor : state->node_fillfactor)
*/
- if (gistnospace(state->stack->page, state->itup, state->ituplen,
- is_leaf ? InvalidOffsetNumber : state->stack->childoffnum,
- state->freespace))
+ is_split = gistnospace(page, itup, ntup, oldoffnum, state->freespace);
+ if (is_split)
{
/* no space for insertion */
IndexTuple *itvec;
int tlen;
SplitedPageLayout *dist = NULL,
*ptr;
- BlockNumber rrlink = InvalidBlockNumber;
- GistNSN oldnsn;
+ BlockNumber oldrlink = InvalidBlockNumber;
+ GistNSN oldnsn = { 0, 0 };
+ SplitedPageLayout rootpg;
+ BlockNumber blkno = BufferGetBlockNumber(buffer);
+ bool is_rootsplit;
- is_splitted = true;
+ is_rootsplit = (blkno == GIST_ROOT_BLKNO);
/*
- * Form index tuples vector to split: remove old tuple if t's needed
- * and add new tuples to vector
+ * Form index tuples vector to split. If we're replacing an old tuple,
+ * remove the old version from the vector.
*/
- itvec = gistextractpage(state->stack->page, &tlen);
- if (!is_leaf)
+ itvec = gistextractpage(page, &tlen);
+ if (OffsetNumberIsValid(oldoffnum))
{
/* on inner page we should remove old tuple */
- int pos = state->stack->childoffnum - FirstOffsetNumber;
+ int pos = oldoffnum - FirstOffsetNumber;
tlen--;
if (pos != tlen)
memmove(itvec + pos, itvec + pos + 1, sizeof(IndexTuple) * (tlen - pos));
}
- itvec = gistjoinvector(itvec, &tlen, state->itup, state->ituplen);
- dist = gistSplit(state->r, state->stack->page, itvec, tlen, giststate);
-
- state->itup = (IndexTuple *) palloc(sizeof(IndexTuple) * tlen);
- state->ituplen = 0;
+ itvec = gistjoinvector(itvec, &tlen, itup, ntup);
+ dist = gistSplit(state->r, page, itvec, tlen, giststate);
- if (state->stack->blkno != GIST_ROOT_BLKNO)
+ /*
+ * Set up pages to work with. Allocate new buffers for all but the
+ * leftmost page. The original page becomes the new leftmost page,
+ * and is just replaced with the new contents.
+ *
+ * For a root-split, allocate new buffers for all child pages, the
+ * original page is overwritten with new root page containing
+ * downlinks to the new child pages.
+ */
+ ptr = dist;
+ if (!is_rootsplit)
{
- /*
- * if non-root split then we should not allocate new buffer, but
- * we must create temporary page to operate
- */
- dist->buffer = state->stack->buffer;
- dist->page = PageGetTempPageCopySpecial(BufferGetPage(dist->buffer));
+ /* save old rightlink and NSN */
+ oldrlink = GistPageGetOpaque(page)->rightlink;
+ oldnsn = GistPageGetOpaque(page)->nsn;
+
+ dist->buffer = buffer;
+ dist->block.blkno = BufferGetBlockNumber(buffer);
+ dist->page = PageGetTempPageCopySpecial(BufferGetPage(buffer));
/* clean all flags except F_LEAF */
GistPageGetOpaque(dist->page)->flags = (is_leaf) ? F_LEAF : 0;
+
+ ptr = ptr->next;
+ }
+ for (; ptr; ptr = ptr->next)
+ {
+ /* Allocate new page */
+ ptr->buffer = gistNewBuffer(state->r);
+ GISTInitBuffer(ptr->buffer, (is_leaf) ? F_LEAF : 0);
+ ptr->page = BufferGetPage(ptr->buffer);
+ ptr->block.blkno = BufferGetBlockNumber(ptr->buffer);
}
- /* make new pages and fills them */
+ /*
+ * Now that we know whick blocks the new pages go to, set up downlink
+ * tuples to point to them.
+ */
for (ptr = dist; ptr; ptr = ptr->next)
{
- int i;
- char *data;
+ ItemPointerSetBlockNumber(&(ptr->itup->t_tid), ptr->block.blkno);
+ GistTupleSetValid(ptr->itup);
+ }
- /* get new page */
- if (ptr->buffer == InvalidBuffer)
+ /*
+ * If this is a root split, we construct the new root page with the
+ * downlinks here directly, instead of requiring the caller to insert
+ * them. Add the new root page to the list along with the child pages.
+ */
+ if (is_rootsplit)
+ {
+ IndexTuple *downlinks;
+ int ndownlinks = 0;
+ int i;
+
+ rootpg.buffer = buffer;
+ rootpg.page = PageGetTempPageCopySpecial(BufferGetPage(rootpg.buffer));
+ GistPageGetOpaque(rootpg.page)->flags = 0;
+
+ /* Prepare a vector of all the downlinks */
+ for (ptr = dist; ptr; ptr = ptr->next)
+ ndownlinks++;
+ downlinks = palloc(sizeof(IndexTuple) * ndownlinks);
+ for (i = 0, ptr = dist; ptr; ptr = ptr->next)
+ downlinks[i++] = ptr->itup;
+
+ rootpg.block.blkno = GIST_ROOT_BLKNO;
+ rootpg.block.num = ndownlinks;
+ rootpg.list = gistfillitupvec(downlinks, ndownlinks,
+ &(rootpg.lenlist));
+ rootpg.itup = NULL;
+
+ rootpg.next = dist;
+ dist = &rootpg;
+ }
+ else
+ {
+ /* Prepare split-info to be returned to caller */
+ for (ptr = dist; ptr; ptr = ptr->next)
{
- ptr->buffer = gistNewBuffer(state->r);
- GISTInitBuffer(ptr->buffer, (is_leaf) ? F_LEAF : 0);
- ptr->page = BufferGetPage(ptr->buffer);
+ GISTPageSplitInfo *si = palloc(sizeof(GISTPageSplitInfo));
+ si->buf = ptr->buffer;
+ si->downlink = ptr->itup;
+ *splitinfo = lappend(*splitinfo, si);
}
- ptr->block.blkno = BufferGetBlockNumber(ptr->buffer);
+ }
- /*
- * fill page, we can do it because all these pages are new (ie not
- * linked in tree or masked by temp page
- */
- data = (char *) (ptr->list);
+ /*
+ * Fill all pages. All the pages are new, ie. freshly allocated empty
+ * pages, or a temporary copy of the old page.
+ */
+ for (ptr = dist; ptr; ptr = ptr->next)
+ {
+ char *data = (char *) (ptr->list);
for (i = 0; i < ptr->block.num; i++)
{
if (PageAddItem(ptr->page, (Item) data, IndexTupleSize((IndexTuple) data), i + FirstOffsetNumber, false, false) == InvalidOffsetNumber)
@@ -371,276 +450,381 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate)
data += IndexTupleSize((IndexTuple) data);
}
- /* set up ItemPointer and remember it for parent */
- ItemPointerSetBlockNumber(&(ptr->itup->t_tid), ptr->block.blkno);
- state->itup[state->ituplen] = ptr->itup;
- state->ituplen++;
- }
+ /* Set up rightlinks */
+ if (ptr->next && ptr->block.blkno != GIST_ROOT_BLKNO)
+ GistPageGetOpaque(ptr->page)->rightlink =
+ ptr->next->block.blkno;
+ else
+ GistPageGetOpaque(ptr->page)->rightlink = oldrlink;
+
+ if (ptr->next && !is_rootsplit)
+ GistMarkFollowRight(ptr->page);
+ else
+ GistClearFollowRight(ptr->page);
- /* saves old rightlink */
- if (state->stack->blkno != GIST_ROOT_BLKNO)
- rrlink = GistPageGetOpaque(dist->page)->rightlink;
+ /*
+ * Copy the NSN of the original page to all pages. The
+ * F_FOLLOW_RIGHT flags ensure that scans will follow the
+ * rightlinks until the downlinks are inserted.
+ */
+ GistPageGetOpaque(ptr->page)->nsn = oldnsn;
+ }
START_CRIT_SECTION();
/*
- * must mark buffers dirty before XLogInsert, even though we'll still
- * be changing their opaque fields below. set up right links.
+ * Must mark buffers dirty before XLogInsert, even though we'll still
+ * be changing their opaque fields below.
*/
for (ptr = dist; ptr; ptr = ptr->next)
- {
MarkBufferDirty(ptr->buffer);
- GistPageGetOpaque(ptr->page)->rightlink = (ptr->next) ?
- ptr->next->block.blkno : rrlink;
- }
+ if (BufferIsValid(leftchildbuf))
+ MarkBufferDirty(leftchildbuf);
- /* restore splitted non-root page */
- if (state->stack->blkno != GIST_ROOT_BLKNO)
- {
- PageRestoreTempPage(dist->page, BufferGetPage(dist->buffer));
- dist->page = BufferGetPage(dist->buffer);
- }
+ /*
+ * The first page in the chain was a temporary working copy meant
+ * to replace the old page. Copy it over the old page.
+ */
+ PageRestoreTempPage(dist->page, BufferGetPage(dist->buffer));
+ dist->page = BufferGetPage(dist->buffer);
+ /* Write the WAL record */
if (RelationNeedsWAL(state->r))
- {
- XLogRecPtr recptr;
- XLogRecData *rdata;
-
- rdata = formSplitRdata(state->r->rd_node, state->stack->blkno,
- is_leaf, &(state->key), dist);
-
- recptr = XLogInsert(RM_GIST_ID, XLOG_GIST_PAGE_SPLIT, rdata);
-
- for (ptr = dist; ptr; ptr = ptr->next)
- {
- PageSetLSN(ptr->page, recptr);
- PageSetTLI(ptr->page, ThisTimeLineID);
- }
- }
+ recptr = gistXLogSplit(state->r->rd_node, blkno, is_leaf,
+ dist, oldrlink, oldnsn, leftchildbuf);
else
- {
- for (ptr = dist; ptr; ptr = ptr->next)
- {
- PageSetLSN(ptr->page, GetXLogRecPtrForTemp());
- }
- }
-
- /* set up NSN */
- oldnsn = GistPageGetOpaque(dist->page)->nsn;
- if (state->stack->blkno == GIST_ROOT_BLKNO)
- /* if root split we should put initial value */
- oldnsn = PageGetLSN(dist->page);
+ recptr = GetXLogRecPtrForTemp();
for (ptr = dist; ptr; ptr = ptr->next)
{
- /* only for last set oldnsn */
- GistPageGetOpaque(ptr->page)->nsn = (ptr->next) ?
- PageGetLSN(ptr->page) : oldnsn;
+ PageSetLSN(ptr->page, recptr);
+ PageSetTLI(ptr->page, ThisTimeLineID);
}
/*
- * release buffers, if it was a root split then release all buffers
- * because we create all buffers
+ * Return the new child buffers to the caller.
+ *
+ * If this was a root split, we've already inserted the downlink
+ * pointers, in the form of a new root page. Therefore we can
+ * release all the new buffers, and keep just the root page locked.
*/
- ptr = (state->stack->blkno == GIST_ROOT_BLKNO) ? dist : dist->next;
- for (; ptr; ptr = ptr->next)
- UnlockReleaseBuffer(ptr->buffer);
-
- if (state->stack->blkno == GIST_ROOT_BLKNO)
+ if (is_rootsplit)
{
- gistnewroot(state->r, state->stack->buffer, state->itup, state->ituplen, &(state->key));
- state->needInsertComplete = false;
+ for (ptr = dist->next; ptr; ptr = ptr->next)
+ UnlockReleaseBuffer(ptr->buffer);
}
-
- END_CRIT_SECTION();
}
else
{
- /* enough space */
+ /*
+ * Enough space. We also get here if ntuples==0.
+ */
START_CRIT_SECTION();
- if (!is_leaf)
- PageIndexTupleDelete(state->stack->page, state->stack->childoffnum);
- gistfillbuffer(state->stack->page, state->itup, state->ituplen, InvalidOffsetNumber);
+ if (OffsetNumberIsValid(oldoffnum))
+ PageIndexTupleDelete(page, oldoffnum);
+ gistfillbuffer(page, itup, ntup, InvalidOffsetNumber);
- MarkBufferDirty(state->stack->buffer);
+ MarkBufferDirty(buffer);
+
+ if (BufferIsValid(leftchildbuf))
+ MarkBufferDirty(leftchildbuf);
if (RelationNeedsWAL(state->r))
{
- OffsetNumber noffs = 0,
- offs[1];
- XLogRecPtr recptr;
- XLogRecData *rdata;
+ OffsetNumber ndeloffs = 0,
+ deloffs[1];
- if (!is_leaf)
+ if (OffsetNumberIsValid(oldoffnum))
{
- /* only on inner page we should delete previous version */
- offs[0] = state->stack->childoffnum;
- noffs = 1;
+ deloffs[0] = oldoffnum;
+ ndeloffs = 1;
}
- rdata = formUpdateRdata(state->r->rd_node, state->stack->buffer,
- offs, noffs,
- state->itup, state->ituplen,
- &(state->key));
+ recptr = gistXLogUpdate(state->r->rd_node, buffer,
+ deloffs, ndeloffs, itup, ntup,
+ leftchildbuf);
- recptr = XLogInsert(RM_GIST_ID, XLOG_GIST_PAGE_UPDATE, rdata);
- PageSetLSN(state->stack->page, recptr);
- PageSetTLI(state->stack->page, ThisTimeLineID);
+ PageSetLSN(page, recptr);
+ PageSetTLI(page, ThisTimeLineID);
}
else
- PageSetLSN(state->stack->page, GetXLogRecPtrForTemp());
-
- if (state->stack->blkno == GIST_ROOT_BLKNO)
- state->needInsertComplete = false;
+ {
+ recptr = GetXLogRecPtrForTemp();
+ PageSetLSN(page, recptr);
+ }
- END_CRIT_SECTION();
+ *splitinfo = NIL;
+ }
- if (state->ituplen > 1)
- { /* previous is_splitted==true */
+ /*
+ * If we inserted the downlink for a child page, set NSN and clear
+ * F_FOLLOW_RIGHT flag on the left child, so that concurrent scans know
+ * to follow the rightlink if and only if they looked at the parent page
+ * before we inserted the downlink.
+ *
+ * Note that we do this *after* writing the WAL record. That means that
+ * the possible full page image in the WAL record does not include
+ * these changes, and they must be replayed even if the page is restored
+ * from the full page image. There's a chicken-and-egg problem: if we
+ * updated the child pages first, we wouldn't know the recptr of the WAL
+ * record we're about to write.
+ */
+ if (BufferIsValid(leftchildbuf))
+ {
+ Page leftpg = BufferGetPage(leftchildbuf);
- /*
- * child was splited, so we must form union for insertion in
- * parent
- */
- IndexTuple newtup = gistunion(state->r, state->itup, state->ituplen, giststate);
+ GistPageGetOpaque(leftpg)->nsn = recptr;
+ GistClearFollowRight(leftpg);
- ItemPointerSetBlockNumber(&(newtup->t_tid), state->stack->blkno);
- state->itup[0] = newtup;
- state->ituplen = 1;
- }
- else if (is_leaf)
- {
- /*
- * itup[0] store key to adjust parent, we set it to valid to
- * correct check by GistTupleIsInvalid macro in gistgetadjusted()
- */
- ItemPointerSetBlockNumber(&(state->itup[0]->t_tid), state->stack->blkno);
- GistTupleSetValid(state->itup[0]);
- }
+ PageSetLSN(leftpg, recptr);
+ PageSetTLI(leftpg, ThisTimeLineID);
}
- return is_splitted;
+
+ END_CRIT_SECTION();
+
+ return is_split;
}
/*
- * returns stack of pages, all pages in stack are pinned, and
- * leaf is X-locked
+ * Workhouse routine for doing insertion into a GiST index. Note that
+ * this routine assumes it is invoked in a short-lived memory context,
+ * so it does not bother releasing palloc'd allocations.
*/
-
static void
-gistfindleaf(GISTInsertState *state, GISTSTATE *giststate)
+gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
{
ItemId iid;
IndexTuple idxtuple;
- GISTPageOpaque opaque;
+ GISTInsertStack firststack;
+ GISTInsertStack *stack;
+ GISTInsertState state;
+ bool xlocked = false;
+
+ memset(&state, 0, sizeof(GISTInsertState));
+ state.freespace = freespace;
+ state.r = r;
+
+ /* Start from the root */
+ firststack.blkno = GIST_ROOT_BLKNO;
+ firststack.lsn.xrecoff = 0;
+ firststack.parent = NULL;
+ state.stack = stack = &firststack;
/*
- * walk down, We don't lock page for a long time, but so we should be
- * ready to recheck path in a bad case... We remember, that page->lsn
- * should never be invalid.
+ * Walk down along the path of smallest penalty, updating the parent
+ * pointers with the key we're inserting as we go. If we crash in the
+ * middle, the tree is consistent, although the possible parent updates
+ * were a waste.
*/
for (;;)
{
- if (XLogRecPtrIsInvalid(state->stack->lsn))
- state->stack->buffer = ReadBuffer(state->r, state->stack->blkno);
- LockBuffer(state->stack->buffer, GIST_SHARE);
- gistcheckpage(state->r, state->stack->buffer);
+ if (XLogRecPtrIsInvalid(stack->lsn))
+ stack->buffer = ReadBuffer(state.r, stack->blkno);
+
+ /*
+ * Be optimistic and grab shared lock first. Swap it for an
+ * exclusive lock later if we need to update the page.
+ */
+ if (!xlocked)
+ {
+ LockBuffer(stack->buffer, GIST_SHARE);
+ gistcheckpage(state.r, stack->buffer);
+ }
+
+ stack->page = (Page) BufferGetPage(stack->buffer);
+ stack->lsn = PageGetLSN(stack->page);
+ Assert(!RelationNeedsWAL(state.r) || !XLogRecPtrIsInvalid(stack->lsn));
- state->stack->page = (Page) BufferGetPage(state->stack->buffer);
- opaque = GistPageGetOpaque(state->stack->page);
+ /*
+ * If this page was split but the downlink was never inserted to
+ * the parent because the inserting backend crashed before doing
+ * that, fix that now.
+ */
+ if (GistFollowRight(stack->page))
+ {
+ if (!xlocked)
+ {
+ LockBuffer(stack->buffer, GIST_UNLOCK);
+ LockBuffer(stack->buffer, GIST_EXCLUSIVE);
+ xlocked = true;
+ /* someone might've completed the split when we unlocked */
+ if (!GistFollowRight(stack->page))
+ continue;
+ }
+ gistfixsplit(&state, giststate);
- state->stack->lsn = PageGetLSN(state->stack->page);
- Assert(!RelationNeedsWAL(state->r) || !XLogRecPtrIsInvalid(state->stack->lsn));
+ UnlockReleaseBuffer(stack->buffer);
+ xlocked = false;
+ state.stack = stack = stack->parent;
+ continue;
+ }
- if (state->stack->blkno != GIST_ROOT_BLKNO &&
- XLByteLT(state->stack->parent->lsn, opaque->nsn))
+ if (stack->blkno != GIST_ROOT_BLKNO &&
+ XLByteLT(stack->parent->lsn,
+ GistPageGetOpaque(stack->page)->nsn))
{
/*
- * caused split non-root page is detected, go up to parent to
- * choose best child
+ * Concurrent split detected. There's no guarantee that the
+ * downlink for this page is consistent with the tuple we're
+ * inserting anymore, so go back to parent and rechoose the
+ * best child.
*/
- UnlockReleaseBuffer(state->stack->buffer);
- state->stack = state->stack->parent;
+ UnlockReleaseBuffer(stack->buffer);
+ xlocked = false;
+ state.stack = stack = stack->parent;
continue;
}
- if (!GistPageIsLeaf(state->stack->page))
+ if (!GistPageIsLeaf(stack->page))
{
/*
- * This is an internal page, so continue to walk down the tree. We
- * find the child node that has the minimum insertion penalty and
- * recursively invoke ourselves to modify that node. Once the
- * recursive call returns, we may need to adjust the parent node
- * for two reasons: the child node split, or the key in this node
- * needs to be adjusted for the newly inserted key below us.
+ * This is an internal page so continue to walk down the tree.
+ * Find the child node that has the minimum insertion penalty.
*/
- GISTInsertStack *item = (GISTInsertStack *) palloc0(sizeof(GISTInsertStack));
-
- state->stack->childoffnum = gistchoose(state->r, state->stack->page, state->itup[0], giststate);
+ BlockNumber childblkno;
+ IndexTuple newtup;
+ GISTInsertStack *item;
- iid = PageGetItemId(state->stack->page, state->stack->childoffnum);
- idxtuple = (IndexTuple) PageGetItem(state->stack->page, iid);
- item->blkno = ItemPointerGetBlockNumber(&(idxtuple->t_tid));
- LockBuffer(state->stack->buffer, GIST_UNLOCK);
+ stack->childoffnum = gistchoose(state.r, stack->page, itup, giststate);
+ iid = PageGetItemId(stack->page, stack->childoffnum);
+ idxtuple = (IndexTuple) PageGetItem(stack->page, iid);
+ childblkno = ItemPointerGetBlockNumber(&(idxtuple->t_tid));
- item->parent = state->stack;
- item->child = NULL;
- if (state->stack)
- state->stack->child = item;
- state->stack = item;
- }
- else
- {
- /* be carefull, during unlock/lock page may be changed... */
- LockBuffer(state->stack->buffer, GIST_UNLOCK);
- LockBuffer(state->stack->buffer, GIST_EXCLUSIVE);
- state->stack->page = (Page) BufferGetPage(state->stack->buffer);
- opaque = GistPageGetOpaque(state->stack->page);
+ /*
+ * Check that it's not a leftover invalid tuple from pre-9.1
+ */
+ if (GistTupleIsInvalid(idxtuple))
+ ereport(ERROR,
+ (errmsg("index \"%s\" contains an inner tuple marked as invalid",
+ RelationGetRelationName(r)),
+ errdetail("This is caused by an incomplete page split at crash recovery before upgrading to 9.1."),
+ errhint("Please REINDEX it.")));
- if (state->stack->blkno == GIST_ROOT_BLKNO)
+ /*
+ * Check that the key representing the target child node is
+ * consistent with the key we're inserting. Update it if it's not.
+ */
+ newtup = gistgetadjusted(state.r, idxtuple, itup, giststate);
+ if (newtup)
{
/*
- * the only page can become inner instead of leaf is a root
- * page, so for root we should recheck it
+ * Swap shared lock for an exclusive one. Beware, the page
+ * may change while we unlock/lock the page...
*/
- if (!GistPageIsLeaf(state->stack->page))
+ if (!xlocked)
{
- /*
- * very rarely situation: during unlock/lock index with
- * number of pages = 1 was increased
- */
- LockBuffer(state->stack->buffer, GIST_UNLOCK);
- continue;
- }
+ LockBuffer(stack->buffer, GIST_UNLOCK);
+ LockBuffer(stack->buffer, GIST_EXCLUSIVE);
+ xlocked = true;
+ stack->page = (Page) BufferGetPage(stack->buffer);
+ if (!XLByteEQ(PageGetLSN(stack->page), stack->lsn))
+ {
+ /* the page was changed while we unlocked it, retry */
+ continue;
+ }
+ }
/*
- * we don't need to check root split, because checking
- * leaf/inner is enough to recognize split for root
+ * Update the tuple.
+ *
+ * gistinserthere() might have to split the page to make the
+ * updated tuple fit. It will adjust the stack so that after
+ * the call, we'll be holding a lock on the page containing
+ * the tuple, which might have moved right.
+ *
+ * Except if this causes a root split, gistinserthere()
+ * returns 'true'. In that case, stack only holds the new
+ * root, and the child page was released. Have to start
+ * all over.
*/
-
+ if (gistinserttuples(&state, stack, giststate, &newtup, 1,
+ stack->childoffnum, InvalidBuffer))
+ {
+ UnlockReleaseBuffer(stack->buffer);
+ xlocked = false;
+ state.stack = stack = stack->parent;
+ continue;
+ }
}
- else if (XLByteLT(state->stack->parent->lsn, opaque->nsn))
+ LockBuffer(stack->buffer, GIST_UNLOCK);
+ xlocked = false;
+
+ /* descend to the chosen child */
+ item = (GISTInsertStack *) palloc0(sizeof(GISTInsertStack));
+ item->blkno = childblkno;
+ item->parent = stack;
+ state.stack = stack = item;
+ }
+ else
+ {
+ /*
+ * Leaf page. Insert the new key. We've already updated all the
+ * parents on the way down, but we might have to split the page
+ * if it doesn't fit. gistinserthere() will take care of that.
+ */
+
+ /*
+ * Swap shared lock for an exclusive one. Be careful, the page
+ * may change while we unlock/lock the page...
+ */
+ if (!xlocked)
{
- /*
- * detecting split during unlock/lock, so we should find
- * better child on parent
- */
+ LockBuffer(stack->buffer, GIST_UNLOCK);
+ LockBuffer(stack->buffer, GIST_EXCLUSIVE);
+ xlocked = true;
+ stack->page = (Page) BufferGetPage(stack->buffer);
+ stack->lsn = PageGetLSN(stack->page);
- /* forget buffer */
- UnlockReleaseBuffer(state->stack->buffer);
+ if (stack->blkno == GIST_ROOT_BLKNO)
+ {
+ /*
+ * the only page that can become inner instead of leaf
+ * is the root page, so for root we should recheck it
+ */
+ if (!GistPageIsLeaf(stack->page))
+ {
+ /*
+ * very rare situation: during unlock/lock index with
+ * number of pages = 1 was increased
+ */
+ LockBuffer(stack->buffer, GIST_UNLOCK);
+ xlocked = false;
+ continue;
+ }
- state->stack = state->stack->parent;
- continue;
+ /*
+ * we don't need to check root split, because checking
+ * leaf/inner is enough to recognize split for root
+ */
+ }
+ else if (GistFollowRight(stack->page) ||
+ XLByteLT(stack->parent->lsn,
+ GistPageGetOpaque(stack->page)->nsn))
+ {
+ /*
+ * The page was split while we momentarily unlocked the
+ * page. Go back to parent.
+ */
+ UnlockReleaseBuffer(stack->buffer);
+ xlocked = false;
+ state.stack = stack = stack->parent;
+ continue;
+ }
}
- state->stack->lsn = PageGetLSN(state->stack->page);
+ /* now state.stack->(page, buffer and blkno) points to leaf page */
- /* ok we found a leaf page and it X-locked */
+ gistinserttuples(&state, stack, giststate, &itup, 1,
+ InvalidOffsetNumber, InvalidBuffer);
+ LockBuffer(stack->buffer, GIST_UNLOCK);
+
+ /* Release any pins we might still hold before exiting */
+ for (; stack; stack = stack->parent)
+ ReleaseBuffer(stack->buffer);
break;
}
}
-
- /* now state->stack->(page, buffer and blkno) points to leaf page */
}
/*
@@ -648,7 +832,7 @@ gistfindleaf(GISTInsertState *state, GISTSTATE *giststate)
*
* returns from the beginning of closest parent;
*
- * To prevent deadlocks, this should lock only one page simultaneously.
+ * To prevent deadlocks, this should lock only one page at a time.
*/
GISTInsertStack *
gistFindPath(Relation r, BlockNumber child)
@@ -683,6 +867,13 @@ gistFindPath(Relation r, BlockNumber child)
top->lsn = PageGetLSN(page);
+ /*
+ * If F_FOLLOW_RIGHT is set, the page to the right doesn't have a
+ * downlink. This should not normally happen..
+ */
+ if (GistFollowRight(page))
+ elog(ERROR, "concurrent GiST page split was incomplete");
+
if (top->parent && XLByteLT(top->parent->lsn, GistPageGetOpaque(page)->nsn) &&
GistPageGetOpaque(page)->rightlink != InvalidBlockNumber /* sanity check */ )
{
@@ -711,8 +902,6 @@ gistFindPath(Relation r, BlockNumber child)
ptr = top;
while (ptr->parent)
{
- /* set child link */
- ptr->parent->child = ptr;
/* move childoffnum.. */
if (ptr == top)
{
@@ -754,17 +943,16 @@ gistFindPath(Relation r, BlockNumber child)
return NULL;
}
-
/*
- * Returns X-locked parent of stack page
+ * Updates the stack so that child->parent is the correct parent of the
+ * child. child->parent must be exclusively locked on entry, and will
+ * remain so at exit, but it might not be the same page anymore.
*/
-
static void
gistFindCorrectParent(Relation r, GISTInsertStack *child)
{
GISTInsertStack *parent = child->parent;
- LockBuffer(parent->buffer, GIST_EXCLUSIVE);
gistcheckpage(r, parent->buffer);
parent->page = (Page) BufferGetPage(parent->buffer);
@@ -836,83 +1024,231 @@ gistFindCorrectParent(Relation r, GISTInsertStack *child)
/* install new chain of parents to stack */
child->parent = parent;
- parent->child = child;
/* make recursive call to normal processing */
+ LockBuffer(child->parent->buffer, GIST_EXCLUSIVE);
gistFindCorrectParent(r, child);
}
return;
}
-void
-gistmakedeal(GISTInsertState *state, GISTSTATE *giststate)
+/*
+ * Form a downlink pointer for the page in 'buf'.
+ */
+static IndexTuple
+gistformdownlink(Relation rel, Buffer buf, GISTSTATE *giststate,
+ GISTInsertStack *stack)
{
- int is_splitted;
- ItemId iid;
- IndexTuple oldtup,
- newtup;
+ Page page = BufferGetPage(buf);
+ OffsetNumber maxoff;
+ OffsetNumber offset;
+ IndexTuple downlink = NULL;
- /* walk up */
- while (true)
+ maxoff = PageGetMaxOffsetNumber(page);
+ for (offset = FirstOffsetNumber; offset <= maxoff; offset = OffsetNumberNext(offset))
{
- /*
- * After this call: 1. if child page was splited, then itup contains
- * keys for each page 2. if child page wasn't splited, then itup
- * contains additional for adjustment of current key
- */
-
- if (state->stack->parent)
+ IndexTuple ituple = (IndexTuple)
+ PageGetItem(page, PageGetItemId(page, offset));
+ if (downlink == NULL)
+ downlink = CopyIndexTuple(ituple);
+ else
{
- /*
- * X-lock parent page before proceed child, gistFindCorrectParent
- * should find and lock it
- */
- gistFindCorrectParent(state->r, state->stack);
+ IndexTuple newdownlink;
+ newdownlink = gistgetadjusted(rel, downlink, ituple,
+ giststate);
+ if (newdownlink)
+ downlink = newdownlink;
}
- is_splitted = gistplacetopage(state, giststate);
+ }
+
+ /*
+ * If the page is completely empty, we can't form a meaningful
+ * downlink for it. But we have to insert a downlink for the page.
+ * Any key will do, as long as its consistent with the downlink of
+ * parent page, so that we can legally insert it to the parent.
+ * A minimal one that matches as few scans as possible would be best,
+ * to keep scans from doing useless work, but we don't know how to
+ * construct that. So we just use the downlink of the original page
+ * that was split - that's as far from optimal as it can get but will
+ * do..
+ */
+ if (!downlink)
+ {
+ ItemId iid;
+
+ LockBuffer(stack->parent->buffer, GIST_EXCLUSIVE);
+ gistFindCorrectParent(rel, stack);
+ iid = PageGetItemId(stack->parent->page, stack->parent->childoffnum);
+ downlink = (IndexTuple) PageGetItem(stack->parent->page, iid);
+ downlink = CopyIndexTuple(downlink);
+ LockBuffer(stack->parent->buffer, GIST_UNLOCK);
+ }
- /* parent locked above, so release child buffer */
- UnlockReleaseBuffer(state->stack->buffer);
+ ItemPointerSetBlockNumber(&(downlink->t_tid), BufferGetBlockNumber(buf));
+ GistTupleSetValid(downlink);
- /* pop parent page from stack */
- state->stack = state->stack->parent;
+ return downlink;
+}
- /* stack is void */
- if (!state->stack)
- break;
- /*
- * child did not split, so we can check is it needed to update parent
- * tuple
- */
- if (!is_splitted)
- {
- /* parent's tuple */
- iid = PageGetItemId(state->stack->page, state->stack->childoffnum);
- oldtup = (IndexTuple) PageGetItem(state->stack->page, iid);
- newtup = gistgetadjusted(state->r, oldtup, state->itup[0], giststate);
-
- if (!newtup)
- { /* not need to update key */
- LockBuffer(state->stack->buffer, GIST_UNLOCK);
- break;
- }
+/*
+ * Complete the incomplete split of state->stack->page.
+ */
+static void
+gistfixsplit(GISTInsertState *state, GISTSTATE *giststate)
+{
+ GISTInsertStack *stack = state->stack;
+ Buffer buf;
+ Page page;
+ List *splitinfo = NIL;
+
+ elog(LOG, "fixing incomplete split in index \"%s\", block %u",
+ RelationGetRelationName(state->r), stack->blkno);
- state->itup[0] = newtup;
+ Assert(GistFollowRight(stack->page));
+ Assert(OffsetNumberIsValid(stack->parent->childoffnum));
+
+ buf = stack->buffer;
+
+ /*
+ * Read the chain of split pages, following the rightlinks. Construct
+ * a downlink tuple for each page.
+ */
+ for (;;)
+ {
+ GISTPageSplitInfo *si = palloc(sizeof(GISTPageSplitInfo));
+ IndexTuple downlink;
+
+ page = BufferGetPage(buf);
+
+ /* Form the new downlink tuples to insert to parent */
+ downlink = gistformdownlink(state->r, buf, giststate, stack);
+
+ si->buf = buf;
+ si->downlink = downlink;
+
+ splitinfo = lappend(splitinfo, si);
+
+ if (GistFollowRight(page))
+ {
+ /* lock next page */
+ buf = ReadBuffer(state->r, GistPageGetOpaque(page)->rightlink);
+ LockBuffer(buf, GIST_EXCLUSIVE);
}
- } /* while */
+ else
+ break;
+ }
+
+ /* Insert the downlinks */
+ gistfinishsplit(state, stack, giststate, splitinfo);
+}
+
+/*
+ * Insert tuples to stack->buffer. If 'oldoffnum' is valid, the new tuples
+ * replace an old tuple at oldoffnum. The caller must hold an exclusive lock
+ * on the page.
+ *
+ * If leftchild is valid, we're inserting/updating the downlink for the
+ * page to the right of leftchild. We clear the F_FOLLOW_RIGHT flag and
+ * update NSN on leftchild, atomically with the insertion of the downlink.
+ *
+ * Returns 'true' if the page had to be split. On return, we will continue
+ * to hold an exclusive lock on state->stack->buffer, but if we had to split
+ * the page, it might not contain the tuple we just inserted/updated.
+ */
+static bool
+gistinserttuples(GISTInsertState *state, GISTInsertStack *stack,
+ GISTSTATE *giststate,
+ IndexTuple *tuples, int ntup, OffsetNumber oldoffnum,
+ Buffer leftchild)
+{
+ List *splitinfo;
+ bool is_split;
+
+ is_split = gistplacetopage(state, giststate, stack->buffer,
+ tuples, ntup, oldoffnum,
+ leftchild,
+ &splitinfo);
+ if (splitinfo)
+ gistfinishsplit(state, stack, giststate, splitinfo);
+
+ return is_split;
+}
+
+/*
+ * Finish an incomplete split by inserting/updating the downlinks in
+ * parent page. 'splitinfo' contains all the child pages, exclusively-locked,
+ * involved in the split, from left-to-right.
+ */
+static void
+gistfinishsplit(GISTInsertState *state, GISTInsertStack *stack,
+ GISTSTATE *giststate, List *splitinfo)
+{
+ ListCell *lc;
+ List *reversed;
+ GISTPageSplitInfo *right;
+ GISTPageSplitInfo *left;
+ IndexTuple tuples[2];
+
+ /* A split always contains at least two halves */
+ Assert(list_length(splitinfo) >= 2);
+
+ /*
+ * We need to insert downlinks for each new page, and update the
+ * downlink for the original (leftmost) page in the split. Begin at
+ * the rightmost page, inserting one downlink at a time until there's
+ * only two pages left. Finally insert the downlink for the last new
+ * page and update the downlink for the original page as one operation.
+ */
- /* release all parent buffers */
- while (state->stack)
+ /* for convenience, create a copy of the list in reverse order */
+ reversed = NIL;
+ foreach(lc, splitinfo)
{
- ReleaseBuffer(state->stack->buffer);
- state->stack = state->stack->parent;
+ reversed = lcons(lfirst(lc), reversed);
}
- /* say to xlog that insert is completed */
- if (state->needInsertComplete && RelationNeedsWAL(state->r))
- gistxlogInsertCompletion(state->r->rd_node, &(state->key), 1);
+ LockBuffer(stack->parent->buffer, GIST_EXCLUSIVE);
+ gistFindCorrectParent(state->r, stack);
+
+ while(list_length(reversed) > 2)
+ {
+ right = (GISTPageSplitInfo *) linitial(reversed);
+ left = (GISTPageSplitInfo *) lsecond(reversed);
+
+ if (gistinserttuples(state, stack->parent, giststate,
+ &right->downlink, 1,
+ InvalidOffsetNumber,
+ left->buf))
+ {
+ /*
+ * If the parent page was split, need to relocate the original
+ * parent pointer.
+ */
+ gistFindCorrectParent(state->r, stack);
+ }
+ UnlockReleaseBuffer(right->buf);
+ reversed = list_delete_first(reversed);
+ }
+
+ right = (GISTPageSplitInfo *) linitial(reversed);
+ left = (GISTPageSplitInfo *) lsecond(reversed);
+
+ /*
+ * Finally insert downlink for the remaining right page and update the
+ * downlink for the original page to not contain the tuples that were
+ * moved to the new pages.
+ */
+ tuples[0] = left->downlink;
+ tuples[1] = right->downlink;
+ gistinserttuples(state, stack->parent, giststate,
+ tuples, 2,
+ stack->parent->childoffnum,
+ left->buf);
+ LockBuffer(stack->parent->buffer, GIST_UNLOCK);
+ UnlockReleaseBuffer(right->buf);
+ Assert(left->buf == stack->buffer);
}
/*
@@ -963,8 +1299,7 @@ gistSplit(Relation r,
ROTATEDIST(res);
res->block.num = v.splitVector.spl_nright;
res->list = gistfillitupvec(rvectup, v.splitVector.spl_nright, &(res->lenlist));
- res->itup = (v.spl_rightvalid) ? gistFormTuple(giststate, r, v.spl_rattr, v.spl_risnull, false)
- : gist_form_invalid_tuple(GIST_ROOT_BLKNO);
+ res->itup = gistFormTuple(giststate, r, v.spl_rattr, v.spl_risnull, false);
}
if (!gistfitpage(lvectup, v.splitVector.spl_nleft))
@@ -986,50 +1321,12 @@ gistSplit(Relation r,
ROTATEDIST(res);
res->block.num = v.splitVector.spl_nleft;
res->list = gistfillitupvec(lvectup, v.splitVector.spl_nleft, &(res->lenlist));
- res->itup = (v.spl_leftvalid) ? gistFormTuple(giststate, r, v.spl_lattr, v.spl_lisnull, false)
- : gist_form_invalid_tuple(GIST_ROOT_BLKNO);
+ res->itup = gistFormTuple(giststate, r, v.spl_lattr, v.spl_lisnull, false);
}
return res;
}
-/*
- * buffer must be pinned and locked by caller
- */
-void
-gistnewroot(Relation r, Buffer buffer, IndexTuple *itup, int len, ItemPointer key)
-{
- Page page;
-
- Assert(BufferGetBlockNumber(buffer) == GIST_ROOT_BLKNO);
- page = BufferGetPage(buffer);
-
- START_CRIT_SECTION();
-
- GISTInitBuffer(buffer, 0);
- gistfillbuffer(page, itup, len, FirstOffsetNumber);
-
- MarkBufferDirty(buffer);
-
- if (RelationNeedsWAL(r))
- {
- XLogRecPtr recptr;
- XLogRecData *rdata;
-
- rdata = formUpdateRdata(r->rd_node, buffer,
- NULL, 0,
- itup, len, key);
-
- recptr = XLogInsert(RM_GIST_ID, XLOG_GIST_NEW_ROOT, rdata);
- PageSetLSN(page, recptr);
- PageSetTLI(page, ThisTimeLineID);
- }
- else
- PageSetLSN(page, GetXLogRecPtrForTemp());
-
- END_CRIT_SECTION();
-}
-
/*
* Fill a GISTSTATE with information about the index
*/
diff --git a/src/backend/access/gist/gistget.c b/src/backend/access/gist/gistget.c
index 56921cfee0..5061003a3b 100644
--- a/src/backend/access/gist/gistget.c
+++ b/src/backend/access/gist/gistget.c
@@ -254,9 +254,15 @@ gistScanPage(IndexScanDesc scan, GISTSearchItem *pageItem, double *myDistances,
page = BufferGetPage(buffer);
opaque = GistPageGetOpaque(page);
- /* check if page split occurred since visit to parent */
+ /*
+ * Check if we need to follow the rightlink. We need to follow it if the
+ * page was concurrently split since we visited the parent (in which case
+ * parentlsn < nsn), or if the the system crashed after a page split but
+ * before the downlink was inserted into the parent.
+ */
if (!XLogRecPtrIsInvalid(pageItem->data.parentlsn) &&
- XLByteLT(pageItem->data.parentlsn, opaque->nsn) &&
+ (GistFollowRight(page) ||
+ XLByteLT(pageItem->data.parentlsn, opaque->nsn)) &&
opaque->rightlink != InvalidBlockNumber /* sanity check */ )
{
/* There was a page split, follow right link to add pages */
diff --git a/src/backend/access/gist/gistsplit.c b/src/backend/access/gist/gistsplit.c
index 0ce317cdbc..ac9a657841 100644
--- a/src/backend/access/gist/gistsplit.c
+++ b/src/backend/access/gist/gistsplit.c
@@ -499,58 +499,6 @@ gistSplitHalf(GIST_SPLITVEC *v, int len)
v->spl_left[v->spl_nleft++] = i;
}
-/*
- * if it was invalid tuple then we need special processing.
- * We move all invalid tuples on right page.
- *
- * if there is no place on left page, gistSplit will be called one more
- * time for left page.
- *
- * Normally, we never exec this code, but after crash replay it's possible
- * to get 'invalid' tuples (probability is low enough)
- */
-static void
-gistSplitByInvalid(GISTSTATE *giststate, GistSplitVector *v, IndexTuple *itup, int len)
-{
- int i;
- static OffsetNumber offInvTuples[MaxOffsetNumber];
- int nOffInvTuples = 0;
-
- for (i = 1; i <= len; i++)
- if (GistTupleIsInvalid(itup[i - 1]))
- offInvTuples[nOffInvTuples++] = i;
-
- if (nOffInvTuples == len)
- {
- /* corner case, all tuples are invalid */
- v->spl_rightvalid = v->spl_leftvalid = false;
- gistSplitHalf(&v->splitVector, len);
- }
- else
- {
- GistSplitUnion gsvp;
-
- v->splitVector.spl_right = offInvTuples;
- v->splitVector.spl_nright = nOffInvTuples;
- v->spl_rightvalid = false;
-
- v->splitVector.spl_left = (OffsetNumber *) palloc(len * sizeof(OffsetNumber));
- v->splitVector.spl_nleft = 0;
- for (i = 1; i <= len; i++)
- if (!GistTupleIsInvalid(itup[i - 1]))
- v->splitVector.spl_left[v->splitVector.spl_nleft++] = i;
- v->spl_leftvalid = true;
-
- gsvp.equiv = NULL;
- gsvp.attr = v->spl_lattr;
- gsvp.len = v->splitVector.spl_nleft;
- gsvp.entries = v->splitVector.spl_left;
- gsvp.isnull = v->spl_lisnull;
-
- gistunionsubkeyvec(giststate, itup, &gsvp, 0);
- }
-}
-
/*
* trys to split page by attno key, in a case of null
* values move its to separate page.
@@ -568,12 +516,6 @@ gistSplitByKey(Relation r, Page page, IndexTuple *itup, int len, GISTSTATE *gist
Datum datum;
bool IsNull;
- if (!GistPageIsLeaf(page) && GistTupleIsInvalid(itup[i - 1]))
- {
- gistSplitByInvalid(giststate, v, itup, len);
- return;
- }
-
datum = index_getattr(itup[i - 1], attno + 1, giststate->tupdesc, &IsNull);
gistdentryinit(giststate, attno, &(entryvec->vector[i]),
datum, r, page, i,
@@ -582,8 +524,6 @@ gistSplitByKey(Relation r, Page page, IndexTuple *itup, int len, GISTSTATE *gist
offNullTuples[nOffNullTuples++] = i;
}
- v->spl_leftvalid = v->spl_rightvalid = true;
-
if (nOffNullTuples == len)
{
/*
diff --git a/src/backend/access/gist/gistutil.c b/src/backend/access/gist/gistutil.c
index d488bbb420..8a0d356860 100644
--- a/src/backend/access/gist/gistutil.c
+++ b/src/backend/access/gist/gistutil.c
@@ -152,7 +152,7 @@ gistfillitupvec(IndexTuple *vec, int veclen, int *memlen)
* invalid tuple. Resulting Datums aren't compressed.
*/
-bool
+void
gistMakeUnionItVec(GISTSTATE *giststate, IndexTuple *itvec, int len, int startkey,
Datum *attr, bool *isnull)
{
@@ -180,10 +180,6 @@ gistMakeUnionItVec(GISTSTATE *giststate, IndexTuple *itvec, int len, int startke
Datum datum;
bool IsNull;
- if (GistTupleIsInvalid(itvec[j]))
- return FALSE; /* signals that union with invalid tuple =>
- * result is invalid */
-
datum = index_getattr(itvec[j], i + 1, giststate->tupdesc, &IsNull);
if (IsNull)
continue;
@@ -218,8 +214,6 @@ gistMakeUnionItVec(GISTSTATE *giststate, IndexTuple *itvec, int len, int startke
isnull[i] = FALSE;
}
}
-
- return TRUE;
}
/*
@@ -231,8 +225,7 @@ gistunion(Relation r, IndexTuple *itvec, int len, GISTSTATE *giststate)
{
memset(isnullS, TRUE, sizeof(bool) * giststate->tupdesc->natts);
- if (!gistMakeUnionItVec(giststate, itvec, len, 0, attrS, isnullS))
- return gist_form_invalid_tuple(InvalidBlockNumber);
+ gistMakeUnionItVec(giststate, itvec, len, 0, attrS, isnullS);
return gistFormTuple(giststate, r, attrS, isnullS, false);
}
@@ -328,9 +321,6 @@ gistgetadjusted(Relation r, IndexTuple oldtup, IndexTuple addtup, GISTSTATE *gis
IndexTuple newtup = NULL;
int i;
- if (GistTupleIsInvalid(oldtup) || GistTupleIsInvalid(addtup))
- return gist_form_invalid_tuple(ItemPointerGetBlockNumber(&(oldtup->t_tid)));
-
gistDeCompressAtt(giststate, r, oldtup, NULL,
(OffsetNumber) 0, oldentries, oldisnull);
@@ -401,14 +391,6 @@ gistchoose(Relation r, Page p, IndexTuple it, /* it has compressed entry */
int j;
IndexTuple itup = (IndexTuple) PageGetItem(p, PageGetItemId(p, i));
- if (!GistPageIsLeaf(p) && GistTupleIsInvalid(itup))
- {
- ereport(LOG,
- (errmsg("index \"%s\" needs VACUUM or REINDEX to finish crash recovery",
- RelationGetRelationName(r))));
- continue;
- }
-
sum_grow = 0;
for (j = 0; j < r->rd_att->natts; j++)
{
@@ -521,7 +503,11 @@ gistFormTuple(GISTSTATE *giststate, Relation r,
}
res = index_form_tuple(giststate->tupdesc, compatt, isnull);
- GistTupleSetValid(res);
+ /*
+ * The offset number on tuples on internal pages is unused. For historical
+ * reasons, it is set 0xffff.
+ */
+ ItemPointerSetOffsetNumber( &(res->t_tid), 0xffff);
return res;
}
diff --git a/src/backend/access/gist/gistvacuum.c b/src/backend/access/gist/gistvacuum.c
index e02e72d431..86af414dce 100644
--- a/src/backend/access/gist/gistvacuum.c
+++ b/src/backend/access/gist/gistvacuum.c
@@ -26,13 +26,6 @@
#include "utils/memutils.h"
-typedef struct GistBulkDeleteResult
-{
- IndexBulkDeleteResult std; /* common state */
- bool needReindex;
-} GistBulkDeleteResult;
-
-
/*
* VACUUM cleanup: update FSM
*/
@@ -40,7 +33,7 @@ Datum
gistvacuumcleanup(PG_FUNCTION_ARGS)
{
IndexVacuumInfo *info = (IndexVacuumInfo *) PG_GETARG_POINTER(0);
- GistBulkDeleteResult *stats = (GistBulkDeleteResult *) PG_GETARG_POINTER(1);
+ IndexBulkDeleteResult *stats = (IndexBulkDeleteResult *) PG_GETARG_POINTER(1);
Relation rel = info->index;
BlockNumber npages,
blkno;
@@ -56,10 +49,10 @@ gistvacuumcleanup(PG_FUNCTION_ARGS)
/* Set up all-zero stats if gistbulkdelete wasn't called */
if (stats == NULL)
{
- stats = (GistBulkDeleteResult *) palloc0(sizeof(GistBulkDeleteResult));
+ stats = (IndexBulkDeleteResult *) palloc0(sizeof(IndexBulkDeleteResult));
/* use heap's tuple count */
- stats->std.num_index_tuples = info->num_heap_tuples;
- stats->std.estimated_count = info->estimated_count;
+ stats->num_index_tuples = info->num_heap_tuples;
+ stats->estimated_count = info->estimated_count;
/*
* XXX the above is wrong if index is partial. Would it be OK to just
@@ -67,11 +60,6 @@ gistvacuumcleanup(PG_FUNCTION_ARGS)
*/
}
- if (stats->needReindex)
- ereport(NOTICE,
- (errmsg("index \"%s\" needs VACUUM FULL or REINDEX to finish crash recovery",
- RelationGetRelationName(rel))));
-
/*
* Need lock unless it's local to this backend.
*/
@@ -112,10 +100,10 @@ gistvacuumcleanup(PG_FUNCTION_ARGS)
IndexFreeSpaceMapVacuum(info->index);
/* return statistics */
- stats->std.pages_free = totFreePages;
+ stats->pages_free = totFreePages;
if (needLock)
LockRelationForExtension(rel, ExclusiveLock);
- stats->std.num_pages = RelationGetNumberOfBlocks(rel);
+ stats->num_pages = RelationGetNumberOfBlocks(rel);
if (needLock)
UnlockRelationForExtension(rel, ExclusiveLock);
@@ -135,7 +123,7 @@ pushStackIfSplited(Page page, GistBDItem *stack)
GISTPageOpaque opaque = GistPageGetOpaque(page);
if (stack->blkno != GIST_ROOT_BLKNO && !XLogRecPtrIsInvalid(stack->parentlsn) &&
- XLByteLT(stack->parentlsn, opaque->nsn) &&
+ (GistFollowRight(page) || XLByteLT(stack->parentlsn, opaque->nsn)) &&
opaque->rightlink != InvalidBlockNumber /* sanity check */ )
{
/* split page detected, install right link to the stack */
@@ -162,7 +150,7 @@ Datum
gistbulkdelete(PG_FUNCTION_ARGS)
{
IndexVacuumInfo *info = (IndexVacuumInfo *) PG_GETARG_POINTER(0);
- GistBulkDeleteResult *stats = (GistBulkDeleteResult *) PG_GETARG_POINTER(1);
+ IndexBulkDeleteResult *stats = (IndexBulkDeleteResult *) PG_GETARG_POINTER(1);
IndexBulkDeleteCallback callback = (IndexBulkDeleteCallback) PG_GETARG_POINTER(2);
void *callback_state = (void *) PG_GETARG_POINTER(3);
Relation rel = info->index;
@@ -171,10 +159,10 @@ gistbulkdelete(PG_FUNCTION_ARGS)
/* first time through? */
if (stats == NULL)
- stats = (GistBulkDeleteResult *) palloc0(sizeof(GistBulkDeleteResult));
+ stats = (IndexBulkDeleteResult *) palloc0(sizeof(IndexBulkDeleteResult));
/* we'll re-count the tuples each time */
- stats->std.estimated_count = false;
- stats->std.num_index_tuples = 0;
+ stats->estimated_count = false;
+ stats->num_index_tuples = 0;
stack = (GistBDItem *) palloc0(sizeof(GistBDItem));
stack->blkno = GIST_ROOT_BLKNO;
@@ -232,10 +220,10 @@ gistbulkdelete(PG_FUNCTION_ARGS)
{
todelete[ntodelete] = i - ntodelete;
ntodelete++;
- stats->std.tuples_removed += 1;
+ stats->tuples_removed += 1;
}
else
- stats->std.num_index_tuples += 1;
+ stats->num_index_tuples += 1;
}
if (ntodelete)
@@ -250,22 +238,13 @@ gistbulkdelete(PG_FUNCTION_ARGS)
if (RelationNeedsWAL(rel))
{
- XLogRecData *rdata;
XLogRecPtr recptr;
- gistxlogPageUpdate *xlinfo;
- rdata = formUpdateRdata(rel->rd_node, buffer,
+ recptr = gistXLogUpdate(rel->rd_node, buffer,
todelete, ntodelete,
- NULL, 0,
- NULL);
- xlinfo = (gistxlogPageUpdate *) rdata->next->data;
-
- recptr = XLogInsert(RM_GIST_ID, XLOG_GIST_PAGE_UPDATE, rdata);
+ NULL, 0, InvalidBuffer);
PageSetLSN(page, recptr);
PageSetTLI(page, ThisTimeLineID);
-
- pfree(xlinfo);
- pfree(rdata);
}
else
PageSetLSN(page, GetXLogRecPtrForTemp());
@@ -293,7 +272,11 @@ gistbulkdelete(PG_FUNCTION_ARGS)
stack->next = ptr;
if (GistTupleIsInvalid(idxtuple))
- stats->needReindex = true;
+ ereport(LOG,
+ (errmsg("index \"%s\" contains an inner tuple marked as invalid",
+ RelationGetRelationName(rel)),
+ errdetail("This is caused by an incomplete page split at crash recovery before upgrading to 9.1."),
+ errhint("Please REINDEX it.")));
}
}
diff --git a/src/backend/access/gist/gistxlog.c b/src/backend/access/gist/gistxlog.c
index a90303e547..7d25728d8d 100644
--- a/src/backend/access/gist/gistxlog.c
+++ b/src/backend/access/gist/gistxlog.c
@@ -20,15 +20,6 @@
#include "utils/memutils.h"
#include "utils/rel.h"
-
-typedef struct
-{
- gistxlogPageUpdate *data;
- int len;
- IndexTuple *itup;
- OffsetNumber *todelete;
-} PageUpdateRecord;
-
typedef struct
{
gistxlogPage *header;
@@ -41,144 +32,37 @@ typedef struct
NewPage *page;
} PageSplitRecord;
-/* track for incomplete inserts, idea was taken from nbtxlog.c */
-
-typedef struct gistIncompleteInsert
-{
- RelFileNode node;
- BlockNumber origblkno; /* for splits */
- ItemPointerData key;
- int lenblk;
- BlockNumber *blkno;
- XLogRecPtr lsn;
- BlockNumber *path;
- int pathlen;
-} gistIncompleteInsert;
-
-
static MemoryContext opCtx; /* working memory for operations */
-static MemoryContext insertCtx; /* holds incomplete_inserts list */
-static List *incomplete_inserts;
-
-
-#define ItemPointerEQ(a, b) \
- ( ItemPointerGetOffsetNumber(a) == ItemPointerGetOffsetNumber(b) && \
- ItemPointerGetBlockNumber (a) == ItemPointerGetBlockNumber(b) )
-
+/*
+ * Replay the clearing of F_FOLLOW_RIGHT flag.
+ */
static void
-pushIncompleteInsert(RelFileNode node, XLogRecPtr lsn, ItemPointerData key,
- BlockNumber *blkno, int lenblk,
- PageSplitRecord *xlinfo /* to extract blkno info */ )
+gistRedoClearFollowRight(RelFileNode node, XLogRecPtr lsn,
+ BlockNumber leftblkno)
{
- MemoryContext oldCxt;
- gistIncompleteInsert *ninsert;
+ Buffer buffer;
- if (!ItemPointerIsValid(&key))
+ buffer = XLogReadBuffer(node, leftblkno, false);
+ if (BufferIsValid(buffer))
+ {
+ Page page = (Page) BufferGetPage(buffer);
/*
- * if key is null then we should not store insertion as incomplete,
- * because it's a vacuum operation..
+ * Note that we still update the page even if page LSN is equal to the
+ * LSN of this record, because the updated NSN is not included in the
+ * full page image.
*/
- return;
-
- oldCxt = MemoryContextSwitchTo(insertCtx);
- ninsert = (gistIncompleteInsert *) palloc(sizeof(gistIncompleteInsert));
-
- ninsert->node = node;
- ninsert->key = key;
- ninsert->lsn = lsn;
-
- if (lenblk && blkno)
- {
- ninsert->lenblk = lenblk;
- ninsert->blkno = (BlockNumber *) palloc(sizeof(BlockNumber) * ninsert->lenblk);
- memcpy(ninsert->blkno, blkno, sizeof(BlockNumber) * ninsert->lenblk);
- ninsert->origblkno = *blkno;
- }
- else
- {
- int i;
-
- Assert(xlinfo);
- ninsert->lenblk = xlinfo->data->npage;
- ninsert->blkno = (BlockNumber *) palloc(sizeof(BlockNumber) * ninsert->lenblk);
- for (i = 0; i < ninsert->lenblk; i++)
- ninsert->blkno[i] = xlinfo->page[i].header->blkno;
- ninsert->origblkno = xlinfo->data->origblkno;
- }
- Assert(ninsert->lenblk > 0);
-
- /*
- * Stick the new incomplete insert onto the front of the list, not the
- * back. This is so that gist_xlog_cleanup will process incompletions in
- * last-in-first-out order.
- */
- incomplete_inserts = lcons(ninsert, incomplete_inserts);
-
- MemoryContextSwitchTo(oldCxt);
-}
-
-static void
-forgetIncompleteInsert(RelFileNode node, ItemPointerData key)
-{
- ListCell *l;
-
- if (!ItemPointerIsValid(&key))
- return;
-
- if (incomplete_inserts == NIL)
- return;
-
- foreach(l, incomplete_inserts)
- {
- gistIncompleteInsert *insert = (gistIncompleteInsert *) lfirst(l);
-
- if (RelFileNodeEquals(node, insert->node) && ItemPointerEQ(&(insert->key), &(key)))
+ if (!XLByteLT(lsn, PageGetLSN(page)))
{
- /* found */
- incomplete_inserts = list_delete_ptr(incomplete_inserts, insert);
- pfree(insert->blkno);
- pfree(insert);
- break;
- }
- }
-}
+ GistPageGetOpaque(page)->nsn = lsn;
+ GistClearFollowRight(page);
-static void
-decodePageUpdateRecord(PageUpdateRecord *decoded, XLogRecord *record)
-{
- char *begin = XLogRecGetData(record),
- *ptr;
- int i = 0,
- addpath = 0;
-
- decoded->data = (gistxlogPageUpdate *) begin;
-
- if (decoded->data->ntodelete)
- {
- decoded->todelete = (OffsetNumber *) (begin + sizeof(gistxlogPageUpdate) + addpath);
- addpath = MAXALIGN(sizeof(OffsetNumber) * decoded->data->ntodelete);
- }
- else
- decoded->todelete = NULL;
-
- decoded->len = 0;
- ptr = begin + sizeof(gistxlogPageUpdate) + addpath;
- while (ptr - begin < record->xl_len)
- {
- decoded->len++;
- ptr += IndexTupleSize((IndexTuple) ptr);
- }
-
- decoded->itup = (IndexTuple *) palloc(sizeof(IndexTuple) * decoded->len);
-
- ptr = begin + sizeof(gistxlogPageUpdate) + addpath;
- while (ptr - begin < record->xl_len)
- {
- decoded->itup[i] = (IndexTuple) ptr;
- ptr += IndexTupleSize(decoded->itup[i]);
- i++;
+ PageSetLSN(page, lsn);
+ PageSetTLI(page, ThisTimeLineID);
+ MarkBufferDirty(buffer);
+ }
+ UnlockReleaseBuffer(buffer);
}
}
@@ -186,29 +70,22 @@ decodePageUpdateRecord(PageUpdateRecord *decoded, XLogRecord *record)
* redo any page update (except page split)
*/
static void
-gistRedoPageUpdateRecord(XLogRecPtr lsn, XLogRecord *record, bool isnewroot)
+gistRedoPageUpdateRecord(XLogRecPtr lsn, XLogRecord *record)
{
- gistxlogPageUpdate *xldata = (gistxlogPageUpdate *) XLogRecGetData(record);
- PageUpdateRecord xlrec;
+ char *begin = XLogRecGetData(record);
+ gistxlogPageUpdate *xldata = (gistxlogPageUpdate *) begin;
Buffer buffer;
Page page;
+ char *data;
- /* we must fix incomplete_inserts list even if XLR_BKP_BLOCK_1 is set */
- forgetIncompleteInsert(xldata->node, xldata->key);
+ if (BlockNumberIsValid(xldata->leftchild))
+ gistRedoClearFollowRight(xldata->node, lsn, xldata->leftchild);
- if (!isnewroot && xldata->blkno != GIST_ROOT_BLKNO)
- /* operation with root always finalizes insertion */
- pushIncompleteInsert(xldata->node, lsn, xldata->key,
- &(xldata->blkno), 1,
- NULL);
-
- /* nothing else to do if page was backed up (and no info to do it with) */
+ /* nothing more to do if page was backed up (and no info to do it with) */
if (record->xl_info & XLR_BKP_BLOCK_1)
return;
- decodePageUpdateRecord(&xlrec, record);
-
- buffer = XLogReadBuffer(xlrec.data->node, xlrec.data->blkno, false);
+ buffer = XLogReadBuffer(xldata->node, xldata->blkno, false);
if (!BufferIsValid(buffer))
return;
page = (Page) BufferGetPage(buffer);
@@ -219,28 +96,49 @@ gistRedoPageUpdateRecord(XLogRecPtr lsn, XLogRecord *record, bool isnewroot)
return;
}
- if (isnewroot)
- GISTInitBuffer(buffer, 0);
- else if (xlrec.data->ntodelete)
+ data = begin + sizeof(gistxlogPageUpdate);
+
+ /* Delete old tuples */
+ if (xldata->ntodelete > 0)
{
int i;
+ OffsetNumber *todelete = (OffsetNumber *) data;
+ data += sizeof(OffsetNumber) * xldata->ntodelete;
- for (i = 0; i < xlrec.data->ntodelete; i++)
- PageIndexTupleDelete(page, xlrec.todelete[i]);
+ for (i = 0; i < xldata->ntodelete; i++)
+ PageIndexTupleDelete(page, todelete[i]);
if (GistPageIsLeaf(page))
GistMarkTuplesDeleted(page);
}
/* add tuples */
- if (xlrec.len > 0)
- gistfillbuffer(page, xlrec.itup, xlrec.len, InvalidOffsetNumber);
-
- /*
- * special case: leafpage, nothing to insert, nothing to delete, then
- * vacuum marks page
- */
- if (GistPageIsLeaf(page) && xlrec.len == 0 && xlrec.data->ntodelete == 0)
- GistClearTuplesDeleted(page);
+ if (data - begin < record->xl_len)
+ {
+ OffsetNumber off = (PageIsEmpty(page)) ? FirstOffsetNumber :
+ OffsetNumberNext(PageGetMaxOffsetNumber(page));
+ while (data - begin < record->xl_len)
+ {
+ IndexTuple itup = (IndexTuple) data;
+ Size sz = IndexTupleSize(itup);
+ OffsetNumber l;
+ data += sz;
+
+ l = PageAddItem(page, (Item) itup, sz, off, false, false);
+ if (l == InvalidOffsetNumber)
+ elog(ERROR, "failed to add item to GiST index page, size %d bytes",
+ (int) sz);
+ off++;
+ }
+ }
+ else
+ {
+ /*
+ * special case: leafpage, nothing to insert, nothing to delete, then
+ * vacuum marks page
+ */
+ if (GistPageIsLeaf(page) && xldata->ntodelete == 0)
+ GistClearTuplesDeleted(page);
+ }
if (!GistPageIsLeaf(page) && PageGetMaxOffsetNumber(page) == InvalidOffsetNumber && xldata->blkno == GIST_ROOT_BLKNO)
@@ -315,41 +213,67 @@ decodePageSplitRecord(PageSplitRecord *decoded, XLogRecord *record)
static void
gistRedoPageSplitRecord(XLogRecPtr lsn, XLogRecord *record)
{
+ gistxlogPageSplit *xldata = (gistxlogPageSplit *) XLogRecGetData(record);
PageSplitRecord xlrec;
Buffer buffer;
Page page;
int i;
- int flags;
+ bool isrootsplit = false;
+ if (BlockNumberIsValid(xldata->leftchild))
+ gistRedoClearFollowRight(xldata->node, lsn, xldata->leftchild);
decodePageSplitRecord(&xlrec, record);
- flags = xlrec.data->origleaf ? F_LEAF : 0;
/* loop around all pages */
for (i = 0; i < xlrec.data->npage; i++)
{
NewPage *newpage = xlrec.page + i;
+ int flags;
+
+ if (newpage->header->blkno == GIST_ROOT_BLKNO)
+ {
+ Assert(i == 0);
+ isrootsplit = true;
+ }
buffer = XLogReadBuffer(xlrec.data->node, newpage->header->blkno, true);
Assert(BufferIsValid(buffer));
page = (Page) BufferGetPage(buffer);
/* ok, clear buffer */
+ if (xlrec.data->origleaf && newpage->header->blkno != GIST_ROOT_BLKNO)
+ flags = F_LEAF;
+ else
+ flags = 0;
GISTInitBuffer(buffer, flags);
/* and fill it */
gistfillbuffer(page, newpage->itup, newpage->header->num, FirstOffsetNumber);
+ if (newpage->header->blkno == GIST_ROOT_BLKNO)
+ {
+ GistPageGetOpaque(page)->rightlink = InvalidBlockNumber;
+ GistPageGetOpaque(page)->nsn = xldata->orignsn;
+ GistClearFollowRight(page);
+ }
+ else
+ {
+ if (i < xlrec.data->npage - 1)
+ GistPageGetOpaque(page)->rightlink = xlrec.page[i + 1].header->blkno;
+ else
+ GistPageGetOpaque(page)->rightlink = xldata->origrlink;
+ GistPageGetOpaque(page)->nsn = xldata->orignsn;
+ if (i < xlrec.data->npage - 1 && !isrootsplit)
+ GistMarkFollowRight(page);
+ else
+ GistClearFollowRight(page);
+ }
+
PageSetLSN(page, lsn);
PageSetTLI(page, ThisTimeLineID);
MarkBufferDirty(buffer);
UnlockReleaseBuffer(buffer);
}
-
- forgetIncompleteInsert(xlrec.data->node, xlrec.data->key);
-
- pushIncompleteInsert(xlrec.data->node, lsn, xlrec.data->key,
- NULL, 0,
- &xlrec);
}
static void
@@ -372,24 +296,6 @@ gistRedoCreateIndex(XLogRecPtr lsn, XLogRecord *record)
UnlockReleaseBuffer(buffer);
}
-static void
-gistRedoCompleteInsert(XLogRecPtr lsn, XLogRecord *record)
-{
- char *begin = XLogRecGetData(record),
- *ptr;
- gistxlogInsertComplete *xlrec;
-
- xlrec = (gistxlogInsertComplete *) begin;
-
- ptr = begin + sizeof(gistxlogInsertComplete);
- while (ptr - begin < record->xl_len)
- {
- Assert(record->xl_len - (ptr - begin) >= sizeof(ItemPointerData));
- forgetIncompleteInsert(xlrec->node, *((ItemPointerData *) ptr));
- ptr += sizeof(ItemPointerData);
- }
-}
-
void
gist_redo(XLogRecPtr lsn, XLogRecord *record)
{
@@ -401,30 +307,23 @@ gist_redo(XLogRecPtr lsn, XLogRecord *record)
* implement a similar optimization we have in b-tree, and remove killed
* tuples outside VACUUM, we'll need to handle that here.
*/
-
RestoreBkpBlocks(lsn, record, false);
oldCxt = MemoryContextSwitchTo(opCtx);
switch (info)
{
case XLOG_GIST_PAGE_UPDATE:
- gistRedoPageUpdateRecord(lsn, record, false);
+ gistRedoPageUpdateRecord(lsn, record);
break;
case XLOG_GIST_PAGE_DELETE:
gistRedoPageDeleteRecord(lsn, record);
break;
- case XLOG_GIST_NEW_ROOT:
- gistRedoPageUpdateRecord(lsn, record, true);
- break;
case XLOG_GIST_PAGE_SPLIT:
gistRedoPageSplitRecord(lsn, record);
break;
case XLOG_GIST_CREATE_INDEX:
gistRedoCreateIndex(lsn, record);
break;
- case XLOG_GIST_INSERT_COMPLETE:
- gistRedoCompleteInsert(lsn, record);
- break;
default:
elog(PANIC, "gist_redo: unknown op code %u", info);
}
@@ -434,20 +333,16 @@ gist_redo(XLogRecPtr lsn, XLogRecord *record)
}
static void
-out_target(StringInfo buf, RelFileNode node, ItemPointerData key)
+out_target(StringInfo buf, RelFileNode node)
{
appendStringInfo(buf, "rel %u/%u/%u",
node.spcNode, node.dbNode, node.relNode);
- if (ItemPointerIsValid(&key))
- appendStringInfo(buf, "; tid %u/%u",
- ItemPointerGetBlockNumber(&key),
- ItemPointerGetOffsetNumber(&key));
}
static void
out_gistxlogPageUpdate(StringInfo buf, gistxlogPageUpdate *xlrec)
{
- out_target(buf, xlrec->node, xlrec->key);
+ out_target(buf, xlrec->node);
appendStringInfo(buf, "; block number %u", xlrec->blkno);
}
@@ -463,7 +358,7 @@ static void
out_gistxlogPageSplit(StringInfo buf, gistxlogPageSplit *xlrec)
{
appendStringInfo(buf, "page_split: ");
- out_target(buf, xlrec->node, xlrec->key);
+ out_target(buf, xlrec->node);
appendStringInfo(buf, "; block number %u splits to %d pages",
xlrec->origblkno, xlrec->npage);
}
@@ -482,10 +377,6 @@ gist_desc(StringInfo buf, uint8 xl_info, char *rec)
case XLOG_GIST_PAGE_DELETE:
out_gistxlogPageDelete(buf, (gistxlogPageDelete *) rec);
break;
- case XLOG_GIST_NEW_ROOT:
- appendStringInfo(buf, "new_root: ");
- out_target(buf, ((gistxlogPageUpdate *) rec)->node, ((gistxlogPageUpdate *) rec)->key);
- break;
case XLOG_GIST_PAGE_SPLIT:
out_gistxlogPageSplit(buf, (gistxlogPageSplit *) rec);
break;
@@ -495,415 +386,102 @@ gist_desc(StringInfo buf, uint8 xl_info, char *rec)
((RelFileNode *) rec)->dbNode,
((RelFileNode *) rec)->relNode);
break;
- case XLOG_GIST_INSERT_COMPLETE:
- appendStringInfo(buf, "complete_insert: rel %u/%u/%u",
- ((gistxlogInsertComplete *) rec)->node.spcNode,
- ((gistxlogInsertComplete *) rec)->node.dbNode,
- ((gistxlogInsertComplete *) rec)->node.relNode);
- break;
default:
appendStringInfo(buf, "unknown gist op code %u", info);
break;
}
}
-IndexTuple
-gist_form_invalid_tuple(BlockNumber blkno)
-{
- /*
- * we don't alloc space for null's bitmap, this is invalid tuple, be
- * carefull in read and write code
- */
- Size size = IndexInfoFindDataOffset(0);
- IndexTuple tuple = (IndexTuple) palloc0(size);
-
- tuple->t_info |= size;
-
- ItemPointerSetBlockNumber(&(tuple->t_tid), blkno);
- GistTupleSetInvalid(tuple);
-
- return tuple;
-}
-
-
-static void
-gistxlogFindPath(Relation index, gistIncompleteInsert *insert)
-{
- GISTInsertStack *top;
-
- insert->pathlen = 0;
- insert->path = NULL;
-
- if ((top = gistFindPath(index, insert->origblkno)) != NULL)
- {
- int i;
- GISTInsertStack *ptr;
-
- for (ptr = top; ptr; ptr = ptr->parent)
- insert->pathlen++;
-
- insert->path = (BlockNumber *) palloc(sizeof(BlockNumber) * insert->pathlen);
-
- i = 0;
- for (ptr = top; ptr; ptr = ptr->parent)
- insert->path[i++] = ptr->blkno;
- }
- else
- elog(ERROR, "lost parent for block %u", insert->origblkno);
-}
-
-static SplitedPageLayout *
-gistMakePageLayout(Buffer *buffers, int nbuffers)
-{
- SplitedPageLayout *res = NULL,
- *resptr;
-
- while (nbuffers-- > 0)
- {
- Page page = BufferGetPage(buffers[nbuffers]);
- IndexTuple *vec;
- int veclen;
-
- resptr = (SplitedPageLayout *) palloc0(sizeof(SplitedPageLayout));
-
- resptr->block.blkno = BufferGetBlockNumber(buffers[nbuffers]);
- resptr->block.num = PageGetMaxOffsetNumber(page);
-
- vec = gistextractpage(page, &veclen);
- resptr->list = gistfillitupvec(vec, veclen, &(resptr->lenlist));
-
- resptr->next = res;
- res = resptr;
- }
-
- return res;
-}
-
-/*
- * Continue insert after crash. In normal situations, there aren't any
- * incomplete inserts, but if a crash occurs partway through an insertion
- * sequence, we'll need to finish making the index valid at the end of WAL
- * replay.
- *
- * Note that we assume the index is now in a valid state, except for the
- * unfinished insertion. In particular it's safe to invoke gistFindPath();
- * there shouldn't be any garbage pages for it to run into.
- *
- * To complete insert we can't use basic insertion algorithm because
- * during insertion we can't call user-defined support functions of opclass.
- * So, we insert 'invalid' tuples without real key and do it by separate algorithm.
- * 'invalid' tuple should be updated by vacuum full.
- */
-static void
-gistContinueInsert(gistIncompleteInsert *insert)
-{
- IndexTuple *itup;
- int i,
- lenitup;
- Relation index;
-
- index = CreateFakeRelcacheEntry(insert->node);
-
- /*
- * needed vector itup never will be more than initial lenblkno+2, because
- * during this processing Indextuple can be only smaller
- */
- lenitup = insert->lenblk;
- itup = (IndexTuple *) palloc(sizeof(IndexTuple) * (lenitup + 2 /* guarantee root split */ ));
-
- for (i = 0; i < insert->lenblk; i++)
- itup[i] = gist_form_invalid_tuple(insert->blkno[i]);
-
- /*
- * any insertion of itup[] should make LOG message about
- */
-
- if (insert->origblkno == GIST_ROOT_BLKNO)
- {
- /*
- * it was split root, so we should only make new root. it can't be
- * simple insert into root, we should replace all content of root.
- */
- Buffer buffer = XLogReadBuffer(insert->node, GIST_ROOT_BLKNO, true);
-
- gistnewroot(index, buffer, itup, lenitup, NULL);
- UnlockReleaseBuffer(buffer);
- }
- else
- {
- Buffer *buffers;
- Page *pages;
- int numbuffer;
- OffsetNumber *todelete;
-
- /* construct path */
- gistxlogFindPath(index, insert);
-
- Assert(insert->pathlen > 0);
-
- buffers = (Buffer *) palloc(sizeof(Buffer) * (insert->lenblk + 2 /* guarantee root split */ ));
- pages = (Page *) palloc(sizeof(Page) * (insert->lenblk + 2 /* guarantee root split */ ));
- todelete = (OffsetNumber *) palloc(sizeof(OffsetNumber) * (insert->lenblk + 2 /* guarantee root split */ ));
-
- for (i = 0; i < insert->pathlen; i++)
- {
- int j,
- k,
- pituplen = 0;
- uint8 xlinfo;
- XLogRecData *rdata;
- XLogRecPtr recptr;
- Buffer tempbuffer = InvalidBuffer;
- int ntodelete = 0;
-
- numbuffer = 1;
- buffers[0] = ReadBuffer(index, insert->path[i]);
- LockBuffer(buffers[0], GIST_EXCLUSIVE);
-
- /*
- * we check buffer, because we restored page earlier
- */
- gistcheckpage(index, buffers[0]);
-
- pages[0] = BufferGetPage(buffers[0]);
- Assert(!GistPageIsLeaf(pages[0]));
-
- pituplen = PageGetMaxOffsetNumber(pages[0]);
-
- /* find remove old IndexTuples to remove */
- for (j = 0; j < pituplen && ntodelete < lenitup; j++)
- {
- BlockNumber blkno;
- ItemId iid = PageGetItemId(pages[0], j + FirstOffsetNumber);
- IndexTuple idxtup = (IndexTuple) PageGetItem(pages[0], iid);
-
- blkno = ItemPointerGetBlockNumber(&(idxtup->t_tid));
-
- for (k = 0; k < lenitup; k++)
- if (ItemPointerGetBlockNumber(&(itup[k]->t_tid)) == blkno)
- {
- todelete[ntodelete] = j + FirstOffsetNumber - ntodelete;
- ntodelete++;
- break;
- }
- }
-
- if (ntodelete == 0)
- elog(PANIC, "gistContinueInsert: cannot find pointer to page(s)");
-
- /*
- * we check space with subtraction only first tuple to delete,
- * hope, that wiil be enough space....
- */
-
- if (gistnospace(pages[0], itup, lenitup, *todelete, 0))
- {
-
- /* no space left on page, so we must split */
- buffers[numbuffer] = ReadBuffer(index, P_NEW);
- LockBuffer(buffers[numbuffer], GIST_EXCLUSIVE);
- GISTInitBuffer(buffers[numbuffer], 0);
- pages[numbuffer] = BufferGetPage(buffers[numbuffer]);
- gistfillbuffer(pages[numbuffer], itup, lenitup, FirstOffsetNumber);
- numbuffer++;
-
- if (BufferGetBlockNumber(buffers[0]) == GIST_ROOT_BLKNO)
- {
- Buffer tmp;
-
- /*
- * we split root, just copy content from root to new page
- */
-
- /* sanity check */
- if (i + 1 != insert->pathlen)
- elog(PANIC, "unexpected pathlen in index \"%s\"",
- RelationGetRelationName(index));
-
- /* fill new page, root will be changed later */
- tempbuffer = ReadBuffer(index, P_NEW);
- LockBuffer(tempbuffer, GIST_EXCLUSIVE);
- memcpy(BufferGetPage(tempbuffer), pages[0], BufferGetPageSize(tempbuffer));
-
- /* swap buffers[0] (was root) and temp buffer */
- tmp = buffers[0];
- buffers[0] = tempbuffer;
- tempbuffer = tmp; /* now in tempbuffer GIST_ROOT_BLKNO,
- * it is still unchanged */
-
- pages[0] = BufferGetPage(buffers[0]);
- }
-
- START_CRIT_SECTION();
-
- for (j = 0; j < ntodelete; j++)
- PageIndexTupleDelete(pages[0], todelete[j]);
-
- xlinfo = XLOG_GIST_PAGE_SPLIT;
- rdata = formSplitRdata(index->rd_node, insert->path[i],
- false, &(insert->key),
- gistMakePageLayout(buffers, numbuffer));
-
- }
- else
- {
- START_CRIT_SECTION();
-
- for (j = 0; j < ntodelete; j++)
- PageIndexTupleDelete(pages[0], todelete[j]);
- gistfillbuffer(pages[0], itup, lenitup, InvalidOffsetNumber);
-
- xlinfo = XLOG_GIST_PAGE_UPDATE;
- rdata = formUpdateRdata(index->rd_node, buffers[0],
- todelete, ntodelete,
- itup, lenitup, &(insert->key));
- }
-
- /*
- * use insert->key as mark for completion of insert (form*Rdata()
- * above) for following possible replays
- */
-
- /* write pages, we should mark it dirty befor XLogInsert() */
- for (j = 0; j < numbuffer; j++)
- {
- GistPageGetOpaque(pages[j])->rightlink = InvalidBlockNumber;
- MarkBufferDirty(buffers[j]);
- }
- recptr = XLogInsert(RM_GIST_ID, xlinfo, rdata);
- for (j = 0; j < numbuffer; j++)
- {
- PageSetLSN(pages[j], recptr);
- PageSetTLI(pages[j], ThisTimeLineID);
- }
-
- END_CRIT_SECTION();
-
- lenitup = numbuffer;
- for (j = 0; j < numbuffer; j++)
- {
- itup[j] = gist_form_invalid_tuple(BufferGetBlockNumber(buffers[j]));
- UnlockReleaseBuffer(buffers[j]);
- }
-
- if (tempbuffer != InvalidBuffer)
- {
- /*
- * it was a root split, so fill it by new values
- */
- gistnewroot(index, tempbuffer, itup, lenitup, &(insert->key));
- UnlockReleaseBuffer(tempbuffer);
- }
- }
- }
-
- FreeFakeRelcacheEntry(index);
-
- ereport(LOG,
- (errmsg("index %u/%u/%u needs VACUUM FULL or REINDEX to finish crash recovery",
- insert->node.spcNode, insert->node.dbNode, insert->node.relNode),
- errdetail("Incomplete insertion detected during crash replay.")));
-}
-
void
gist_xlog_startup(void)
{
- incomplete_inserts = NIL;
- insertCtx = AllocSetContextCreate(CurrentMemoryContext,
- "GiST recovery temporary context",
- ALLOCSET_DEFAULT_MINSIZE,
- ALLOCSET_DEFAULT_INITSIZE,
- ALLOCSET_DEFAULT_MAXSIZE);
opCtx = createTempGistContext();
}
void
gist_xlog_cleanup(void)
{
- ListCell *l;
- MemoryContext oldCxt;
-
- oldCxt = MemoryContextSwitchTo(opCtx);
-
- foreach(l, incomplete_inserts)
- {
- gistIncompleteInsert *insert = (gistIncompleteInsert *) lfirst(l);
-
- gistContinueInsert(insert);
- MemoryContextReset(opCtx);
- }
- MemoryContextSwitchTo(oldCxt);
-
MemoryContextDelete(opCtx);
- MemoryContextDelete(insertCtx);
-}
-
-bool
-gist_safe_restartpoint(void)
-{
- if (incomplete_inserts)
- return false;
- return true;
}
-
-XLogRecData *
-formSplitRdata(RelFileNode node, BlockNumber blkno, bool page_is_leaf,
- ItemPointer key, SplitedPageLayout *dist)
+/*
+ * Write WAL record of a page split.
+ */
+XLogRecPtr
+gistXLogSplit(RelFileNode node, BlockNumber blkno, bool page_is_leaf,
+ SplitedPageLayout *dist,
+ BlockNumber origrlink, GistNSN orignsn,
+ Buffer leftchildbuf)
{
XLogRecData *rdata;
- gistxlogPageSplit *xlrec = (gistxlogPageSplit *) palloc(sizeof(gistxlogPageSplit));
+ gistxlogPageSplit xlrec;
SplitedPageLayout *ptr;
int npage = 0,
- cur = 1;
+ cur;
+ XLogRecPtr recptr;
- ptr = dist;
- while (ptr)
- {
+ for (ptr = dist; ptr; ptr = ptr->next)
npage++;
- ptr = ptr->next;
- }
rdata = (XLogRecData *) palloc(sizeof(XLogRecData) * (npage * 2 + 2));
- xlrec->node = node;
- xlrec->origblkno = blkno;
- xlrec->origleaf = page_is_leaf;
- xlrec->npage = (uint16) npage;
- if (key)
- xlrec->key = *key;
- else
- ItemPointerSetInvalid(&(xlrec->key));
+ xlrec.node = node;
+ xlrec.origblkno = blkno;
+ xlrec.origrlink = origrlink;
+ xlrec.orignsn = orignsn;
+ xlrec.origleaf = page_is_leaf;
+ xlrec.npage = (uint16) npage;
+ xlrec.leftchild =
+ BufferIsValid(leftchildbuf) ? BufferGetBlockNumber(leftchildbuf) : InvalidBlockNumber;
- rdata[0].buffer = InvalidBuffer;
- rdata[0].data = (char *) xlrec;
+ rdata[0].data = (char *) &xlrec;
rdata[0].len = sizeof(gistxlogPageSplit);
- rdata[0].next = NULL;
+ rdata[0].buffer = InvalidBuffer;
- ptr = dist;
- while (ptr)
+ cur = 1;
+
+ /*
+ * Include a full page image of the child buf. (only necessary if a
+ * checkpoint happened since the child page was split)
+ */
+ if (BufferIsValid(leftchildbuf))
{
+ rdata[cur - 1].next = &(rdata[cur]);
+ rdata[cur].data = NULL;
+ rdata[cur].len = 0;
+ rdata[cur].buffer = leftchildbuf;
+ rdata[cur].buffer_std = true;
+ cur++;
+ }
+
+ for (ptr = dist; ptr; ptr = ptr->next)
+ {
+ rdata[cur - 1].next = &(rdata[cur]);
rdata[cur].buffer = InvalidBuffer;
rdata[cur].data = (char *) &(ptr->block);
rdata[cur].len = sizeof(gistxlogPage);
- rdata[cur - 1].next = &(rdata[cur]);
cur++;
+ rdata[cur - 1].next = &(rdata[cur]);
rdata[cur].buffer = InvalidBuffer;
rdata[cur].data = (char *) (ptr->list);
rdata[cur].len = ptr->lenlist;
- rdata[cur - 1].next = &(rdata[cur]);
- rdata[cur].next = NULL;
cur++;
- ptr = ptr->next;
}
+ rdata[cur - 1].next = NULL;
+
+ recptr = XLogInsert(RM_GIST_ID, XLOG_GIST_PAGE_SPLIT, rdata);
- return rdata;
+ pfree(rdata);
+ return recptr;
}
/*
- * Construct the rdata array for an XLOG record describing a page update
- * (deletion and/or insertion of tuples on a single index page).
+ * Write XLOG record describing a page update. The update can include any
+ * number of deletions and/or insertions of tuples on a single index page.
+ *
+ * If this update inserts a downlink for a split page, also record that
+ * the F_FOLLOW_RIGHT flag on the child page is cleared and NSN set.
*
* Note that both the todelete array and the tuples are marked as belonging
* to the target buffer; they need not be stored in XLOG if XLogInsert decides
@@ -911,27 +489,26 @@ formSplitRdata(RelFileNode node, BlockNumber blkno, bool page_is_leaf,
* at least one rdata item referencing the buffer, even when ntodelete and
* ituplen are both zero; this ensures that XLogInsert knows about the buffer.
*/
-XLogRecData *
-formUpdateRdata(RelFileNode node, Buffer buffer,
- OffsetNumber *todelete, int ntodelete,
- IndexTuple *itup, int ituplen, ItemPointer key)
+XLogRecPtr
+gistXLogUpdate(RelFileNode node, Buffer buffer,
+ OffsetNumber *todelete, int ntodelete,
+ IndexTuple *itup, int ituplen,
+ Buffer leftchildbuf)
{
XLogRecData *rdata;
gistxlogPageUpdate *xlrec;
int cur,
i;
+ XLogRecPtr recptr;
- rdata = (XLogRecData *) palloc(sizeof(XLogRecData) * (3 + ituplen));
+ rdata = (XLogRecData *) palloc(sizeof(XLogRecData) * (4 + ituplen));
xlrec = (gistxlogPageUpdate *) palloc(sizeof(gistxlogPageUpdate));
xlrec->node = node;
xlrec->blkno = BufferGetBlockNumber(buffer);
xlrec->ntodelete = ntodelete;
-
- if (key)
- xlrec->key = *key;
- else
- ItemPointerSetInvalid(&(xlrec->key));
+ xlrec->leftchild =
+ BufferIsValid(leftchildbuf) ? BufferGetBlockNumber(leftchildbuf) : InvalidBlockNumber;
rdata[0].buffer = buffer;
rdata[0].buffer_std = true;
@@ -945,13 +522,13 @@ formUpdateRdata(RelFileNode node, Buffer buffer,
rdata[1].next = &(rdata[2]);
rdata[2].data = (char *) todelete;
- rdata[2].len = MAXALIGN(sizeof(OffsetNumber) * ntodelete);
+ rdata[2].len = sizeof(OffsetNumber) * ntodelete;
rdata[2].buffer = buffer;
rdata[2].buffer_std = true;
- rdata[2].next = NULL;
- /* new tuples */
cur = 3;
+
+ /* new tuples */
for (i = 0; i < ituplen; i++)
{
rdata[cur - 1].next = &(rdata[cur]);
@@ -959,38 +536,26 @@ formUpdateRdata(RelFileNode node, Buffer buffer,
rdata[cur].len = IndexTupleSize(itup[i]);
rdata[cur].buffer = buffer;
rdata[cur].buffer_std = true;
- rdata[cur].next = NULL;
cur++;
}
- return rdata;
-}
-
-XLogRecPtr
-gistxlogInsertCompletion(RelFileNode node, ItemPointerData *keys, int len)
-{
- gistxlogInsertComplete xlrec;
- XLogRecData rdata[2];
- XLogRecPtr recptr;
-
- Assert(len > 0);
- xlrec.node = node;
-
- rdata[0].buffer = InvalidBuffer;
- rdata[0].data = (char *) &xlrec;
- rdata[0].len = sizeof(gistxlogInsertComplete);
- rdata[0].next = &(rdata[1]);
-
- rdata[1].buffer = InvalidBuffer;
- rdata[1].data = (char *) keys;
- rdata[1].len = sizeof(ItemPointerData) * len;
- rdata[1].next = NULL;
-
- START_CRIT_SECTION();
-
- recptr = XLogInsert(RM_GIST_ID, XLOG_GIST_INSERT_COMPLETE, rdata);
+ /*
+ * Include a full page image of the child buf. (only necessary if
+ * a checkpoint happened since the child page was split)
+ */
+ if (BufferIsValid(leftchildbuf))
+ {
+ rdata[cur - 1].next = &(rdata[cur]);
+ rdata[cur].data = NULL;
+ rdata[cur].len = 0;
+ rdata[cur].buffer = leftchildbuf;
+ rdata[cur].buffer_std = true;
+ cur++;
+ }
+ rdata[cur - 1].next = NULL;
- END_CRIT_SECTION();
+ recptr = XLogInsert(RM_GIST_ID, XLOG_GIST_PAGE_UPDATE, rdata);
+ pfree(rdata);
return recptr;
}
diff --git a/src/backend/access/transam/rmgr.c b/src/backend/access/transam/rmgr.c
index c706e97956..f8f797c33d 100644
--- a/src/backend/access/transam/rmgr.c
+++ b/src/backend/access/transam/rmgr.c
@@ -40,6 +40,6 @@ const RmgrData RmgrTable[RM_MAX_ID + 1] = {
{"Btree", btree_redo, btree_desc, btree_xlog_startup, btree_xlog_cleanup, btree_safe_restartpoint},
{"Hash", hash_redo, hash_desc, NULL, NULL, NULL},
{"Gin", gin_redo, gin_desc, gin_xlog_startup, gin_xlog_cleanup, gin_safe_restartpoint},
- {"Gist", gist_redo, gist_desc, gist_xlog_startup, gist_xlog_cleanup, gist_safe_restartpoint},
+ {"Gist", gist_redo, gist_desc, gist_xlog_startup, gist_xlog_cleanup, NULL},
{"Sequence", seq_redo, seq_desc, NULL, NULL, NULL}
};
diff --git a/src/include/access/gist.h b/src/include/access/gist.h
index 01fddb94af..3913218204 100644
--- a/src/include/access/gist.h
+++ b/src/include/access/gist.h
@@ -58,9 +58,10 @@
/*
* Page opaque data in a GiST index page.
*/
-#define F_LEAF (1 << 0)
-#define F_DELETED (1 << 1)
-#define F_TUPLES_DELETED (1 << 2)
+#define F_LEAF (1 << 0) /* leaf page */
+#define F_DELETED (1 << 1) /* the page has been deleted */
+#define F_TUPLES_DELETED (1 << 2) /* some tuples on the page are dead */
+#define F_FOLLOW_RIGHT (1 << 3) /* page to the right has no downlink */
typedef XLogRecPtr GistNSN;
@@ -132,6 +133,10 @@ typedef struct GISTENTRY
#define GistMarkTuplesDeleted(page) ( GistPageGetOpaque(page)->flags |= F_TUPLES_DELETED)
#define GistClearTuplesDeleted(page) ( GistPageGetOpaque(page)->flags &= ~F_TUPLES_DELETED)
+#define GistFollowRight(page) ( GistPageGetOpaque(page)->flags & F_FOLLOW_RIGHT)
+#define GistMarkFollowRight(page) ( GistPageGetOpaque(page)->flags |= F_FOLLOW_RIGHT)
+#define GistClearFollowRight(page) ( GistPageGetOpaque(page)->flags &= ~F_FOLLOW_RIGHT)
+
/*
* Vector of GISTENTRY structs; user-defined methods union and picksplit
* take it as one of their arguments
diff --git a/src/include/access/gist_private.h b/src/include/access/gist_private.h
index 058435cfe5..1bacb468ee 100644
--- a/src/include/access/gist_private.h
+++ b/src/include/access/gist_private.h
@@ -132,9 +132,9 @@ typedef GISTScanOpaqueData *GISTScanOpaque;
/* XLog stuff */
#define XLOG_GIST_PAGE_UPDATE 0x00
-#define XLOG_GIST_NEW_ROOT 0x20
+/* #define XLOG_GIST_NEW_ROOT 0x20 */ /* not used anymore */
#define XLOG_GIST_PAGE_SPLIT 0x30
-#define XLOG_GIST_INSERT_COMPLETE 0x40
+/* #define XLOG_GIST_INSERT_COMPLETE 0x40 */ /* not used anymore */
#define XLOG_GIST_CREATE_INDEX 0x50
#define XLOG_GIST_PAGE_DELETE 0x60
@@ -144,9 +144,10 @@ typedef struct gistxlogPageUpdate
BlockNumber blkno;
/*
- * It used to identify completeness of insert. Sets to leaf itup
+ * If this operation completes a page split, by inserting a downlink for
+ * the split page, leftchild points to the left half of the split.
*/
- ItemPointerData key;
+ BlockNumber leftchild;
/* number of deleted offsets */
uint16 ntodelete;
@@ -160,11 +161,12 @@ typedef struct gistxlogPageSplit
{
RelFileNode node;
BlockNumber origblkno; /* splitted page */
+ BlockNumber origrlink; /* rightlink of the page before split */
+ GistNSN orignsn; /* NSN of the page before split */
bool origleaf; /* was splitted page a leaf page? */
- uint16 npage;
- /* see comments on gistxlogPageUpdate */
- ItemPointerData key;
+ BlockNumber leftchild; /* like in gistxlogPageUpdate */
+ uint16 npage; /* # of pages in the split */
/*
* follow: 1. gistxlogPage and array of IndexTupleData per page
@@ -177,12 +179,6 @@ typedef struct gistxlogPage
int num; /* number of index tuples following */
} gistxlogPage;
-typedef struct gistxlogInsertComplete
-{
- RelFileNode node;
- /* follows ItemPointerData key to clean */
-} gistxlogInsertComplete;
-
typedef struct gistxlogPageDelete
{
RelFileNode node;
@@ -206,7 +202,6 @@ typedef struct SplitedPageLayout
* GISTInsertStack used for locking buffers and transfer arguments during
* insertion
*/
-
typedef struct GISTInsertStack
{
/* current page */
@@ -215,7 +210,7 @@ typedef struct GISTInsertStack
Page page;
/*
- * log sequence number from page->lsn to recognize page update and
+ * log sequence number from page->lsn to recognize page update and
* compare it with page's nsn to recognize page split
*/
GistNSN lsn;
@@ -223,9 +218,8 @@ typedef struct GISTInsertStack
/* child's offset */
OffsetNumber childoffnum;
- /* pointer to parent and child */
+ /* pointer to parent */
struct GISTInsertStack *parent;
- struct GISTInsertStack *child;
/* for gistFindPath */
struct GISTInsertStack *next;
@@ -238,12 +232,10 @@ typedef struct GistSplitVector
Datum spl_lattr[INDEX_MAX_KEYS]; /* Union of subkeys in
* spl_left */
bool spl_lisnull[INDEX_MAX_KEYS];
- bool spl_leftvalid;
Datum spl_rattr[INDEX_MAX_KEYS]; /* Union of subkeys in
* spl_right */
bool spl_risnull[INDEX_MAX_KEYS];
- bool spl_rightvalid;
bool *spl_equiv; /* equivalent tuples which can be freely
* distributed between left and right pages */
@@ -252,28 +244,40 @@ typedef struct GistSplitVector
typedef struct
{
Relation r;
- IndexTuple *itup; /* in/out, points to compressed entry */
- int ituplen; /* length of itup */
Size freespace; /* free space to be left */
- GISTInsertStack *stack;
- bool needInsertComplete;
- /* pointer to heap tuple */
- ItemPointerData key;
+ GISTInsertStack *stack;
} GISTInsertState;
/* root page of a gist index */
#define GIST_ROOT_BLKNO 0
/*
- * mark tuples on inner pages during recovery
+ * Before PostgreSQL 9.1, we used rely on so-called "invalid tuples" on inner
+ * pages to finish crash recovery of incomplete page splits. If a crash
+ * happened in the middle of a page split, so that the downlink pointers were
+ * not yet inserted, crash recovery inserted a special downlink pointer. The
+ * semantics of an invalid tuple was that it if you encounter one in a scan,
+ * it must always be followed, because we don't know if the tuples on the
+ * child page match or not.
+ *
+ * We no longer create such invalid tuples, we now mark the left-half of such
+ * an incomplete split with the F_FOLLOW_RIGHT flag instead, and finish the
+ * split properly the next time we need to insert on that page. To retain
+ * on-disk compatibility for the sake of pg_upgrade, we still store 0xffff as
+ * the offset number of all inner tuples. If we encounter any invalid tuples
+ * with 0xfffe during insertion, we throw an error, though scans still handle
+ * them. You should only encounter invalid tuples if you pg_upgrade a pre-9.1
+ * gist index which already has invalid tuples in it because of a crash. That
+ * should be rare, and you are recommended to REINDEX anyway if you have any
+ * invalid tuples in an index, so throwing an error is as far as we go with
+ * supporting that.
*/
#define TUPLE_IS_VALID 0xffff
#define TUPLE_IS_INVALID 0xfffe
#define GistTupleIsInvalid(itup) ( ItemPointerGetOffsetNumber( &((itup)->t_tid) ) == TUPLE_IS_INVALID )
#define GistTupleSetValid(itup) ItemPointerSetOffsetNumber( &((itup)->t_tid), TUPLE_IS_VALID )
-#define GistTupleSetInvalid(itup) ItemPointerSetOffsetNumber( &((itup)->t_tid), TUPLE_IS_INVALID )
/* gist.c */
extern Datum gistbuild(PG_FUNCTION_ARGS);
@@ -281,8 +285,6 @@ extern Datum gistinsert(PG_FUNCTION_ARGS);
extern MemoryContext createTempGistContext(void);
extern void initGISTstate(GISTSTATE *giststate, Relation index);
extern void freeGISTstate(GISTSTATE *giststate);
-extern void gistmakedeal(GISTInsertState *state, GISTSTATE *giststate);
-extern void gistnewroot(Relation r, Buffer buffer, IndexTuple *itup, int len, ItemPointer key);
extern SplitedPageLayout *gistSplit(Relation r, Page page, IndexTuple *itup,
int len, GISTSTATE *giststate);
@@ -294,18 +296,17 @@ extern void gist_redo(XLogRecPtr lsn, XLogRecord *record);
extern void gist_desc(StringInfo buf, uint8 xl_info, char *rec);
extern void gist_xlog_startup(void);
extern void gist_xlog_cleanup(void);
-extern bool gist_safe_restartpoint(void);
-extern IndexTuple gist_form_invalid_tuple(BlockNumber blkno);
-
-extern XLogRecData *formUpdateRdata(RelFileNode node, Buffer buffer,
- OffsetNumber *todelete, int ntodelete,
- IndexTuple *itup, int ituplen, ItemPointer key);
-extern XLogRecData *formSplitRdata(RelFileNode node,
- BlockNumber blkno, bool page_is_leaf,
- ItemPointer key, SplitedPageLayout *dist);
+extern XLogRecPtr gistXLogUpdate(RelFileNode node, Buffer buffer,
+ OffsetNumber *todelete, int ntodelete,
+ IndexTuple *itup, int ntup,
+ Buffer leftchild);
-extern XLogRecPtr gistxlogInsertCompletion(RelFileNode node, ItemPointerData *keys, int len);
+extern XLogRecPtr gistXLogSplit(RelFileNode node,
+ BlockNumber blkno, bool page_is_leaf,
+ SplitedPageLayout *dist,
+ BlockNumber origrlink, GistNSN oldnsn,
+ Buffer leftchild);
/* gistget.c */
extern Datum gistgettuple(PG_FUNCTION_ARGS);
@@ -357,7 +358,7 @@ extern void gistdentryinit(GISTSTATE *giststate, int nkey, GISTENTRY *e,
extern float gistpenalty(GISTSTATE *giststate, int attno,
GISTENTRY *key1, bool isNull1,
GISTENTRY *key2, bool isNull2);
-extern bool gistMakeUnionItVec(GISTSTATE *giststate, IndexTuple *itvec, int len, int startkey,
+extern void gistMakeUnionItVec(GISTSTATE *giststate, IndexTuple *itvec, int len, int startkey,
Datum *attr, bool *isnull);
extern bool gistKeyIsEQ(GISTSTATE *giststate, int attno, Datum a, Datum b);
extern void gistDeCompressAtt(GISTSTATE *giststate, Relation r, IndexTuple tuple, Page p,
--
cgit v1.2.3
From 5d950e3b0c75d65dd09f8ca5f76cd429a0aabbdc Mon Sep 17 00:00:00 2001
From: Bruce Momjian
Date: Sat, 1 Jan 2011 13:18:15 -0500
Subject: Stamp copyrights for year 2011.
---
COPYRIGHT | 2 +-
configure | 4 ++--
configure.in | 2 +-
contrib/adminpack/adminpack.c | 2 +-
contrib/auto_explain/auto_explain.c | 2 +-
contrib/dblink/dblink.c | 2 +-
contrib/dblink/dblink.h | 2 +-
contrib/dict_int/dict_int.c | 2 +-
contrib/dict_xsyn/dict_xsyn.c | 2 +-
contrib/dummy_seclabel/dummy_seclabel.c | 2 +-
contrib/fuzzystrmatch/fuzzystrmatch.c | 2 +-
contrib/fuzzystrmatch/levenshtein.c | 2 +-
contrib/isn/isn.c | 2 +-
contrib/isn/isn.h | 2 +-
contrib/pageinspect/fsmfuncs.c | 2 +-
contrib/pageinspect/heapfuncs.c | 2 +-
contrib/pageinspect/rawpage.c | 2 +-
contrib/passwordcheck/passwordcheck.c | 2 +-
contrib/pg_stat_statements/pg_stat_statements.c | 2 +-
contrib/pg_upgrade/check.c | 2 +-
contrib/pg_upgrade/controldata.c | 2 +-
contrib/pg_upgrade/dump.c | 2 +-
contrib/pg_upgrade/exec.c | 2 +-
contrib/pg_upgrade/file.c | 2 +-
contrib/pg_upgrade/function.c | 2 +-
contrib/pg_upgrade/info.c | 2 +-
contrib/pg_upgrade/option.c | 2 +-
contrib/pg_upgrade/page.c | 2 +-
contrib/pg_upgrade/pg_upgrade.c | 2 +-
contrib/pg_upgrade/pg_upgrade.h | 2 +-
contrib/pg_upgrade/relfilenode.c | 2 +-
contrib/pg_upgrade/server.c | 2 +-
contrib/pg_upgrade/tablespace.c | 2 +-
contrib/pg_upgrade/util.c | 2 +-
contrib/pg_upgrade/version.c | 2 +-
contrib/pg_upgrade/version_old_8_3.c | 2 +-
contrib/pg_upgrade_support/pg_upgrade_support.c | 2 +-
contrib/pgbench/pgbench.c | 2 +-
contrib/tablefunc/tablefunc.c | 2 +-
contrib/tablefunc/tablefunc.h | 2 +-
contrib/test_parser/test_parser.c | 2 +-
contrib/tsearch2/tsearch2.c | 2 +-
contrib/unaccent/unaccent.c | 2 +-
contrib/uuid-ossp/uuid-ossp.c | 2 +-
contrib/vacuumlo/vacuumlo.c | 2 +-
doc/src/sgml/legal.sgml | 4 ++--
src/backend/Makefile | 2 +-
src/backend/access/common/heaptuple.c | 2 +-
src/backend/access/common/indextuple.c | 2 +-
src/backend/access/common/printtup.c | 2 +-
src/backend/access/common/reloptions.c | 2 +-
src/backend/access/common/scankey.c | 2 +-
src/backend/access/common/tupconvert.c | 2 +-
src/backend/access/common/tupdesc.c | 2 +-
src/backend/access/gin/ginarrayproc.c | 2 +-
src/backend/access/gin/ginbtree.c | 2 +-
src/backend/access/gin/ginbulk.c | 2 +-
src/backend/access/gin/gindatapage.c | 2 +-
src/backend/access/gin/ginentrypage.c | 2 +-
src/backend/access/gin/ginfast.c | 2 +-
src/backend/access/gin/ginget.c | 2 +-
src/backend/access/gin/gininsert.c | 2 +-
src/backend/access/gin/ginscan.c | 2 +-
src/backend/access/gin/ginutil.c | 2 +-
src/backend/access/gin/ginvacuum.c | 2 +-
src/backend/access/gin/ginxlog.c | 2 +-
src/backend/access/gist/gist.c | 2 +-
src/backend/access/gist/gistget.c | 2 +-
src/backend/access/gist/gistproc.c | 2 +-
src/backend/access/gist/gistscan.c | 2 +-
src/backend/access/gist/gistsplit.c | 2 +-
src/backend/access/gist/gistutil.c | 2 +-
src/backend/access/gist/gistvacuum.c | 2 +-
src/backend/access/gist/gistxlog.c | 2 +-
src/backend/access/hash/hash.c | 2 +-
src/backend/access/hash/hashfunc.c | 2 +-
src/backend/access/hash/hashinsert.c | 2 +-
src/backend/access/hash/hashovfl.c | 2 +-
src/backend/access/hash/hashpage.c | 2 +-
src/backend/access/hash/hashscan.c | 2 +-
src/backend/access/hash/hashsearch.c | 2 +-
src/backend/access/hash/hashsort.c | 2 +-
src/backend/access/hash/hashutil.c | 2 +-
src/backend/access/heap/heapam.c | 2 +-
src/backend/access/heap/hio.c | 2 +-
src/backend/access/heap/pruneheap.c | 2 +-
src/backend/access/heap/rewriteheap.c | 2 +-
src/backend/access/heap/syncscan.c | 2 +-
src/backend/access/heap/tuptoaster.c | 2 +-
src/backend/access/heap/visibilitymap.c | 2 +-
src/backend/access/index/genam.c | 2 +-
src/backend/access/index/indexam.c | 2 +-
src/backend/access/nbtree/nbtcompare.c | 2 +-
src/backend/access/nbtree/nbtinsert.c | 2 +-
src/backend/access/nbtree/nbtpage.c | 2 +-
src/backend/access/nbtree/nbtree.c | 2 +-
src/backend/access/nbtree/nbtsearch.c | 2 +-
src/backend/access/nbtree/nbtsort.c | 2 +-
src/backend/access/nbtree/nbtutils.c | 2 +-
src/backend/access/nbtree/nbtxlog.c | 2 +-
src/backend/access/transam/clog.c | 2 +-
src/backend/access/transam/multixact.c | 2 +-
src/backend/access/transam/slru.c | 2 +-
src/backend/access/transam/subtrans.c | 2 +-
src/backend/access/transam/transam.c | 2 +-
src/backend/access/transam/twophase.c | 2 +-
src/backend/access/transam/twophase_rmgr.c | 2 +-
src/backend/access/transam/varsup.c | 2 +-
src/backend/access/transam/xact.c | 2 +-
src/backend/access/transam/xlog.c | 2 +-
src/backend/access/transam/xlogutils.c | 2 +-
src/backend/bootstrap/bootparse.y | 2 +-
src/backend/bootstrap/bootscanner.l | 2 +-
src/backend/bootstrap/bootstrap.c | 2 +-
src/backend/catalog/Catalog.pm | 2 +-
src/backend/catalog/aclchk.c | 2 +-
src/backend/catalog/catalog.c | 2 +-
src/backend/catalog/dependency.c | 2 +-
src/backend/catalog/genbki.pl | 4 ++--
src/backend/catalog/heap.c | 2 +-
src/backend/catalog/index.c | 2 +-
src/backend/catalog/indexing.c | 2 +-
src/backend/catalog/information_schema.sql | 2 +-
src/backend/catalog/namespace.c | 2 +-
src/backend/catalog/objectaddress.c | 2 +-
src/backend/catalog/pg_aggregate.c | 2 +-
src/backend/catalog/pg_constraint.c | 2 +-
src/backend/catalog/pg_conversion.c | 2 +-
src/backend/catalog/pg_db_role_setting.c | 2 +-
src/backend/catalog/pg_depend.c | 2 +-
src/backend/catalog/pg_enum.c | 2 +-
src/backend/catalog/pg_inherits.c | 2 +-
src/backend/catalog/pg_largeobject.c | 2 +-
src/backend/catalog/pg_namespace.c | 2 +-
src/backend/catalog/pg_operator.c | 2 +-
src/backend/catalog/pg_proc.c | 2 +-
src/backend/catalog/pg_shdepend.c | 2 +-
src/backend/catalog/pg_type.c | 2 +-
src/backend/catalog/storage.c | 2 +-
src/backend/catalog/system_views.sql | 2 +-
src/backend/catalog/toasting.c | 2 +-
src/backend/commands/aggregatecmds.c | 2 +-
src/backend/commands/alter.c | 2 +-
src/backend/commands/analyze.c | 2 +-
src/backend/commands/async.c | 2 +-
src/backend/commands/cluster.c | 2 +-
src/backend/commands/comment.c | 2 +-
src/backend/commands/constraint.c | 2 +-
src/backend/commands/conversioncmds.c | 2 +-
src/backend/commands/copy.c | 2 +-
src/backend/commands/dbcommands.c | 2 +-
src/backend/commands/define.c | 2 +-
src/backend/commands/discard.c | 2 +-
src/backend/commands/explain.c | 2 +-
src/backend/commands/foreigncmds.c | 2 +-
src/backend/commands/functioncmds.c | 2 +-
src/backend/commands/indexcmds.c | 2 +-
src/backend/commands/lockcmds.c | 2 +-
src/backend/commands/opclasscmds.c | 2 +-
src/backend/commands/operatorcmds.c | 2 +-
src/backend/commands/portalcmds.c | 2 +-
src/backend/commands/prepare.c | 2 +-
src/backend/commands/proclang.c | 2 +-
src/backend/commands/schemacmds.c | 2 +-
src/backend/commands/seclabel.c | 2 +-
src/backend/commands/sequence.c | 2 +-
src/backend/commands/tablecmds.c | 2 +-
src/backend/commands/tablespace.c | 2 +-
src/backend/commands/trigger.c | 2 +-
src/backend/commands/tsearchcmds.c | 2 +-
src/backend/commands/typecmds.c | 2 +-
src/backend/commands/user.c | 2 +-
src/backend/commands/vacuum.c | 2 +-
src/backend/commands/vacuumlazy.c | 2 +-
src/backend/commands/variable.c | 2 +-
src/backend/commands/view.c | 2 +-
src/backend/executor/execAmi.c | 2 +-
src/backend/executor/execCurrent.c | 2 +-
src/backend/executor/execGrouping.c | 2 +-
src/backend/executor/execJunk.c | 2 +-
src/backend/executor/execMain.c | 2 +-
src/backend/executor/execProcnode.c | 2 +-
src/backend/executor/execQual.c | 2 +-
src/backend/executor/execScan.c | 2 +-
src/backend/executor/execTuples.c | 2 +-
src/backend/executor/execUtils.c | 2 +-
src/backend/executor/functions.c | 2 +-
src/backend/executor/instrument.c | 2 +-
src/backend/executor/nodeAgg.c | 2 +-
src/backend/executor/nodeAppend.c | 2 +-
src/backend/executor/nodeBitmapAnd.c | 2 +-
src/backend/executor/nodeBitmapHeapscan.c | 2 +-
src/backend/executor/nodeBitmapIndexscan.c | 2 +-
src/backend/executor/nodeBitmapOr.c | 2 +-
src/backend/executor/nodeCtescan.c | 2 +-
src/backend/executor/nodeFunctionscan.c | 2 +-
src/backend/executor/nodeGroup.c | 2 +-
src/backend/executor/nodeHash.c | 2 +-
src/backend/executor/nodeHashjoin.c | 2 +-
src/backend/executor/nodeIndexscan.c | 2 +-
src/backend/executor/nodeLimit.c | 2 +-
src/backend/executor/nodeLockRows.c | 2 +-
src/backend/executor/nodeMaterial.c | 2 +-
src/backend/executor/nodeMergeAppend.c | 2 +-
src/backend/executor/nodeMergejoin.c | 2 +-
src/backend/executor/nodeModifyTable.c | 2 +-
src/backend/executor/nodeNestloop.c | 2 +-
src/backend/executor/nodeRecursiveunion.c | 2 +-
src/backend/executor/nodeResult.c | 2 +-
src/backend/executor/nodeSeqscan.c | 2 +-
src/backend/executor/nodeSetOp.c | 2 +-
src/backend/executor/nodeSort.c | 2 +-
src/backend/executor/nodeSubplan.c | 2 +-
src/backend/executor/nodeSubqueryscan.c | 2 +-
src/backend/executor/nodeTidscan.c | 2 +-
src/backend/executor/nodeUnique.c | 2 +-
src/backend/executor/nodeValuesscan.c | 2 +-
src/backend/executor/nodeWindowAgg.c | 2 +-
src/backend/executor/nodeWorktablescan.c | 2 +-
src/backend/executor/spi.c | 2 +-
src/backend/executor/tstoreReceiver.c | 2 +-
src/backend/foreign/foreign.c | 2 +-
src/backend/lib/dllist.c | 2 +-
src/backend/lib/stringinfo.c | 2 +-
src/backend/libpq/auth.c | 2 +-
src/backend/libpq/be-fsstubs.c | 2 +-
src/backend/libpq/be-secure.c | 2 +-
src/backend/libpq/crypt.c | 2 +-
src/backend/libpq/hba.c | 2 +-
src/backend/libpq/ip.c | 2 +-
src/backend/libpq/md5.c | 2 +-
src/backend/libpq/pqcomm.c | 2 +-
src/backend/libpq/pqformat.c | 2 +-
src/backend/libpq/pqsignal.c | 2 +-
src/backend/main/main.c | 2 +-
src/backend/nodes/bitmapset.c | 2 +-
src/backend/nodes/copyfuncs.c | 2 +-
src/backend/nodes/equalfuncs.c | 2 +-
src/backend/nodes/list.c | 2 +-
src/backend/nodes/makefuncs.c | 2 +-
src/backend/nodes/nodeFuncs.c | 2 +-
src/backend/nodes/nodes.c | 2 +-
src/backend/nodes/outfuncs.c | 2 +-
src/backend/nodes/params.c | 2 +-
src/backend/nodes/print.c | 2 +-
src/backend/nodes/read.c | 2 +-
src/backend/nodes/readfuncs.c | 2 +-
src/backend/nodes/tidbitmap.c | 2 +-
src/backend/nodes/value.c | 2 +-
src/backend/optimizer/geqo/geqo_copy.c | 2 +-
src/backend/optimizer/geqo/geqo_eval.c | 2 +-
src/backend/optimizer/geqo/geqo_main.c | 2 +-
src/backend/optimizer/geqo/geqo_misc.c | 2 +-
src/backend/optimizer/geqo/geqo_pool.c | 2 +-
src/backend/optimizer/geqo/geqo_random.c | 2 +-
src/backend/optimizer/geqo/geqo_selection.c | 2 +-
src/backend/optimizer/path/allpaths.c | 2 +-
src/backend/optimizer/path/clausesel.c | 2 +-
src/backend/optimizer/path/costsize.c | 2 +-
src/backend/optimizer/path/equivclass.c | 2 +-
src/backend/optimizer/path/indxpath.c | 2 +-
src/backend/optimizer/path/joinpath.c | 2 +-
src/backend/optimizer/path/joinrels.c | 2 +-
src/backend/optimizer/path/orindxpath.c | 2 +-
src/backend/optimizer/path/pathkeys.c | 2 +-
src/backend/optimizer/path/tidpath.c | 2 +-
src/backend/optimizer/plan/analyzejoins.c | 2 +-
src/backend/optimizer/plan/createplan.c | 2 +-
src/backend/optimizer/plan/initsplan.c | 2 +-
src/backend/optimizer/plan/planagg.c | 2 +-
src/backend/optimizer/plan/planmain.c | 2 +-
src/backend/optimizer/plan/planner.c | 2 +-
src/backend/optimizer/plan/setrefs.c | 2 +-
src/backend/optimizer/plan/subselect.c | 2 +-
src/backend/optimizer/prep/prepjointree.c | 2 +-
src/backend/optimizer/prep/prepqual.c | 2 +-
src/backend/optimizer/prep/preptlist.c | 2 +-
src/backend/optimizer/prep/prepunion.c | 2 +-
src/backend/optimizer/util/clauses.c | 2 +-
src/backend/optimizer/util/joininfo.c | 2 +-
src/backend/optimizer/util/pathnode.c | 2 +-
src/backend/optimizer/util/placeholder.c | 2 +-
src/backend/optimizer/util/plancat.c | 2 +-
src/backend/optimizer/util/predtest.c | 2 +-
src/backend/optimizer/util/relnode.c | 2 +-
src/backend/optimizer/util/restrictinfo.c | 2 +-
src/backend/optimizer/util/tlist.c | 2 +-
src/backend/optimizer/util/var.c | 2 +-
src/backend/parser/analyze.c | 2 +-
src/backend/parser/gram.y | 2 +-
src/backend/parser/keywords.c | 2 +-
src/backend/parser/kwlookup.c | 2 +-
src/backend/parser/parse_agg.c | 2 +-
src/backend/parser/parse_clause.c | 2 +-
src/backend/parser/parse_coerce.c | 2 +-
src/backend/parser/parse_cte.c | 2 +-
src/backend/parser/parse_expr.c | 2 +-
src/backend/parser/parse_func.c | 2 +-
src/backend/parser/parse_node.c | 2 +-
src/backend/parser/parse_oper.c | 2 +-
src/backend/parser/parse_param.c | 2 +-
src/backend/parser/parse_relation.c | 2 +-
src/backend/parser/parse_target.c | 2 +-
src/backend/parser/parse_type.c | 2 +-
src/backend/parser/parse_utilcmd.c | 2 +-
src/backend/parser/parser.c | 2 +-
src/backend/parser/scan.l | 2 +-
src/backend/parser/scansup.c | 2 +-
src/backend/port/dynloader/aix.h | 2 +-
src/backend/port/dynloader/bsdi.c | 2 +-
src/backend/port/dynloader/bsdi.h | 2 +-
src/backend/port/dynloader/cygwin.h | 2 +-
src/backend/port/dynloader/dgux.h | 2 +-
src/backend/port/dynloader/freebsd.c | 2 +-
src/backend/port/dynloader/freebsd.h | 2 +-
src/backend/port/dynloader/hpux.c | 2 +-
src/backend/port/dynloader/hpux.h | 2 +-
src/backend/port/dynloader/irix.h | 2 +-
src/backend/port/dynloader/linux.c | 2 +-
src/backend/port/dynloader/linux.h | 2 +-
src/backend/port/dynloader/netbsd.c | 2 +-
src/backend/port/dynloader/netbsd.h | 2 +-
src/backend/port/dynloader/openbsd.c | 2 +-
src/backend/port/dynloader/openbsd.h | 2 +-
src/backend/port/dynloader/osf.h | 2 +-
src/backend/port/dynloader/sco.h | 2 +-
src/backend/port/dynloader/solaris.h | 2 +-
src/backend/port/dynloader/sunos4.h | 2 +-
src/backend/port/dynloader/svr4.h | 2 +-
src/backend/port/dynloader/ultrix4.c | 2 +-
src/backend/port/dynloader/ultrix4.h | 2 +-
src/backend/port/dynloader/univel.h | 2 +-
src/backend/port/dynloader/unixware.h | 2 +-
src/backend/port/ipc_test.c | 2 +-
src/backend/port/posix_sema.c | 2 +-
src/backend/port/sysv_sema.c | 2 +-
src/backend/port/sysv_shmem.c | 2 +-
src/backend/port/tas/sunstudio_sparc.s | 2 +-
src/backend/port/tas/sunstudio_x86.s | 2 +-
src/backend/port/unix_latch.c | 2 +-
src/backend/port/win32/crashdump.c | 2 +-
src/backend/port/win32/mingwcompat.c | 2 +-
src/backend/port/win32/security.c | 2 +-
src/backend/port/win32/signal.c | 2 +-
src/backend/port/win32/socket.c | 2 +-
src/backend/port/win32/timer.c | 2 +-
src/backend/port/win32_latch.c | 2 +-
src/backend/port/win32_sema.c | 2 +-
src/backend/port/win32_shmem.c | 2 +-
src/backend/postmaster/autovacuum.c | 2 +-
src/backend/postmaster/bgwriter.c | 2 +-
src/backend/postmaster/fork_process.c | 2 +-
src/backend/postmaster/pgarch.c | 2 +-
src/backend/postmaster/pgstat.c | 2 +-
src/backend/postmaster/postmaster.c | 2 +-
src/backend/postmaster/syslogger.c | 2 +-
src/backend/postmaster/walwriter.c | 2 +-
src/backend/replication/libpqwalreceiver/libpqwalreceiver.c | 2 +-
src/backend/replication/walreceiver.c | 2 +-
src/backend/replication/walreceiverfuncs.c | 2 +-
src/backend/replication/walsender.c | 2 +-
src/backend/rewrite/rewriteDefine.c | 2 +-
src/backend/rewrite/rewriteHandler.c | 2 +-
src/backend/rewrite/rewriteManip.c | 2 +-
src/backend/rewrite/rewriteRemove.c | 2 +-
src/backend/rewrite/rewriteSupport.c | 2 +-
src/backend/snowball/dict_snowball.c | 2 +-
src/backend/storage/buffer/buf_init.c | 2 +-
src/backend/storage/buffer/buf_table.c | 2 +-
src/backend/storage/buffer/bufmgr.c | 2 +-
src/backend/storage/buffer/freelist.c | 2 +-
src/backend/storage/buffer/localbuf.c | 2 +-
src/backend/storage/file/buffile.c | 2 +-
src/backend/storage/file/copydir.c | 2 +-
src/backend/storage/file/fd.c | 2 +-
src/backend/storage/file/reinit.c | 2 +-
src/backend/storage/freespace/freespace.c | 2 +-
src/backend/storage/freespace/fsmpage.c | 2 +-
src/backend/storage/freespace/indexfsm.c | 2 +-
src/backend/storage/ipc/ipc.c | 2 +-
src/backend/storage/ipc/ipci.c | 2 +-
src/backend/storage/ipc/pmsignal.c | 2 +-
src/backend/storage/ipc/procarray.c | 2 +-
src/backend/storage/ipc/procsignal.c | 2 +-
src/backend/storage/ipc/shmem.c | 2 +-
src/backend/storage/ipc/shmqueue.c | 2 +-
src/backend/storage/ipc/sinval.c | 2 +-
src/backend/storage/ipc/sinvaladt.c | 2 +-
src/backend/storage/ipc/standby.c | 2 +-
src/backend/storage/large_object/inv_api.c | 2 +-
src/backend/storage/lmgr/deadlock.c | 2 +-
src/backend/storage/lmgr/lmgr.c | 2 +-
src/backend/storage/lmgr/lock.c | 2 +-
src/backend/storage/lmgr/lwlock.c | 2 +-
src/backend/storage/lmgr/proc.c | 2 +-
src/backend/storage/lmgr/s_lock.c | 2 +-
src/backend/storage/lmgr/spin.c | 2 +-
src/backend/storage/page/bufpage.c | 2 +-
src/backend/storage/page/itemptr.c | 2 +-
src/backend/storage/smgr/md.c | 2 +-
src/backend/storage/smgr/smgr.c | 2 +-
src/backend/storage/smgr/smgrtype.c | 2 +-
src/backend/tcop/dest.c | 2 +-
src/backend/tcop/fastpath.c | 2 +-
src/backend/tcop/postgres.c | 2 +-
src/backend/tcop/pquery.c | 2 +-
src/backend/tcop/utility.c | 2 +-
src/backend/tsearch/Makefile | 2 +-
src/backend/tsearch/dict.c | 2 +-
src/backend/tsearch/dict_ispell.c | 2 +-
src/backend/tsearch/dict_simple.c | 2 +-
src/backend/tsearch/dict_synonym.c | 2 +-
src/backend/tsearch/dict_thesaurus.c | 2 +-
src/backend/tsearch/regis.c | 2 +-
src/backend/tsearch/spell.c | 2 +-
src/backend/tsearch/to_tsany.c | 2 +-
src/backend/tsearch/ts_locale.c | 2 +-
src/backend/tsearch/ts_parse.c | 2 +-
src/backend/tsearch/ts_selfuncs.c | 2 +-
src/backend/tsearch/ts_typanalyze.c | 2 +-
src/backend/tsearch/ts_utils.c | 2 +-
src/backend/tsearch/wparser.c | 2 +-
src/backend/tsearch/wparser_def.c | 2 +-
src/backend/utils/Gen_dummy_probes.sed | 2 +-
src/backend/utils/Gen_fmgrtab.pl | 6 +++---
src/backend/utils/adt/acl.c | 2 +-
src/backend/utils/adt/array_userfuncs.c | 2 +-
src/backend/utils/adt/arrayfuncs.c | 2 +-
src/backend/utils/adt/arrayutils.c | 2 +-
src/backend/utils/adt/ascii.c | 2 +-
src/backend/utils/adt/bool.c | 2 +-
src/backend/utils/adt/char.c | 2 +-
src/backend/utils/adt/date.c | 2 +-
src/backend/utils/adt/datetime.c | 2 +-
src/backend/utils/adt/datum.c | 2 +-
src/backend/utils/adt/dbsize.c | 2 +-
src/backend/utils/adt/domains.c | 2 +-
src/backend/utils/adt/encode.c | 2 +-
src/backend/utils/adt/enum.c | 2 +-
src/backend/utils/adt/float.c | 2 +-
src/backend/utils/adt/format_type.c | 2 +-
src/backend/utils/adt/formatting.c | 2 +-
src/backend/utils/adt/genfile.c | 2 +-
src/backend/utils/adt/geo_ops.c | 2 +-
src/backend/utils/adt/geo_selfuncs.c | 2 +-
src/backend/utils/adt/int.c | 2 +-
src/backend/utils/adt/int8.c | 2 +-
src/backend/utils/adt/like.c | 2 +-
src/backend/utils/adt/like_match.c | 2 +-
src/backend/utils/adt/lockfuncs.c | 2 +-
src/backend/utils/adt/misc.c | 2 +-
src/backend/utils/adt/nabstime.c | 2 +-
src/backend/utils/adt/name.c | 2 +-
src/backend/utils/adt/numeric.c | 2 +-
src/backend/utils/adt/numutils.c | 2 +-
src/backend/utils/adt/oid.c | 2 +-
src/backend/utils/adt/oracle_compat.c | 2 +-
src/backend/utils/adt/pg_locale.c | 2 +-
src/backend/utils/adt/pg_lzcompress.c | 2 +-
src/backend/utils/adt/pgstatfuncs.c | 2 +-
src/backend/utils/adt/pseudotypes.c | 2 +-
src/backend/utils/adt/quote.c | 2 +-
src/backend/utils/adt/regexp.c | 2 +-
src/backend/utils/adt/regproc.c | 2 +-
src/backend/utils/adt/ri_triggers.c | 2 +-
src/backend/utils/adt/rowtypes.c | 2 +-
src/backend/utils/adt/ruleutils.c | 2 +-
src/backend/utils/adt/selfuncs.c | 2 +-
src/backend/utils/adt/tid.c | 2 +-
src/backend/utils/adt/timestamp.c | 2 +-
src/backend/utils/adt/trigfuncs.c | 2 +-
src/backend/utils/adt/tsginidx.c | 2 +-
src/backend/utils/adt/tsgistidx.c | 2 +-
src/backend/utils/adt/tsquery.c | 2 +-
src/backend/utils/adt/tsquery_cleanup.c | 2 +-
src/backend/utils/adt/tsquery_gist.c | 2 +-
src/backend/utils/adt/tsquery_op.c | 2 +-
src/backend/utils/adt/tsquery_rewrite.c | 2 +-
src/backend/utils/adt/tsquery_util.c | 2 +-
src/backend/utils/adt/tsrank.c | 2 +-
src/backend/utils/adt/tsvector.c | 2 +-
src/backend/utils/adt/tsvector_op.c | 2 +-
src/backend/utils/adt/tsvector_parser.c | 2 +-
src/backend/utils/adt/txid.c | 2 +-
src/backend/utils/adt/uuid.c | 2 +-
src/backend/utils/adt/varbit.c | 2 +-
src/backend/utils/adt/varchar.c | 2 +-
src/backend/utils/adt/varlena.c | 2 +-
src/backend/utils/adt/version.c | 2 +-
src/backend/utils/adt/windowfuncs.c | 2 +-
src/backend/utils/adt/xid.c | 2 +-
src/backend/utils/adt/xml.c | 2 +-
src/backend/utils/cache/attoptcache.c | 2 +-
src/backend/utils/cache/catcache.c | 2 +-
src/backend/utils/cache/inval.c | 2 +-
src/backend/utils/cache/lsyscache.c | 2 +-
src/backend/utils/cache/plancache.c | 2 +-
src/backend/utils/cache/relcache.c | 2 +-
src/backend/utils/cache/relmapper.c | 2 +-
src/backend/utils/cache/spccache.c | 2 +-
src/backend/utils/cache/syscache.c | 2 +-
src/backend/utils/cache/ts_cache.c | 2 +-
src/backend/utils/cache/typcache.c | 2 +-
src/backend/utils/error/assert.c | 2 +-
src/backend/utils/error/elog.c | 2 +-
src/backend/utils/fmgr/dfmgr.c | 2 +-
src/backend/utils/fmgr/fmgr.c | 2 +-
src/backend/utils/fmgr/funcapi.c | 2 +-
src/backend/utils/hash/dynahash.c | 2 +-
src/backend/utils/hash/hashfn.c | 2 +-
src/backend/utils/hash/pg_crc.c | 2 +-
src/backend/utils/init/globals.c | 2 +-
src/backend/utils/init/miscinit.c | 2 +-
src/backend/utils/init/postinit.c | 2 +-
src/backend/utils/mb/Unicode/Makefile | 2 +-
src/backend/utils/mb/Unicode/UCS_to_BIG5.pl | 2 +-
src/backend/utils/mb/Unicode/UCS_to_EUC_CN.pl | 2 +-
src/backend/utils/mb/Unicode/UCS_to_EUC_JIS_2004.pl | 2 +-
src/backend/utils/mb/Unicode/UCS_to_EUC_JP.pl | 2 +-
src/backend/utils/mb/Unicode/UCS_to_EUC_KR.pl | 2 +-
src/backend/utils/mb/Unicode/UCS_to_EUC_TW.pl | 2 +-
src/backend/utils/mb/Unicode/UCS_to_GB18030.pl | 2 +-
src/backend/utils/mb/Unicode/UCS_to_SHIFT_JIS_2004.pl | 2 +-
src/backend/utils/mb/Unicode/UCS_to_SJIS.pl | 2 +-
src/backend/utils/mb/Unicode/UCS_to_most.pl | 2 +-
src/backend/utils/mb/Unicode/ucs2utf.pl | 2 +-
src/backend/utils/mb/conv.c | 2 +-
src/backend/utils/mb/conversion_procs/ascii_and_mic/ascii_and_mic.c | 2 +-
.../utils/mb/conversion_procs/cyrillic_and_mic/cyrillic_and_mic.c | 2 +-
.../utils/mb/conversion_procs/euc2004_sjis2004/euc2004_sjis2004.c | 2 +-
.../utils/mb/conversion_procs/euc_cn_and_mic/euc_cn_and_mic.c | 2 +-
.../utils/mb/conversion_procs/euc_jp_and_sjis/euc_jp_and_sjis.c | 2 +-
.../utils/mb/conversion_procs/euc_kr_and_mic/euc_kr_and_mic.c | 2 +-
.../utils/mb/conversion_procs/euc_tw_and_big5/euc_tw_and_big5.c | 2 +-
.../mb/conversion_procs/latin2_and_win1250/latin2_and_win1250.c | 2 +-
src/backend/utils/mb/conversion_procs/latin_and_mic/latin_and_mic.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_ascii/utf8_and_ascii.c | 2 +-
src/backend/utils/mb/conversion_procs/utf8_and_big5/utf8_and_big5.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_cyrillic/utf8_and_cyrillic.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_euc2004/utf8_and_euc2004.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_euc_cn/utf8_and_euc_cn.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_euc_jp/utf8_and_euc_jp.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_euc_kr/utf8_and_euc_kr.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_euc_tw/utf8_and_euc_tw.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_gb18030/utf8_and_gb18030.c | 2 +-
src/backend/utils/mb/conversion_procs/utf8_and_gbk/utf8_and_gbk.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_iso8859/utf8_and_iso8859.c | 2 +-
.../mb/conversion_procs/utf8_and_iso8859_1/utf8_and_iso8859_1.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_johab/utf8_and_johab.c | 2 +-
src/backend/utils/mb/conversion_procs/utf8_and_sjis/utf8_and_sjis.c | 2 +-
.../utils/mb/conversion_procs/utf8_and_sjis2004/utf8_and_sjis2004.c | 2 +-
src/backend/utils/mb/conversion_procs/utf8_and_uhc/utf8_and_uhc.c | 2 +-
src/backend/utils/mb/conversion_procs/utf8_and_win/utf8_and_win.c | 2 +-
src/backend/utils/misc/guc-file.l | 2 +-
src/backend/utils/misc/guc.c | 2 +-
src/backend/utils/misc/help_config.c | 2 +-
src/backend/utils/misc/pg_rusage.c | 2 +-
src/backend/utils/misc/ps_status.c | 2 +-
src/backend/utils/misc/rbtree.c | 2 +-
src/backend/utils/misc/superuser.c | 2 +-
src/backend/utils/misc/tzparser.c | 2 +-
src/backend/utils/mmgr/aset.c | 2 +-
src/backend/utils/mmgr/mcxt.c | 2 +-
src/backend/utils/mmgr/portalmem.c | 2 +-
src/backend/utils/probes.d | 2 +-
src/backend/utils/resowner/resowner.c | 2 +-
src/backend/utils/sort/logtape.c | 2 +-
src/backend/utils/sort/tuplesort.c | 2 +-
src/backend/utils/sort/tuplestore.c | 2 +-
src/backend/utils/time/combocid.c | 2 +-
src/backend/utils/time/snapmgr.c | 2 +-
src/backend/utils/time/tqual.c | 2 +-
src/bin/Makefile | 2 +-
src/bin/initdb/Makefile | 2 +-
src/bin/initdb/initdb.c | 2 +-
src/bin/pg_config/Makefile | 2 +-
src/bin/pg_config/pg_config.c | 2 +-
src/bin/pg_controldata/Makefile | 2 +-
src/bin/pg_ctl/Makefile | 2 +-
src/bin/pg_ctl/pg_ctl.c | 2 +-
src/bin/pg_dump/Makefile | 2 +-
src/bin/pg_dump/common.c | 2 +-
src/bin/pg_dump/compress_io.c | 2 +-
src/bin/pg_dump/compress_io.h | 2 +-
src/bin/pg_dump/dumputils.c | 2 +-
src/bin/pg_dump/dumputils.h | 2 +-
src/bin/pg_dump/keywords.c | 2 +-
src/bin/pg_dump/pg_dump.c | 2 +-
src/bin/pg_dump/pg_dump.h | 2 +-
src/bin/pg_dump/pg_dump_sort.c | 2 +-
src/bin/pg_dump/pg_dumpall.c | 2 +-
src/bin/pg_resetxlog/Makefile | 2 +-
src/bin/pg_resetxlog/pg_resetxlog.c | 2 +-
src/bin/pgevent/Makefile | 2 +-
src/bin/psql/Makefile | 2 +-
src/bin/psql/command.c | 2 +-
src/bin/psql/command.h | 2 +-
src/bin/psql/common.c | 2 +-
src/bin/psql/common.h | 2 +-
src/bin/psql/copy.c | 2 +-
src/bin/psql/copy.h | 2 +-
src/bin/psql/create_help.pl | 2 +-
src/bin/psql/describe.c | 2 +-
src/bin/psql/describe.h | 2 +-
src/bin/psql/help.c | 4 ++--
src/bin/psql/help.h | 2 +-
src/bin/psql/input.c | 2 +-
src/bin/psql/input.h | 2 +-
src/bin/psql/large_obj.c | 2 +-
src/bin/psql/large_obj.h | 2 +-
src/bin/psql/mainloop.c | 2 +-
src/bin/psql/mainloop.h | 2 +-
src/bin/psql/mbprint.c | 2 +-
src/bin/psql/print.c | 2 +-
src/bin/psql/print.h | 2 +-
src/bin/psql/prompt.c | 2 +-
src/bin/psql/prompt.h | 2 +-
src/bin/psql/psqlscan.h | 2 +-
src/bin/psql/psqlscan.l | 2 +-
src/bin/psql/settings.h | 2 +-
src/bin/psql/startup.c | 2 +-
src/bin/psql/stringutils.c | 2 +-
src/bin/psql/stringutils.h | 2 +-
src/bin/psql/tab-complete.c | 2 +-
src/bin/psql/tab-complete.h | 2 +-
src/bin/psql/variables.c | 2 +-
src/bin/psql/variables.h | 2 +-
src/bin/scripts/Makefile | 2 +-
src/bin/scripts/clusterdb.c | 2 +-
src/bin/scripts/common.c | 2 +-
src/bin/scripts/common.h | 2 +-
src/bin/scripts/createdb.c | 2 +-
src/bin/scripts/createlang.c | 2 +-
src/bin/scripts/createuser.c | 2 +-
src/bin/scripts/dropdb.c | 2 +-
src/bin/scripts/droplang.c | 2 +-
src/bin/scripts/dropuser.c | 2 +-
src/bin/scripts/reindexdb.c | 2 +-
src/bin/scripts/vacuumdb.c | 2 +-
src/include/access/attnum.h | 2 +-
src/include/access/clog.h | 2 +-
src/include/access/genam.h | 2 +-
src/include/access/gin.h | 2 +-
src/include/access/gist.h | 2 +-
src/include/access/gist_private.h | 2 +-
src/include/access/gistscan.h | 2 +-
src/include/access/hash.h | 2 +-
src/include/access/heapam.h | 2 +-
src/include/access/hio.h | 2 +-
src/include/access/htup.h | 2 +-
src/include/access/itup.h | 2 +-
src/include/access/multixact.h | 2 +-
src/include/access/nbtree.h | 2 +-
src/include/access/printtup.h | 2 +-
src/include/access/reloptions.h | 2 +-
src/include/access/relscan.h | 2 +-
src/include/access/rewriteheap.h | 2 +-
src/include/access/sdir.h | 2 +-
src/include/access/skey.h | 2 +-
src/include/access/slru.h | 2 +-
src/include/access/subtrans.h | 2 +-
src/include/access/sysattr.h | 2 +-
src/include/access/transam.h | 2 +-
src/include/access/tupconvert.h | 2 +-
src/include/access/tupdesc.h | 2 +-
src/include/access/tupmacs.h | 2 +-
src/include/access/tuptoaster.h | 2 +-
src/include/access/twophase.h | 2 +-
src/include/access/twophase_rmgr.h | 2 +-
src/include/access/valid.h | 2 +-
src/include/access/visibilitymap.h | 2 +-
src/include/access/xact.h | 2 +-
src/include/access/xlog.h | 2 +-
src/include/access/xlog_internal.h | 2 +-
src/include/access/xlogdefs.h | 2 +-
src/include/access/xlogutils.h | 2 +-
src/include/bootstrap/bootstrap.h | 2 +-
src/include/c.h | 2 +-
src/include/catalog/catalog.h | 2 +-
src/include/catalog/catversion.h | 2 +-
src/include/catalog/dependency.h | 2 +-
src/include/catalog/genbki.h | 2 +-
src/include/catalog/heap.h | 2 +-
src/include/catalog/index.h | 2 +-
src/include/catalog/indexing.h | 2 +-
src/include/catalog/namespace.h | 2 +-
src/include/catalog/objectaccess.h | 2 +-
src/include/catalog/objectaddress.h | 2 +-
src/include/catalog/pg_aggregate.h | 2 +-
src/include/catalog/pg_am.h | 2 +-
src/include/catalog/pg_amop.h | 2 +-
src/include/catalog/pg_amproc.h | 2 +-
src/include/catalog/pg_attrdef.h | 2 +-
src/include/catalog/pg_attribute.h | 2 +-
src/include/catalog/pg_auth_members.h | 2 +-
src/include/catalog/pg_authid.h | 2 +-
src/include/catalog/pg_cast.h | 2 +-
src/include/catalog/pg_class.h | 2 +-
src/include/catalog/pg_constraint.h | 2 +-
src/include/catalog/pg_control.h | 2 +-
src/include/catalog/pg_conversion.h | 2 +-
src/include/catalog/pg_conversion_fn.h | 2 +-
src/include/catalog/pg_database.h | 2 +-
src/include/catalog/pg_db_role_setting.h | 2 +-
src/include/catalog/pg_default_acl.h | 2 +-
src/include/catalog/pg_depend.h | 2 +-
src/include/catalog/pg_description.h | 2 +-
src/include/catalog/pg_enum.h | 2 +-
src/include/catalog/pg_foreign_data_wrapper.h | 2 +-
src/include/catalog/pg_foreign_server.h | 2 +-
src/include/catalog/pg_index.h | 2 +-
src/include/catalog/pg_inherits.h | 2 +-
src/include/catalog/pg_inherits_fn.h | 2 +-
src/include/catalog/pg_language.h | 2 +-
src/include/catalog/pg_largeobject.h | 2 +-
src/include/catalog/pg_largeobject_metadata.h | 2 +-
src/include/catalog/pg_namespace.h | 2 +-
src/include/catalog/pg_opclass.h | 2 +-
src/include/catalog/pg_operator.h | 2 +-
src/include/catalog/pg_opfamily.h | 2 +-
src/include/catalog/pg_pltemplate.h | 2 +-
src/include/catalog/pg_proc.h | 2 +-
src/include/catalog/pg_proc_fn.h | 2 +-
src/include/catalog/pg_rewrite.h | 2 +-
src/include/catalog/pg_seclabel.h | 2 +-
src/include/catalog/pg_shdepend.h | 2 +-
src/include/catalog/pg_shdescription.h | 2 +-
src/include/catalog/pg_statistic.h | 2 +-
src/include/catalog/pg_tablespace.h | 2 +-
src/include/catalog/pg_trigger.h | 2 +-
src/include/catalog/pg_ts_config.h | 2 +-
src/include/catalog/pg_ts_config_map.h | 2 +-
src/include/catalog/pg_ts_dict.h | 2 +-
src/include/catalog/pg_ts_parser.h | 2 +-
src/include/catalog/pg_ts_template.h | 2 +-
src/include/catalog/pg_type.h | 2 +-
src/include/catalog/pg_type_fn.h | 2 +-
src/include/catalog/pg_user_mapping.h | 2 +-
src/include/catalog/storage.h | 2 +-
src/include/catalog/toasting.h | 2 +-
src/include/commands/alter.h | 2 +-
src/include/commands/async.h | 2 +-
src/include/commands/cluster.h | 2 +-
src/include/commands/comment.h | 2 +-
src/include/commands/conversioncmds.h | 2 +-
src/include/commands/copy.h | 2 +-
src/include/commands/dbcommands.h | 2 +-
src/include/commands/defrem.h | 2 +-
src/include/commands/discard.h | 2 +-
src/include/commands/explain.h | 2 +-
src/include/commands/lockcmds.h | 2 +-
src/include/commands/portalcmds.h | 2 +-
src/include/commands/prepare.h | 2 +-
src/include/commands/schemacmds.h | 2 +-
src/include/commands/seclabel.h | 2 +-
src/include/commands/sequence.h | 2 +-
src/include/commands/tablecmds.h | 2 +-
src/include/commands/tablespace.h | 2 +-
src/include/commands/trigger.h | 2 +-
src/include/commands/typecmds.h | 2 +-
src/include/commands/vacuum.h | 2 +-
src/include/commands/variable.h | 2 +-
src/include/commands/view.h | 2 +-
src/include/executor/execdebug.h | 2 +-
src/include/executor/execdesc.h | 2 +-
src/include/executor/executor.h | 2 +-
src/include/executor/functions.h | 2 +-
src/include/executor/hashjoin.h | 2 +-
src/include/executor/instrument.h | 2 +-
src/include/executor/nodeAgg.h | 2 +-
src/include/executor/nodeAppend.h | 2 +-
src/include/executor/nodeBitmapAnd.h | 2 +-
src/include/executor/nodeBitmapHeapscan.h | 2 +-
src/include/executor/nodeBitmapIndexscan.h | 2 +-
src/include/executor/nodeBitmapOr.h | 2 +-
src/include/executor/nodeCtescan.h | 2 +-
src/include/executor/nodeFunctionscan.h | 2 +-
src/include/executor/nodeGroup.h | 2 +-
src/include/executor/nodeHash.h | 2 +-
src/include/executor/nodeHashjoin.h | 2 +-
src/include/executor/nodeIndexscan.h | 2 +-
src/include/executor/nodeLimit.h | 2 +-
src/include/executor/nodeLockRows.h | 2 +-
src/include/executor/nodeMaterial.h | 2 +-
src/include/executor/nodeMergeAppend.h | 2 +-
src/include/executor/nodeMergejoin.h | 2 +-
src/include/executor/nodeModifyTable.h | 2 +-
src/include/executor/nodeNestloop.h | 2 +-
src/include/executor/nodeRecursiveunion.h | 2 +-
src/include/executor/nodeResult.h | 2 +-
src/include/executor/nodeSeqscan.h | 2 +-
src/include/executor/nodeSetOp.h | 2 +-
src/include/executor/nodeSort.h | 2 +-
src/include/executor/nodeSubplan.h | 2 +-
src/include/executor/nodeSubqueryscan.h | 2 +-
src/include/executor/nodeTidscan.h | 2 +-
src/include/executor/nodeUnique.h | 2 +-
src/include/executor/nodeValuesscan.h | 2 +-
src/include/executor/nodeWindowAgg.h | 2 +-
src/include/executor/nodeWorktablescan.h | 2 +-
src/include/executor/spi.h | 2 +-
src/include/executor/spi_priv.h | 2 +-
src/include/executor/tstoreReceiver.h | 2 +-
src/include/executor/tuptable.h | 2 +-
src/include/fmgr.h | 2 +-
src/include/foreign/foreign.h | 2 +-
src/include/funcapi.h | 2 +-
src/include/getaddrinfo.h | 2 +-
src/include/getopt_long.h | 2 +-
src/include/lib/dllist.h | 2 +-
src/include/lib/stringinfo.h | 2 +-
src/include/libpq/auth.h | 2 +-
src/include/libpq/be-fsstubs.h | 2 +-
src/include/libpq/crypt.h | 2 +-
src/include/libpq/ip.h | 2 +-
src/include/libpq/libpq-be.h | 2 +-
src/include/libpq/libpq-fs.h | 2 +-
src/include/libpq/libpq.h | 2 +-
src/include/libpq/md5.h | 2 +-
src/include/libpq/pqcomm.h | 2 +-
src/include/libpq/pqformat.h | 2 +-
src/include/libpq/pqsignal.h | 2 +-
src/include/mb/pg_wchar.h | 2 +-
src/include/miscadmin.h | 2 +-
src/include/nodes/bitmapset.h | 2 +-
src/include/nodes/execnodes.h | 2 +-
src/include/nodes/makefuncs.h | 2 +-
src/include/nodes/memnodes.h | 2 +-
src/include/nodes/nodeFuncs.h | 2 +-
src/include/nodes/nodes.h | 2 +-
src/include/nodes/params.h | 2 +-
src/include/nodes/parsenodes.h | 2 +-
src/include/nodes/pg_list.h | 2 +-
src/include/nodes/plannodes.h | 2 +-
src/include/nodes/primnodes.h | 2 +-
src/include/nodes/print.h | 2 +-
src/include/nodes/readfuncs.h | 2 +-
src/include/nodes/relation.h | 2 +-
src/include/nodes/tidbitmap.h | 2 +-
src/include/nodes/value.h | 2 +-
src/include/optimizer/clauses.h | 2 +-
src/include/optimizer/cost.h | 2 +-
src/include/optimizer/geqo.h | 2 +-
src/include/optimizer/geqo_copy.h | 2 +-
src/include/optimizer/geqo_gene.h | 2 +-
src/include/optimizer/geqo_misc.h | 2 +-
src/include/optimizer/geqo_mutation.h | 2 +-
src/include/optimizer/geqo_pool.h | 2 +-
src/include/optimizer/geqo_random.h | 2 +-
src/include/optimizer/geqo_recombination.h | 2 +-
src/include/optimizer/geqo_selection.h | 2 +-
src/include/optimizer/joininfo.h | 2 +-
src/include/optimizer/pathnode.h | 2 +-
src/include/optimizer/paths.h | 2 +-
src/include/optimizer/placeholder.h | 2 +-
src/include/optimizer/plancat.h | 2 +-
src/include/optimizer/planmain.h | 2 +-
src/include/optimizer/planner.h | 2 +-
src/include/optimizer/predtest.h | 2 +-
src/include/optimizer/prep.h | 2 +-
src/include/optimizer/restrictinfo.h | 2 +-
src/include/optimizer/subselect.h | 2 +-
src/include/optimizer/tlist.h | 2 +-
src/include/optimizer/var.h | 2 +-
src/include/parser/analyze.h | 2 +-
src/include/parser/gramparse.h | 2 +-
src/include/parser/keywords.h | 2 +-
src/include/parser/kwlist.h | 2 +-
src/include/parser/parse_agg.h | 2 +-
src/include/parser/parse_clause.h | 2 +-
src/include/parser/parse_coerce.h | 2 +-
src/include/parser/parse_cte.h | 2 +-
src/include/parser/parse_expr.h | 2 +-
src/include/parser/parse_func.h | 2 +-
src/include/parser/parse_node.h | 2 +-
src/include/parser/parse_oper.h | 2 +-
src/include/parser/parse_param.h | 2 +-
src/include/parser/parse_relation.h | 2 +-
src/include/parser/parse_target.h | 2 +-
src/include/parser/parse_type.h | 2 +-
src/include/parser/parse_utilcmd.h | 2 +-
src/include/parser/parser.h | 2 +-
src/include/parser/parsetree.h | 2 +-
src/include/parser/scanner.h | 2 +-
src/include/parser/scansup.h | 2 +-
src/include/pg_trace.h | 2 +-
src/include/pgstat.h | 2 +-
src/include/pgtime.h | 2 +-
src/include/port.h | 2 +-
src/include/portability/instr_time.h | 2 +-
src/include/postgres.h | 2 +-
src/include/postgres_fe.h | 2 +-
src/include/postmaster/autovacuum.h | 2 +-
src/include/postmaster/bgwriter.h | 2 +-
src/include/postmaster/fork_process.h | 2 +-
src/include/postmaster/pgarch.h | 2 +-
src/include/postmaster/postmaster.h | 2 +-
src/include/postmaster/syslogger.h | 2 +-
src/include/postmaster/walwriter.h | 2 +-
src/include/replication/walprotocol.h | 2 +-
src/include/replication/walreceiver.h | 2 +-
src/include/replication/walsender.h | 2 +-
src/include/rewrite/prs2lock.h | 2 +-
src/include/rewrite/rewriteDefine.h | 2 +-
src/include/rewrite/rewriteHandler.h | 2 +-
src/include/rewrite/rewriteManip.h | 2 +-
src/include/rewrite/rewriteRemove.h | 2 +-
src/include/rewrite/rewriteSupport.h | 2 +-
src/include/rusagestub.h | 2 +-
src/include/snowball/header.h | 2 +-
src/include/storage/backendid.h | 2 +-
src/include/storage/block.h | 2 +-
src/include/storage/buf.h | 2 +-
src/include/storage/buf_internals.h | 2 +-
src/include/storage/buffile.h | 2 +-
src/include/storage/bufmgr.h | 2 +-
src/include/storage/bufpage.h | 2 +-
src/include/storage/copydir.h | 2 +-
src/include/storage/fd.h | 2 +-
src/include/storage/freespace.h | 2 +-
src/include/storage/fsm_internals.h | 2 +-
src/include/storage/indexfsm.h | 2 +-
src/include/storage/ipc.h | 2 +-
src/include/storage/item.h | 2 +-
src/include/storage/itemid.h | 2 +-
src/include/storage/itemptr.h | 2 +-
src/include/storage/large_object.h | 2 +-
src/include/storage/latch.h | 2 +-
src/include/storage/lmgr.h | 2 +-
src/include/storage/lock.h | 2 +-
src/include/storage/lwlock.h | 2 +-
src/include/storage/off.h | 2 +-
src/include/storage/pg_sema.h | 2 +-
src/include/storage/pg_shmem.h | 2 +-
src/include/storage/pmsignal.h | 2 +-
src/include/storage/pos.h | 2 +-
src/include/storage/proc.h | 2 +-
src/include/storage/procarray.h | 2 +-
src/include/storage/procsignal.h | 2 +-
src/include/storage/reinit.h | 2 +-
src/include/storage/relfilenode.h | 2 +-
src/include/storage/s_lock.h | 2 +-
src/include/storage/shmem.h | 2 +-
src/include/storage/sinval.h | 2 +-
src/include/storage/sinvaladt.h | 2 +-
src/include/storage/smgr.h | 2 +-
src/include/storage/spin.h | 2 +-
src/include/storage/standby.h | 2 +-
src/include/tcop/dest.h | 2 +-
src/include/tcop/fastpath.h | 2 +-
src/include/tcop/pquery.h | 2 +-
src/include/tcop/tcopdebug.h | 2 +-
src/include/tcop/tcopprot.h | 2 +-
src/include/tcop/utility.h | 2 +-
src/include/tsearch/dicts/regis.h | 2 +-
src/include/tsearch/dicts/spell.h | 2 +-
src/include/tsearch/ts_cache.h | 2 +-
src/include/tsearch/ts_locale.h | 2 +-
src/include/tsearch/ts_public.h | 2 +-
src/include/tsearch/ts_type.h | 2 +-
src/include/tsearch/ts_utils.h | 2 +-
src/include/utils/acl.h | 2 +-
src/include/utils/array.h | 2 +-
src/include/utils/ascii.h | 2 +-
src/include/utils/attoptcache.h | 2 +-
src/include/utils/builtins.h | 2 +-
src/include/utils/bytea.h | 2 +-
src/include/utils/catcache.h | 2 +-
src/include/utils/combocid.h | 2 +-
src/include/utils/date.h | 2 +-
src/include/utils/datetime.h | 2 +-
src/include/utils/datum.h | 2 +-
src/include/utils/dynahash.h | 2 +-
src/include/utils/dynamic_loader.h | 2 +-
src/include/utils/elog.h | 2 +-
src/include/utils/errcodes.h | 2 +-
src/include/utils/fmgrtab.h | 2 +-
src/include/utils/formatting.h | 2 +-
src/include/utils/geo_decls.h | 2 +-
src/include/utils/guc.h | 2 +-
src/include/utils/guc_tables.h | 2 +-
src/include/utils/help_config.h | 2 +-
src/include/utils/hsearch.h | 2 +-
src/include/utils/inet.h | 2 +-
src/include/utils/int8.h | 2 +-
src/include/utils/inval.h | 2 +-
src/include/utils/logtape.h | 2 +-
src/include/utils/lsyscache.h | 2 +-
src/include/utils/memutils.h | 2 +-
src/include/utils/nabstime.h | 2 +-
src/include/utils/numeric.h | 2 +-
src/include/utils/palloc.h | 2 +-
src/include/utils/pg_crc.h | 2 +-
src/include/utils/pg_locale.h | 2 +-
src/include/utils/pg_rusage.h | 2 +-
src/include/utils/plancache.h | 2 +-
src/include/utils/portal.h | 2 +-
src/include/utils/rbtree.h | 2 +-
src/include/utils/rel.h | 2 +-
src/include/utils/relcache.h | 2 +-
src/include/utils/relmapper.h | 2 +-
src/include/utils/resowner.h | 2 +-
src/include/utils/selfuncs.h | 2 +-
src/include/utils/snapmgr.h | 2 +-
src/include/utils/snapshot.h | 2 +-
src/include/utils/spccache.h | 2 +-
src/include/utils/syscache.h | 2 +-
src/include/utils/timestamp.h | 2 +-
src/include/utils/tqual.h | 2 +-
src/include/utils/tuplesort.h | 2 +-
src/include/utils/tuplestore.h | 2 +-
src/include/utils/typcache.h | 2 +-
src/include/utils/tzparser.h | 2 +-
src/include/utils/uuid.h | 2 +-
src/include/utils/varbit.h | 2 +-
src/include/utils/xml.h | 2 +-
src/include/windowapi.h | 2 +-
src/interfaces/ecpg/compatlib/Makefile | 2 +-
src/interfaces/ecpg/ecpglib/Makefile | 2 +-
src/interfaces/ecpg/ecpglib/pg_type.h | 2 +-
src/interfaces/ecpg/pgtypeslib/Makefile | 2 +-
src/interfaces/ecpg/preproc/Makefile | 2 +-
src/interfaces/ecpg/preproc/check_rules.pl | 2 +-
src/interfaces/ecpg/preproc/ecpg.c | 2 +-
src/interfaces/ecpg/preproc/keywords.c | 2 +-
src/interfaces/ecpg/preproc/parse.pl | 2 +-
src/interfaces/ecpg/preproc/parser.c | 2 +-
src/interfaces/ecpg/preproc/pgc.l | 2 +-
src/interfaces/ecpg/test/pg_regress_ecpg.c | 2 +-
src/interfaces/libpq/Makefile | 2 +-
src/interfaces/libpq/fe-auth.c | 2 +-
src/interfaces/libpq/fe-auth.h | 2 +-
src/interfaces/libpq/fe-connect.c | 2 +-
src/interfaces/libpq/fe-exec.c | 2 +-
src/interfaces/libpq/fe-lobj.c | 2 +-
src/interfaces/libpq/fe-misc.c | 2 +-
src/interfaces/libpq/fe-print.c | 2 +-
src/interfaces/libpq/fe-protocol2.c | 2 +-
src/interfaces/libpq/fe-protocol3.c | 2 +-
src/interfaces/libpq/fe-secure.c | 2 +-
src/interfaces/libpq/libpq-events.c | 2 +-
src/interfaces/libpq/libpq-events.h | 2 +-
src/interfaces/libpq/libpq-fe.h | 2 +-
src/interfaces/libpq/libpq-int.h | 2 +-
src/interfaces/libpq/libpq.rc.in | 2 +-
src/interfaces/libpq/pqexpbuffer.c | 2 +-
src/interfaces/libpq/pqexpbuffer.h | 2 +-
src/interfaces/libpq/pqsignal.c | 2 +-
src/interfaces/libpq/pqsignal.h | 2 +-
src/interfaces/libpq/pthread-win32.c | 2 +-
src/interfaces/libpq/win32.c | 2 +-
src/pl/plperl/plperl.h | 2 +-
src/pl/plpgsql/src/gram.y | 2 +-
src/pl/plpgsql/src/pl_comp.c | 2 +-
src/pl/plpgsql/src/pl_exec.c | 2 +-
src/pl/plpgsql/src/pl_funcs.c | 2 +-
src/pl/plpgsql/src/pl_handler.c | 2 +-
src/pl/plpgsql/src/pl_scanner.c | 2 +-
src/pl/plpgsql/src/plerrcodes.h | 2 +-
src/pl/plpgsql/src/plpgsql.h | 2 +-
src/port/chklocale.c | 2 +-
src/port/dirent.c | 2 +-
src/port/dirmod.c | 2 +-
src/port/exec.c | 2 +-
src/port/fseeko.c | 2 +-
src/port/getaddrinfo.c | 2 +-
src/port/gethostname.c | 2 +-
src/port/getrusage.c | 2 +-
src/port/isinf.c | 2 +-
src/port/kill.c | 2 +-
src/port/memcmp.c | 2 +-
src/port/noblock.c | 2 +-
src/port/open.c | 2 +-
src/port/path.c | 2 +-
src/port/pgcheckdir.c | 2 +-
src/port/pgsleep.c | 2 +-
src/port/pgstrcasecmp.c | 2 +-
src/port/pipe.c | 2 +-
src/port/random.c | 2 +-
src/port/sprompt.c | 2 +-
src/port/srandom.c | 2 +-
src/port/strdup.c | 2 +-
src/port/strlcpy.c | 2 +-
src/port/strtol.c | 2 +-
src/port/thread.c | 2 +-
src/port/unsetenv.c | 2 +-
src/port/win32env.c | 2 +-
src/port/win32error.c | 2 +-
src/port/win32ver.rc | 2 +-
src/test/examples/testlo.c | 2 +-
src/test/regress/GNUmakefile | 2 +-
src/test/regress/pg_regress.c | 2 +-
src/test/regress/pg_regress.h | 2 +-
src/test/regress/pg_regress_main.c | 2 +-
src/test/thread/Makefile | 2 +-
src/test/thread/thread_test.c | 2 +-
src/timezone/pgtz.c | 2 +-
src/timezone/pgtz.h | 2 +-
src/tools/findoidjoins/Makefile | 2 +-
src/tools/findoidjoins/findoidjoins.c | 2 +-
src/tools/fsync/Makefile | 2 +-
src/tools/ifaddrs/Makefile | 2 +-
src/tools/version_stamp.pl | 2 +-
src/tools/win32tzlist.pl | 2 +-
src/tutorial/complex.source | 2 +-
src/tutorial/syscat.source | 2 +-
1106 files changed, 1112 insertions(+), 1112 deletions(-)
(limited to 'src/backend/access/gist/gistxlog.c')
diff --git a/COPYRIGHT b/COPYRIGHT
index b773b4d9c2..4babbf3316 100644
--- a/COPYRIGHT
+++ b/COPYRIGHT
@@ -1,7 +1,7 @@
PostgreSQL Database Management System
(formerly known as Postgres, then as Postgres95)
-Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
Portions Copyright (c) 1994, The Regents of the University of California
diff --git a/configure b/configure
index 388cf34d28..104ae3072c 100755
--- a/configure
+++ b/configure
@@ -9,7 +9,7 @@
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.
#
-# Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Copyright (c) 1996-2011, PostgreSQL Global Development Group
## --------------------- ##
## M4sh Initialization. ##
## --------------------- ##
@@ -1633,7 +1633,7 @@ Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
-Copyright (c) 1996-2010, PostgreSQL Global Development Group
+Copyright (c) 1996-2011, PostgreSQL Global Development Group
_ACEOF
exit
fi
diff --git a/configure.in b/configure.in
index 8ee2152d78..109eb0c0b0 100644
--- a/configure.in
+++ b/configure.in
@@ -23,7 +23,7 @@ m4_if(m4_defn([m4_PACKAGE_VERSION]), [2.63], [], [m4_fatal([Autoconf version 2.6
Untested combinations of 'autoconf' and PostgreSQL versions are not
recommended. You can remove the check from 'configure.in' but it is then
your responsibility whether the result works or not.])])
-AC_COPYRIGHT([Copyright (c) 1996-2010, PostgreSQL Global Development Group])
+AC_COPYRIGHT([Copyright (c) 1996-2011, PostgreSQL Global Development Group])
AC_CONFIG_SRCDIR([src/backend/access/common/heaptuple.c])
AC_CONFIG_AUX_DIR(config)
AC_PREFIX_DEFAULT(/usr/local/pgsql)
diff --git a/contrib/adminpack/adminpack.c b/contrib/adminpack/adminpack.c
index 4f7eedaa26..381554d114 100644
--- a/contrib/adminpack/adminpack.c
+++ b/contrib/adminpack/adminpack.c
@@ -3,7 +3,7 @@
* adminpack.c
*
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* Author: Andreas Pflug
*
diff --git a/contrib/auto_explain/auto_explain.c b/contrib/auto_explain/auto_explain.c
index b165d68d79..664b1ce262 100644
--- a/contrib/auto_explain/auto_explain.c
+++ b/contrib/auto_explain/auto_explain.c
@@ -3,7 +3,7 @@
* auto_explain.c
*
*
- * Copyright (c) 2008-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2008-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/auto_explain/auto_explain.c
diff --git a/contrib/dblink/dblink.c b/contrib/dblink/dblink.c
index 2db12d5103..19b98fb73d 100644
--- a/contrib/dblink/dblink.c
+++ b/contrib/dblink/dblink.c
@@ -9,7 +9,7 @@
* Shridhar Daithankar
*
* contrib/dblink/dblink.c
- * Copyright (c) 2001-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2001-2011, PostgreSQL Global Development Group
* ALL RIGHTS RESERVED;
*
* Permission to use, copy, modify, and distribute this software and its
diff --git a/contrib/dblink/dblink.h b/contrib/dblink/dblink.h
index 3d097ac1de..40de83f2b6 100644
--- a/contrib/dblink/dblink.h
+++ b/contrib/dblink/dblink.h
@@ -9,7 +9,7 @@
* Shridhar Daithankar
*
* contrib/dblink/dblink.h
- * Copyright (c) 2001-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2001-2011, PostgreSQL Global Development Group
* ALL RIGHTS RESERVED;
*
* Permission to use, copy, modify, and distribute this software and its
diff --git a/contrib/dict_int/dict_int.c b/contrib/dict_int/dict_int.c
index 174eec6e1c..c4ad6ef343 100644
--- a/contrib/dict_int/dict_int.c
+++ b/contrib/dict_int/dict_int.c
@@ -3,7 +3,7 @@
* dict_int.c
* Text search dictionary for integers
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/dict_int/dict_int.c
diff --git a/contrib/dict_xsyn/dict_xsyn.c b/contrib/dict_xsyn/dict_xsyn.c
index 4fe0ac6db2..ded20facd4 100644
--- a/contrib/dict_xsyn/dict_xsyn.c
+++ b/contrib/dict_xsyn/dict_xsyn.c
@@ -3,7 +3,7 @@
* dict_xsyn.c
* Extended synonym dictionary
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/dict_xsyn/dict_xsyn.c
diff --git a/contrib/dummy_seclabel/dummy_seclabel.c b/contrib/dummy_seclabel/dummy_seclabel.c
index 8bd50a34cf..974806f1b6 100644
--- a/contrib/dummy_seclabel/dummy_seclabel.c
+++ b/contrib/dummy_seclabel/dummy_seclabel.c
@@ -7,7 +7,7 @@
* perspective, but allows regression testing independent of platform-specific
* features like SELinux.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*/
#include "postgres.h"
diff --git a/contrib/fuzzystrmatch/fuzzystrmatch.c b/contrib/fuzzystrmatch/fuzzystrmatch.c
index 7265841dc5..782bc1e4d4 100644
--- a/contrib/fuzzystrmatch/fuzzystrmatch.c
+++ b/contrib/fuzzystrmatch/fuzzystrmatch.c
@@ -6,7 +6,7 @@
* Joe Conway
*
* contrib/fuzzystrmatch/fuzzystrmatch.c
- * Copyright (c) 2001-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2001-2011, PostgreSQL Global Development Group
* ALL RIGHTS RESERVED;
*
* metaphone()
diff --git a/contrib/fuzzystrmatch/levenshtein.c b/contrib/fuzzystrmatch/levenshtein.c
index 0d3ebe03dc..30a517f5f9 100644
--- a/contrib/fuzzystrmatch/levenshtein.c
+++ b/contrib/fuzzystrmatch/levenshtein.c
@@ -5,7 +5,7 @@
*
* Joe Conway
*
- * Copyright (c) 2001-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2001-2011, PostgreSQL Global Development Group
* ALL RIGHTS RESERVED;
*
* levenshtein()
diff --git a/contrib/isn/isn.c b/contrib/isn/isn.c
index 602a9472a3..46e904b1c4 100644
--- a/contrib/isn/isn.c
+++ b/contrib/isn/isn.c
@@ -4,7 +4,7 @@
* PostgreSQL type definitions for ISNs (ISBN, ISMN, ISSN, EAN13, UPC)
*
* Author: German Mendez Bravo (Kronuz)
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/isn/isn.c
diff --git a/contrib/isn/isn.h b/contrib/isn/isn.h
index e9d6f4df87..3f478b5f4b 100644
--- a/contrib/isn/isn.h
+++ b/contrib/isn/isn.h
@@ -4,7 +4,7 @@
* PostgreSQL type definitions for ISNs (ISBN, ISMN, ISSN, EAN13, UPC)
*
* Author: German Mendez Bravo (Kronuz)
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/isn/isn.h
diff --git a/contrib/pageinspect/fsmfuncs.c b/contrib/pageinspect/fsmfuncs.c
index 0a22971b9b..eca3230a98 100644
--- a/contrib/pageinspect/fsmfuncs.c
+++ b/contrib/pageinspect/fsmfuncs.c
@@ -9,7 +9,7 @@
* there's hardly any use case for using these without superuser-rights
* anyway.
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/pageinspect/fsmfuncs.c
diff --git a/contrib/pageinspect/heapfuncs.c b/contrib/pageinspect/heapfuncs.c
index 3ed77118b4..49a2f91120 100644
--- a/contrib/pageinspect/heapfuncs.c
+++ b/contrib/pageinspect/heapfuncs.c
@@ -15,7 +15,7 @@
* there's hardly any use case for using these without superuser-rights
* anyway.
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/pageinspect/heapfuncs.c
diff --git a/contrib/pageinspect/rawpage.c b/contrib/pageinspect/rawpage.c
index f341a7247d..e4e933dfaf 100644
--- a/contrib/pageinspect/rawpage.c
+++ b/contrib/pageinspect/rawpage.c
@@ -5,7 +5,7 @@
*
* Access-method specific inspection functions are in separate files.
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/pageinspect/rawpage.c
diff --git a/contrib/passwordcheck/passwordcheck.c b/contrib/passwordcheck/passwordcheck.c
index 32b7c9a5c1..711ec9fc36 100644
--- a/contrib/passwordcheck/passwordcheck.c
+++ b/contrib/passwordcheck/passwordcheck.c
@@ -3,7 +3,7 @@
* passwordcheck.c
*
*
- * Copyright (c) 2009-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2009-2011, PostgreSQL Global Development Group
*
* Author: Laurenz Albe
*
diff --git a/contrib/pg_stat_statements/pg_stat_statements.c b/contrib/pg_stat_statements/pg_stat_statements.c
index 6db6cc0ea2..c361c7a86c 100644
--- a/contrib/pg_stat_statements/pg_stat_statements.c
+++ b/contrib/pg_stat_statements/pg_stat_statements.c
@@ -11,7 +11,7 @@
* disappear!) and also take the entry's mutex spinlock.
*
*
- * Copyright (c) 2008-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2008-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/pg_stat_statements/pg_stat_statements.c
diff --git a/contrib/pg_upgrade/check.c b/contrib/pg_upgrade/check.c
index 5708e2ff0e..74449df73d 100644
--- a/contrib/pg_upgrade/check.c
+++ b/contrib/pg_upgrade/check.c
@@ -3,7 +3,7 @@
*
* server checks and output routines
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/check.c
*/
diff --git a/contrib/pg_upgrade/controldata.c b/contrib/pg_upgrade/controldata.c
index 035f3aed8c..78c75e8a84 100644
--- a/contrib/pg_upgrade/controldata.c
+++ b/contrib/pg_upgrade/controldata.c
@@ -3,7 +3,7 @@
*
* controldata functions
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/controldata.c
*/
diff --git a/contrib/pg_upgrade/dump.c b/contrib/pg_upgrade/dump.c
index b63fdb0a38..a192cbb37e 100644
--- a/contrib/pg_upgrade/dump.c
+++ b/contrib/pg_upgrade/dump.c
@@ -3,7 +3,7 @@
*
* dump functions
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/dump.c
*/
diff --git a/contrib/pg_upgrade/exec.c b/contrib/pg_upgrade/exec.c
index 1959b8aa94..cce40e4dee 100644
--- a/contrib/pg_upgrade/exec.c
+++ b/contrib/pg_upgrade/exec.c
@@ -3,7 +3,7 @@
*
* execution functions
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/exec.c
*/
diff --git a/contrib/pg_upgrade/file.c b/contrib/pg_upgrade/file.c
index e84110665f..deaca4698b 100644
--- a/contrib/pg_upgrade/file.c
+++ b/contrib/pg_upgrade/file.c
@@ -3,7 +3,7 @@
*
* file system operations
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/file.c
*/
diff --git a/contrib/pg_upgrade/function.c b/contrib/pg_upgrade/function.c
index 877b0041ce..bd96b03ef4 100644
--- a/contrib/pg_upgrade/function.c
+++ b/contrib/pg_upgrade/function.c
@@ -3,7 +3,7 @@
*
* server-side function support
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/function.c
*/
diff --git a/contrib/pg_upgrade/info.c b/contrib/pg_upgrade/info.c
index 7651096113..a83248c44f 100644
--- a/contrib/pg_upgrade/info.c
+++ b/contrib/pg_upgrade/info.c
@@ -3,7 +3,7 @@
*
* information support functions
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/info.c
*/
diff --git a/contrib/pg_upgrade/option.c b/contrib/pg_upgrade/option.c
index f6b5706537..c984535461 100644
--- a/contrib/pg_upgrade/option.c
+++ b/contrib/pg_upgrade/option.c
@@ -3,7 +3,7 @@
*
* options functions
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/option.c
*/
diff --git a/contrib/pg_upgrade/page.c b/contrib/pg_upgrade/page.c
index 1c0d912db0..22a587f4b1 100644
--- a/contrib/pg_upgrade/page.c
+++ b/contrib/pg_upgrade/page.c
@@ -3,7 +3,7 @@
*
* per-page conversion operations
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/page.c
*/
diff --git a/contrib/pg_upgrade/pg_upgrade.c b/contrib/pg_upgrade/pg_upgrade.c
index 5b8bf7271c..64fb8f8398 100644
--- a/contrib/pg_upgrade/pg_upgrade.c
+++ b/contrib/pg_upgrade/pg_upgrade.c
@@ -3,7 +3,7 @@
*
* main source file
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/pg_upgrade.c
*/
diff --git a/contrib/pg_upgrade/pg_upgrade.h b/contrib/pg_upgrade/pg_upgrade.h
index 5405209fe9..3bbddee824 100644
--- a/contrib/pg_upgrade/pg_upgrade.h
+++ b/contrib/pg_upgrade/pg_upgrade.h
@@ -1,7 +1,7 @@
/*
* pg_upgrade.h
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/pg_upgrade.h
*/
diff --git a/contrib/pg_upgrade/relfilenode.c b/contrib/pg_upgrade/relfilenode.c
index b23ce2f37d..b9656c4c32 100644
--- a/contrib/pg_upgrade/relfilenode.c
+++ b/contrib/pg_upgrade/relfilenode.c
@@ -3,7 +3,7 @@
*
* relfilenode functions
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/relfilenode.c
*/
diff --git a/contrib/pg_upgrade/server.c b/contrib/pg_upgrade/server.c
index 785e2eea08..c7684f87e5 100644
--- a/contrib/pg_upgrade/server.c
+++ b/contrib/pg_upgrade/server.c
@@ -3,7 +3,7 @@
*
* database server functions
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/server.c
*/
diff --git a/contrib/pg_upgrade/tablespace.c b/contrib/pg_upgrade/tablespace.c
index 70fe0578fd..a575487621 100644
--- a/contrib/pg_upgrade/tablespace.c
+++ b/contrib/pg_upgrade/tablespace.c
@@ -3,7 +3,7 @@
*
* tablespace functions
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/tablespace.c
*/
diff --git a/contrib/pg_upgrade/util.c b/contrib/pg_upgrade/util.c
index da6dca0e2c..5207334e0c 100644
--- a/contrib/pg_upgrade/util.c
+++ b/contrib/pg_upgrade/util.c
@@ -3,7 +3,7 @@
*
* utility functions
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/util.c
*/
diff --git a/contrib/pg_upgrade/version.c b/contrib/pg_upgrade/version.c
index cdda741552..e32153818a 100644
--- a/contrib/pg_upgrade/version.c
+++ b/contrib/pg_upgrade/version.c
@@ -3,7 +3,7 @@
*
* Postgres-version-specific routines
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/version.c
*/
diff --git a/contrib/pg_upgrade/version_old_8_3.c b/contrib/pg_upgrade/version_old_8_3.c
index c342cd99a7..664380b47b 100644
--- a/contrib/pg_upgrade/version_old_8_3.c
+++ b/contrib/pg_upgrade/version_old_8_3.c
@@ -3,7 +3,7 @@
*
* Postgres-version-specific routines
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade/version_old_8_3.c
*/
diff --git a/contrib/pg_upgrade_support/pg_upgrade_support.c b/contrib/pg_upgrade_support/pg_upgrade_support.c
index 3ec436fe14..e55e139f7c 100644
--- a/contrib/pg_upgrade_support/pg_upgrade_support.c
+++ b/contrib/pg_upgrade_support/pg_upgrade_support.c
@@ -4,7 +4,7 @@
* server-side functions to set backend global variables
* to control oid and relfilenode assignment
*
- * Copyright (c) 2010, PostgreSQL Global Development Group
+ * Copyright (c) 2010-2011, PostgreSQL Global Development Group
* contrib/pg_upgrade_support/pg_upgrade_support.c
*/
diff --git a/contrib/pgbench/pgbench.c b/contrib/pgbench/pgbench.c
index 55ca1e82e6..7c2ca6e84d 100644
--- a/contrib/pgbench/pgbench.c
+++ b/contrib/pgbench/pgbench.c
@@ -5,7 +5,7 @@
* Originally written by Tatsuo Ishii and enhanced by many contributors.
*
* contrib/pgbench/pgbench.c
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
* ALL RIGHTS RESERVED;
*
* Permission to use, copy, modify, and distribute this software and its
diff --git a/contrib/tablefunc/tablefunc.c b/contrib/tablefunc/tablefunc.c
index 2e9ea1a626..4ef9b00a6d 100644
--- a/contrib/tablefunc/tablefunc.c
+++ b/contrib/tablefunc/tablefunc.c
@@ -10,7 +10,7 @@
* And contributors:
* Nabil Sayegh
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without a written agreement
diff --git a/contrib/tablefunc/tablefunc.h b/contrib/tablefunc/tablefunc.h
index 267a8d1eeb..a0e03e285d 100644
--- a/contrib/tablefunc/tablefunc.h
+++ b/contrib/tablefunc/tablefunc.h
@@ -10,7 +10,7 @@
* And contributors:
* Nabil Sayegh
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without a written agreement
diff --git a/contrib/test_parser/test_parser.c b/contrib/test_parser/test_parser.c
index 58b1c67970..8e4c7a32d9 100644
--- a/contrib/test_parser/test_parser.c
+++ b/contrib/test_parser/test_parser.c
@@ -3,7 +3,7 @@
* test_parser.c
* Simple example of a text search parser
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/test_parser/test_parser.c
diff --git a/contrib/tsearch2/tsearch2.c b/contrib/tsearch2/tsearch2.c
index 030a84c73b..c6ced6396c 100644
--- a/contrib/tsearch2/tsearch2.c
+++ b/contrib/tsearch2/tsearch2.c
@@ -3,7 +3,7 @@
* tsearch2.c
* Backwards-compatibility package for old contrib/tsearch2 API
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/contrib/unaccent/unaccent.c b/contrib/unaccent/unaccent.c
index 2097d18a1b..709f4c4492 100644
--- a/contrib/unaccent/unaccent.c
+++ b/contrib/unaccent/unaccent.c
@@ -3,7 +3,7 @@
* unaccent.c
* Text search unaccent dictionary
*
- * Copyright (c) 2009-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2009-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* contrib/unaccent/unaccent.c
diff --git a/contrib/uuid-ossp/uuid-ossp.c b/contrib/uuid-ossp/uuid-ossp.c
index f89c9fafba..2be278d489 100644
--- a/contrib/uuid-ossp/uuid-ossp.c
+++ b/contrib/uuid-ossp/uuid-ossp.c
@@ -2,7 +2,7 @@
*
* UUID generation functions using the OSSP UUID library
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* contrib/uuid-ossp/uuid-ossp.c
*
diff --git a/contrib/vacuumlo/vacuumlo.c b/contrib/vacuumlo/vacuumlo.c
index 07da355e84..f6e2a28cf3 100644
--- a/contrib/vacuumlo/vacuumlo.c
+++ b/contrib/vacuumlo/vacuumlo.c
@@ -3,7 +3,7 @@
* vacuumlo.c
* This removes orphaned large objects from a database.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/doc/src/sgml/legal.sgml b/doc/src/sgml/legal.sgml
index 22b08ccdbb..4531686341 100644
--- a/doc/src/sgml/legal.sgml
+++ b/doc/src/sgml/legal.sgml
@@ -1,7 +1,7 @@
- 1996-2010
+ 1996-2011
The PostgreSQL Global Development Group
@@ -9,7 +9,7 @@
Legal Notice
- PostgreSQL is Copyright © 1996-2010
+ PostgreSQL is Copyright © 1996-2011
by the PostgreSQL Global Development Group and is distributed under
the terms of the license of the University of California below.
diff --git a/src/backend/Makefile b/src/backend/Makefile
index 87b97c21d9..bb43526fec 100644
--- a/src/backend/Makefile
+++ b/src/backend/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for the postgres backend
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/backend/Makefile
diff --git a/src/backend/access/common/heaptuple.c b/src/backend/access/common/heaptuple.c
index 9ac43be09b..6d608fed89 100644
--- a/src/backend/access/common/heaptuple.c
+++ b/src/backend/access/common/heaptuple.c
@@ -45,7 +45,7 @@
* and we'd like to still refer to them via C struct offsets.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/common/indextuple.c b/src/backend/access/common/indextuple.c
index c33f587806..9ea87360f9 100644
--- a/src/backend/access/common/indextuple.c
+++ b/src/backend/access/common/indextuple.c
@@ -4,7 +4,7 @@
* This file contains index tuple accessor and mutator routines,
* as well as various tuple utilities.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/common/printtup.c b/src/backend/access/common/printtup.c
index 0c51e470fd..afce6d5edf 100644
--- a/src/backend/access/common/printtup.c
+++ b/src/backend/access/common/printtup.c
@@ -5,7 +5,7 @@
* clients and standalone backends are supported here).
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/common/reloptions.c b/src/backend/access/common/reloptions.c
index 438e8b007a..eb6ccc6582 100644
--- a/src/backend/access/common/reloptions.c
+++ b/src/backend/access/common/reloptions.c
@@ -3,7 +3,7 @@
* reloptions.c
* Core support for relation options (pg_class.reloptions)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/common/scankey.c b/src/backend/access/common/scankey.c
index 1b6ac8be64..232322a91e 100644
--- a/src/backend/access/common/scankey.c
+++ b/src/backend/access/common/scankey.c
@@ -3,7 +3,7 @@
* scankey.c
* scan key support code
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/common/tupconvert.c b/src/backend/access/common/tupconvert.c
index 21026d437b..34e5f11440 100644
--- a/src/backend/access/common/tupconvert.c
+++ b/src/backend/access/common/tupconvert.c
@@ -9,7 +9,7 @@
* executor's "junkfilter" routines, but these functions work on bare
* HeapTuples rather than TupleTableSlots.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/common/tupdesc.c b/src/backend/access/common/tupdesc.c
index eae34618d8..cfc95b9312 100644
--- a/src/backend/access/common/tupdesc.c
+++ b/src/backend/access/common/tupdesc.c
@@ -3,7 +3,7 @@
* tupdesc.c
* POSTGRES tuple descriptor support code
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/gin/ginarrayproc.c b/src/backend/access/gin/ginarrayproc.c
index c62d54ed42..1837a0d5a1 100644
--- a/src/backend/access/gin/ginarrayproc.c
+++ b/src/backend/access/gin/ginarrayproc.c
@@ -4,7 +4,7 @@
* support functions for GIN's indexing of any array
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/ginbtree.c b/src/backend/access/gin/ginbtree.c
index 9d857a0310..ec038aac4b 100644
--- a/src/backend/access/gin/ginbtree.c
+++ b/src/backend/access/gin/ginbtree.c
@@ -4,7 +4,7 @@
* page utilities routines for the postgres inverted index access method.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/ginbulk.c b/src/backend/access/gin/ginbulk.c
index 83c8fe27a1..a4ee3364e1 100644
--- a/src/backend/access/gin/ginbulk.c
+++ b/src/backend/access/gin/ginbulk.c
@@ -4,7 +4,7 @@
* routines for fast build of inverted index
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/gindatapage.c b/src/backend/access/gin/gindatapage.c
index f74373ca59..f6e86da8db 100644
--- a/src/backend/access/gin/gindatapage.c
+++ b/src/backend/access/gin/gindatapage.c
@@ -4,7 +4,7 @@
* page utilities routines for the postgres inverted index access method.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/ginentrypage.c b/src/backend/access/gin/ginentrypage.c
index d07bafed85..e56034202a 100644
--- a/src/backend/access/gin/ginentrypage.c
+++ b/src/backend/access/gin/ginentrypage.c
@@ -4,7 +4,7 @@
* page utilities routines for the postgres inverted index access method.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/ginfast.c b/src/backend/access/gin/ginfast.c
index 74339c9eea..3941f7eb00 100644
--- a/src/backend/access/gin/ginfast.c
+++ b/src/backend/access/gin/ginfast.c
@@ -7,7 +7,7 @@
* transfer pending entries into the regular index structure. This
* wins because bulk insertion is much more efficient than retail.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/ginget.c b/src/backend/access/gin/ginget.c
index 34a6cd9cfd..ed1e71c9d6 100644
--- a/src/backend/access/gin/ginget.c
+++ b/src/backend/access/gin/ginget.c
@@ -4,7 +4,7 @@
* fetch tuples from a GIN scan.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/gininsert.c b/src/backend/access/gin/gininsert.c
index d66c79cb8d..5b146d6c26 100644
--- a/src/backend/access/gin/gininsert.c
+++ b/src/backend/access/gin/gininsert.c
@@ -4,7 +4,7 @@
* insert routines for the postgres inverted index access method.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/ginscan.c b/src/backend/access/gin/ginscan.c
index 3a5e52dc38..2a39c4b383 100644
--- a/src/backend/access/gin/ginscan.c
+++ b/src/backend/access/gin/ginscan.c
@@ -4,7 +4,7 @@
* routines to manage scans inverted index relations
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/ginutil.c b/src/backend/access/gin/ginutil.c
index 5f20ac9349..4674606f79 100644
--- a/src/backend/access/gin/ginutil.c
+++ b/src/backend/access/gin/ginutil.c
@@ -4,7 +4,7 @@
* utilities routines for the postgres inverted index access method.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/ginvacuum.c b/src/backend/access/gin/ginvacuum.c
index 4b35acb983..3054030a2c 100644
--- a/src/backend/access/gin/ginvacuum.c
+++ b/src/backend/access/gin/ginvacuum.c
@@ -4,7 +4,7 @@
* delete & vacuum routines for the postgres GIN
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gin/ginxlog.c b/src/backend/access/gin/ginxlog.c
index 9fd6167c3e..36f0233baa 100644
--- a/src/backend/access/gin/ginxlog.c
+++ b/src/backend/access/gin/ginxlog.c
@@ -4,7 +4,7 @@
* WAL replay logic for inverted index.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gist/gist.c b/src/backend/access/gist/gist.c
index c26ac74332..4bd1e43827 100644
--- a/src/backend/access/gist/gist.c
+++ b/src/backend/access/gist/gist.c
@@ -4,7 +4,7 @@
* interface routines for the postgres GiST index access method.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gist/gistget.c b/src/backend/access/gist/gistget.c
index 5061003a3b..8355081553 100644
--- a/src/backend/access/gist/gistget.c
+++ b/src/backend/access/gist/gistget.c
@@ -4,7 +4,7 @@
* fetch tuples from a GiST scan.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gist/gistproc.c b/src/backend/access/gist/gistproc.c
index bdc84befc6..86a5d90f95 100644
--- a/src/backend/access/gist/gistproc.c
+++ b/src/backend/access/gist/gistproc.c
@@ -6,7 +6,7 @@
* This gives R-tree behavior, with Guttman's poly-time split algorithm.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gist/gistscan.c b/src/backend/access/gist/gistscan.c
index 546880c01e..c5d32ef748 100644
--- a/src/backend/access/gist/gistscan.c
+++ b/src/backend/access/gist/gistscan.c
@@ -4,7 +4,7 @@
* routines to manage scans on GiST index relations
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gist/gistsplit.c b/src/backend/access/gist/gistsplit.c
index ac9a657841..f65c493e98 100644
--- a/src/backend/access/gist/gistsplit.c
+++ b/src/backend/access/gist/gistsplit.c
@@ -4,7 +4,7 @@
* Split page algorithm
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gist/gistutil.c b/src/backend/access/gist/gistutil.c
index 8a0d356860..6736fd166c 100644
--- a/src/backend/access/gist/gistutil.c
+++ b/src/backend/access/gist/gistutil.c
@@ -4,7 +4,7 @@
* utilities routines for the postgres GiST index access method.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gist/gistvacuum.c b/src/backend/access/gist/gistvacuum.c
index 86af414dce..4369d01154 100644
--- a/src/backend/access/gist/gistvacuum.c
+++ b/src/backend/access/gist/gistvacuum.c
@@ -4,7 +4,7 @@
* vacuuming routines for the postgres GiST index access method.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/gist/gistxlog.c b/src/backend/access/gist/gistxlog.c
index 7d25728d8d..0f406e16c4 100644
--- a/src/backend/access/gist/gistxlog.c
+++ b/src/backend/access/gist/gistxlog.c
@@ -4,7 +4,7 @@
* WAL replay logic for GiST.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/hash/hash.c b/src/backend/access/hash/hash.c
index 4df92d44c0..f19e5627f8 100644
--- a/src/backend/access/hash/hash.c
+++ b/src/backend/access/hash/hash.c
@@ -3,7 +3,7 @@
* hash.c
* Implementation of Margo Seltzer's Hashing package for postgres.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/hash/hashfunc.c b/src/backend/access/hash/hashfunc.c
index 577873b5cd..897bf9c1ac 100644
--- a/src/backend/access/hash/hashfunc.c
+++ b/src/backend/access/hash/hashfunc.c
@@ -3,7 +3,7 @@
* hashfunc.c
* Support functions for hash access method.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/hash/hashinsert.c b/src/backend/access/hash/hashinsert.c
index 4eb57ca826..dd58f16840 100644
--- a/src/backend/access/hash/hashinsert.c
+++ b/src/backend/access/hash/hashinsert.c
@@ -3,7 +3,7 @@
* hashinsert.c
* Item insertion in hash tables for Postgres.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/hash/hashovfl.c b/src/backend/access/hash/hashovfl.c
index 454ad6c7a8..ae8b2b1cfd 100644
--- a/src/backend/access/hash/hashovfl.c
+++ b/src/backend/access/hash/hashovfl.c
@@ -3,7 +3,7 @@
* hashovfl.c
* Overflow page management code for the Postgres hash access method
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/hash/hashpage.c b/src/backend/access/hash/hashpage.c
index 29f7b25b4e..fe991cf27b 100644
--- a/src/backend/access/hash/hashpage.c
+++ b/src/backend/access/hash/hashpage.c
@@ -3,7 +3,7 @@
* hashpage.c
* Hash table page management code for the Postgres hash access method
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/hash/hashscan.c b/src/backend/access/hash/hashscan.c
index 9e4e93dcc2..93d63b86ea 100644
--- a/src/backend/access/hash/hashscan.c
+++ b/src/backend/access/hash/hashscan.c
@@ -3,7 +3,7 @@
* hashscan.c
* manage scans on hash tables
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/hash/hashsearch.c b/src/backend/access/hash/hashsearch.c
index 11df41eedb..bf42be103f 100644
--- a/src/backend/access/hash/hashsearch.c
+++ b/src/backend/access/hash/hashsearch.c
@@ -3,7 +3,7 @@
* hashsearch.c
* search code for postgres hash tables
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/hash/hashsort.c b/src/backend/access/hash/hashsort.c
index a06663aa2a..dbb9c3f39b 100644
--- a/src/backend/access/hash/hashsort.c
+++ b/src/backend/access/hash/hashsort.c
@@ -14,7 +14,7 @@
* plenty of locality of access.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/hash/hashutil.c b/src/backend/access/hash/hashutil.c
index c2e2cb2703..b00b32d69f 100644
--- a/src/backend/access/hash/hashutil.c
+++ b/src/backend/access/hash/hashutil.c
@@ -3,7 +3,7 @@
* hashutil.c
* Utility code for Postgres hash implementation.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/heap/heapam.c b/src/backend/access/heap/heapam.c
index 4020906b34..ac744e4187 100644
--- a/src/backend/access/heap/heapam.c
+++ b/src/backend/access/heap/heapam.c
@@ -3,7 +3,7 @@
* heapam.c
* heap access method code
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/heap/hio.c b/src/backend/access/heap/hio.c
index 01d71a1df9..2849992528 100644
--- a/src/backend/access/heap/hio.c
+++ b/src/backend/access/heap/hio.c
@@ -3,7 +3,7 @@
* hio.c
* POSTGRES heap access method input/output code.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/heap/pruneheap.c b/src/backend/access/heap/pruneheap.c
index d1b08b3a8b..0cfa866108 100644
--- a/src/backend/access/heap/pruneheap.c
+++ b/src/backend/access/heap/pruneheap.c
@@ -3,7 +3,7 @@
* pruneheap.c
* heap page pruning and HOT-chain management code
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/heap/rewriteheap.c b/src/backend/access/heap/rewriteheap.c
index eb2dbffb9d..c710f1d316 100644
--- a/src/backend/access/heap/rewriteheap.c
+++ b/src/backend/access/heap/rewriteheap.c
@@ -92,7 +92,7 @@
* heap's TOAST table will go through the normal bufmgr.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994-5, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/heap/syncscan.c b/src/backend/access/heap/syncscan.c
index 05497ace12..957d1a12f3 100644
--- a/src/backend/access/heap/syncscan.c
+++ b/src/backend/access/heap/syncscan.c
@@ -36,7 +36,7 @@
* ss_report_location - update current scan location
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/heap/tuptoaster.c b/src/backend/access/heap/tuptoaster.c
index c83aed2e39..4f4dd69291 100644
--- a/src/backend/access/heap/tuptoaster.c
+++ b/src/backend/access/heap/tuptoaster.c
@@ -4,7 +4,7 @@
* Support routines for external and compressed storage of
* variable size attributes.
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/access/heap/visibilitymap.c b/src/backend/access/heap/visibilitymap.c
index ab941debcb..58bab7df10 100644
--- a/src/backend/access/heap/visibilitymap.c
+++ b/src/backend/access/heap/visibilitymap.c
@@ -3,7 +3,7 @@
* visibilitymap.c
* bitmap for tracking visibility of heap tuples
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/index/genam.c b/src/backend/access/index/genam.c
index d0eaa36b3b..db04e26a65 100644
--- a/src/backend/access/index/genam.c
+++ b/src/backend/access/index/genam.c
@@ -3,7 +3,7 @@
* genam.c
* general index access method routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/index/indexam.c b/src/backend/access/index/indexam.c
index 8c79c6149b..32af32a206 100644
--- a/src/backend/access/index/indexam.c
+++ b/src/backend/access/index/indexam.c
@@ -3,7 +3,7 @@
* indexam.c
* general index access method routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/nbtree/nbtcompare.c b/src/backend/access/nbtree/nbtcompare.c
index 8849a0244d..23f2b61fe9 100644
--- a/src/backend/access/nbtree/nbtcompare.c
+++ b/src/backend/access/nbtree/nbtcompare.c
@@ -3,7 +3,7 @@
* nbtcompare.c
* Comparison functions for btree access method.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/nbtree/nbtinsert.c b/src/backend/access/nbtree/nbtinsert.c
index ee0f04cdb5..91b72b8f91 100644
--- a/src/backend/access/nbtree/nbtinsert.c
+++ b/src/backend/access/nbtree/nbtinsert.c
@@ -3,7 +3,7 @@
* nbtinsert.c
* Item insertion in Lehman and Yao btrees for Postgres.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/nbtree/nbtpage.c b/src/backend/access/nbtree/nbtpage.c
index 2b4478089d..db86ec9a1a 100644
--- a/src/backend/access/nbtree/nbtpage.c
+++ b/src/backend/access/nbtree/nbtpage.c
@@ -4,7 +4,7 @@
* BTree-specific page management code for the Postgres btree access
* method.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/nbtree/nbtree.c b/src/backend/access/nbtree/nbtree.c
index a13d629b0e..d66bdd47e4 100644
--- a/src/backend/access/nbtree/nbtree.c
+++ b/src/backend/access/nbtree/nbtree.c
@@ -8,7 +8,7 @@
* This file contains only the public interface routines.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/nbtree/nbtsearch.c b/src/backend/access/nbtree/nbtsearch.c
index b3bb273b30..42d956c6ea 100644
--- a/src/backend/access/nbtree/nbtsearch.c
+++ b/src/backend/access/nbtree/nbtsearch.c
@@ -4,7 +4,7 @@
* Search code for postgres btrees.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/nbtree/nbtsort.c b/src/backend/access/nbtree/nbtsort.c
index 3fb43a2e58..e02f0081fd 100644
--- a/src/backend/access/nbtree/nbtsort.c
+++ b/src/backend/access/nbtree/nbtsort.c
@@ -55,7 +55,7 @@
* This code isn't concerned about the FSM at all. The caller is responsible
* for initializing that.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/nbtree/nbtutils.c b/src/backend/access/nbtree/nbtutils.c
index 8f0f226113..7ee7ebeb3c 100644
--- a/src/backend/access/nbtree/nbtutils.c
+++ b/src/backend/access/nbtree/nbtutils.c
@@ -3,7 +3,7 @@
* nbtutils.c
* Utility code for Postgres btree implementation.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/nbtree/nbtxlog.c b/src/backend/access/nbtree/nbtxlog.c
index e1221709b1..2775ae6d29 100644
--- a/src/backend/access/nbtree/nbtxlog.c
+++ b/src/backend/access/nbtree/nbtxlog.c
@@ -4,7 +4,7 @@
* WAL replay logic for btrees.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/transam/clog.c b/src/backend/access/transam/clog.c
index df40137925..df0f15679f 100644
--- a/src/backend/access/transam/clog.c
+++ b/src/backend/access/transam/clog.c
@@ -23,7 +23,7 @@
* for aborts (whether sync or async), since the post-crash assumption would
* be that such transactions failed anyway.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/access/transam/clog.c
diff --git a/src/backend/access/transam/multixact.c b/src/backend/access/transam/multixact.c
index 7e84444f46..bb3afd6000 100644
--- a/src/backend/access/transam/multixact.c
+++ b/src/backend/access/transam/multixact.c
@@ -39,7 +39,7 @@
* anything we saw during replay.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/access/transam/multixact.c
diff --git a/src/backend/access/transam/slru.c b/src/backend/access/transam/slru.c
index 3bf8bb0b33..69e5245beb 100644
--- a/src/backend/access/transam/slru.c
+++ b/src/backend/access/transam/slru.c
@@ -38,7 +38,7 @@
* by re-setting the page's page_dirty flag.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/access/transam/slru.c
diff --git a/src/backend/access/transam/subtrans.c b/src/backend/access/transam/subtrans.c
index 4e266513cb..deef99aeb2 100644
--- a/src/backend/access/transam/subtrans.c
+++ b/src/backend/access/transam/subtrans.c
@@ -19,7 +19,7 @@
* data across crashes. During database startup, we simply force the
* currently-active page of SUBTRANS to zeroes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/access/transam/subtrans.c
diff --git a/src/backend/access/transam/transam.c b/src/backend/access/transam/transam.c
index 799780af73..bc02f15e86 100644
--- a/src/backend/access/transam/transam.c
+++ b/src/backend/access/transam/transam.c
@@ -3,7 +3,7 @@
* transam.c
* postgres transaction log interface routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/transam/twophase.c b/src/backend/access/transam/twophase.c
index cc8afc5bdf..4fee9c3244 100644
--- a/src/backend/access/transam/twophase.c
+++ b/src/backend/access/transam/twophase.c
@@ -3,7 +3,7 @@
* twophase.c
* Two-phase commit support functions.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/access/transam/twophase_rmgr.c b/src/backend/access/transam/twophase_rmgr.c
index bb2c33c173..02de1e8526 100644
--- a/src/backend/access/transam/twophase_rmgr.c
+++ b/src/backend/access/transam/twophase_rmgr.c
@@ -3,7 +3,7 @@
* twophase_rmgr.c
* Two-phase-commit resource managers tables
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/transam/varsup.c b/src/backend/access/transam/varsup.c
index 6f423bcf3a..a03ec85f8f 100644
--- a/src/backend/access/transam/varsup.c
+++ b/src/backend/access/transam/varsup.c
@@ -3,7 +3,7 @@
* varsup.c
* postgres OID & XID variables support routines
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/access/transam/varsup.c
diff --git a/src/backend/access/transam/xact.c b/src/backend/access/transam/xact.c
index 67f817ca4b..4ecf82d6a1 100644
--- a/src/backend/access/transam/xact.c
+++ b/src/backend/access/transam/xact.c
@@ -5,7 +5,7 @@
*
* See src/backend/access/transam/README for more information.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/access/transam/xlog.c b/src/backend/access/transam/xlog.c
index 1ec6f2f15a..818a59f671 100644
--- a/src/backend/access/transam/xlog.c
+++ b/src/backend/access/transam/xlog.c
@@ -4,7 +4,7 @@
* PostgreSQL transaction log manager
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/access/transam/xlog.c
diff --git a/src/backend/access/transam/xlogutils.c b/src/backend/access/transam/xlogutils.c
index a3ec4259ee..cbb61bb899 100644
--- a/src/backend/access/transam/xlogutils.c
+++ b/src/backend/access/transam/xlogutils.c
@@ -8,7 +8,7 @@
* None of this code is used during normal system operation.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/access/transam/xlogutils.c
diff --git a/src/backend/bootstrap/bootparse.y b/src/backend/bootstrap/bootparse.y
index 73ef114d9c..16f84f96a3 100644
--- a/src/backend/bootstrap/bootparse.y
+++ b/src/backend/bootstrap/bootparse.y
@@ -4,7 +4,7 @@
* bootparse.y
* yacc grammar for the "bootstrap" mode (BKI file format)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/bootstrap/bootscanner.l b/src/backend/bootstrap/bootscanner.l
index 146110270a..fba020008f 100644
--- a/src/backend/bootstrap/bootscanner.l
+++ b/src/backend/bootstrap/bootscanner.l
@@ -4,7 +4,7 @@
* bootscanner.l
* a lexical scanner for the bootstrap parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/bootstrap/bootstrap.c b/src/backend/bootstrap/bootstrap.c
index a082ed807a..dbcc55c822 100644
--- a/src/backend/bootstrap/bootstrap.c
+++ b/src/backend/bootstrap/bootstrap.c
@@ -4,7 +4,7 @@
* routines to support running postgres in 'bootstrap' mode
* bootstrap mode is used to create the initial template database
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/catalog/Catalog.pm b/src/backend/catalog/Catalog.pm
index f6f5cd1215..8526d7d555 100644
--- a/src/backend/catalog/Catalog.pm
+++ b/src/backend/catalog/Catalog.pm
@@ -4,7 +4,7 @@
# Perl module that extracts info from catalog headers into Perl
# data structures
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/backend/catalog/Catalog.pm
diff --git a/src/backend/catalog/aclchk.c b/src/backend/catalog/aclchk.c
index fefa335e09..01105aae1e 100644
--- a/src/backend/catalog/aclchk.c
+++ b/src/backend/catalog/aclchk.c
@@ -3,7 +3,7 @@
* aclchk.c
* Routines to check access control permissions.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/catalog/catalog.c b/src/backend/catalog/catalog.c
index fc5a8fcd65..12935754bc 100644
--- a/src/backend/catalog/catalog.c
+++ b/src/backend/catalog/catalog.c
@@ -5,7 +5,7 @@
* bits of hard-wired knowledge
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/catalog/dependency.c b/src/backend/catalog/dependency.c
index a912971aba..7627c7dd20 100644
--- a/src/backend/catalog/dependency.c
+++ b/src/backend/catalog/dependency.c
@@ -4,7 +4,7 @@
* Routines to support inter-object dependencies.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/catalog/genbki.pl b/src/backend/catalog/genbki.pl
index a3b8e7ba4c..d07e892525 100644
--- a/src/backend/catalog/genbki.pl
+++ b/src/backend/catalog/genbki.pl
@@ -7,7 +7,7 @@
# header files. The .bki files are used to initialize the postgres
# template database.
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/backend/catalog/genbki.pl
@@ -264,7 +264,7 @@ print SCHEMAPG <
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/libpq/pqcomm.c b/src/backend/libpq/pqcomm.c
index 711fa8299c..3c7b05ba8a 100644
--- a/src/backend/libpq/pqcomm.c
+++ b/src/backend/libpq/pqcomm.c
@@ -27,7 +27,7 @@
* the backend's "backend/libpq" is quite separate from "interfaces/libpq".
* All that remains is similarities of names to trap the unwary...
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/libpq/pqcomm.c
diff --git a/src/backend/libpq/pqformat.c b/src/backend/libpq/pqformat.c
index e24482915e..52922b54d3 100644
--- a/src/backend/libpq/pqformat.c
+++ b/src/backend/libpq/pqformat.c
@@ -21,7 +21,7 @@
* are different.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/libpq/pqformat.c
diff --git a/src/backend/libpq/pqsignal.c b/src/backend/libpq/pqsignal.c
index 2d7e78af4a..31e37e9a2b 100644
--- a/src/backend/libpq/pqsignal.c
+++ b/src/backend/libpq/pqsignal.c
@@ -4,7 +4,7 @@
* reliable BSD-style signal(2) routine stolen from RWW who stole it
* from Stevens...
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/main/main.c b/src/backend/main/main.c
index d3f9bcde7f..5d077888c9 100644
--- a/src/backend/main/main.c
+++ b/src/backend/main/main.c
@@ -9,7 +9,7 @@
* proper FooMain() routine for the incarnation.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/nodes/bitmapset.c b/src/backend/nodes/bitmapset.c
index 48ccc703ed..5546034694 100644
--- a/src/backend/nodes/bitmapset.c
+++ b/src/backend/nodes/bitmapset.c
@@ -11,7 +11,7 @@
* bms_is_empty() in preference to testing for NULL.)
*
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/nodes/bitmapset.c
diff --git a/src/backend/nodes/copyfuncs.c b/src/backend/nodes/copyfuncs.c
index 4e1f221af1..a968e375a6 100644
--- a/src/backend/nodes/copyfuncs.c
+++ b/src/backend/nodes/copyfuncs.c
@@ -11,7 +11,7 @@
* be handled easily in a simple depth-first traversal.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/nodes/equalfuncs.c b/src/backend/nodes/equalfuncs.c
index 85cded0f74..9e7c9481bd 100644
--- a/src/backend/nodes/equalfuncs.c
+++ b/src/backend/nodes/equalfuncs.c
@@ -18,7 +18,7 @@
* "x" to be considered equal() to another reference to "x" in the query.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/nodes/list.c b/src/backend/nodes/list.c
index 37e46ec677..d4684d3cc8 100644
--- a/src/backend/nodes/list.c
+++ b/src/backend/nodes/list.c
@@ -4,7 +4,7 @@
* implementation for PostgreSQL generic linked list package
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/nodes/makefuncs.c b/src/backend/nodes/makefuncs.c
index f06f73bd6a..79da1853c3 100644
--- a/src/backend/nodes/makefuncs.c
+++ b/src/backend/nodes/makefuncs.c
@@ -4,7 +4,7 @@
* creator functions for primitive nodes. The functions here are for
* the most frequently created nodes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/nodes/nodeFuncs.c b/src/backend/nodes/nodeFuncs.c
index a7d1ff4913..d17b347e45 100644
--- a/src/backend/nodes/nodeFuncs.c
+++ b/src/backend/nodes/nodeFuncs.c
@@ -3,7 +3,7 @@
* nodeFuncs.c
* Various general-purpose manipulations of Node trees
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/nodes/nodes.c b/src/backend/nodes/nodes.c
index 76a0c29579..97dbc6918a 100644
--- a/src/backend/nodes/nodes.c
+++ b/src/backend/nodes/nodes.c
@@ -4,7 +4,7 @@
* support code for nodes (now that we have removed the home-brew
* inheritance system, our support code for nodes is much simpler)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/nodes/outfuncs.c b/src/backend/nodes/outfuncs.c
index 7d77d84a37..8825663666 100644
--- a/src/backend/nodes/outfuncs.c
+++ b/src/backend/nodes/outfuncs.c
@@ -3,7 +3,7 @@
* outfuncs.c
* Output functions for Postgres tree nodes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/nodes/params.c b/src/backend/nodes/params.c
index 0c6ed71383..d6e6e6a2bd 100644
--- a/src/backend/nodes/params.c
+++ b/src/backend/nodes/params.c
@@ -4,7 +4,7 @@
* Support for finding the values associated with Param nodes.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/nodes/print.c b/src/backend/nodes/print.c
index bf5bd70bee..14487f25a1 100644
--- a/src/backend/nodes/print.c
+++ b/src/backend/nodes/print.c
@@ -3,7 +3,7 @@
* print.c
* various print routines (used mostly for debugging)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/nodes/read.c b/src/backend/nodes/read.c
index 81a2781fce..78775e8bbd 100644
--- a/src/backend/nodes/read.c
+++ b/src/backend/nodes/read.c
@@ -4,7 +4,7 @@
* routines to convert a string (legal ascii representation of node) back
* to nodes
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/nodes/readfuncs.c b/src/backend/nodes/readfuncs.c
index d0d0b1cfe3..99d0576e5e 100644
--- a/src/backend/nodes/readfuncs.c
+++ b/src/backend/nodes/readfuncs.c
@@ -3,7 +3,7 @@
* readfuncs.c
* Reader functions for Postgres tree nodes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/nodes/tidbitmap.c b/src/backend/nodes/tidbitmap.c
index 9f60439ee7..33f94c03b2 100644
--- a/src/backend/nodes/tidbitmap.c
+++ b/src/backend/nodes/tidbitmap.c
@@ -29,7 +29,7 @@
* and a non-lossy page.
*
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/nodes/tidbitmap.c
diff --git a/src/backend/nodes/value.c b/src/backend/nodes/value.c
index 43cfd79375..cab31eef3e 100644
--- a/src/backend/nodes/value.c
+++ b/src/backend/nodes/value.c
@@ -4,7 +4,7 @@
* implementation of Value nodes
*
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/optimizer/geqo/geqo_copy.c b/src/backend/optimizer/geqo/geqo_copy.c
index 17218e5d22..b6c0331fa0 100644
--- a/src/backend/optimizer/geqo/geqo_copy.c
+++ b/src/backend/optimizer/geqo/geqo_copy.c
@@ -2,7 +2,7 @@
*
* geqo_copy.c
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/optimizer/geqo/geqo_copy.c
diff --git a/src/backend/optimizer/geqo/geqo_eval.c b/src/backend/optimizer/geqo/geqo_eval.c
index 1692264d31..61caec4f85 100644
--- a/src/backend/optimizer/geqo/geqo_eval.c
+++ b/src/backend/optimizer/geqo/geqo_eval.c
@@ -3,7 +3,7 @@
* geqo_eval.c
* Routines to evaluate query trees
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/optimizer/geqo/geqo_eval.c
diff --git a/src/backend/optimizer/geqo/geqo_main.c b/src/backend/optimizer/geqo/geqo_main.c
index c5f93ce787..b3b02d6332 100644
--- a/src/backend/optimizer/geqo/geqo_main.c
+++ b/src/backend/optimizer/geqo/geqo_main.c
@@ -4,7 +4,7 @@
* solution to the query optimization problem
* by means of a Genetic Algorithm (GA)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/optimizer/geqo/geqo_main.c
diff --git a/src/backend/optimizer/geqo/geqo_misc.c b/src/backend/optimizer/geqo/geqo_misc.c
index bec69a595d..a00892d089 100644
--- a/src/backend/optimizer/geqo/geqo_misc.c
+++ b/src/backend/optimizer/geqo/geqo_misc.c
@@ -3,7 +3,7 @@
* geqo_misc.c
* misc. printout and debug stuff
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/optimizer/geqo/geqo_misc.c
diff --git a/src/backend/optimizer/geqo/geqo_pool.c b/src/backend/optimizer/geqo/geqo_pool.c
index b8e13f93d0..d2bbdce804 100644
--- a/src/backend/optimizer/geqo/geqo_pool.c
+++ b/src/backend/optimizer/geqo/geqo_pool.c
@@ -3,7 +3,7 @@
* geqo_pool.c
* Genetic Algorithm (GA) pool stuff
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/optimizer/geqo/geqo_pool.c
diff --git a/src/backend/optimizer/geqo/geqo_random.c b/src/backend/optimizer/geqo/geqo_random.c
index 273b4ec3b5..6d04c8ec2f 100644
--- a/src/backend/optimizer/geqo/geqo_random.c
+++ b/src/backend/optimizer/geqo/geqo_random.c
@@ -3,7 +3,7 @@
* geqo_random.c
* random number generator
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/optimizer/geqo/geqo_random.c
diff --git a/src/backend/optimizer/geqo/geqo_selection.c b/src/backend/optimizer/geqo/geqo_selection.c
index 0bcfe0bb9d..af70c735df 100644
--- a/src/backend/optimizer/geqo/geqo_selection.c
+++ b/src/backend/optimizer/geqo/geqo_selection.c
@@ -3,7 +3,7 @@
* geqo_selection.c
* linear selection scheme for the genetic query optimizer
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/optimizer/geqo/geqo_selection.c
diff --git a/src/backend/optimizer/path/allpaths.c b/src/backend/optimizer/path/allpaths.c
index ce893a77be..37d83323d6 100644
--- a/src/backend/optimizer/path/allpaths.c
+++ b/src/backend/optimizer/path/allpaths.c
@@ -3,7 +3,7 @@
* allpaths.c
* Routines to find possible search paths for processing a query
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/path/clausesel.c b/src/backend/optimizer/path/clausesel.c
index 2eb17afda2..ca068991c1 100644
--- a/src/backend/optimizer/path/clausesel.c
+++ b/src/backend/optimizer/path/clausesel.c
@@ -3,7 +3,7 @@
* clausesel.c
* Routines to compute clause selectivities
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/path/costsize.c b/src/backend/optimizer/path/costsize.c
index e6edbdb1e8..6c98c49bff 100644
--- a/src/backend/optimizer/path/costsize.c
+++ b/src/backend/optimizer/path/costsize.c
@@ -55,7 +55,7 @@
* the non-cost fields of the passed XXXPath to be filled in.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/optimizer/path/equivclass.c b/src/backend/optimizer/path/equivclass.c
index fd38e8bd7a..3d87a5b903 100644
--- a/src/backend/optimizer/path/equivclass.c
+++ b/src/backend/optimizer/path/equivclass.c
@@ -6,7 +6,7 @@
* See src/backend/optimizer/README for discussion of EquivalenceClasses.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/optimizer/path/indxpath.c b/src/backend/optimizer/path/indxpath.c
index 90ccb3928b..ab3d8d00b7 100644
--- a/src/backend/optimizer/path/indxpath.c
+++ b/src/backend/optimizer/path/indxpath.c
@@ -4,7 +4,7 @@
* Routines to determine which indexes are usable for scanning a
* given relation, and create Paths accordingly.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/path/joinpath.c b/src/backend/optimizer/path/joinpath.c
index 7147536429..740dc32dc7 100644
--- a/src/backend/optimizer/path/joinpath.c
+++ b/src/backend/optimizer/path/joinpath.c
@@ -3,7 +3,7 @@
* joinpath.c
* Routines to find all possible paths for processing a set of joins
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/path/joinrels.c b/src/backend/optimizer/path/joinrels.c
index 605a32d52d..42618649fb 100644
--- a/src/backend/optimizer/path/joinrels.c
+++ b/src/backend/optimizer/path/joinrels.c
@@ -3,7 +3,7 @@
* joinrels.c
* Routines to determine which relations should be joined
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/path/orindxpath.c b/src/backend/optimizer/path/orindxpath.c
index 2573809f30..732ab06363 100644
--- a/src/backend/optimizer/path/orindxpath.c
+++ b/src/backend/optimizer/path/orindxpath.c
@@ -3,7 +3,7 @@
* orindxpath.c
* Routines to find index paths that match a set of OR clauses
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/path/pathkeys.c b/src/backend/optimizer/path/pathkeys.c
index 6325655eed..d5536fc2b3 100644
--- a/src/backend/optimizer/path/pathkeys.c
+++ b/src/backend/optimizer/path/pathkeys.c
@@ -7,7 +7,7 @@
* the nature and use of path keys.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/optimizer/path/tidpath.c b/src/backend/optimizer/path/tidpath.c
index 82f144d5ed..05c18b5a87 100644
--- a/src/backend/optimizer/path/tidpath.c
+++ b/src/backend/optimizer/path/tidpath.c
@@ -25,7 +25,7 @@
* for that.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/plan/analyzejoins.c b/src/backend/optimizer/plan/analyzejoins.c
index 89805c36b0..80d42f3be6 100644
--- a/src/backend/optimizer/plan/analyzejoins.c
+++ b/src/backend/optimizer/plan/analyzejoins.c
@@ -11,7 +11,7 @@
* is that we have to work harder to clean up after ourselves when we modify
* the query, since the derived data structures have to be updated too.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/plan/createplan.c b/src/backend/optimizer/plan/createplan.c
index 1bbf35ed74..c74125f1f7 100644
--- a/src/backend/optimizer/plan/createplan.c
+++ b/src/backend/optimizer/plan/createplan.c
@@ -5,7 +5,7 @@
* Planning is complete, we just need to convert the selected
* Path into a Plan.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/plan/initsplan.c b/src/backend/optimizer/plan/initsplan.c
index c74a91f8a7..845b4ae34b 100644
--- a/src/backend/optimizer/plan/initsplan.c
+++ b/src/backend/optimizer/plan/initsplan.c
@@ -3,7 +3,7 @@
* initsplan.c
* Target list, qualification, joininfo initialization routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/plan/planagg.c b/src/backend/optimizer/plan/planagg.c
index 9a18be2046..dfbc624aa8 100644
--- a/src/backend/optimizer/plan/planagg.c
+++ b/src/backend/optimizer/plan/planagg.c
@@ -14,7 +14,7 @@
* scan all the rows anyway.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/plan/planmain.c b/src/backend/optimizer/plan/planmain.c
index 9e6b0b724c..d0e872b646 100644
--- a/src/backend/optimizer/plan/planmain.c
+++ b/src/backend/optimizer/plan/planmain.c
@@ -9,7 +9,7 @@
* shorn of features like subselects, inheritance, aggregates, grouping,
* and so on. (Those are the things planner.c deals with.)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/plan/planner.c b/src/backend/optimizer/plan/planner.c
index fe8ea7e0a4..20b147ce94 100644
--- a/src/backend/optimizer/plan/planner.c
+++ b/src/backend/optimizer/plan/planner.c
@@ -3,7 +3,7 @@
* planner.c
* The query optimizer external interface.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/plan/setrefs.c b/src/backend/optimizer/plan/setrefs.c
index 0074679207..02f5cabd25 100644
--- a/src/backend/optimizer/plan/setrefs.c
+++ b/src/backend/optimizer/plan/setrefs.c
@@ -4,7 +4,7 @@
* Post-processing of a completed plan tree: fix references to subplan
* vars, compute regproc values for operators, etc
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/plan/subselect.c b/src/backend/optimizer/plan/subselect.c
index 39ef420284..febec1e15f 100644
--- a/src/backend/optimizer/plan/subselect.c
+++ b/src/backend/optimizer/plan/subselect.c
@@ -3,7 +3,7 @@
* subselect.c
* Planning routines for subselects and parameters.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/optimizer/prep/prepjointree.c b/src/backend/optimizer/prep/prepjointree.c
index 9c99f0fb5c..c386586f40 100644
--- a/src/backend/optimizer/prep/prepjointree.c
+++ b/src/backend/optimizer/prep/prepjointree.c
@@ -12,7 +12,7 @@
* reduce_outer_joins
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/prep/prepqual.c b/src/backend/optimizer/prep/prepqual.c
index a701390afe..fbd6809724 100644
--- a/src/backend/optimizer/prep/prepqual.c
+++ b/src/backend/optimizer/prep/prepqual.c
@@ -20,7 +20,7 @@
* tree after local transformations that might introduce nested AND/ORs.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/prep/preptlist.c b/src/backend/optimizer/prep/preptlist.c
index bc8b7709d3..2a04e2562d 100644
--- a/src/backend/optimizer/prep/preptlist.c
+++ b/src/backend/optimizer/prep/preptlist.c
@@ -13,7 +13,7 @@
* between here and there is a bit arbitrary and historical.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/optimizer/prep/prepunion.c b/src/backend/optimizer/prep/prepunion.c
index 4686578e3b..dd5513bb57 100644
--- a/src/backend/optimizer/prep/prepunion.c
+++ b/src/backend/optimizer/prep/prepunion.c
@@ -17,7 +17,7 @@
* append relations, and thenceforth share code with the UNION ALL case.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/clauses.c b/src/backend/optimizer/util/clauses.c
index ccf913b35c..86990c8725 100644
--- a/src/backend/optimizer/util/clauses.c
+++ b/src/backend/optimizer/util/clauses.c
@@ -3,7 +3,7 @@
* clauses.c
* routines to manipulate qualification clauses
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/joininfo.c b/src/backend/optimizer/util/joininfo.c
index 0c02181901..b618777762 100644
--- a/src/backend/optimizer/util/joininfo.c
+++ b/src/backend/optimizer/util/joininfo.c
@@ -3,7 +3,7 @@
* joininfo.c
* joininfo list manipulation routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/pathnode.c b/src/backend/optimizer/util/pathnode.c
index 2439d814ce..d1010af662 100644
--- a/src/backend/optimizer/util/pathnode.c
+++ b/src/backend/optimizer/util/pathnode.c
@@ -3,7 +3,7 @@
* pathnode.c
* Routines to manipulate pathlists and create path nodes
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/placeholder.c b/src/backend/optimizer/util/placeholder.c
index c9da718bd1..61edd4991c 100644
--- a/src/backend/optimizer/util/placeholder.c
+++ b/src/backend/optimizer/util/placeholder.c
@@ -4,7 +4,7 @@
* PlaceHolderVar and PlaceHolderInfo manipulation routines
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/plancat.c b/src/backend/optimizer/util/plancat.c
index 2ab272552b..f0504e1397 100644
--- a/src/backend/optimizer/util/plancat.c
+++ b/src/backend/optimizer/util/plancat.c
@@ -4,7 +4,7 @@
* routines for accessing the system catalogs
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/predtest.c b/src/backend/optimizer/util/predtest.c
index d7ccba0a11..6e80b4c0c7 100644
--- a/src/backend/optimizer/util/predtest.c
+++ b/src/backend/optimizer/util/predtest.c
@@ -4,7 +4,7 @@
* Routines to attempt to prove logical implications between predicate
* expressions.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/relnode.c b/src/backend/optimizer/util/relnode.c
index bffd705f18..b7a5845bb1 100644
--- a/src/backend/optimizer/util/relnode.c
+++ b/src/backend/optimizer/util/relnode.c
@@ -3,7 +3,7 @@
* relnode.c
* Relation-node lookup/construction routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/restrictinfo.c b/src/backend/optimizer/util/restrictinfo.c
index aa5861ea44..93f9aa846a 100644
--- a/src/backend/optimizer/util/restrictinfo.c
+++ b/src/backend/optimizer/util/restrictinfo.c
@@ -3,7 +3,7 @@
* restrictinfo.c
* RestrictInfo node manipulation routines.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/tlist.c b/src/backend/optimizer/util/tlist.c
index 8096fcbe61..d7e3a38e6f 100644
--- a/src/backend/optimizer/util/tlist.c
+++ b/src/backend/optimizer/util/tlist.c
@@ -3,7 +3,7 @@
* tlist.c
* Target list manipulation routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/optimizer/util/var.c b/src/backend/optimizer/util/var.c
index b26decc437..944db23800 100644
--- a/src/backend/optimizer/util/var.c
+++ b/src/backend/optimizer/util/var.c
@@ -9,7 +9,7 @@
* contains variables.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/analyze.c b/src/backend/parser/analyze.c
index 3d84f61e0a..070e4c177a 100644
--- a/src/backend/parser/analyze.c
+++ b/src/backend/parser/analyze.c
@@ -14,7 +14,7 @@
* optimizable statements.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/parser/analyze.c
diff --git a/src/backend/parser/gram.y b/src/backend/parser/gram.y
index 26a5e84d44..8c89d5c5f7 100644
--- a/src/backend/parser/gram.y
+++ b/src/backend/parser/gram.y
@@ -6,7 +6,7 @@
* gram.y
* POSTGRESQL BISON rules/actions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/keywords.c b/src/backend/parser/keywords.c
index 8fa4c97cb9..bb910e706d 100644
--- a/src/backend/parser/keywords.c
+++ b/src/backend/parser/keywords.c
@@ -4,7 +4,7 @@
* lexical token lookup for key words in PostgreSQL
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/kwlookup.c b/src/backend/parser/kwlookup.c
index 2b06023611..1d8b7283c1 100644
--- a/src/backend/parser/kwlookup.c
+++ b/src/backend/parser/kwlookup.c
@@ -6,7 +6,7 @@
* NB - this file is also used by ECPG and several frontend programs in
* src/bin/ including pg_dump and psql
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_agg.c b/src/backend/parser/parse_agg.c
index 70e60ab716..e43bc54b3f 100644
--- a/src/backend/parser/parse_agg.c
+++ b/src/backend/parser/parse_agg.c
@@ -3,7 +3,7 @@
* parse_agg.c
* handle aggregates and window functions in parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_clause.c b/src/backend/parser/parse_clause.c
index 898c55e98f..f9560d07b9 100644
--- a/src/backend/parser/parse_clause.c
+++ b/src/backend/parser/parse_clause.c
@@ -3,7 +3,7 @@
* parse_clause.c
* handle clauses in parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_coerce.c b/src/backend/parser/parse_coerce.c
index 4eb48ff8b1..33a60a1edb 100644
--- a/src/backend/parser/parse_coerce.c
+++ b/src/backend/parser/parse_coerce.c
@@ -3,7 +3,7 @@
* parse_coerce.c
* handle type coercions/conversions for parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_cte.c b/src/backend/parser/parse_cte.c
index bd8e6a1a30..24ba008f9e 100644
--- a/src/backend/parser/parse_cte.c
+++ b/src/backend/parser/parse_cte.c
@@ -3,7 +3,7 @@
* parse_cte.c
* handle CTEs (common table expressions) in parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_expr.c b/src/backend/parser/parse_expr.c
index ca48b9b104..129b39cb26 100644
--- a/src/backend/parser/parse_expr.c
+++ b/src/backend/parser/parse_expr.c
@@ -3,7 +3,7 @@
* parse_expr.c
* handle expressions in parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_func.c b/src/backend/parser/parse_func.c
index 9bb100e0c1..f1a4f9b959 100644
--- a/src/backend/parser/parse_func.c
+++ b/src/backend/parser/parse_func.c
@@ -3,7 +3,7 @@
* parse_func.c
* handle function calls in parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_node.c b/src/backend/parser/parse_node.c
index 0f0a188eec..aed404eb1d 100644
--- a/src/backend/parser/parse_node.c
+++ b/src/backend/parser/parse_node.c
@@ -3,7 +3,7 @@
* parse_node.c
* various routines that make nodes for querytrees
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_oper.c b/src/backend/parser/parse_oper.c
index 8305ca9798..1f50bdcc34 100644
--- a/src/backend/parser/parse_oper.c
+++ b/src/backend/parser/parse_oper.c
@@ -3,7 +3,7 @@
* parse_oper.c
* handle operator things for parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_param.c b/src/backend/parser/parse_param.c
index 205c42b924..c9987d2723 100644
--- a/src/backend/parser/parse_param.c
+++ b/src/backend/parser/parse_param.c
@@ -12,7 +12,7 @@
* Note that other approaches to parameters are possible using the parser
* hooks defined in ParseState.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_relation.c b/src/backend/parser/parse_relation.c
index b32ca3cfcd..331ac670ff 100644
--- a/src/backend/parser/parse_relation.c
+++ b/src/backend/parser/parse_relation.c
@@ -3,7 +3,7 @@
* parse_relation.c
* parser support routines dealing with relations
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_target.c b/src/backend/parser/parse_target.c
index c777484d45..7d77e0b63f 100644
--- a/src/backend/parser/parse_target.c
+++ b/src/backend/parser/parse_target.c
@@ -3,7 +3,7 @@
* parse_target.c
* handle target lists
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_type.c b/src/backend/parser/parse_type.c
index b9acbdc431..0b601c8b75 100644
--- a/src/backend/parser/parse_type.c
+++ b/src/backend/parser/parse_type.c
@@ -3,7 +3,7 @@
* parse_type.c
* handle type operations for parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/parser/parse_utilcmd.c b/src/backend/parser/parse_utilcmd.c
index aa7c144c94..d75c706816 100644
--- a/src/backend/parser/parse_utilcmd.c
+++ b/src/backend/parser/parse_utilcmd.c
@@ -16,7 +16,7 @@
* a quick copyObject() call before manipulating the query tree.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/parser/parse_utilcmd.c
diff --git a/src/backend/parser/parser.c b/src/backend/parser/parser.c
index d0a1d85ace..e389208d46 100644
--- a/src/backend/parser/parser.c
+++ b/src/backend/parser/parser.c
@@ -10,7 +10,7 @@
* analyze.c and related files.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/parser/scan.l b/src/backend/parser/scan.l
index 1fe2b9bcf3..4f9af543d6 100644
--- a/src/backend/parser/scan.l
+++ b/src/backend/parser/scan.l
@@ -20,7 +20,7 @@
* resulting "lex.backup" file says that no backing up is needed.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/parser/scansup.c b/src/backend/parser/scansup.c
index 1d8453e7fd..c6ac203f86 100644
--- a/src/backend/parser/scansup.c
+++ b/src/backend/parser/scansup.c
@@ -4,7 +4,7 @@
* support routines for the lex/flex scanner, used by both the normal
* backend as well as the bootstrap backend
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/port/dynloader/aix.h b/src/backend/port/dynloader/aix.h
index e7b18f0555..a6ff723e7b 100644
--- a/src/backend/port/dynloader/aix.h
+++ b/src/backend/port/dynloader/aix.h
@@ -4,7 +4,7 @@
* prototypes for AIX-specific routines
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/aix.h
diff --git a/src/backend/port/dynloader/bsdi.c b/src/backend/port/dynloader/bsdi.c
index 978bfb44d9..559f30ba9b 100644
--- a/src/backend/port/dynloader/bsdi.c
+++ b/src/backend/port/dynloader/bsdi.c
@@ -6,7 +6,7 @@
*
* You need to install the dld library on your Linux system!
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/port/dynloader/bsdi.h b/src/backend/port/dynloader/bsdi.h
index 9f7827fbf5..12daffa851 100644
--- a/src/backend/port/dynloader/bsdi.h
+++ b/src/backend/port/dynloader/bsdi.h
@@ -3,7 +3,7 @@
* bsdi.h
* Dynamic loader interface for BSD/OS
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/bsdi.h
diff --git a/src/backend/port/dynloader/cygwin.h b/src/backend/port/dynloader/cygwin.h
index 111bf8269a..67ae4b0ab5 100644
--- a/src/backend/port/dynloader/cygwin.h
+++ b/src/backend/port/dynloader/cygwin.h
@@ -2,7 +2,7 @@
*
* Dynamic loader declarations for Cygwin
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/cygwin.h
diff --git a/src/backend/port/dynloader/dgux.h b/src/backend/port/dynloader/dgux.h
index 7fc6c9ef3c..5c1e3b39a8 100644
--- a/src/backend/port/dynloader/dgux.h
+++ b/src/backend/port/dynloader/dgux.h
@@ -2,7 +2,7 @@
*
* dgux.h
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/dgux.h
diff --git a/src/backend/port/dynloader/freebsd.c b/src/backend/port/dynloader/freebsd.c
index cc79d321a5..58cf979df5 100644
--- a/src/backend/port/dynloader/freebsd.c
+++ b/src/backend/port/dynloader/freebsd.c
@@ -1,7 +1,7 @@
/* src/backend/port/dynloader/freebsd.c */
/*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1990 The Regents of the University of California.
* All rights reserved.
*
diff --git a/src/backend/port/dynloader/freebsd.h b/src/backend/port/dynloader/freebsd.h
index 67009c2467..c10ffe6cbf 100644
--- a/src/backend/port/dynloader/freebsd.h
+++ b/src/backend/port/dynloader/freebsd.h
@@ -3,7 +3,7 @@
* freebsd.h
* port-specific prototypes for FreeBSD
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/freebsd.h
diff --git a/src/backend/port/dynloader/hpux.c b/src/backend/port/dynloader/hpux.c
index db66af243d..561f738e58 100644
--- a/src/backend/port/dynloader/hpux.c
+++ b/src/backend/port/dynloader/hpux.c
@@ -3,7 +3,7 @@
* dynloader.c
* dynamic loader for HP-UX using the shared library mechanism
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/port/dynloader/hpux.h b/src/backend/port/dynloader/hpux.h
index 141bde6a4e..3ae77a4f74 100644
--- a/src/backend/port/dynloader/hpux.h
+++ b/src/backend/port/dynloader/hpux.h
@@ -3,7 +3,7 @@
* dynloader.h
* dynamic loader for HP-UX using the shared library mechanism
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/port/dynloader/irix.h b/src/backend/port/dynloader/irix.h
index d57d8dcc7a..ae9377df64 100644
--- a/src/backend/port/dynloader/irix.h
+++ b/src/backend/port/dynloader/irix.h
@@ -4,7 +4,7 @@
* port-specific prototypes for Irix
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/irix.h
diff --git a/src/backend/port/dynloader/linux.c b/src/backend/port/dynloader/linux.c
index 7b81345e51..5b1b78db0c 100644
--- a/src/backend/port/dynloader/linux.c
+++ b/src/backend/port/dynloader/linux.c
@@ -6,7 +6,7 @@
*
* You need to install the dld library on your Linux system!
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/port/dynloader/linux.h b/src/backend/port/dynloader/linux.h
index 2607696bac..2e1330cd3f 100644
--- a/src/backend/port/dynloader/linux.h
+++ b/src/backend/port/dynloader/linux.h
@@ -4,7 +4,7 @@
* Port-specific prototypes for Linux
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/linux.h
diff --git a/src/backend/port/dynloader/netbsd.c b/src/backend/port/dynloader/netbsd.c
index ef22681243..7aecf170c5 100644
--- a/src/backend/port/dynloader/netbsd.c
+++ b/src/backend/port/dynloader/netbsd.c
@@ -1,5 +1,5 @@
/*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1990 The Regents of the University of California.
* All rights reserved.
*
diff --git a/src/backend/port/dynloader/netbsd.h b/src/backend/port/dynloader/netbsd.h
index a06cecbaf7..71d9260a7c 100644
--- a/src/backend/port/dynloader/netbsd.h
+++ b/src/backend/port/dynloader/netbsd.h
@@ -4,7 +4,7 @@
* port-specific prototypes for NetBSD
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/netbsd.h
diff --git a/src/backend/port/dynloader/openbsd.c b/src/backend/port/dynloader/openbsd.c
index 1391c70d55..d099ec3760 100644
--- a/src/backend/port/dynloader/openbsd.c
+++ b/src/backend/port/dynloader/openbsd.c
@@ -1,5 +1,5 @@
/*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1990 The Regents of the University of California.
* All rights reserved.
*
diff --git a/src/backend/port/dynloader/openbsd.h b/src/backend/port/dynloader/openbsd.h
index 372a3d1624..55fc106292 100644
--- a/src/backend/port/dynloader/openbsd.h
+++ b/src/backend/port/dynloader/openbsd.h
@@ -3,7 +3,7 @@
* openbsd.h
* port-specific prototypes for OpenBSD
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/openbsd.h
diff --git a/src/backend/port/dynloader/osf.h b/src/backend/port/dynloader/osf.h
index 2a2dbbc38a..f211ebf43c 100644
--- a/src/backend/port/dynloader/osf.h
+++ b/src/backend/port/dynloader/osf.h
@@ -4,7 +4,7 @@
* prototypes for OSF/1-specific routines
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/osf.h
diff --git a/src/backend/port/dynloader/sco.h b/src/backend/port/dynloader/sco.h
index aa6be7ebf3..2774e9efde 100644
--- a/src/backend/port/dynloader/sco.h
+++ b/src/backend/port/dynloader/sco.h
@@ -4,7 +4,7 @@
* port-specific prototypes for SCO 3.2v5.2
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/sco.h
diff --git a/src/backend/port/dynloader/solaris.h b/src/backend/port/dynloader/solaris.h
index 3182f0807c..75c1255f8a 100644
--- a/src/backend/port/dynloader/solaris.h
+++ b/src/backend/port/dynloader/solaris.h
@@ -4,7 +4,7 @@
* port-specific prototypes for Solaris
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/solaris.h
diff --git a/src/backend/port/dynloader/sunos4.h b/src/backend/port/dynloader/sunos4.h
index f4f1aff583..c65ad43dd5 100644
--- a/src/backend/port/dynloader/sunos4.h
+++ b/src/backend/port/dynloader/sunos4.h
@@ -4,7 +4,7 @@
* port-specific prototypes for SunOS 4
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/sunos4.h
diff --git a/src/backend/port/dynloader/svr4.h b/src/backend/port/dynloader/svr4.h
index 617711cfad..2f34fed678 100644
--- a/src/backend/port/dynloader/svr4.h
+++ b/src/backend/port/dynloader/svr4.h
@@ -4,7 +4,7 @@
* port-specific prototypes for Intel x86/Intel SVR4
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/svr4.h
diff --git a/src/backend/port/dynloader/ultrix4.c b/src/backend/port/dynloader/ultrix4.c
index 7992b6a514..e4348b96c3 100644
--- a/src/backend/port/dynloader/ultrix4.c
+++ b/src/backend/port/dynloader/ultrix4.c
@@ -3,7 +3,7 @@
* ultrix4.c
* This dynamic loader uses Andrew Yu's libdl-1.0 package for Ultrix 4.x.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/port/dynloader/ultrix4.h b/src/backend/port/dynloader/ultrix4.h
index 159330adab..5cd9754d2d 100644
--- a/src/backend/port/dynloader/ultrix4.h
+++ b/src/backend/port/dynloader/ultrix4.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/port/dynloader/ultrix4.h
diff --git a/src/backend/port/dynloader/univel.h b/src/backend/port/dynloader/univel.h
index a072468d1c..68e5c40e1a 100644
--- a/src/backend/port/dynloader/univel.h
+++ b/src/backend/port/dynloader/univel.h
@@ -7,7 +7,7 @@
* port-specific prototypes for Intel x86/UNIXWARE
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* univel.h,v 1.2 1995/03/17 06:40:18 andrew Exp
diff --git a/src/backend/port/dynloader/unixware.h b/src/backend/port/dynloader/unixware.h
index b31e0dc8b0..b046968afa 100644
--- a/src/backend/port/dynloader/unixware.h
+++ b/src/backend/port/dynloader/unixware.h
@@ -7,7 +7,7 @@
* port-specific prototypes for Intel x86/UNIXWARE 7
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* unixware.h,v 1.2 1995/03/17 06:40:18 andrew Exp
diff --git a/src/backend/port/ipc_test.c b/src/backend/port/ipc_test.c
index 461a7a65b2..2518007c4b 100644
--- a/src/backend/port/ipc_test.c
+++ b/src/backend/port/ipc_test.c
@@ -16,7 +16,7 @@
* the parallel regression tests for a more complete test.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/port/posix_sema.c b/src/backend/port/posix_sema.c
index aeba75816f..acd0094360 100644
--- a/src/backend/port/posix_sema.c
+++ b/src/backend/port/posix_sema.c
@@ -7,7 +7,7 @@
* sem_init). We can cope with the kind made with sem_open, however.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/port/sysv_sema.c b/src/backend/port/sysv_sema.c
index 00d3de1bb0..72f62e7951 100644
--- a/src/backend/port/sysv_sema.c
+++ b/src/backend/port/sysv_sema.c
@@ -4,7 +4,7 @@
* Implement PGSemaphores using SysV semaphore facilities
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/port/sysv_shmem.c b/src/backend/port/sysv_shmem.c
index ff77099885..474c6142eb 100644
--- a/src/backend/port/sysv_shmem.c
+++ b/src/backend/port/sysv_shmem.c
@@ -6,7 +6,7 @@
* These routines represent a fairly thin layer on top of SysV shared
* memory functionality.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/port/tas/sunstudio_sparc.s b/src/backend/port/tas/sunstudio_sparc.s
index c8c20e747a..92103156d2 100644
--- a/src/backend/port/tas/sunstudio_sparc.s
+++ b/src/backend/port/tas/sunstudio_sparc.s
@@ -3,7 +3,7 @@
! sunstudio_sparc.s
! compare and swap for Sun Studio on Sparc
!
-! Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+! Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
! Portions Copyright (c) 1994, Regents of the University of California
!
! IDENTIFICATION
diff --git a/src/backend/port/tas/sunstudio_x86.s b/src/backend/port/tas/sunstudio_x86.s
index ef2233bce1..1feb8b0ab8 100644
--- a/src/backend/port/tas/sunstudio_x86.s
+++ b/src/backend/port/tas/sunstudio_x86.s
@@ -3,7 +3,7 @@
/ sunstudio_x86.s
/ compare and swap for Sun Studio on x86
/
-/ Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+/ Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
/ Portions Copyright (c) 1994, Regents of the University of California
/
/ IDENTIFICATION
diff --git a/src/backend/port/unix_latch.c b/src/backend/port/unix_latch.c
index b8bab4ece8..a4f559ed3f 100644
--- a/src/backend/port/unix_latch.c
+++ b/src/backend/port/unix_latch.c
@@ -73,7 +73,7 @@
* process, SIGUSR1 is sent and the signal handler in the waiting process
* writes the byte to the pipe on behalf of the signaling process.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/port/win32/crashdump.c b/src/backend/port/win32/crashdump.c
index 2f7c1b3ab6..b58b181ed9 100644
--- a/src/backend/port/win32/crashdump.c
+++ b/src/backend/port/win32/crashdump.c
@@ -28,7 +28,7 @@
* be added, though at the cost of a greater chance of the crash dump failing.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/port/win32/crashdump.c
diff --git a/src/backend/port/win32/mingwcompat.c b/src/backend/port/win32/mingwcompat.c
index 7e7055f5c0..e12aca3d70 100644
--- a/src/backend/port/win32/mingwcompat.c
+++ b/src/backend/port/win32/mingwcompat.c
@@ -3,7 +3,7 @@
* mingwcompat.c
* MinGW compatibility functions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/port/win32/mingwcompat.c
diff --git a/src/backend/port/win32/security.c b/src/backend/port/win32/security.c
index 80bc08bbcd..f5e16052d8 100644
--- a/src/backend/port/win32/security.c
+++ b/src/backend/port/win32/security.c
@@ -3,7 +3,7 @@
* security.c
* Microsoft Windows Win32 Security Support Functions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/port/win32/security.c
diff --git a/src/backend/port/win32/signal.c b/src/backend/port/win32/signal.c
index da14f24a9b..b5675ec76f 100644
--- a/src/backend/port/win32/signal.c
+++ b/src/backend/port/win32/signal.c
@@ -3,7 +3,7 @@
* signal.c
* Microsoft Windows Win32 Signal Emulation Functions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/port/win32/signal.c
diff --git a/src/backend/port/win32/socket.c b/src/backend/port/win32/socket.c
index f7090b9210..76dd6be9a6 100644
--- a/src/backend/port/win32/socket.c
+++ b/src/backend/port/win32/socket.c
@@ -3,7 +3,7 @@
* socket.c
* Microsoft Windows Win32 Socket Functions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/port/win32/socket.c
diff --git a/src/backend/port/win32/timer.c b/src/backend/port/win32/timer.c
index 94ce92e621..1eb6de9bdb 100644
--- a/src/backend/port/win32/timer.c
+++ b/src/backend/port/win32/timer.c
@@ -8,7 +8,7 @@
* - Does not support interval timer (value->it_interval)
* - Only supports ITIMER_REAL
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/port/win32/timer.c
diff --git a/src/backend/port/win32_latch.c b/src/backend/port/win32_latch.c
index c499d02920..ac20c4958f 100644
--- a/src/backend/port/win32_latch.c
+++ b/src/backend/port/win32_latch.c
@@ -8,7 +8,7 @@
* The Windows implementation uses Windows events that are inherited by
* all postmaster child processes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/port/win32_sema.c b/src/backend/port/win32_sema.c
index 3d833ab155..8c364dfe88 100644
--- a/src/backend/port/win32_sema.c
+++ b/src/backend/port/win32_sema.c
@@ -3,7 +3,7 @@
* win32_sema.c
* Microsoft Windows Win32 Semaphores Emulation
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/port/win32_sema.c
diff --git a/src/backend/port/win32_shmem.c b/src/backend/port/win32_shmem.c
index ff9baf9d38..1a2ee12dcb 100644
--- a/src/backend/port/win32_shmem.c
+++ b/src/backend/port/win32_shmem.c
@@ -3,7 +3,7 @@
* win32_shmem.c
* Implement shared memory using win32 facilities
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/port/win32_shmem.c
diff --git a/src/backend/postmaster/autovacuum.c b/src/backend/postmaster/autovacuum.c
index 89b2540871..7bacf9b2de 100644
--- a/src/backend/postmaster/autovacuum.c
+++ b/src/backend/postmaster/autovacuum.c
@@ -50,7 +50,7 @@
* there is a window (caused by pgstat delay) on which a worker may choose a
* table that was already vacuumed; this is a bug in the current design.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/postmaster/bgwriter.c b/src/backend/postmaster/bgwriter.c
index 620b1972a6..4457df6e74 100644
--- a/src/backend/postmaster/bgwriter.c
+++ b/src/backend/postmaster/bgwriter.c
@@ -34,7 +34,7 @@
* restart needs to be forced.)
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/postmaster/fork_process.c b/src/backend/postmaster/fork_process.c
index 5b8e5f6708..b2fe9a13f4 100644
--- a/src/backend/postmaster/fork_process.c
+++ b/src/backend/postmaster/fork_process.c
@@ -4,7 +4,7 @@
* EXEC_BACKEND case; it might be extended to do so, but it would be
* considerably more complex.
*
- * Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/postmaster/fork_process.c
diff --git a/src/backend/postmaster/pgarch.c b/src/backend/postmaster/pgarch.c
index a414f34221..b40375aaaa 100644
--- a/src/backend/postmaster/pgarch.c
+++ b/src/backend/postmaster/pgarch.c
@@ -14,7 +14,7 @@
*
* Initial author: Simon Riggs simon@2ndquadrant.com
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/postmaster/pgstat.c b/src/backend/postmaster/pgstat.c
index 856daa721d..850a543d7e 100644
--- a/src/backend/postmaster/pgstat.c
+++ b/src/backend/postmaster/pgstat.c
@@ -11,7 +11,7 @@
* - Add a pgstat config column to pg_database, so this
* entire thing can be enabled/disabled on a per db basis.
*
- * Copyright (c) 2001-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2001-2011, PostgreSQL Global Development Group
*
* src/backend/postmaster/pgstat.c
* ----------
diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c
index c1e553a85b..d158ded390 100644
--- a/src/backend/postmaster/postmaster.c
+++ b/src/backend/postmaster/postmaster.c
@@ -32,7 +32,7 @@
* clients.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/postmaster/syslogger.c b/src/backend/postmaster/syslogger.c
index 7541f88cc3..f2eb0ad02b 100644
--- a/src/backend/postmaster/syslogger.c
+++ b/src/backend/postmaster/syslogger.c
@@ -14,7 +14,7 @@
*
* Author: Andreas Pflug
*
- * Copyright (c) 2004-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2004-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/postmaster/walwriter.c b/src/backend/postmaster/walwriter.c
index 260b053bb1..d0d7c9bebf 100644
--- a/src/backend/postmaster/walwriter.c
+++ b/src/backend/postmaster/walwriter.c
@@ -30,7 +30,7 @@
* should be killed by SIGQUIT and then a recovery cycle started.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/replication/libpqwalreceiver/libpqwalreceiver.c b/src/backend/replication/libpqwalreceiver/libpqwalreceiver.c
index d1ab36755f..5aac85d2ee 100644
--- a/src/backend/replication/libpqwalreceiver/libpqwalreceiver.c
+++ b/src/backend/replication/libpqwalreceiver/libpqwalreceiver.c
@@ -6,7 +6,7 @@
* loaded as a dynamic module to avoid linking the main server binary with
* libpq.
*
- * Portions Copyright (c) 2010-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2010-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/replication/walreceiver.c b/src/backend/replication/walreceiver.c
index fac3be340f..d257caf913 100644
--- a/src/backend/replication/walreceiver.c
+++ b/src/backend/replication/walreceiver.c
@@ -25,7 +25,7 @@
* specific parts are in the libpqwalreceiver module. It's loaded
* dynamically to avoid linking the server with libpq.
*
- * Portions Copyright (c) 2010-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2010-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/replication/walreceiverfuncs.c b/src/backend/replication/walreceiverfuncs.c
index 1852fd3c92..04c9004943 100644
--- a/src/backend/replication/walreceiverfuncs.c
+++ b/src/backend/replication/walreceiverfuncs.c
@@ -6,7 +6,7 @@
* with the walreceiver process. Functions implementing walreceiver itself
* are in walreceiver.c.
*
- * Portions Copyright (c) 2010-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2010-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/replication/walsender.c b/src/backend/replication/walsender.c
index c8d2433158..269d200707 100644
--- a/src/backend/replication/walsender.c
+++ b/src/backend/replication/walsender.c
@@ -25,7 +25,7 @@
* shutdown checkpoint record, and then exit.
*
*
- * Portions Copyright (c) 2010-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2010-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/replication/walsender.c
diff --git a/src/backend/rewrite/rewriteDefine.c b/src/backend/rewrite/rewriteDefine.c
index 4354897981..99c397b4f2 100644
--- a/src/backend/rewrite/rewriteDefine.c
+++ b/src/backend/rewrite/rewriteDefine.c
@@ -3,7 +3,7 @@
* rewriteDefine.c
* routines for defining a rewrite rule
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/rewrite/rewriteHandler.c b/src/backend/rewrite/rewriteHandler.c
index a332611a58..c12d4cb6a3 100644
--- a/src/backend/rewrite/rewriteHandler.c
+++ b/src/backend/rewrite/rewriteHandler.c
@@ -3,7 +3,7 @@
* rewriteHandler.c
* Primary module of query rewriter.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/rewrite/rewriteManip.c b/src/backend/rewrite/rewriteManip.c
index 7333ce29aa..49a6df0e80 100644
--- a/src/backend/rewrite/rewriteManip.c
+++ b/src/backend/rewrite/rewriteManip.c
@@ -2,7 +2,7 @@
*
* rewriteManip.c
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/rewrite/rewriteRemove.c b/src/backend/rewrite/rewriteRemove.c
index ce3d53ebea..b9dc7c5d9f 100644
--- a/src/backend/rewrite/rewriteRemove.c
+++ b/src/backend/rewrite/rewriteRemove.c
@@ -3,7 +3,7 @@
* rewriteRemove.c
* routines for removing rewrite rules
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/rewrite/rewriteSupport.c b/src/backend/rewrite/rewriteSupport.c
index c6522c98f9..9feed7345e 100644
--- a/src/backend/rewrite/rewriteSupport.c
+++ b/src/backend/rewrite/rewriteSupport.c
@@ -3,7 +3,7 @@
* rewriteSupport.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/snowball/dict_snowball.c b/src/backend/snowball/dict_snowball.c
index bfd27b97c8..c59ad1cb65 100644
--- a/src/backend/snowball/dict_snowball.c
+++ b/src/backend/snowball/dict_snowball.c
@@ -3,7 +3,7 @@
* dict_snowball.c
* Snowball dictionary
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/snowball/dict_snowball.c
diff --git a/src/backend/storage/buffer/buf_init.c b/src/backend/storage/buffer/buf_init.c
index 2da85db7c5..dadb49dae9 100644
--- a/src/backend/storage/buffer/buf_init.c
+++ b/src/backend/storage/buffer/buf_init.c
@@ -3,7 +3,7 @@
* buf_init.c
* buffer manager initialization routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/buffer/buf_table.c b/src/backend/storage/buffer/buf_table.c
index dc30e47fb5..33ecd1214e 100644
--- a/src/backend/storage/buffer/buf_table.c
+++ b/src/backend/storage/buffer/buf_table.c
@@ -10,7 +10,7 @@
* before the lock is released (see notes in README).
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/buffer/bufmgr.c b/src/backend/storage/buffer/bufmgr.c
index 34e5453669..1f89e52705 100644
--- a/src/backend/storage/buffer/bufmgr.c
+++ b/src/backend/storage/buffer/bufmgr.c
@@ -3,7 +3,7 @@
* bufmgr.c
* buffer manager interface routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/buffer/freelist.c b/src/backend/storage/buffer/freelist.c
index 995e745750..72968db026 100644
--- a/src/backend/storage/buffer/freelist.c
+++ b/src/backend/storage/buffer/freelist.c
@@ -4,7 +4,7 @@
* routines for managing the buffer pool's replacement strategy.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/buffer/localbuf.c b/src/backend/storage/buffer/localbuf.c
index 059c7f1847..0a01ed544e 100644
--- a/src/backend/storage/buffer/localbuf.c
+++ b/src/backend/storage/buffer/localbuf.c
@@ -4,7 +4,7 @@
* local buffer manager. Fast buffer manager for temporary tables,
* which never need to be WAL-logged or checkpointed, etc.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994-5, Regents of the University of California
*
*
diff --git a/src/backend/storage/file/buffile.c b/src/backend/storage/file/buffile.c
index 59813b83d0..c436d71877 100644
--- a/src/backend/storage/file/buffile.c
+++ b/src/backend/storage/file/buffile.c
@@ -3,7 +3,7 @@
* buffile.c
* Management of large buffered files, primarily temporary files.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/file/copydir.c b/src/backend/storage/file/copydir.c
index 587fb9260c..6cfb8164f6 100644
--- a/src/backend/storage/file/copydir.c
+++ b/src/backend/storage/file/copydir.c
@@ -3,7 +3,7 @@
* copydir.c
* copies a directory
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* While "xcopy /e /i /q" works fine for copying directories, on Windows XP
diff --git a/src/backend/storage/file/fd.c b/src/backend/storage/file/fd.c
index a1dc18be44..bdb97b2ad1 100644
--- a/src/backend/storage/file/fd.c
+++ b/src/backend/storage/file/fd.c
@@ -3,7 +3,7 @@
* fd.c
* Virtual file descriptor code.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/file/reinit.c b/src/backend/storage/file/reinit.c
index b75178b804..54fde73de8 100644
--- a/src/backend/storage/file/reinit.c
+++ b/src/backend/storage/file/reinit.c
@@ -3,7 +3,7 @@
* reinit.c
* Reinitialization of unlogged relations
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/freespace/freespace.c b/src/backend/storage/freespace/freespace.c
index cde9746f8c..1a5a874c86 100644
--- a/src/backend/storage/freespace/freespace.c
+++ b/src/backend/storage/freespace/freespace.c
@@ -4,7 +4,7 @@
* POSTGRES free space map for quickly finding free space in relations
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/freespace/fsmpage.c b/src/backend/storage/freespace/fsmpage.c
index 635cbcd28a..8e8096cece 100644
--- a/src/backend/storage/freespace/fsmpage.c
+++ b/src/backend/storage/freespace/fsmpage.c
@@ -4,7 +4,7 @@
* routines to search and manipulate one FSM page.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/freespace/indexfsm.c b/src/backend/storage/freespace/indexfsm.c
index 07771fe2f5..0994e61bbb 100644
--- a/src/backend/storage/freespace/indexfsm.c
+++ b/src/backend/storage/freespace/indexfsm.c
@@ -4,7 +4,7 @@
* POSTGRES free space map for quickly finding free pages in relations
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/ipc/ipc.c b/src/backend/storage/ipc/ipc.c
index 27b46954e0..540209ce79 100644
--- a/src/backend/storage/ipc/ipc.c
+++ b/src/backend/storage/ipc/ipc.c
@@ -8,7 +8,7 @@
* exit-time cleanup for either a postmaster or a backend.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/ipc/ipci.c b/src/backend/storage/ipc/ipci.c
index 95beba8ab4..2dbac56c25 100644
--- a/src/backend/storage/ipc/ipci.c
+++ b/src/backend/storage/ipc/ipci.c
@@ -3,7 +3,7 @@
* ipci.c
* POSTGRES inter-process communication initialization code.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/ipc/pmsignal.c b/src/backend/storage/ipc/pmsignal.c
index d2d6fa4687..155bd751bf 100644
--- a/src/backend/storage/ipc/pmsignal.c
+++ b/src/backend/storage/ipc/pmsignal.c
@@ -4,7 +4,7 @@
* routines for signaling the postmaster from its child processes
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/ipc/procarray.c b/src/backend/storage/ipc/procarray.c
index 980996e5eb..d5786477bc 100644
--- a/src/backend/storage/ipc/procarray.c
+++ b/src/backend/storage/ipc/procarray.c
@@ -32,7 +32,7 @@
* happen, it would tie up KnownAssignedXids indefinitely, so we protect
* ourselves by pruning the array when a valid list of running XIDs arrives.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/ipc/procsignal.c b/src/backend/storage/ipc/procsignal.c
index 7704b35161..28bcaa7e1e 100644
--- a/src/backend/storage/ipc/procsignal.c
+++ b/src/backend/storage/ipc/procsignal.c
@@ -4,7 +4,7 @@
* Routines for interprocess signalling
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/ipc/shmem.c b/src/backend/storage/ipc/shmem.c
index 2e69f1f60f..6280957799 100644
--- a/src/backend/storage/ipc/shmem.c
+++ b/src/backend/storage/ipc/shmem.c
@@ -3,7 +3,7 @@
* shmem.c
* create shared memory and initialize shared memory data structures.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/ipc/shmqueue.c b/src/backend/storage/ipc/shmqueue.c
index 58cd538bfd..0277c3f9f4 100644
--- a/src/backend/storage/ipc/shmqueue.c
+++ b/src/backend/storage/ipc/shmqueue.c
@@ -3,7 +3,7 @@
* shmqueue.c
* shared memory linked lists
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/ipc/sinval.c b/src/backend/storage/ipc/sinval.c
index 6c33c932e3..9ab16b16ed 100644
--- a/src/backend/storage/ipc/sinval.c
+++ b/src/backend/storage/ipc/sinval.c
@@ -3,7 +3,7 @@
* sinval.c
* POSTGRES shared cache invalidation communication code.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/ipc/sinvaladt.c b/src/backend/storage/ipc/sinvaladt.c
index 7910346dd5..1df20c4732 100644
--- a/src/backend/storage/ipc/sinvaladt.c
+++ b/src/backend/storage/ipc/sinvaladt.c
@@ -3,7 +3,7 @@
* sinvaladt.c
* POSTGRES shared cache invalidation data manager.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/ipc/standby.c b/src/backend/storage/ipc/standby.c
index b659c32058..8d827464d9 100644
--- a/src/backend/storage/ipc/standby.c
+++ b/src/backend/storage/ipc/standby.c
@@ -7,7 +7,7 @@
* AccessExclusiveLocks and starting snapshots for Hot Standby mode.
* Plus conflict recovery processing.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/large_object/inv_api.c b/src/backend/storage/large_object/inv_api.c
index 686770cd45..f06bf65075 100644
--- a/src/backend/storage/large_object/inv_api.c
+++ b/src/backend/storage/large_object/inv_api.c
@@ -19,7 +19,7 @@
* memory context given to inv_open (for LargeObjectDesc structs).
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/lmgr/deadlock.c b/src/backend/storage/lmgr/deadlock.c
index 0ac4874188..980042b6af 100644
--- a/src/backend/storage/lmgr/deadlock.c
+++ b/src/backend/storage/lmgr/deadlock.c
@@ -7,7 +7,7 @@
* detection and resolution algorithms.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/lmgr/lmgr.c b/src/backend/storage/lmgr/lmgr.c
index 9f335ed486..859b3852db 100644
--- a/src/backend/storage/lmgr/lmgr.c
+++ b/src/backend/storage/lmgr/lmgr.c
@@ -3,7 +3,7 @@
* lmgr.c
* POSTGRES lock manager code
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/lmgr/lock.c b/src/backend/storage/lmgr/lock.c
index e7cf1cd7ad..cea5096c77 100644
--- a/src/backend/storage/lmgr/lock.c
+++ b/src/backend/storage/lmgr/lock.c
@@ -3,7 +3,7 @@
* lock.c
* POSTGRES primary lock mechanism
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/lmgr/lwlock.c b/src/backend/storage/lmgr/lwlock.c
index 32cb81998c..61621a4d0a 100644
--- a/src/backend/storage/lmgr/lwlock.c
+++ b/src/backend/storage/lmgr/lwlock.c
@@ -11,7 +11,7 @@
* LWLocks to protect its shared state.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/storage/lmgr/proc.c b/src/backend/storage/lmgr/proc.c
index e4a7dd901e..be577bcd5f 100644
--- a/src/backend/storage/lmgr/proc.c
+++ b/src/backend/storage/lmgr/proc.c
@@ -3,7 +3,7 @@
* proc.c
* routines to manage per-process shared memory data structure
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/lmgr/s_lock.c b/src/backend/storage/lmgr/s_lock.c
index 3552b66fb0..1b678075a8 100644
--- a/src/backend/storage/lmgr/s_lock.c
+++ b/src/backend/storage/lmgr/s_lock.c
@@ -4,7 +4,7 @@
* Hardware-dependent implementation of spinlocks.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/lmgr/spin.c b/src/backend/storage/lmgr/spin.c
index ed851c9244..cb3e126af1 100644
--- a/src/backend/storage/lmgr/spin.c
+++ b/src/backend/storage/lmgr/spin.c
@@ -11,7 +11,7 @@
* is too slow to be very useful :-(
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/page/bufpage.c b/src/backend/storage/page/bufpage.c
index de8bcd63bf..6bd3812710 100644
--- a/src/backend/storage/page/bufpage.c
+++ b/src/backend/storage/page/bufpage.c
@@ -3,7 +3,7 @@
* bufpage.c
* POSTGRES standard buffer page code.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/page/itemptr.c b/src/backend/storage/page/itemptr.c
index 6733868668..96756c449c 100644
--- a/src/backend/storage/page/itemptr.c
+++ b/src/backend/storage/page/itemptr.c
@@ -3,7 +3,7 @@
* itemptr.c
* POSTGRES disk item pointer code.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/smgr/md.c b/src/backend/storage/smgr/md.c
index 944eed83c5..5f880ee8e2 100644
--- a/src/backend/storage/smgr/md.c
+++ b/src/backend/storage/smgr/md.c
@@ -3,7 +3,7 @@
* md.c
* This code manages relations that reside on magnetic disk.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/smgr/smgr.c b/src/backend/storage/smgr/smgr.c
index 343a7f308e..82bf232645 100644
--- a/src/backend/storage/smgr/smgr.c
+++ b/src/backend/storage/smgr/smgr.c
@@ -6,7 +6,7 @@
* All file system operations in POSTGRES dispatch through these
* routines.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/storage/smgr/smgrtype.c b/src/backend/storage/smgr/smgrtype.c
index 7db5fa7815..ec3292afcd 100644
--- a/src/backend/storage/smgr/smgrtype.c
+++ b/src/backend/storage/smgr/smgrtype.c
@@ -3,7 +3,7 @@
* smgrtype.c
* storage manager type
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/tcop/dest.c b/src/backend/tcop/dest.c
index 11bf0ab27c..24af3fb356 100644
--- a/src/backend/tcop/dest.c
+++ b/src/backend/tcop/dest.c
@@ -4,7 +4,7 @@
* support for communication destinations
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/tcop/fastpath.c b/src/backend/tcop/fastpath.c
index af58e4ea26..d0a23d007a 100644
--- a/src/backend/tcop/fastpath.c
+++ b/src/backend/tcop/fastpath.c
@@ -3,7 +3,7 @@
* fastpath.c
* routines to handle function requests from the frontend
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c
index e690cdbf39..4bfc674f8f 100644
--- a/src/backend/tcop/postgres.c
+++ b/src/backend/tcop/postgres.c
@@ -3,7 +3,7 @@
* postgres.c
* POSTGRES C Backend Interface
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/tcop/pquery.c b/src/backend/tcop/pquery.c
index 8eb02da4b6..0b108ac134 100644
--- a/src/backend/tcop/pquery.c
+++ b/src/backend/tcop/pquery.c
@@ -3,7 +3,7 @@
* pquery.c
* POSTGRES process query command code
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/tcop/utility.c b/src/backend/tcop/utility.c
index 803c6036ab..f4e41a1765 100644
--- a/src/backend/tcop/utility.c
+++ b/src/backend/tcop/utility.c
@@ -5,7 +5,7 @@
* commands. At one time acted as an interface between the Lisp and C
* systems.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/tsearch/Makefile b/src/backend/tsearch/Makefile
index 395c21eae1..cabb4b2f58 100644
--- a/src/backend/tsearch/Makefile
+++ b/src/backend/tsearch/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for backend/tsearch
#
-# Copyright (c) 2006-2010, PostgreSQL Global Development Group
+# Copyright (c) 2006-2011, PostgreSQL Global Development Group
#
# src/backend/tsearch/Makefile
#
diff --git a/src/backend/tsearch/dict.c b/src/backend/tsearch/dict.c
index 28f0ca73e5..9fa3a6d328 100644
--- a/src/backend/tsearch/dict.c
+++ b/src/backend/tsearch/dict.c
@@ -3,7 +3,7 @@
* dict.c
* Standard interface to dictionary
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/dict_ispell.c b/src/backend/tsearch/dict_ispell.c
index 720adb0c1a..31929c00ac 100644
--- a/src/backend/tsearch/dict_ispell.c
+++ b/src/backend/tsearch/dict_ispell.c
@@ -3,7 +3,7 @@
* dict_ispell.c
* Ispell dictionary interface
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/dict_simple.c b/src/backend/tsearch/dict_simple.c
index 603c873d7f..24e9732cde 100644
--- a/src/backend/tsearch/dict_simple.c
+++ b/src/backend/tsearch/dict_simple.c
@@ -3,7 +3,7 @@
* dict_simple.c
* Simple dictionary: just lowercase and check for stopword
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/dict_synonym.c b/src/backend/tsearch/dict_synonym.c
index 947088556d..d2298b3738 100644
--- a/src/backend/tsearch/dict_synonym.c
+++ b/src/backend/tsearch/dict_synonym.c
@@ -3,7 +3,7 @@
* dict_synonym.c
* Synonym dictionary: replace word by its synonym
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/dict_thesaurus.c b/src/backend/tsearch/dict_thesaurus.c
index 24ec3a9247..7ff28b80b3 100644
--- a/src/backend/tsearch/dict_thesaurus.c
+++ b/src/backend/tsearch/dict_thesaurus.c
@@ -3,7 +3,7 @@
* dict_thesaurus.c
* Thesaurus dictionary: phrase to phrase substitution
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/regis.c b/src/backend/tsearch/regis.c
index 93e2cfd209..f34a7c925e 100644
--- a/src/backend/tsearch/regis.c
+++ b/src/backend/tsearch/regis.c
@@ -3,7 +3,7 @@
* regis.c
* Fast regex subset
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/spell.c b/src/backend/tsearch/spell.c
index 713833986a..d4ddcba631 100644
--- a/src/backend/tsearch/spell.c
+++ b/src/backend/tsearch/spell.c
@@ -3,7 +3,7 @@
* spell.c
* Normalizing word with ISpell
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/to_tsany.c b/src/backend/tsearch/to_tsany.c
index f2f13dd8dc..5284c9c714 100644
--- a/src/backend/tsearch/to_tsany.c
+++ b/src/backend/tsearch/to_tsany.c
@@ -3,7 +3,7 @@
* to_tsany.c
* to_ts* function definitions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/ts_locale.c b/src/backend/tsearch/ts_locale.c
index a9ce462377..2b6a6cb946 100644
--- a/src/backend/tsearch/ts_locale.c
+++ b/src/backend/tsearch/ts_locale.c
@@ -3,7 +3,7 @@
* ts_locale.c
* locale compatibility layer for tsearch
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/ts_parse.c b/src/backend/tsearch/ts_parse.c
index 71772e7fe3..5c2962c011 100644
--- a/src/backend/tsearch/ts_parse.c
+++ b/src/backend/tsearch/ts_parse.c
@@ -3,7 +3,7 @@
* ts_parse.c
* main parse functions for tsearch
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/ts_selfuncs.c b/src/backend/tsearch/ts_selfuncs.c
index 8a70c2fd4a..8ce9fb46aa 100644
--- a/src/backend/tsearch/ts_selfuncs.c
+++ b/src/backend/tsearch/ts_selfuncs.c
@@ -3,7 +3,7 @@
* ts_selfuncs.c
* Selectivity estimation functions for text search operators.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/ts_typanalyze.c b/src/backend/tsearch/ts_typanalyze.c
index a42d09b280..2654d64457 100644
--- a/src/backend/tsearch/ts_typanalyze.c
+++ b/src/backend/tsearch/ts_typanalyze.c
@@ -3,7 +3,7 @@
* ts_typanalyze.c
* functions for gathering statistics from tsvector columns
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/ts_utils.c b/src/backend/tsearch/ts_utils.c
index e45f4da64e..abf53c0019 100644
--- a/src/backend/tsearch/ts_utils.c
+++ b/src/backend/tsearch/ts_utils.c
@@ -3,7 +3,7 @@
* ts_utils.c
* various support functions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/wparser.c b/src/backend/tsearch/wparser.c
index ff007161fe..f636c2d23b 100644
--- a/src/backend/tsearch/wparser.c
+++ b/src/backend/tsearch/wparser.c
@@ -3,7 +3,7 @@
* wparser.c
* Standard interface to word parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/tsearch/wparser_def.c b/src/backend/tsearch/wparser_def.c
index e10457797e..f3c78178e7 100644
--- a/src/backend/tsearch/wparser_def.c
+++ b/src/backend/tsearch/wparser_def.c
@@ -3,7 +3,7 @@
* wparser_def.c
* Default text search parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/Gen_dummy_probes.sed b/src/backend/utils/Gen_dummy_probes.sed
index 16c8c8de4a..5239e11599 100644
--- a/src/backend/utils/Gen_dummy_probes.sed
+++ b/src/backend/utils/Gen_dummy_probes.sed
@@ -1,7 +1,7 @@
#-------------------------------------------------------------------------
# sed script to create dummy probes.h file when dtrace is not available
#
-# Copyright (c) 2008-2010, PostgreSQL Global Development Group
+# Copyright (c) 2008-2011, PostgreSQL Global Development Group
#
# src/backend/utils/Gen_dummy_probes.sed
#-------------------------------------------------------------------------
diff --git a/src/backend/utils/Gen_fmgrtab.pl b/src/backend/utils/Gen_fmgrtab.pl
index 797324dcf3..7415a2585b 100644
--- a/src/backend/utils/Gen_fmgrtab.pl
+++ b/src/backend/utils/Gen_fmgrtab.pl
@@ -4,7 +4,7 @@
# Gen_fmgrtab.pl
# Perl script that generates fmgroids.h and fmgrtab.c from pg_proc.h
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
#
@@ -102,7 +102,7 @@ qq|/*-------------------------------------------------------------------------
* These macros can be used to avoid a catalog lookup when a specific
* fmgr-callable function needs to be referenced.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* NOTES
@@ -137,7 +137,7 @@ qq|/*-------------------------------------------------------------------------
* fmgrtab.c
* The function manager's table of internal functions.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* NOTES
diff --git a/src/backend/utils/adt/acl.c b/src/backend/utils/adt/acl.c
index e2af0592c5..05c9c266ff 100644
--- a/src/backend/utils/adt/acl.c
+++ b/src/backend/utils/adt/acl.c
@@ -3,7 +3,7 @@
* acl.c
* Basic access control list data structures manipulation routines.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/array_userfuncs.c b/src/backend/utils/adt/array_userfuncs.c
index d7ec310f51..499d3578b3 100644
--- a/src/backend/utils/adt/array_userfuncs.c
+++ b/src/backend/utils/adt/array_userfuncs.c
@@ -3,7 +3,7 @@
* array_userfuncs.c
* Misc user-visible array support functions
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/adt/array_userfuncs.c
diff --git a/src/backend/utils/adt/arrayfuncs.c b/src/backend/utils/adt/arrayfuncs.c
index 1b7bec5a31..fb4cbce23c 100644
--- a/src/backend/utils/adt/arrayfuncs.c
+++ b/src/backend/utils/adt/arrayfuncs.c
@@ -3,7 +3,7 @@
* arrayfuncs.c
* Support functions for arrays.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/arrayutils.c b/src/backend/utils/adt/arrayutils.c
index f0f49d3530..e3f116975d 100644
--- a/src/backend/utils/adt/arrayutils.c
+++ b/src/backend/utils/adt/arrayutils.c
@@ -3,7 +3,7 @@
* arrayutils.c
* This file contains some support routines required for array functions.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/ascii.c b/src/backend/utils/adt/ascii.c
index f161171411..7ecf4949b5 100644
--- a/src/backend/utils/adt/ascii.c
+++ b/src/backend/utils/adt/ascii.c
@@ -2,7 +2,7 @@
* ascii.c
* The PostgreSQL routine for string to ascii conversion.
*
- * Portions Copyright (c) 1999-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1999-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/adt/ascii.c
diff --git a/src/backend/utils/adt/bool.c b/src/backend/utils/adt/bool.c
index 1513a42786..1a9d5100e4 100644
--- a/src/backend/utils/adt/bool.c
+++ b/src/backend/utils/adt/bool.c
@@ -3,7 +3,7 @@
* bool.c
* Functions for the built-in type "bool".
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/char.c b/src/backend/utils/adt/char.c
index 4680cff812..974cb22358 100644
--- a/src/backend/utils/adt/char.c
+++ b/src/backend/utils/adt/char.c
@@ -4,7 +4,7 @@
* Functions for the built-in type "char" (not to be confused with
* bpchar, which is the SQL CHAR(n) type).
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/date.c b/src/backend/utils/adt/date.c
index ee0b09f049..80dd10b841 100644
--- a/src/backend/utils/adt/date.c
+++ b/src/backend/utils/adt/date.c
@@ -3,7 +3,7 @@
* date.c
* implements DATE and TIME data types specified in SQL-92 standard
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994-5, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/datetime.c b/src/backend/utils/adt/datetime.c
index 34d563605b..85f0206a6a 100644
--- a/src/backend/utils/adt/datetime.c
+++ b/src/backend/utils/adt/datetime.c
@@ -3,7 +3,7 @@
* datetime.c
* Support functions for date/time types.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/datum.c b/src/backend/utils/adt/datum.c
index 580f9fb9d3..1fd7ff777a 100644
--- a/src/backend/utils/adt/datum.c
+++ b/src/backend/utils/adt/datum.c
@@ -3,7 +3,7 @@
* datum.c
* POSTGRES Datum (abstract data type) manipulation routines.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/dbsize.c b/src/backend/utils/adt/dbsize.c
index f33c29e4b2..f4729a7b6b 100644
--- a/src/backend/utils/adt/dbsize.c
+++ b/src/backend/utils/adt/dbsize.c
@@ -2,7 +2,7 @@
* dbsize.c
* Database object size functions, and related inquiries
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/adt/dbsize.c
diff --git a/src/backend/utils/adt/domains.c b/src/backend/utils/adt/domains.c
index c0317e7371..c178fd0bdd 100644
--- a/src/backend/utils/adt/domains.c
+++ b/src/backend/utils/adt/domains.c
@@ -20,7 +20,7 @@
* to evaluate them in.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/encode.c b/src/backend/utils/adt/encode.c
index 549ea36fab..127b17380e 100644
--- a/src/backend/utils/adt/encode.c
+++ b/src/backend/utils/adt/encode.c
@@ -3,7 +3,7 @@
* encode.c
* Various data encoding/decoding things.
*
- * Copyright (c) 2001-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2001-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/enum.c b/src/backend/utils/adt/enum.c
index dd168dd973..be4f984ed6 100644
--- a/src/backend/utils/adt/enum.c
+++ b/src/backend/utils/adt/enum.c
@@ -3,7 +3,7 @@
* enum.c
* I/O functions, operators, aggregates etc for enum types
*
- * Copyright (c) 2006-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2006-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/float.c b/src/backend/utils/adt/float.c
index b2a5b6c3df..e3c84fd6c5 100644
--- a/src/backend/utils/adt/float.c
+++ b/src/backend/utils/adt/float.c
@@ -3,7 +3,7 @@
* float.c
* Functions for the built-in floating-point types.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/format_type.c b/src/backend/utils/adt/format_type.c
index f6f5efe126..b56bb74bdc 100644
--- a/src/backend/utils/adt/format_type.c
+++ b/src/backend/utils/adt/format_type.c
@@ -4,7 +4,7 @@
* Display type names "nicely".
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/formatting.c b/src/backend/utils/adt/formatting.c
index fc0bf439fa..4855bac41d 100644
--- a/src/backend/utils/adt/formatting.c
+++ b/src/backend/utils/adt/formatting.c
@@ -4,7 +4,7 @@
* src/backend/utils/adt/formatting.c
*
*
- * Portions Copyright (c) 1999-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1999-2011, PostgreSQL Global Development Group
*
*
* TO_CHAR(); TO_TIMESTAMP(); TO_DATE(); TO_NUMBER();
diff --git a/src/backend/utils/adt/genfile.c b/src/backend/utils/adt/genfile.c
index 8a9012e054..93bc401c2d 100644
--- a/src/backend/utils/adt/genfile.c
+++ b/src/backend/utils/adt/genfile.c
@@ -4,7 +4,7 @@
* Functions for direct access to files
*
*
- * Copyright (c) 2004-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2004-2011, PostgreSQL Global Development Group
*
* Author: Andreas Pflug
*
diff --git a/src/backend/utils/adt/geo_ops.c b/src/backend/utils/adt/geo_ops.c
index 006023a07e..b8cf9a8d06 100644
--- a/src/backend/utils/adt/geo_ops.c
+++ b/src/backend/utils/adt/geo_ops.c
@@ -3,7 +3,7 @@
* geo_ops.c
* 2D geometric operations
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/geo_selfuncs.c b/src/backend/utils/adt/geo_selfuncs.c
index d21ebff98c..c2e6bc1794 100644
--- a/src/backend/utils/adt/geo_selfuncs.c
+++ b/src/backend/utils/adt/geo_selfuncs.c
@@ -4,7 +4,7 @@
* Selectivity routines registered in the operator catalog in the
* "oprrest" and "oprjoin" attributes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/int.c b/src/backend/utils/adt/int.c
index c4503332f6..78bac406ed 100644
--- a/src/backend/utils/adt/int.c
+++ b/src/backend/utils/adt/int.c
@@ -3,7 +3,7 @@
* int.c
* Functions for the built-in integer types (except int8).
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/int8.c b/src/backend/utils/adt/int8.c
index 91133f7741..bbab90c0c1 100644
--- a/src/backend/utils/adt/int8.c
+++ b/src/backend/utils/adt/int8.c
@@ -3,7 +3,7 @@
* int8.c
* Internal 64-bit integer operations
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/like.c b/src/backend/utils/adt/like.c
index 57687fb015..1e7a6f32ea 100644
--- a/src/backend/utils/adt/like.c
+++ b/src/backend/utils/adt/like.c
@@ -7,7 +7,7 @@
* A big hack of the regexp.c code!! Contributed by
* Keith Parks (7/95).
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/like_match.c b/src/backend/utils/adt/like_match.c
index e464695ec7..2a99e94017 100644
--- a/src/backend/utils/adt/like_match.c
+++ b/src/backend/utils/adt/like_match.c
@@ -16,7 +16,7 @@
* do_like_escape - name of function if wanted - needs CHAREQ and CopyAdvChar
* MATCH_LOWER - define for case (4), using to_lower on single-byte chars
*
- * Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/adt/like_match.c
diff --git a/src/backend/utils/adt/lockfuncs.c b/src/backend/utils/adt/lockfuncs.c
index 3eba7fb0cf..78cafada2c 100644
--- a/src/backend/utils/adt/lockfuncs.c
+++ b/src/backend/utils/adt/lockfuncs.c
@@ -3,7 +3,7 @@
* lockfuncs.c
* Functions for SQL access to various lock-manager capabilities.
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/adt/lockfuncs.c
diff --git a/src/backend/utils/adt/misc.c b/src/backend/utils/adt/misc.c
index fb968eafd1..5bda4af50f 100644
--- a/src/backend/utils/adt/misc.c
+++ b/src/backend/utils/adt/misc.c
@@ -3,7 +3,7 @@
* misc.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/nabstime.c b/src/backend/utils/adt/nabstime.c
index 8870e89495..0e25c5fbfe 100644
--- a/src/backend/utils/adt/nabstime.c
+++ b/src/backend/utils/adt/nabstime.c
@@ -5,7 +5,7 @@
* Functions for the built-in type "RelativeTime".
* Functions for the built-in type "TimeInterval".
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/name.c b/src/backend/utils/adt/name.c
index c48db15c29..09c12efd8d 100644
--- a/src/backend/utils/adt/name.c
+++ b/src/backend/utils/adt/name.c
@@ -9,7 +9,7 @@
* always use NAMEDATALEN as the symbolic constant! - jolly 8/21/95
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/numeric.c b/src/backend/utils/adt/numeric.c
index 5d29cf6533..eec89aa54f 100644
--- a/src/backend/utils/adt/numeric.c
+++ b/src/backend/utils/adt/numeric.c
@@ -11,7 +11,7 @@
* Transactions on Mathematical Software, Vol. 24, No. 4, December 1998,
* pages 359-367.
*
- * Copyright (c) 1998-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1998-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/adt/numeric.c
diff --git a/src/backend/utils/adt/numutils.c b/src/backend/utils/adt/numutils.c
index a021c7d62e..38ce38821e 100644
--- a/src/backend/utils/adt/numutils.c
+++ b/src/backend/utils/adt/numutils.c
@@ -3,7 +3,7 @@
* numutils.c
* utility functions for I/O of built-in numeric types.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/oid.c b/src/backend/utils/adt/oid.c
index 09d0b32a34..b2152a2491 100644
--- a/src/backend/utils/adt/oid.c
+++ b/src/backend/utils/adt/oid.c
@@ -3,7 +3,7 @@
* oid.c
* Functions for the built-in type Oid ... also oidvector.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/oracle_compat.c b/src/backend/utils/adt/oracle_compat.c
index 90d2b8a824..65559dff58 100644
--- a/src/backend/utils/adt/oracle_compat.c
+++ b/src/backend/utils/adt/oracle_compat.c
@@ -2,7 +2,7 @@
* oracle_compat.c
* Oracle compatible functions.
*
- * Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* Author: Edmund Mergl
* Multibyte enhancement: Tatsuo Ishii
diff --git a/src/backend/utils/adt/pg_locale.c b/src/backend/utils/adt/pg_locale.c
index 20214365ef..f76305a219 100644
--- a/src/backend/utils/adt/pg_locale.c
+++ b/src/backend/utils/adt/pg_locale.c
@@ -2,7 +2,7 @@
*
* PostgreSQL locale utilities
*
- * Portions Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* src/backend/utils/adt/pg_locale.c
*
diff --git a/src/backend/utils/adt/pg_lzcompress.c b/src/backend/utils/adt/pg_lzcompress.c
index 8b1e636396..6b0fd364e4 100644
--- a/src/backend/utils/adt/pg_lzcompress.c
+++ b/src/backend/utils/adt/pg_lzcompress.c
@@ -164,7 +164,7 @@
*
* Jan Wieck
*
- * Copyright (c) 1999-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1999-2011, PostgreSQL Global Development Group
*
* src/backend/utils/adt/pg_lzcompress.c
* ----------
diff --git a/src/backend/utils/adt/pgstatfuncs.c b/src/backend/utils/adt/pgstatfuncs.c
index adab948e0d..d357b5c8b5 100644
--- a/src/backend/utils/adt/pgstatfuncs.c
+++ b/src/backend/utils/adt/pgstatfuncs.c
@@ -3,7 +3,7 @@
* pgstatfuncs.c
* Functions for accessing the statistics collector data
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/pseudotypes.c b/src/backend/utils/adt/pseudotypes.c
index dd12592473..2be0696f60 100644
--- a/src/backend/utils/adt/pseudotypes.c
+++ b/src/backend/utils/adt/pseudotypes.c
@@ -11,7 +11,7 @@
* we do better?)
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/quote.c b/src/backend/utils/adt/quote.c
index af07443f7d..055d0a7ab8 100644
--- a/src/backend/utils/adt/quote.c
+++ b/src/backend/utils/adt/quote.c
@@ -3,7 +3,7 @@
* quote.c
* Functions for quoting identifiers and literals
*
- * Portions Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/regexp.c b/src/backend/utils/adt/regexp.c
index 4e2a953cdc..a4cb87915b 100644
--- a/src/backend/utils/adt/regexp.c
+++ b/src/backend/utils/adt/regexp.c
@@ -3,7 +3,7 @@
* regexp.c
* Postgres' interface to the regular expression package.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/regproc.c b/src/backend/utils/adt/regproc.c
index ce3d39d9df..6716c0204c 100644
--- a/src/backend/utils/adt/regproc.c
+++ b/src/backend/utils/adt/regproc.c
@@ -8,7 +8,7 @@
* special I/O conversion routines.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/ri_triggers.c b/src/backend/utils/adt/ri_triggers.c
index 33a8935932..7bc1ab1e81 100644
--- a/src/backend/utils/adt/ri_triggers.c
+++ b/src/backend/utils/adt/ri_triggers.c
@@ -13,7 +13,7 @@
* plan --- consider improving this someday.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/backend/utils/adt/ri_triggers.c
*
diff --git a/src/backend/utils/adt/rowtypes.c b/src/backend/utils/adt/rowtypes.c
index 429153a41b..2c552e173b 100644
--- a/src/backend/utils/adt/rowtypes.c
+++ b/src/backend/utils/adt/rowtypes.c
@@ -3,7 +3,7 @@
* rowtypes.c
* I/O and comparison functions for generic composite types.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/ruleutils.c b/src/backend/utils/adt/ruleutils.c
index 21aa6718c8..b8259febb8 100644
--- a/src/backend/utils/adt/ruleutils.c
+++ b/src/backend/utils/adt/ruleutils.c
@@ -4,7 +4,7 @@
* Functions to convert stored expressions/querytrees back to
* source text
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/selfuncs.c b/src/backend/utils/adt/selfuncs.c
index cf8618dd90..05100cdc8a 100644
--- a/src/backend/utils/adt/selfuncs.c
+++ b/src/backend/utils/adt/selfuncs.c
@@ -10,7 +10,7 @@
* Index cost functions are registered in the pg_am catalog
* in the "amcostestimate" attribute.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/tid.c b/src/backend/utils/adt/tid.c
index 49c9b5339a..69e89b82c9 100644
--- a/src/backend/utils/adt/tid.c
+++ b/src/backend/utils/adt/tid.c
@@ -3,7 +3,7 @@
* tid.c
* Functions for the built-in type tuple id
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/timestamp.c b/src/backend/utils/adt/timestamp.c
index c6e1d13183..1c2c160589 100644
--- a/src/backend/utils/adt/timestamp.c
+++ b/src/backend/utils/adt/timestamp.c
@@ -3,7 +3,7 @@
* timestamp.c
* Functions for the built-in SQL92 types "timestamp" and "interval".
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/trigfuncs.c b/src/backend/utils/adt/trigfuncs.c
index ec0db88c6a..86f81bb5be 100644
--- a/src/backend/utils/adt/trigfuncs.c
+++ b/src/backend/utils/adt/trigfuncs.c
@@ -4,7 +4,7 @@
* Builtin functions for useful trigger support.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/utils/adt/trigfuncs.c
diff --git a/src/backend/utils/adt/tsginidx.c b/src/backend/utils/adt/tsginidx.c
index f5533928ef..9e7ca66132 100644
--- a/src/backend/utils/adt/tsginidx.c
+++ b/src/backend/utils/adt/tsginidx.c
@@ -3,7 +3,7 @@
* tsginidx.c
* GIN support functions for tsvector_ops
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsgistidx.c b/src/backend/utils/adt/tsgistidx.c
index 6270094c51..2189a1a20e 100644
--- a/src/backend/utils/adt/tsgistidx.c
+++ b/src/backend/utils/adt/tsgistidx.c
@@ -3,7 +3,7 @@
* tsgistidx.c
* GiST support functions for tsvector_ops
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsquery.c b/src/backend/utils/adt/tsquery.c
index a155c933e2..5baa02b1c0 100644
--- a/src/backend/utils/adt/tsquery.c
+++ b/src/backend/utils/adt/tsquery.c
@@ -3,7 +3,7 @@
* tsquery.c
* I/O functions for tsquery
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsquery_cleanup.c b/src/backend/utils/adt/tsquery_cleanup.c
index c38471026b..9feb4b796a 100644
--- a/src/backend/utils/adt/tsquery_cleanup.c
+++ b/src/backend/utils/adt/tsquery_cleanup.c
@@ -4,7 +4,7 @@
* Cleanup query from NOT values and/or stopword
* Utility functions to correct work.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsquery_gist.c b/src/backend/utils/adt/tsquery_gist.c
index 849ba6d82e..2ecb13e3b9 100644
--- a/src/backend/utils/adt/tsquery_gist.c
+++ b/src/backend/utils/adt/tsquery_gist.c
@@ -3,7 +3,7 @@
* tsquery_gist.c
* GiST index support for tsquery
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsquery_op.c b/src/backend/utils/adt/tsquery_op.c
index 80c794da48..4cf628772c 100644
--- a/src/backend/utils/adt/tsquery_op.c
+++ b/src/backend/utils/adt/tsquery_op.c
@@ -3,7 +3,7 @@
* tsquery_op.c
* Various operations with tsquery
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsquery_rewrite.c b/src/backend/utils/adt/tsquery_rewrite.c
index 9a56732643..e2faed26d3 100644
--- a/src/backend/utils/adt/tsquery_rewrite.c
+++ b/src/backend/utils/adt/tsquery_rewrite.c
@@ -3,7 +3,7 @@
* tsquery_rewrite.c
* Utilities for reconstructing tsquery
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsquery_util.c b/src/backend/utils/adt/tsquery_util.c
index 3aa19aa77d..ca254f901f 100644
--- a/src/backend/utils/adt/tsquery_util.c
+++ b/src/backend/utils/adt/tsquery_util.c
@@ -3,7 +3,7 @@
* tsquery_util.c
* Utilities for tsquery datatype
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsrank.c b/src/backend/utils/adt/tsrank.c
index 4b9e938329..65823bd705 100644
--- a/src/backend/utils/adt/tsrank.c
+++ b/src/backend/utils/adt/tsrank.c
@@ -3,7 +3,7 @@
* tsrank.c
* rank tsvector by tsquery
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsvector.c b/src/backend/utils/adt/tsvector.c
index 4562aaf063..6810615a25 100644
--- a/src/backend/utils/adt/tsvector.c
+++ b/src/backend/utils/adt/tsvector.c
@@ -3,7 +3,7 @@
* tsvector.c
* I/O functions for tsvector
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsvector_op.c b/src/backend/utils/adt/tsvector_op.c
index 1920f2ad26..38c1401398 100644
--- a/src/backend/utils/adt/tsvector_op.c
+++ b/src/backend/utils/adt/tsvector_op.c
@@ -3,7 +3,7 @@
* tsvector_op.c
* operations over tsvector
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/tsvector_parser.c b/src/backend/utils/adt/tsvector_parser.c
index c2494c5894..65eec00563 100644
--- a/src/backend/utils/adt/tsvector_parser.c
+++ b/src/backend/utils/adt/tsvector_parser.c
@@ -3,7 +3,7 @@
* tsvector_parser.c
* Parser for tsvector
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/txid.c b/src/backend/utils/adt/txid.c
index c3d35c944c..2907306e92 100644
--- a/src/backend/utils/adt/txid.c
+++ b/src/backend/utils/adt/txid.c
@@ -10,7 +10,7 @@
* via functions such as SubTransGetTopmostTransaction().
*
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
* Author: Jan Wieck, Afilias USA INC.
* 64-bit txids: Marko Kreen, Skype Technologies
*
diff --git a/src/backend/utils/adt/uuid.c b/src/backend/utils/adt/uuid.c
index 4ff95ecc8e..13ae11ee67 100644
--- a/src/backend/utils/adt/uuid.c
+++ b/src/backend/utils/adt/uuid.c
@@ -3,7 +3,7 @@
* uuid.c
* Functions for the built-in type "uuid".
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/adt/uuid.c
diff --git a/src/backend/utils/adt/varbit.c b/src/backend/utils/adt/varbit.c
index d847611240..0eb6071e12 100644
--- a/src/backend/utils/adt/varbit.c
+++ b/src/backend/utils/adt/varbit.c
@@ -5,7 +5,7 @@
*
* Code originally contributed by Adriaan Joubert.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/varchar.c b/src/backend/utils/adt/varchar.c
index b3d7ba3f40..08be966249 100644
--- a/src/backend/utils/adt/varchar.c
+++ b/src/backend/utils/adt/varchar.c
@@ -3,7 +3,7 @@
* varchar.c
* Functions for the built-in types char(n) and varchar(n).
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/varlena.c b/src/backend/utils/adt/varlena.c
index 2fa740ac8c..ed57685a18 100644
--- a/src/backend/utils/adt/varlena.c
+++ b/src/backend/utils/adt/varlena.c
@@ -3,7 +3,7 @@
* varlena.c
* Functions for the variable-length built-in types.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/version.c b/src/backend/utils/adt/version.c
index 27394199e9..6ea5bd2267 100644
--- a/src/backend/utils/adt/version.c
+++ b/src/backend/utils/adt/version.c
@@ -3,7 +3,7 @@
* version.c
* Returns the PostgreSQL version string
*
- * Copyright (c) 1998-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1998-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
*
diff --git a/src/backend/utils/adt/windowfuncs.c b/src/backend/utils/adt/windowfuncs.c
index 96fa82e3be..2e16383137 100644
--- a/src/backend/utils/adt/windowfuncs.c
+++ b/src/backend/utils/adt/windowfuncs.c
@@ -3,7 +3,7 @@
* windowfuncs.c
* Standard window functions defined in SQL spec.
*
- * Portions Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/backend/utils/adt/xid.c b/src/backend/utils/adt/xid.c
index 1231ecd33d..76d29ff2a3 100644
--- a/src/backend/utils/adt/xid.c
+++ b/src/backend/utils/adt/xid.c
@@ -3,7 +3,7 @@
* xid.c
* POSTGRES transaction identifier and command identifier datatypes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/adt/xml.c b/src/backend/utils/adt/xml.c
index 726780bf37..c175e4f4ca 100644
--- a/src/backend/utils/adt/xml.c
+++ b/src/backend/utils/adt/xml.c
@@ -4,7 +4,7 @@
* XML data type support.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/backend/utils/adt/xml.c
diff --git a/src/backend/utils/cache/attoptcache.c b/src/backend/utils/cache/attoptcache.c
index 56c1a37055..7018ccfe62 100644
--- a/src/backend/utils/cache/attoptcache.c
+++ b/src/backend/utils/cache/attoptcache.c
@@ -6,7 +6,7 @@
* Attribute options are cached separately from the fixed-size portion of
* pg_attribute entries, which are handled by the relcache.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/cache/catcache.c b/src/backend/utils/cache/catcache.c
index c24e6b351d..d0e364e00d 100644
--- a/src/backend/utils/cache/catcache.c
+++ b/src/backend/utils/cache/catcache.c
@@ -3,7 +3,7 @@
* catcache.c
* System catalog cache for tuples matching a key.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/cache/inval.c b/src/backend/utils/cache/inval.c
index c9d68e71ac..fe89b71df2 100644
--- a/src/backend/utils/cache/inval.c
+++ b/src/backend/utils/cache/inval.c
@@ -76,7 +76,7 @@
* simplicity we keep the controlling list-of-lists in TopTransactionContext.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/cache/lsyscache.c b/src/backend/utils/cache/lsyscache.c
index cbdfe05031..0a4144ba54 100644
--- a/src/backend/utils/cache/lsyscache.c
+++ b/src/backend/utils/cache/lsyscache.c
@@ -3,7 +3,7 @@
* lsyscache.c
* Convenience routines for common queries in the system catalog cache.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/cache/plancache.c b/src/backend/utils/cache/plancache.c
index 491d05ab77..dc911e00ac 100644
--- a/src/backend/utils/cache/plancache.c
+++ b/src/backend/utils/cache/plancache.c
@@ -31,7 +31,7 @@
* be infrequent enough that more-detailed tracking is not worth the effort.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/cache/relcache.c b/src/backend/utils/cache/relcache.c
index fa9e9ca3a4..3b40acf4df 100644
--- a/src/backend/utils/cache/relcache.c
+++ b/src/backend/utils/cache/relcache.c
@@ -3,7 +3,7 @@
* relcache.c
* POSTGRES relation descriptor cache code
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/cache/relmapper.c b/src/backend/utils/cache/relmapper.c
index 6367c6bbac..a19ee28b53 100644
--- a/src/backend/utils/cache/relmapper.c
+++ b/src/backend/utils/cache/relmapper.c
@@ -28,7 +28,7 @@
* all these files commit in a single map file update rather than being tied
* to transaction commit.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/cache/spccache.c b/src/backend/utils/cache/spccache.c
index a269351b25..57e5d0342a 100644
--- a/src/backend/utils/cache/spccache.c
+++ b/src/backend/utils/cache/spccache.c
@@ -8,7 +8,7 @@
* be a measurable performance gain from doing this, but that might change
* in the future as we add more options.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/cache/syscache.c b/src/backend/utils/cache/syscache.c
index 08a14431b1..cba130b55e 100644
--- a/src/backend/utils/cache/syscache.c
+++ b/src/backend/utils/cache/syscache.c
@@ -3,7 +3,7 @@
* syscache.c
* System cache management routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/cache/ts_cache.c b/src/backend/utils/cache/ts_cache.c
index 2956644554..6a99e78c6a 100644
--- a/src/backend/utils/cache/ts_cache.c
+++ b/src/backend/utils/cache/ts_cache.c
@@ -17,7 +17,7 @@
* any database access.
*
*
- * Copyright (c) 2006-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2006-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/cache/ts_cache.c
diff --git a/src/backend/utils/cache/typcache.c b/src/backend/utils/cache/typcache.c
index c2537e1de7..54e1942c31 100644
--- a/src/backend/utils/cache/typcache.c
+++ b/src/backend/utils/cache/typcache.c
@@ -32,7 +32,7 @@
* entry, since that may need to change as a consequence of ALTER TABLE.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/error/assert.c b/src/backend/utils/error/assert.c
index 2222872da6..34909f76c6 100644
--- a/src/backend/utils/error/assert.c
+++ b/src/backend/utils/error/assert.c
@@ -3,7 +3,7 @@
* assert.c
* Assert code.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/error/elog.c b/src/backend/utils/error/elog.c
index 6e2cef9504..a1a449f2dd 100644
--- a/src/backend/utils/error/elog.c
+++ b/src/backend/utils/error/elog.c
@@ -37,7 +37,7 @@
* overflow.)
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/fmgr/dfmgr.c b/src/backend/utils/fmgr/dfmgr.c
index d08fdddde2..9526f2eb2c 100644
--- a/src/backend/utils/fmgr/dfmgr.c
+++ b/src/backend/utils/fmgr/dfmgr.c
@@ -3,7 +3,7 @@
* dfmgr.c
* Dynamic function manager code.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/fmgr/fmgr.c b/src/backend/utils/fmgr/fmgr.c
index a14d9ba8c0..54d50e9637 100644
--- a/src/backend/utils/fmgr/fmgr.c
+++ b/src/backend/utils/fmgr/fmgr.c
@@ -3,7 +3,7 @@
* fmgr.c
* The Postgres function manager.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/fmgr/funcapi.c b/src/backend/utils/fmgr/funcapi.c
index 53a884e8f1..e32c716392 100644
--- a/src/backend/utils/fmgr/funcapi.c
+++ b/src/backend/utils/fmgr/funcapi.c
@@ -4,7 +4,7 @@
* Utility and convenience functions for fmgr functions that return
* sets and/or composite types.
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/fmgr/funcapi.c
diff --git a/src/backend/utils/hash/dynahash.c b/src/backend/utils/hash/dynahash.c
index b3cdbe82b9..f718785ee4 100644
--- a/src/backend/utils/hash/dynahash.c
+++ b/src/backend/utils/hash/dynahash.c
@@ -21,7 +21,7 @@
* lookup key's hash value as a partition number --- this will work because
* of the way calc_bucket() maps hash values to bucket numbers.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/hash/hashfn.c b/src/backend/utils/hash/hashfn.c
index a9d8359c4e..7406d266db 100644
--- a/src/backend/utils/hash/hashfn.c
+++ b/src/backend/utils/hash/hashfn.c
@@ -4,7 +4,7 @@
* Hash functions for use in dynahash.c hashtables
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/hash/pg_crc.c b/src/backend/utils/hash/pg_crc.c
index 5ac19ddc6f..0bed2fd2be 100644
--- a/src/backend/utils/hash/pg_crc.c
+++ b/src/backend/utils/hash/pg_crc.c
@@ -14,7 +14,7 @@
* code for possible future use.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/init/globals.c b/src/backend/utils/init/globals.c
index 66033ffe17..984ffd0c73 100644
--- a/src/backend/utils/init/globals.c
+++ b/src/backend/utils/init/globals.c
@@ -3,7 +3,7 @@
* globals.c
* global variable declarations
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/init/miscinit.c b/src/backend/utils/init/miscinit.c
index 27679259e4..4f708352da 100644
--- a/src/backend/utils/init/miscinit.c
+++ b/src/backend/utils/init/miscinit.c
@@ -3,7 +3,7 @@
* miscinit.c
* miscellaneous initialization support stuff
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/init/postinit.c b/src/backend/utils/init/postinit.c
index eaaf27ffa5..76890f2fda 100644
--- a/src/backend/utils/init/postinit.c
+++ b/src/backend/utils/init/postinit.c
@@ -3,7 +3,7 @@
* postinit.c
* postgres initialization utilities
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/mb/Unicode/Makefile b/src/backend/utils/mb/Unicode/Makefile
index a6cbd72510..7a4983405b 100644
--- a/src/backend/utils/mb/Unicode/Makefile
+++ b/src/backend/utils/mb/Unicode/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/backend/utils/mb/Unicode
#
-# Copyright (c) 2001-2010, PostgreSQL Global Development Group
+# Copyright (c) 2001-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/Makefile
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_BIG5.pl b/src/backend/utils/mb/Unicode/UCS_to_BIG5.pl
index 7582767a79..f631372704 100755
--- a/src/backend/utils/mb/Unicode/UCS_to_BIG5.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_BIG5.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2001-2010, PostgreSQL Global Development Group
+# Copyright (c) 2001-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_BIG5.pl
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_EUC_CN.pl b/src/backend/utils/mb/Unicode/UCS_to_EUC_CN.pl
index f2bf957a2e..60090a6dab 100755
--- a/src/backend/utils/mb/Unicode/UCS_to_EUC_CN.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_EUC_CN.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2001-2010, PostgreSQL Global Development Group
+# Copyright (c) 2001-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_EUC_CN.pl
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_EUC_JIS_2004.pl b/src/backend/utils/mb/Unicode/UCS_to_EUC_JIS_2004.pl
index 94e850cc7b..0623fa281e 100755
--- a/src/backend/utils/mb/Unicode/UCS_to_EUC_JIS_2004.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_EUC_JIS_2004.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2007-2010, PostgreSQL Global Development Group
+# Copyright (c) 2007-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_EUC_JIS_2004.pl
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_EUC_JP.pl b/src/backend/utils/mb/Unicode/UCS_to_EUC_JP.pl
index 2951fc2f1b..c2ab9f45bc 100755
--- a/src/backend/utils/mb/Unicode/UCS_to_EUC_JP.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_EUC_JP.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2001-2010, PostgreSQL Global Development Group
+# Copyright (c) 2001-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_EUC_JP.pl
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_EUC_KR.pl b/src/backend/utils/mb/Unicode/UCS_to_EUC_KR.pl
index 2d44837133..8f63e20007 100755
--- a/src/backend/utils/mb/Unicode/UCS_to_EUC_KR.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_EUC_KR.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2001-2010, PostgreSQL Global Development Group
+# Copyright (c) 2001-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_EUC_KR.pl
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_EUC_TW.pl b/src/backend/utils/mb/Unicode/UCS_to_EUC_TW.pl
index 176f765a28..8068c5d784 100755
--- a/src/backend/utils/mb/Unicode/UCS_to_EUC_TW.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_EUC_TW.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2001-2010, PostgreSQL Global Development Group
+# Copyright (c) 2001-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_EUC_TW.pl
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_GB18030.pl b/src/backend/utils/mb/Unicode/UCS_to_GB18030.pl
index 4475c13a01..6b1dc2f47d 100755
--- a/src/backend/utils/mb/Unicode/UCS_to_GB18030.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_GB18030.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2007-2010, PostgreSQL Global Development Group
+# Copyright (c) 2007-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_GB18030.pl
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_SHIFT_JIS_2004.pl b/src/backend/utils/mb/Unicode/UCS_to_SHIFT_JIS_2004.pl
index 5b7254feb0..13fca20834 100755
--- a/src/backend/utils/mb/Unicode/UCS_to_SHIFT_JIS_2004.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_SHIFT_JIS_2004.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2007-2010, PostgreSQL Global Development Group
+# Copyright (c) 2007-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_SHIFT_JIS_2004.pl
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_SJIS.pl b/src/backend/utils/mb/Unicode/UCS_to_SJIS.pl
index 68037bd77a..dc3879df96 100755
--- a/src/backend/utils/mb/Unicode/UCS_to_SJIS.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_SJIS.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2001-2010, PostgreSQL Global Development Group
+# Copyright (c) 2001-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_SJIS.pl
#
diff --git a/src/backend/utils/mb/Unicode/UCS_to_most.pl b/src/backend/utils/mb/Unicode/UCS_to_most.pl
index 0232957788..77170ac597 100644
--- a/src/backend/utils/mb/Unicode/UCS_to_most.pl
+++ b/src/backend/utils/mb/Unicode/UCS_to_most.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl
#
-# Copyright (c) 2001-2010, PostgreSQL Global Development Group
+# Copyright (c) 2001-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/UCS_to_most.pl
#
diff --git a/src/backend/utils/mb/Unicode/ucs2utf.pl b/src/backend/utils/mb/Unicode/ucs2utf.pl
index 7e137f2e47..4d88202ca8 100644
--- a/src/backend/utils/mb/Unicode/ucs2utf.pl
+++ b/src/backend/utils/mb/Unicode/ucs2utf.pl
@@ -1,5 +1,5 @@
#
-# Copyright (c) 2001-2010, PostgreSQL Global Development Group
+# Copyright (c) 2001-2011, PostgreSQL Global Development Group
#
# src/backend/utils/mb/Unicode/ucs2utf.pl
# convert UCS-4 to UTF-8
diff --git a/src/backend/utils/mb/conv.c b/src/backend/utils/mb/conv.c
index aabba52268..8af157b2d5 100644
--- a/src/backend/utils/mb/conv.c
+++ b/src/backend/utils/mb/conv.c
@@ -2,7 +2,7 @@
*
* Utility functions for conversion procs.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/ascii_and_mic/ascii_and_mic.c b/src/backend/utils/mb/conversion_procs/ascii_and_mic/ascii_and_mic.c
index aaf2772a31..b6e7763bf4 100644
--- a/src/backend/utils/mb/conversion_procs/ascii_and_mic/ascii_and_mic.c
+++ b/src/backend/utils/mb/conversion_procs/ascii_and_mic/ascii_and_mic.c
@@ -2,7 +2,7 @@
*
* ASCII and MULE_INTERNAL
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/cyrillic_and_mic/cyrillic_and_mic.c b/src/backend/utils/mb/conversion_procs/cyrillic_and_mic/cyrillic_and_mic.c
index 02453bb754..1e793cafd4 100644
--- a/src/backend/utils/mb/conversion_procs/cyrillic_and_mic/cyrillic_and_mic.c
+++ b/src/backend/utils/mb/conversion_procs/cyrillic_and_mic/cyrillic_and_mic.c
@@ -2,7 +2,7 @@
*
* Cyrillic and MULE_INTERNAL
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/euc2004_sjis2004/euc2004_sjis2004.c b/src/backend/utils/mb/conversion_procs/euc2004_sjis2004/euc2004_sjis2004.c
index 4009b2cba1..3499f774b3 100644
--- a/src/backend/utils/mb/conversion_procs/euc2004_sjis2004/euc2004_sjis2004.c
+++ b/src/backend/utils/mb/conversion_procs/euc2004_sjis2004/euc2004_sjis2004.c
@@ -2,7 +2,7 @@
*
* EUC_JIS_2004, SHIFT_JIS_2004
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/mb/conversion_procs/euc2004_sjis2004/euc2004_sjis2004.c
diff --git a/src/backend/utils/mb/conversion_procs/euc_cn_and_mic/euc_cn_and_mic.c b/src/backend/utils/mb/conversion_procs/euc_cn_and_mic/euc_cn_and_mic.c
index 8cd69fba61..f1713e4383 100644
--- a/src/backend/utils/mb/conversion_procs/euc_cn_and_mic/euc_cn_and_mic.c
+++ b/src/backend/utils/mb/conversion_procs/euc_cn_and_mic/euc_cn_and_mic.c
@@ -2,7 +2,7 @@
*
* EUC_CN and MULE_INTERNAL
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/euc_jp_and_sjis/euc_jp_and_sjis.c b/src/backend/utils/mb/conversion_procs/euc_jp_and_sjis/euc_jp_and_sjis.c
index 3585d281df..118ecadd8f 100644
--- a/src/backend/utils/mb/conversion_procs/euc_jp_and_sjis/euc_jp_and_sjis.c
+++ b/src/backend/utils/mb/conversion_procs/euc_jp_and_sjis/euc_jp_and_sjis.c
@@ -2,7 +2,7 @@
*
* EUC_JP, SJIS and MULE_INTERNAL
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/euc_kr_and_mic/euc_kr_and_mic.c b/src/backend/utils/mb/conversion_procs/euc_kr_and_mic/euc_kr_and_mic.c
index 365dd96c7e..0c9529d40c 100644
--- a/src/backend/utils/mb/conversion_procs/euc_kr_and_mic/euc_kr_and_mic.c
+++ b/src/backend/utils/mb/conversion_procs/euc_kr_and_mic/euc_kr_and_mic.c
@@ -2,7 +2,7 @@
*
* EUC_KR and MULE_INTERNAL
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/euc_tw_and_big5/euc_tw_and_big5.c b/src/backend/utils/mb/conversion_procs/euc_tw_and_big5/euc_tw_and_big5.c
index ac4894377b..73dcd1dcd6 100644
--- a/src/backend/utils/mb/conversion_procs/euc_tw_and_big5/euc_tw_and_big5.c
+++ b/src/backend/utils/mb/conversion_procs/euc_tw_and_big5/euc_tw_and_big5.c
@@ -2,7 +2,7 @@
*
* EUC_TW, BIG5 and MULE_INTERNAL
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/latin2_and_win1250/latin2_and_win1250.c b/src/backend/utils/mb/conversion_procs/latin2_and_win1250/latin2_and_win1250.c
index 2daba2382c..003f117364 100644
--- a/src/backend/utils/mb/conversion_procs/latin2_and_win1250/latin2_and_win1250.c
+++ b/src/backend/utils/mb/conversion_procs/latin2_and_win1250/latin2_and_win1250.c
@@ -2,7 +2,7 @@
*
* LATIN2 and WIN1250
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/latin_and_mic/latin_and_mic.c b/src/backend/utils/mb/conversion_procs/latin_and_mic/latin_and_mic.c
index cbba781649..17f9977bc5 100644
--- a/src/backend/utils/mb/conversion_procs/latin_and_mic/latin_and_mic.c
+++ b/src/backend/utils/mb/conversion_procs/latin_and_mic/latin_and_mic.c
@@ -2,7 +2,7 @@
*
* LATINn and MULE_INTERNAL
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_ascii/utf8_and_ascii.c b/src/backend/utils/mb/conversion_procs/utf8_and_ascii/utf8_and_ascii.c
index 8c6b9c8d2c..05fac65270 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_ascii/utf8_and_ascii.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_ascii/utf8_and_ascii.c
@@ -2,7 +2,7 @@
*
* ASCII <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_big5/utf8_and_big5.c b/src/backend/utils/mb/conversion_procs/utf8_and_big5/utf8_and_big5.c
index 6ecaed56a4..3e28390f07 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_big5/utf8_and_big5.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_big5/utf8_and_big5.c
@@ -2,7 +2,7 @@
*
* BIG5 <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_cyrillic/utf8_and_cyrillic.c b/src/backend/utils/mb/conversion_procs/utf8_and_cyrillic/utf8_and_cyrillic.c
index c2e1f5284b..e12eef3748 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_cyrillic/utf8_and_cyrillic.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_cyrillic/utf8_and_cyrillic.c
@@ -2,7 +2,7 @@
*
* UTF8 and Cyrillic
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_euc2004/utf8_and_euc2004.c b/src/backend/utils/mb/conversion_procs/utf8_and_euc2004/utf8_and_euc2004.c
index 98d0732ec7..5055238c82 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_euc2004/utf8_and_euc2004.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_euc2004/utf8_and_euc2004.c
@@ -2,7 +2,7 @@
*
* EUC_JIS_2004 <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_euc_cn/utf8_and_euc_cn.c b/src/backend/utils/mb/conversion_procs/utf8_and_euc_cn/utf8_and_euc_cn.c
index cc23ada817..d4a2f471bd 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_euc_cn/utf8_and_euc_cn.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_euc_cn/utf8_and_euc_cn.c
@@ -2,7 +2,7 @@
*
* EUC_CN <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_euc_jp/utf8_and_euc_jp.c b/src/backend/utils/mb/conversion_procs/utf8_and_euc_jp/utf8_and_euc_jp.c
index 20d0858d3c..2c50f3550e 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_euc_jp/utf8_and_euc_jp.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_euc_jp/utf8_and_euc_jp.c
@@ -2,7 +2,7 @@
*
* EUC_JP <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_euc_kr/utf8_and_euc_kr.c b/src/backend/utils/mb/conversion_procs/utf8_and_euc_kr/utf8_and_euc_kr.c
index ac3324f21f..a494d55b42 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_euc_kr/utf8_and_euc_kr.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_euc_kr/utf8_and_euc_kr.c
@@ -2,7 +2,7 @@
*
* EUC_KR <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_euc_tw/utf8_and_euc_tw.c b/src/backend/utils/mb/conversion_procs/utf8_and_euc_tw/utf8_and_euc_tw.c
index ac1b7984f2..adb887e854 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_euc_tw/utf8_and_euc_tw.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_euc_tw/utf8_and_euc_tw.c
@@ -2,7 +2,7 @@
*
* EUC_TW <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_gb18030/utf8_and_gb18030.c b/src/backend/utils/mb/conversion_procs/utf8_and_gb18030/utf8_and_gb18030.c
index 693229f9f4..42b076e0cd 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_gb18030/utf8_and_gb18030.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_gb18030/utf8_and_gb18030.c
@@ -2,7 +2,7 @@
*
* GB18030 <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_gbk/utf8_and_gbk.c b/src/backend/utils/mb/conversion_procs/utf8_and_gbk/utf8_and_gbk.c
index ce461bf06c..97b4d0c992 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_gbk/utf8_and_gbk.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_gbk/utf8_and_gbk.c
@@ -2,7 +2,7 @@
*
* GBK <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_iso8859/utf8_and_iso8859.c b/src/backend/utils/mb/conversion_procs/utf8_and_iso8859/utf8_and_iso8859.c
index d9ed1e6b9b..89f589d62d 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_iso8859/utf8_and_iso8859.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_iso8859/utf8_and_iso8859.c
@@ -2,7 +2,7 @@
*
* ISO 8859 2-16 <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_iso8859_1/utf8_and_iso8859_1.c b/src/backend/utils/mb/conversion_procs/utf8_and_iso8859_1/utf8_and_iso8859_1.c
index 15e6bbf471..31c3894efc 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_iso8859_1/utf8_and_iso8859_1.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_iso8859_1/utf8_and_iso8859_1.c
@@ -2,7 +2,7 @@
*
* ISO8859_1 <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_johab/utf8_and_johab.c b/src/backend/utils/mb/conversion_procs/utf8_and_johab/utf8_and_johab.c
index fdaae4b38f..821f6f33b3 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_johab/utf8_and_johab.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_johab/utf8_and_johab.c
@@ -2,7 +2,7 @@
*
* JOHAB <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_sjis/utf8_and_sjis.c b/src/backend/utils/mb/conversion_procs/utf8_and_sjis/utf8_and_sjis.c
index 91ef89fc3b..3097595952 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_sjis/utf8_and_sjis.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_sjis/utf8_and_sjis.c
@@ -2,7 +2,7 @@
*
* SJIS <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_sjis2004/utf8_and_sjis2004.c b/src/backend/utils/mb/conversion_procs/utf8_and_sjis2004/utf8_and_sjis2004.c
index 3a3d86f6cc..7d4cbff7d4 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_sjis2004/utf8_and_sjis2004.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_sjis2004/utf8_and_sjis2004.c
@@ -2,7 +2,7 @@
*
* SHIFT_JIS_2004 <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_uhc/utf8_and_uhc.c b/src/backend/utils/mb/conversion_procs/utf8_and_uhc/utf8_and_uhc.c
index a8babba323..e21c4866d3 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_uhc/utf8_and_uhc.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_uhc/utf8_and_uhc.c
@@ -2,7 +2,7 @@
*
* UHC <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mb/conversion_procs/utf8_and_win/utf8_and_win.c b/src/backend/utils/mb/conversion_procs/utf8_and_win/utf8_and_win.c
index 338c855077..8102a9074b 100644
--- a/src/backend/utils/mb/conversion_procs/utf8_and_win/utf8_and_win.c
+++ b/src/backend/utils/mb/conversion_procs/utf8_and_win/utf8_and_win.c
@@ -2,7 +2,7 @@
*
* WIN <--> UTF8
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/misc/guc-file.l b/src/backend/utils/misc/guc-file.l
index 8f6280656d..e660395898 100644
--- a/src/backend/utils/misc/guc-file.l
+++ b/src/backend/utils/misc/guc-file.l
@@ -2,7 +2,7 @@
/*
* Scanner for the configuration file
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/backend/utils/misc/guc-file.l
*/
diff --git a/src/backend/utils/misc/guc.c b/src/backend/utils/misc/guc.c
index 1b9fe28af8..e4dea31e79 100644
--- a/src/backend/utils/misc/guc.c
+++ b/src/backend/utils/misc/guc.c
@@ -6,7 +6,7 @@
* See src/backend/utils/misc/README for more information.
*
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
* Written by Peter Eisentraut .
*
* IDENTIFICATION
diff --git a/src/backend/utils/misc/help_config.c b/src/backend/utils/misc/help_config.c
index f637ddb65e..1ca7ae1443 100644
--- a/src/backend/utils/misc/help_config.c
+++ b/src/backend/utils/misc/help_config.c
@@ -7,7 +7,7 @@
* or GUC_DISALLOW_IN_FILE are not displayed, unless the user specifically
* requests that variable by name
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/misc/help_config.c
diff --git a/src/backend/utils/misc/pg_rusage.c b/src/backend/utils/misc/pg_rusage.c
index c843c58a9c..c96316403f 100644
--- a/src/backend/utils/misc/pg_rusage.c
+++ b/src/backend/utils/misc/pg_rusage.c
@@ -4,7 +4,7 @@
* Resource usage measurement support routines.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/misc/ps_status.c b/src/backend/utils/misc/ps_status.c
index 72c4dae7d6..66d03adaf9 100644
--- a/src/backend/utils/misc/ps_status.c
+++ b/src/backend/utils/misc/ps_status.c
@@ -7,7 +7,7 @@
*
* src/backend/utils/misc/ps_status.c
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
* various details abducted from various places
*--------------------------------------------------------------------
*/
diff --git a/src/backend/utils/misc/rbtree.c b/src/backend/utils/misc/rbtree.c
index 717142566a..7a8ddf0a17 100644
--- a/src/backend/utils/misc/rbtree.c
+++ b/src/backend/utils/misc/rbtree.c
@@ -17,7 +17,7 @@
* longest path from root to leaf is only about twice as long as the shortest,
* so lookups are guaranteed to run in O(lg n) time.
*
- * Copyright (c) 2009-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2009-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/backend/utils/misc/rbtree.c
diff --git a/src/backend/utils/misc/superuser.c b/src/backend/utils/misc/superuser.c
index 417af1e8ed..e70b1f5ccf 100644
--- a/src/backend/utils/misc/superuser.c
+++ b/src/backend/utils/misc/superuser.c
@@ -9,7 +9,7 @@
* the single-user case works.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/misc/tzparser.c b/src/backend/utils/misc/tzparser.c
index c619dba2d0..e63ce58e69 100644
--- a/src/backend/utils/misc/tzparser.c
+++ b/src/backend/utils/misc/tzparser.c
@@ -9,7 +9,7 @@
* probably fix with PG_TRY if necessary.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mmgr/aset.c b/src/backend/utils/mmgr/aset.c
index 3dd80b2e1f..b28dc47420 100644
--- a/src/backend/utils/mmgr/aset.c
+++ b/src/backend/utils/mmgr/aset.c
@@ -7,7 +7,7 @@
* type.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/mmgr/mcxt.c b/src/backend/utils/mmgr/mcxt.c
index 880f738434..8783edf026 100644
--- a/src/backend/utils/mmgr/mcxt.c
+++ b/src/backend/utils/mmgr/mcxt.c
@@ -9,7 +9,7 @@
* context's MemoryContextMethods struct.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/mmgr/portalmem.c b/src/backend/utils/mmgr/portalmem.c
index 61309b3daa..e61094209f 100644
--- a/src/backend/utils/mmgr/portalmem.c
+++ b/src/backend/utils/mmgr/portalmem.c
@@ -8,7 +8,7 @@
* doesn't actually run the executor for them.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/probes.d b/src/backend/utils/probes.d
index 22855c2746..71c5ab0bee 100644
--- a/src/backend/utils/probes.d
+++ b/src/backend/utils/probes.d
@@ -1,7 +1,7 @@
/* ----------
* DTrace probes for PostgreSQL backend
*
- * Copyright (c) 2006-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2006-2011, PostgreSQL Global Development Group
*
* src/backend/utils/probes.d
* ----------
diff --git a/src/backend/utils/resowner/resowner.c b/src/backend/utils/resowner/resowner.c
index 8468d2c3f1..ef1cac0147 100644
--- a/src/backend/utils/resowner/resowner.c
+++ b/src/backend/utils/resowner/resowner.c
@@ -9,7 +9,7 @@
* See utils/resowner/README for more info.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/backend/utils/sort/logtape.c b/src/backend/utils/sort/logtape.c
index c2d8557d67..1f21b1dd54 100644
--- a/src/backend/utils/sort/logtape.c
+++ b/src/backend/utils/sort/logtape.c
@@ -66,7 +66,7 @@
* care that all calls for a single LogicalTapeSet are made in the same
* palloc context.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/sort/tuplesort.c b/src/backend/utils/sort/tuplesort.c
index dae73f15af..d20a3b3739 100644
--- a/src/backend/utils/sort/tuplesort.c
+++ b/src/backend/utils/sort/tuplesort.c
@@ -87,7 +87,7 @@
* above. Nonetheless, with large workMem we can have many tapes.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/sort/tuplestore.c b/src/backend/utils/sort/tuplestore.c
index 8c8139c897..b59587b73b 100644
--- a/src/backend/utils/sort/tuplestore.c
+++ b/src/backend/utils/sort/tuplestore.c
@@ -43,7 +43,7 @@
* before switching to the other state or activating a different read pointer.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/time/combocid.c b/src/backend/utils/time/combocid.c
index 6b0205c090..d9b37b2ba3 100644
--- a/src/backend/utils/time/combocid.c
+++ b/src/backend/utils/time/combocid.c
@@ -30,7 +30,7 @@
* destroyed at the end of each transaction.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/time/snapmgr.c b/src/backend/utils/time/snapmgr.c
index 273d8bdd05..45b92a0ef8 100644
--- a/src/backend/utils/time/snapmgr.c
+++ b/src/backend/utils/time/snapmgr.c
@@ -15,7 +15,7 @@
* long.)
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/backend/utils/time/tqual.c b/src/backend/utils/time/tqual.c
index 719dc13964..2fd32e05d1 100644
--- a/src/backend/utils/time/tqual.c
+++ b/src/backend/utils/time/tqual.c
@@ -46,7 +46,7 @@
* HeapTupleSatisfiesAny()
* all tuples are visible
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/bin/Makefile b/src/bin/Makefile
index c81b665481..c18c05c6c5 100644
--- a/src/bin/Makefile
+++ b/src/bin/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin (client programs)
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/bin/Makefile
diff --git a/src/bin/initdb/Makefile b/src/bin/initdb/Makefile
index 903fbc1097..7dd6683813 100644
--- a/src/bin/initdb/Makefile
+++ b/src/bin/initdb/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin/initdb
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/bin/initdb/Makefile
diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c
index 040cbdfab0..73d5a62d85 100644
--- a/src/bin/initdb/initdb.c
+++ b/src/bin/initdb/initdb.c
@@ -38,7 +38,7 @@
*
* This code is released under the terms of the PostgreSQL License.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/initdb/initdb.c
diff --git a/src/bin/pg_config/Makefile b/src/bin/pg_config/Makefile
index c7e5a02374..479db9cd4b 100644
--- a/src/bin/pg_config/Makefile
+++ b/src/bin/pg_config/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin/pg_config
#
-# Copyright (c) 1998-2010, PostgreSQL Global Development Group
+# Copyright (c) 1998-2011, PostgreSQL Global Development Group
#
# src/bin/pg_config/Makefile
#
diff --git a/src/bin/pg_config/pg_config.c b/src/bin/pg_config/pg_config.c
index 2e87060f80..532c4a61e3 100644
--- a/src/bin/pg_config/pg_config.c
+++ b/src/bin/pg_config/pg_config.c
@@ -15,7 +15,7 @@
*
* This code is released under the terms of the PostgreSQL License.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/bin/pg_config/pg_config.c
*
diff --git a/src/bin/pg_controldata/Makefile b/src/bin/pg_controldata/Makefile
index 180c5ebfe8..207f5e525d 100644
--- a/src/bin/pg_controldata/Makefile
+++ b/src/bin/pg_controldata/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin/pg_controldata
#
-# Copyright (c) 1998-2010, PostgreSQL Global Development Group
+# Copyright (c) 1998-2011, PostgreSQL Global Development Group
#
# src/bin/pg_controldata/Makefile
#
diff --git a/src/bin/pg_ctl/Makefile b/src/bin/pg_ctl/Makefile
index 992799c215..00fc682795 100644
--- a/src/bin/pg_ctl/Makefile
+++ b/src/bin/pg_ctl/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin/pg_ctl
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/bin/pg_ctl/Makefile
diff --git a/src/bin/pg_ctl/pg_ctl.c b/src/bin/pg_ctl/pg_ctl.c
index 92ea514f1d..baef17681b 100644
--- a/src/bin/pg_ctl/pg_ctl.c
+++ b/src/bin/pg_ctl/pg_ctl.c
@@ -2,7 +2,7 @@
*
* pg_ctl --- start/stops/restarts the PostgreSQL server
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/bin/pg_ctl/pg_ctl.c
*
diff --git a/src/bin/pg_dump/Makefile b/src/bin/pg_dump/Makefile
index efb031a989..db607b46f5 100644
--- a/src/bin/pg_dump/Makefile
+++ b/src/bin/pg_dump/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin/pg_dump
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/bin/pg_dump/Makefile
diff --git a/src/bin/pg_dump/common.c b/src/bin/pg_dump/common.c
index e4a02014fd..55cc3126e1 100644
--- a/src/bin/pg_dump/common.c
+++ b/src/bin/pg_dump/common.c
@@ -6,7 +6,7 @@
* Since pg4_dump is long-dead code, there is no longer any useful distinction
* between this file and pg_dump.c.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/bin/pg_dump/compress_io.c b/src/bin/pg_dump/compress_io.c
index 825334fd5e..8c41a69043 100644
--- a/src/bin/pg_dump/compress_io.c
+++ b/src/bin/pg_dump/compress_io.c
@@ -4,7 +4,7 @@
* Routines for archivers to write an uncompressed or compressed data
* stream.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* The interface for writing to an archive consists of three functions:
diff --git a/src/bin/pg_dump/compress_io.h b/src/bin/pg_dump/compress_io.h
index 26930cdb26..13e536f36d 100644
--- a/src/bin/pg_dump/compress_io.h
+++ b/src/bin/pg_dump/compress_io.h
@@ -3,7 +3,7 @@
* compress_io.h
* Interface to compress_io.c routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/bin/pg_dump/dumputils.c b/src/bin/pg_dump/dumputils.c
index d53e908a44..e280b5de17 100644
--- a/src/bin/pg_dump/dumputils.c
+++ b/src/bin/pg_dump/dumputils.c
@@ -5,7 +5,7 @@
* Lately it's also being used by psql and bin/scripts/ ...
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/pg_dump/dumputils.c
diff --git a/src/bin/pg_dump/dumputils.h b/src/bin/pg_dump/dumputils.h
index 04f111bb38..556883b229 100644
--- a/src/bin/pg_dump/dumputils.h
+++ b/src/bin/pg_dump/dumputils.h
@@ -5,7 +5,7 @@
* Lately it's also being used by psql and bin/scripts/ ...
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/pg_dump/dumputils.h
diff --git a/src/bin/pg_dump/keywords.c b/src/bin/pg_dump/keywords.c
index c798bb821b..e05cdd46c0 100644
--- a/src/bin/pg_dump/keywords.c
+++ b/src/bin/pg_dump/keywords.c
@@ -4,7 +4,7 @@
* lexical token lookup for key words in PostgreSQL
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c
index afd759142b..b35a5457f9 100644
--- a/src/bin/pg_dump/pg_dump.c
+++ b/src/bin/pg_dump/pg_dump.c
@@ -4,7 +4,7 @@
* pg_dump is a utility for dumping out a postgres database
* into a script file.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* pg_dump will read the system catalogs in a database and dump out a
diff --git a/src/bin/pg_dump/pg_dump.h b/src/bin/pg_dump/pg_dump.h
index 4313fd866b..43fd1ade27 100644
--- a/src/bin/pg_dump/pg_dump.h
+++ b/src/bin/pg_dump/pg_dump.h
@@ -3,7 +3,7 @@
* pg_dump.h
* Common header file for the pg_dump utility
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/pg_dump/pg_dump.h
diff --git a/src/bin/pg_dump/pg_dump_sort.c b/src/bin/pg_dump/pg_dump_sort.c
index a52d03c27a..fe5cf56e69 100644
--- a/src/bin/pg_dump/pg_dump_sort.c
+++ b/src/bin/pg_dump/pg_dump_sort.c
@@ -4,7 +4,7 @@
* Sort the items of a dump into a safe order for dumping
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/bin/pg_dump/pg_dumpall.c b/src/bin/pg_dump/pg_dumpall.c
index ef05a46e7a..17a73b87f1 100644
--- a/src/bin/pg_dump/pg_dumpall.c
+++ b/src/bin/pg_dump/pg_dumpall.c
@@ -2,7 +2,7 @@
*
* pg_dumpall.c
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/bin/pg_resetxlog/Makefile b/src/bin/pg_resetxlog/Makefile
index ad56a11503..a2769284f6 100644
--- a/src/bin/pg_resetxlog/Makefile
+++ b/src/bin/pg_resetxlog/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin/pg_resetxlog
#
-# Copyright (c) 1998-2010, PostgreSQL Global Development Group
+# Copyright (c) 1998-2011, PostgreSQL Global Development Group
#
# src/bin/pg_resetxlog/Makefile
#
diff --git a/src/bin/pg_resetxlog/pg_resetxlog.c b/src/bin/pg_resetxlog/pg_resetxlog.c
index e813874305..1e1412d29d 100644
--- a/src/bin/pg_resetxlog/pg_resetxlog.c
+++ b/src/bin/pg_resetxlog/pg_resetxlog.c
@@ -20,7 +20,7 @@
* step 2 ...
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/pg_resetxlog/pg_resetxlog.c
diff --git a/src/bin/pgevent/Makefile b/src/bin/pgevent/Makefile
index 39cb7dcc5a..f585820d38 100644
--- a/src/bin/pgevent/Makefile
+++ b/src/bin/pgevent/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin/pgevent
#
-# Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Copyright (c) 1996-2011, PostgreSQL Global Development Group
#
#-------------------------------------------------------------------------
diff --git a/src/bin/psql/Makefile b/src/bin/psql/Makefile
index a30c668424..ce990ce08a 100644
--- a/src/bin/psql/Makefile
+++ b/src/bin/psql/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin/psql
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/bin/psql/Makefile
diff --git a/src/bin/psql/command.c b/src/bin/psql/command.c
index c1edf44a60..04be60f73e 100644
--- a/src/bin/psql/command.c
+++ b/src/bin/psql/command.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/command.c
*/
diff --git a/src/bin/psql/command.h b/src/bin/psql/command.h
index 9f12d4ae87..852d645cfd 100644
--- a/src/bin/psql/command.h
+++ b/src/bin/psql/command.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/command.h
*/
diff --git a/src/bin/psql/common.c b/src/bin/psql/common.c
index 7c232f8d25..b57da05345 100644
--- a/src/bin/psql/common.c
+++ b/src/bin/psql/common.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/common.c
*/
diff --git a/src/bin/psql/common.h b/src/bin/psql/common.h
index 5fa13b76a8..7b559f3c80 100644
--- a/src/bin/psql/common.h
+++ b/src/bin/psql/common.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/common.h
*/
diff --git a/src/bin/psql/copy.c b/src/bin/psql/copy.c
index 5c39d94dfb..5e69d29b6c 100644
--- a/src/bin/psql/copy.c
+++ b/src/bin/psql/copy.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/copy.c
*/
diff --git a/src/bin/psql/copy.h b/src/bin/psql/copy.h
index 7f1b565bfe..07d8afe581 100644
--- a/src/bin/psql/copy.h
+++ b/src/bin/psql/copy.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/copy.h
*/
diff --git a/src/bin/psql/create_help.pl b/src/bin/psql/create_help.pl
index 495100326d..7e30abac17 100644
--- a/src/bin/psql/create_help.pl
+++ b/src/bin/psql/create_help.pl
@@ -3,7 +3,7 @@
#################################################################
# create_help.pl -- converts SGML docs to internal psql help
#
-# Copyright (c) 2000-2010, PostgreSQL Global Development Group
+# Copyright (c) 2000-2011, PostgreSQL Global Development Group
#
# src/bin/psql/create_help.pl
#################################################################
diff --git a/src/bin/psql/describe.c b/src/bin/psql/describe.c
index 406cc838e9..19ba517d1b 100644
--- a/src/bin/psql/describe.c
+++ b/src/bin/psql/describe.c
@@ -6,7 +6,7 @@
* with servers of versions 7.4 and up. It's okay to omit irrelevant
* information for an old server, but not to fail outright.
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/describe.c
*/
diff --git a/src/bin/psql/describe.h b/src/bin/psql/describe.h
index 6a6abdba47..6d9fada58f 100644
--- a/src/bin/psql/describe.h
+++ b/src/bin/psql/describe.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/describe.h
*/
diff --git a/src/bin/psql/help.c b/src/bin/psql/help.c
index 4458d631ab..8ab3b4722e 100644
--- a/src/bin/psql/help.c
+++ b/src/bin/psql/help.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/help.c
*/
@@ -423,7 +423,7 @@ print_copyright(void)
{
puts(
"PostgreSQL Data Base Management System\n\n"
- "Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group\n\n"
+ "Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group\n\n"
"This software is based on Postgres95, formerly known as Postgres, which\n"
"contains the following notice:\n\n"
"Portions Copyright(c) 1994, Regents of the University of California\n\n"
diff --git a/src/bin/psql/help.h b/src/bin/psql/help.h
index 0b7bf8f645..f2e57f06ed 100644
--- a/src/bin/psql/help.h
+++ b/src/bin/psql/help.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/help.h
*/
diff --git a/src/bin/psql/input.c b/src/bin/psql/input.c
index c95ee22d88..6628c0c30c 100644
--- a/src/bin/psql/input.c
+++ b/src/bin/psql/input.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/input.c
*/
diff --git a/src/bin/psql/input.h b/src/bin/psql/input.h
index 1c52f8d27a..ad09802b68 100644
--- a/src/bin/psql/input.h
+++ b/src/bin/psql/input.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/input.h
*/
diff --git a/src/bin/psql/large_obj.c b/src/bin/psql/large_obj.c
index ecc7b76b5c..594fa0eccf 100644
--- a/src/bin/psql/large_obj.c
+++ b/src/bin/psql/large_obj.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/large_obj.c
*/
diff --git a/src/bin/psql/large_obj.h b/src/bin/psql/large_obj.h
index b7aa204ed8..592540d223 100644
--- a/src/bin/psql/large_obj.h
+++ b/src/bin/psql/large_obj.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/large_obj.h
*/
diff --git a/src/bin/psql/mainloop.c b/src/bin/psql/mainloop.c
index b124ec5ea9..6c4a079b0a 100644
--- a/src/bin/psql/mainloop.c
+++ b/src/bin/psql/mainloop.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/mainloop.c
*/
diff --git a/src/bin/psql/mainloop.h b/src/bin/psql/mainloop.h
index cbb931b0c9..f83cc0c753 100644
--- a/src/bin/psql/mainloop.h
+++ b/src/bin/psql/mainloop.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/mainloop.h
*/
diff --git a/src/bin/psql/mbprint.c b/src/bin/psql/mbprint.c
index 6bca2f29bb..248a4db042 100644
--- a/src/bin/psql/mbprint.c
+++ b/src/bin/psql/mbprint.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/mbprint.c
*
diff --git a/src/bin/psql/print.c b/src/bin/psql/print.c
index c94607644a..28afcdda74 100644
--- a/src/bin/psql/print.c
+++ b/src/bin/psql/print.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/print.c
*/
diff --git a/src/bin/psql/print.h b/src/bin/psql/print.h
index 1f54075e0e..35bb4cde1d 100644
--- a/src/bin/psql/print.h
+++ b/src/bin/psql/print.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/print.h
*/
diff --git a/src/bin/psql/prompt.c b/src/bin/psql/prompt.c
index 6f097652a9..aceab70091 100644
--- a/src/bin/psql/prompt.c
+++ b/src/bin/psql/prompt.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/prompt.c
*/
diff --git a/src/bin/psql/prompt.h b/src/bin/psql/prompt.h
index 8eb58977d6..8cbd76a64d 100644
--- a/src/bin/psql/prompt.h
+++ b/src/bin/psql/prompt.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/prompt.h
*/
diff --git a/src/bin/psql/psqlscan.h b/src/bin/psql/psqlscan.h
index c644d286e5..b2545d0ebf 100644
--- a/src/bin/psql/psqlscan.h
+++ b/src/bin/psql/psqlscan.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/psqlscan.h
*/
diff --git a/src/bin/psql/psqlscan.l b/src/bin/psql/psqlscan.l
index a1da032a6f..3575f91a61 100644
--- a/src/bin/psql/psqlscan.l
+++ b/src/bin/psql/psqlscan.l
@@ -29,7 +29,7 @@
* subroutine is responsible for looking back to the original string and
* replacing FF's with the corresponding original bytes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/bin/psql/settings.h b/src/bin/psql/settings.h
index 188e819de0..7228f9d0ee 100644
--- a/src/bin/psql/settings.h
+++ b/src/bin/psql/settings.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/settings.h
*/
diff --git a/src/bin/psql/startup.c b/src/bin/psql/startup.c
index 996910270d..4f3815a28a 100644
--- a/src/bin/psql/startup.c
+++ b/src/bin/psql/startup.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/startup.c
*/
diff --git a/src/bin/psql/stringutils.c b/src/bin/psql/stringutils.c
index 09ccbc336a..24bc2e3e03 100644
--- a/src/bin/psql/stringutils.c
+++ b/src/bin/psql/stringutils.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/stringutils.c
*/
diff --git a/src/bin/psql/stringutils.h b/src/bin/psql/stringutils.h
index 1519e6aede..2c79705f1d 100644
--- a/src/bin/psql/stringutils.h
+++ b/src/bin/psql/stringutils.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/stringutils.h
*/
diff --git a/src/bin/psql/tab-complete.c b/src/bin/psql/tab-complete.c
index c88d671f40..2b140c150d 100644
--- a/src/bin/psql/tab-complete.c
+++ b/src/bin/psql/tab-complete.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/tab-complete.c
*/
diff --git a/src/bin/psql/tab-complete.h b/src/bin/psql/tab-complete.h
index 682ab74f54..626cbf48dd 100644
--- a/src/bin/psql/tab-complete.h
+++ b/src/bin/psql/tab-complete.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/tab-complete.h
*/
diff --git a/src/bin/psql/variables.c b/src/bin/psql/variables.c
index 50b015759f..3825289337 100644
--- a/src/bin/psql/variables.c
+++ b/src/bin/psql/variables.c
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/variables.c
*/
diff --git a/src/bin/psql/variables.h b/src/bin/psql/variables.h
index 4f01fe8129..4197069b4b 100644
--- a/src/bin/psql/variables.h
+++ b/src/bin/psql/variables.h
@@ -1,7 +1,7 @@
/*
* psql - the PostgreSQL interactive terminal
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/bin/psql/variables.h
*/
diff --git a/src/bin/scripts/Makefile b/src/bin/scripts/Makefile
index d0b0c1c20e..0c05966527 100644
--- a/src/bin/scripts/Makefile
+++ b/src/bin/scripts/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/bin/scripts
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/bin/scripts/Makefile
diff --git a/src/bin/scripts/clusterdb.c b/src/bin/scripts/clusterdb.c
index d16262284e..f4c317ae14 100644
--- a/src/bin/scripts/clusterdb.c
+++ b/src/bin/scripts/clusterdb.c
@@ -2,7 +2,7 @@
*
* clusterdb
*
- * Portions Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* src/bin/scripts/clusterdb.c
*
diff --git a/src/bin/scripts/common.c b/src/bin/scripts/common.c
index 5cc0e70a7f..c882123dd1 100644
--- a/src/bin/scripts/common.c
+++ b/src/bin/scripts/common.c
@@ -4,7 +4,7 @@
* Common support routines for bin/scripts/
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/scripts/common.c
diff --git a/src/bin/scripts/common.h b/src/bin/scripts/common.h
index bcddf8008f..694977b73b 100644
--- a/src/bin/scripts/common.h
+++ b/src/bin/scripts/common.h
@@ -2,7 +2,7 @@
* common.h
* Common support routines for bin/scripts/
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* src/bin/scripts/common.h
*/
diff --git a/src/bin/scripts/createdb.c b/src/bin/scripts/createdb.c
index 937a573d77..9b72eac79b 100644
--- a/src/bin/scripts/createdb.c
+++ b/src/bin/scripts/createdb.c
@@ -2,7 +2,7 @@
*
* createdb
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/scripts/createdb.c
diff --git a/src/bin/scripts/createlang.c b/src/bin/scripts/createlang.c
index 23ce45b310..3c68400528 100644
--- a/src/bin/scripts/createlang.c
+++ b/src/bin/scripts/createlang.c
@@ -2,7 +2,7 @@
*
* createlang
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/scripts/createlang.c
diff --git a/src/bin/scripts/createuser.c b/src/bin/scripts/createuser.c
index c2c7aeeabe..04bbebcaf3 100644
--- a/src/bin/scripts/createuser.c
+++ b/src/bin/scripts/createuser.c
@@ -2,7 +2,7 @@
*
* createuser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/scripts/createuser.c
diff --git a/src/bin/scripts/dropdb.c b/src/bin/scripts/dropdb.c
index f52ed7d94a..1cf18fd5d8 100644
--- a/src/bin/scripts/dropdb.c
+++ b/src/bin/scripts/dropdb.c
@@ -2,7 +2,7 @@
*
* dropdb
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/scripts/dropdb.c
diff --git a/src/bin/scripts/droplang.c b/src/bin/scripts/droplang.c
index 2ba0728b95..0d03d3c4b7 100644
--- a/src/bin/scripts/droplang.c
+++ b/src/bin/scripts/droplang.c
@@ -2,7 +2,7 @@
*
* droplang
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/scripts/droplang.c
diff --git a/src/bin/scripts/dropuser.c b/src/bin/scripts/dropuser.c
index f2b7336c23..0949a5eefe 100644
--- a/src/bin/scripts/dropuser.c
+++ b/src/bin/scripts/dropuser.c
@@ -2,7 +2,7 @@
*
* dropuser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/scripts/dropuser.c
diff --git a/src/bin/scripts/reindexdb.c b/src/bin/scripts/reindexdb.c
index 6feb5d6852..53fff01a74 100644
--- a/src/bin/scripts/reindexdb.c
+++ b/src/bin/scripts/reindexdb.c
@@ -2,7 +2,7 @@
*
* reindexdb
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/bin/scripts/reindexdb.c
*
diff --git a/src/bin/scripts/vacuumdb.c b/src/bin/scripts/vacuumdb.c
index f281dca096..7457e6d304 100644
--- a/src/bin/scripts/vacuumdb.c
+++ b/src/bin/scripts/vacuumdb.c
@@ -2,7 +2,7 @@
*
* vacuumdb
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/bin/scripts/vacuumdb.c
diff --git a/src/include/access/attnum.h b/src/include/access/attnum.h
index db2a8d305a..4fec9b5f8c 100644
--- a/src/include/access/attnum.h
+++ b/src/include/access/attnum.h
@@ -4,7 +4,7 @@
* POSTGRES attribute number definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/attnum.h
diff --git a/src/include/access/clog.h b/src/include/access/clog.h
index bef1c88143..7a8918e0fc 100644
--- a/src/include/access/clog.h
+++ b/src/include/access/clog.h
@@ -3,7 +3,7 @@
*
* PostgreSQL transaction-commit-log manager
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/clog.h
diff --git a/src/include/access/genam.h b/src/include/access/genam.h
index 896fb75fdd..a95b3d745b 100644
--- a/src/include/access/genam.h
+++ b/src/include/access/genam.h
@@ -4,7 +4,7 @@
* POSTGRES generalized index access method definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/genam.h
diff --git a/src/include/access/gin.h b/src/include/access/gin.h
index b1eef92054..d07454af68 100644
--- a/src/include/access/gin.h
+++ b/src/include/access/gin.h
@@ -2,7 +2,7 @@
* gin.h
* header file for postgres inverted index access method implementation.
*
- * Copyright (c) 2006-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2006-2011, PostgreSQL Global Development Group
*
* src/include/access/gin.h
*--------------------------------------------------------------------------
diff --git a/src/include/access/gist.h b/src/include/access/gist.h
index 3913218204..230e138f08 100644
--- a/src/include/access/gist.h
+++ b/src/include/access/gist.h
@@ -6,7 +6,7 @@
* changes should be made with care.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/gist.h
diff --git a/src/include/access/gist_private.h b/src/include/access/gist_private.h
index 77d679d489..70638705c2 100644
--- a/src/include/access/gist_private.h
+++ b/src/include/access/gist_private.h
@@ -4,7 +4,7 @@
* private declarations for GiST -- declarations related to the
* internal implementation of GiST, not the public API
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/gist_private.h
diff --git a/src/include/access/gistscan.h b/src/include/access/gistscan.h
index cb0e23771c..7cec1f3d29 100644
--- a/src/include/access/gistscan.h
+++ b/src/include/access/gistscan.h
@@ -4,7 +4,7 @@
* routines defined in access/gist/gistscan.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/gistscan.h
diff --git a/src/include/access/hash.h b/src/include/access/hash.h
index a48320bbee..13ff37ab0b 100644
--- a/src/include/access/hash.h
+++ b/src/include/access/hash.h
@@ -4,7 +4,7 @@
* header file for postgres hash access method implementation
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/hash.h
diff --git a/src/include/access/heapam.h b/src/include/access/heapam.h
index 45e100c39b..9efab4c500 100644
--- a/src/include/access/heapam.h
+++ b/src/include/access/heapam.h
@@ -4,7 +4,7 @@
* POSTGRES heap access method definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/heapam.h
diff --git a/src/include/access/hio.h b/src/include/access/hio.h
index ea97e10957..6951dfb010 100644
--- a/src/include/access/hio.h
+++ b/src/include/access/hio.h
@@ -4,7 +4,7 @@
* POSTGRES heap access method input/output definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/hio.h
diff --git a/src/include/access/htup.h b/src/include/access/htup.h
index f540966d68..0e626e8469 100644
--- a/src/include/access/htup.h
+++ b/src/include/access/htup.h
@@ -4,7 +4,7 @@
* POSTGRES heap tuple definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/htup.h
diff --git a/src/include/access/itup.h b/src/include/access/itup.h
index da937fca09..cab7193964 100644
--- a/src/include/access/itup.h
+++ b/src/include/access/itup.h
@@ -4,7 +4,7 @@
* POSTGRES index tuple definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/itup.h
diff --git a/src/include/access/multixact.h b/src/include/access/multixact.h
index 565848e5e5..c3ec763985 100644
--- a/src/include/access/multixact.h
+++ b/src/include/access/multixact.h
@@ -3,7 +3,7 @@
*
* PostgreSQL multi-transaction-log manager
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/multixact.h
diff --git a/src/include/access/nbtree.h b/src/include/access/nbtree.h
index 283612eaed..b62e42cfde 100644
--- a/src/include/access/nbtree.h
+++ b/src/include/access/nbtree.h
@@ -4,7 +4,7 @@
* header file for postgres btree access method implementation.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/nbtree.h
diff --git a/src/include/access/printtup.h b/src/include/access/printtup.h
index 500268ed3b..2eb7e12183 100644
--- a/src/include/access/printtup.h
+++ b/src/include/access/printtup.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/printtup.h
diff --git a/src/include/access/reloptions.h b/src/include/access/reloptions.h
index 9bba58bc2f..c7709cc058 100644
--- a/src/include/access/reloptions.h
+++ b/src/include/access/reloptions.h
@@ -9,7 +9,7 @@
* into a lot of low-level code.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/reloptions.h
diff --git a/src/include/access/relscan.h b/src/include/access/relscan.h
index f412fc3844..989dc57685 100644
--- a/src/include/access/relscan.h
+++ b/src/include/access/relscan.h
@@ -4,7 +4,7 @@
* POSTGRES relation scan descriptor definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/relscan.h
diff --git a/src/include/access/rewriteheap.h b/src/include/access/rewriteheap.h
index db51d7cfaf..a562480225 100644
--- a/src/include/access/rewriteheap.h
+++ b/src/include/access/rewriteheap.h
@@ -3,7 +3,7 @@
* rewriteheap.h
* Declarations for heap rewrite support functions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994-5, Regents of the University of California
*
* src/include/access/rewriteheap.h
diff --git a/src/include/access/sdir.h b/src/include/access/sdir.h
index 9aae49c6e3..0108ed23d8 100644
--- a/src/include/access/sdir.h
+++ b/src/include/access/sdir.h
@@ -4,7 +4,7 @@
* POSTGRES scan direction definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/sdir.h
diff --git a/src/include/access/skey.h b/src/include/access/skey.h
index c30a44bde3..5a498956c9 100644
--- a/src/include/access/skey.h
+++ b/src/include/access/skey.h
@@ -4,7 +4,7 @@
* POSTGRES scan key definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/skey.h
diff --git a/src/include/access/slru.h b/src/include/access/slru.h
index ede1b428ab..c491b7d5f9 100644
--- a/src/include/access/slru.h
+++ b/src/include/access/slru.h
@@ -3,7 +3,7 @@
* slru.h
* Simple LRU buffering for transaction status logfiles
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/slru.h
diff --git a/src/include/access/subtrans.h b/src/include/access/subtrans.h
index 9ad51976b5..01acd45d1a 100644
--- a/src/include/access/subtrans.h
+++ b/src/include/access/subtrans.h
@@ -3,7 +3,7 @@
*
* PostgreSQL subtransaction-log manager
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/subtrans.h
diff --git a/src/include/access/sysattr.h b/src/include/access/sysattr.h
index 5f9264dd88..1b3e64aaf8 100644
--- a/src/include/access/sysattr.h
+++ b/src/include/access/sysattr.h
@@ -4,7 +4,7 @@
* POSTGRES system attribute definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/sysattr.h
diff --git a/src/include/access/transam.h b/src/include/access/transam.h
index a7ae7528ec..c5e6ab0ca4 100644
--- a/src/include/access/transam.h
+++ b/src/include/access/transam.h
@@ -4,7 +4,7 @@
* postgres transaction access method support code
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/transam.h
diff --git a/src/include/access/tupconvert.h b/src/include/access/tupconvert.h
index 8b5ff2818c..ab79f09fe8 100644
--- a/src/include/access/tupconvert.h
+++ b/src/include/access/tupconvert.h
@@ -4,7 +4,7 @@
* Tuple conversion support.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/tupconvert.h
diff --git a/src/include/access/tupdesc.h b/src/include/access/tupdesc.h
index f9f2900919..3b0710e2dc 100644
--- a/src/include/access/tupdesc.h
+++ b/src/include/access/tupdesc.h
@@ -4,7 +4,7 @@
* POSTGRES tuple descriptor definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/tupdesc.h
diff --git a/src/include/access/tupmacs.h b/src/include/access/tupmacs.h
index 4173b81000..38e65a807b 100644
--- a/src/include/access/tupmacs.h
+++ b/src/include/access/tupmacs.h
@@ -4,7 +4,7 @@
* Tuple macros used by both index tuples and heap tuples.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/tupmacs.h
diff --git a/src/include/access/tuptoaster.h b/src/include/access/tuptoaster.h
index ae50bdcae8..977e0b4748 100644
--- a/src/include/access/tuptoaster.h
+++ b/src/include/access/tuptoaster.h
@@ -4,7 +4,7 @@
* POSTGRES definitions for external and compressed storage
* of variable size attributes.
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/include/access/tuptoaster.h
*
diff --git a/src/include/access/twophase.h b/src/include/access/twophase.h
index 7f30d6ce18..799bf8bf38 100644
--- a/src/include/access/twophase.h
+++ b/src/include/access/twophase.h
@@ -4,7 +4,7 @@
* Two-phase-commit related declarations.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/twophase.h
diff --git a/src/include/access/twophase_rmgr.h b/src/include/access/twophase_rmgr.h
index 0dba7cfb15..a541d0fce7 100644
--- a/src/include/access/twophase_rmgr.h
+++ b/src/include/access/twophase_rmgr.h
@@ -4,7 +4,7 @@
* Two-phase-commit resource managers definition
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/twophase_rmgr.h
diff --git a/src/include/access/valid.h b/src/include/access/valid.h
index a679c6a60c..e81f4cb723 100644
--- a/src/include/access/valid.h
+++ b/src/include/access/valid.h
@@ -4,7 +4,7 @@
* POSTGRES tuple qualification validity definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/valid.h
diff --git a/src/include/access/visibilitymap.h b/src/include/access/visibilitymap.h
index be22bb9f1b..689060bc15 100644
--- a/src/include/access/visibilitymap.h
+++ b/src/include/access/visibilitymap.h
@@ -4,7 +4,7 @@
* visibility map interface
*
*
- * Portions Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2007-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/visibilitymap.h
diff --git a/src/include/access/xact.h b/src/include/access/xact.h
index ff391726b2..902e99e815 100644
--- a/src/include/access/xact.h
+++ b/src/include/access/xact.h
@@ -4,7 +4,7 @@
* postgres transaction system definitions
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/xact.h
diff --git a/src/include/access/xlog.h b/src/include/access/xlog.h
index e9d8d15814..2ed1c640ed 100644
--- a/src/include/access/xlog.h
+++ b/src/include/access/xlog.h
@@ -3,7 +3,7 @@
*
* PostgreSQL transaction log manager
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/xlog.h
diff --git a/src/include/access/xlog_internal.h b/src/include/access/xlog_internal.h
index feae4563e1..ba640359cc 100644
--- a/src/include/access/xlog_internal.h
+++ b/src/include/access/xlog_internal.h
@@ -8,7 +8,7 @@
* needed by rmgr routines (redo support for individual record types).
* So the XLogRecord typedef and associated stuff appear in xlog.h.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/xlog_internal.h
diff --git a/src/include/access/xlogdefs.h b/src/include/access/xlogdefs.h
index 072096ddff..9078f3eb4e 100644
--- a/src/include/access/xlogdefs.h
+++ b/src/include/access/xlogdefs.h
@@ -4,7 +4,7 @@
* Postgres transaction log manager record pointer and
* timeline number definitions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/xlogdefs.h
diff --git a/src/include/access/xlogutils.h b/src/include/access/xlogutils.h
index cda5b8e162..bc3db143eb 100644
--- a/src/include/access/xlogutils.h
+++ b/src/include/access/xlogutils.h
@@ -3,7 +3,7 @@
*
* PostgreSQL transaction log manager utility routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/access/xlogutils.h
diff --git a/src/include/bootstrap/bootstrap.h b/src/include/bootstrap/bootstrap.h
index 90ab1ce6d8..cee9bd1fa4 100644
--- a/src/include/bootstrap/bootstrap.h
+++ b/src/include/bootstrap/bootstrap.h
@@ -4,7 +4,7 @@
* include file for the bootstrapping code
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/bootstrap/bootstrap.h
diff --git a/src/include/c.h b/src/include/c.h
index 0686ad3d07..634b21fa94 100644
--- a/src/include/c.h
+++ b/src/include/c.h
@@ -9,7 +9,7 @@
* polluting the namespace with lots of stuff...
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/c.h
diff --git a/src/include/catalog/catalog.h b/src/include/catalog/catalog.h
index 40cb9ff2e4..bb3aa781f2 100644
--- a/src/include/catalog/catalog.h
+++ b/src/include/catalog/catalog.h
@@ -4,7 +4,7 @@
* prototypes for functions in backend/catalog/catalog.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/catalog.h
diff --git a/src/include/catalog/catversion.h b/src/include/catalog/catversion.h
index b44991de80..ac13a27830 100644
--- a/src/include/catalog/catversion.h
+++ b/src/include/catalog/catversion.h
@@ -34,7 +34,7 @@
* database contents or layout, such as altering tuple headers.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/catversion.h
diff --git a/src/include/catalog/dependency.h b/src/include/catalog/dependency.h
index 87f853d0e5..5de61f1b26 100644
--- a/src/include/catalog/dependency.h
+++ b/src/include/catalog/dependency.h
@@ -4,7 +4,7 @@
* Routines to support inter-object dependencies.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/dependency.h
diff --git a/src/include/catalog/genbki.h b/src/include/catalog/genbki.h
index 7cd57befa9..7915b3745a 100644
--- a/src/include/catalog/genbki.h
+++ b/src/include/catalog/genbki.h
@@ -9,7 +9,7 @@
* bootstrap file from these header files.)
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/genbki.h
diff --git a/src/include/catalog/heap.h b/src/include/catalog/heap.h
index 646ab9c8f1..f62536a8b2 100644
--- a/src/include/catalog/heap.h
+++ b/src/include/catalog/heap.h
@@ -4,7 +4,7 @@
* prototypes for functions in backend/catalog/heap.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/heap.h
diff --git a/src/include/catalog/index.h b/src/include/catalog/index.h
index 66a6002ab8..2804c6338e 100644
--- a/src/include/catalog/index.h
+++ b/src/include/catalog/index.h
@@ -4,7 +4,7 @@
* prototypes for catalog/index.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/index.h
diff --git a/src/include/catalog/indexing.h b/src/include/catalog/indexing.h
index 1542c8d5f4..de11e440e8 100644
--- a/src/include/catalog/indexing.h
+++ b/src/include/catalog/indexing.h
@@ -5,7 +5,7 @@
* on system catalogs
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/indexing.h
diff --git a/src/include/catalog/namespace.h b/src/include/catalog/namespace.h
index a842ea7ee6..d2381fbadb 100644
--- a/src/include/catalog/namespace.h
+++ b/src/include/catalog/namespace.h
@@ -4,7 +4,7 @@
* prototypes for functions in backend/catalog/namespace.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/namespace.h
diff --git a/src/include/catalog/objectaccess.h b/src/include/catalog/objectaccess.h
index 88508b0103..f1eace251a 100644
--- a/src/include/catalog/objectaccess.h
+++ b/src/include/catalog/objectaccess.h
@@ -3,7 +3,7 @@
*
* Object access hooks.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*/
diff --git a/src/include/catalog/objectaddress.h b/src/include/catalog/objectaddress.h
index 1831fd01ee..36d18ce0bc 100644
--- a/src/include/catalog/objectaddress.h
+++ b/src/include/catalog/objectaddress.h
@@ -3,7 +3,7 @@
* objectaddress.h
* functions for working with object addresses
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/objectaddress.h
diff --git a/src/include/catalog/pg_aggregate.h b/src/include/catalog/pg_aggregate.h
index 5ac3492bc6..26966d2837 100644
--- a/src/include/catalog/pg_aggregate.h
+++ b/src/include/catalog/pg_aggregate.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_aggregate.h
diff --git a/src/include/catalog/pg_am.h b/src/include/catalog/pg_am.h
index 1aa43a9e35..a0822dbee6 100644
--- a/src/include/catalog/pg_am.h
+++ b/src/include/catalog/pg_am.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_am.h
diff --git a/src/include/catalog/pg_amop.h b/src/include/catalog/pg_amop.h
index 4e0727e8e7..aabb900ddc 100644
--- a/src/include/catalog/pg_amop.h
+++ b/src/include/catalog/pg_amop.h
@@ -30,7 +30,7 @@
* intentional denormalization of the catalogs to buy lookup speed.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_amop.h
diff --git a/src/include/catalog/pg_amproc.h b/src/include/catalog/pg_amproc.h
index 4e2bfbab93..9e2da2c30b 100644
--- a/src/include/catalog/pg_amproc.h
+++ b/src/include/catalog/pg_amproc.h
@@ -19,7 +19,7 @@
* some don't pay attention to non-default functions at all.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_amproc.h
diff --git a/src/include/catalog/pg_attrdef.h b/src/include/catalog/pg_attrdef.h
index d55479b6bc..f6513b77b3 100644
--- a/src/include/catalog/pg_attrdef.h
+++ b/src/include/catalog/pg_attrdef.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_attrdef.h
diff --git a/src/include/catalog/pg_attribute.h b/src/include/catalog/pg_attribute.h
index 2a1b593c34..1845c8d37c 100644
--- a/src/include/catalog/pg_attribute.h
+++ b/src/include/catalog/pg_attribute.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_attribute.h
diff --git a/src/include/catalog/pg_auth_members.h b/src/include/catalog/pg_auth_members.h
index 91e4dd1dc3..2a24b863f2 100644
--- a/src/include/catalog/pg_auth_members.h
+++ b/src/include/catalog/pg_auth_members.h
@@ -5,7 +5,7 @@
* (pg_auth_members) along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_auth_members.h
diff --git a/src/include/catalog/pg_authid.h b/src/include/catalog/pg_authid.h
index b6d18385f4..7eee4cb5cb 100644
--- a/src/include/catalog/pg_authid.h
+++ b/src/include/catalog/pg_authid.h
@@ -7,7 +7,7 @@
* pg_shadow and pg_group are now publicly accessible views on pg_authid.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_authid.h
diff --git a/src/include/catalog/pg_cast.h b/src/include/catalog/pg_cast.h
index 7e33b94b8f..bf8a6fcb77 100644
--- a/src/include/catalog/pg_cast.h
+++ b/src/include/catalog/pg_cast.h
@@ -8,7 +8,7 @@
* but also length coercion functions.
*
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* src/include/catalog/pg_cast.h
*
diff --git a/src/include/catalog/pg_class.h b/src/include/catalog/pg_class.h
index 39f9743990..f0cff76e3a 100644
--- a/src/include/catalog/pg_class.h
+++ b/src/include/catalog/pg_class.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_class.h
diff --git a/src/include/catalog/pg_constraint.h b/src/include/catalog/pg_constraint.h
index 49e7c31d86..26dbcace4f 100644
--- a/src/include/catalog/pg_constraint.h
+++ b/src/include/catalog/pg_constraint.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_constraint.h
diff --git a/src/include/catalog/pg_control.h b/src/include/catalog/pg_control.h
index d386165933..ddf139857d 100644
--- a/src/include/catalog/pg_control.h
+++ b/src/include/catalog/pg_control.h
@@ -5,7 +5,7 @@
* However, we define it here so that the format is documented.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_control.h
diff --git a/src/include/catalog/pg_conversion.h b/src/include/catalog/pg_conversion.h
index c3a3b3c830..f2789b3daa 100644
--- a/src/include/catalog/pg_conversion.h
+++ b/src/include/catalog/pg_conversion.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_conversion.h
diff --git a/src/include/catalog/pg_conversion_fn.h b/src/include/catalog/pg_conversion_fn.h
index 01b9355510..95af90189d 100644
--- a/src/include/catalog/pg_conversion_fn.h
+++ b/src/include/catalog/pg_conversion_fn.h
@@ -4,7 +4,7 @@
* prototypes for functions in catalog/pg_conversion.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_conversion_fn.h
diff --git a/src/include/catalog/pg_database.h b/src/include/catalog/pg_database.h
index bfed2e2bdc..6419d65682 100644
--- a/src/include/catalog/pg_database.h
+++ b/src/include/catalog/pg_database.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_database.h
diff --git a/src/include/catalog/pg_db_role_setting.h b/src/include/catalog/pg_db_role_setting.h
index 64816b1b77..cda9b72827 100644
--- a/src/include/catalog/pg_db_role_setting.h
+++ b/src/include/catalog/pg_db_role_setting.h
@@ -4,7 +4,7 @@
* definition of configuration settings
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_db_role_setting.h
diff --git a/src/include/catalog/pg_default_acl.h b/src/include/catalog/pg_default_acl.h
index 8f2d88ef3d..96e9f0c4c6 100644
--- a/src/include/catalog/pg_default_acl.h
+++ b/src/include/catalog/pg_default_acl.h
@@ -4,7 +4,7 @@
* definition of default ACLs for new objects.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_default_acl.h
diff --git a/src/include/catalog/pg_depend.h b/src/include/catalog/pg_depend.h
index 6d78250339..9215eaf370 100644
--- a/src/include/catalog/pg_depend.h
+++ b/src/include/catalog/pg_depend.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_depend.h
diff --git a/src/include/catalog/pg_description.h b/src/include/catalog/pg_description.h
index e75560e0ab..bb7234e2ec 100644
--- a/src/include/catalog/pg_description.h
+++ b/src/include/catalog/pg_description.h
@@ -19,7 +19,7 @@
* for example).
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_description.h
diff --git a/src/include/catalog/pg_enum.h b/src/include/catalog/pg_enum.h
index cc69eb531c..a0fca30019 100644
--- a/src/include/catalog/pg_enum.h
+++ b/src/include/catalog/pg_enum.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Copyright (c) 2006-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2006-2011, PostgreSQL Global Development Group
*
* src/include/catalog/pg_enum.h
*
diff --git a/src/include/catalog/pg_foreign_data_wrapper.h b/src/include/catalog/pg_foreign_data_wrapper.h
index 6dd01e60f6..a83556df15 100644
--- a/src/include/catalog/pg_foreign_data_wrapper.h
+++ b/src/include/catalog/pg_foreign_data_wrapper.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_foreign_data_wrapper.h
diff --git a/src/include/catalog/pg_foreign_server.h b/src/include/catalog/pg_foreign_server.h
index bb1e0a2f81..f2ce32dc1d 100644
--- a/src/include/catalog/pg_foreign_server.h
+++ b/src/include/catalog/pg_foreign_server.h
@@ -3,7 +3,7 @@
* pg_foreign_server.h
* definition of the system "foreign server" relation (pg_foreign_server)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_foreign_server.h
diff --git a/src/include/catalog/pg_index.h b/src/include/catalog/pg_index.h
index 3811e73363..9bdf4da043 100644
--- a/src/include/catalog/pg_index.h
+++ b/src/include/catalog/pg_index.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_index.h
diff --git a/src/include/catalog/pg_inherits.h b/src/include/catalog/pg_inherits.h
index 74acd0516c..53e6aff3bf 100644
--- a/src/include/catalog/pg_inherits.h
+++ b/src/include/catalog/pg_inherits.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_inherits.h
diff --git a/src/include/catalog/pg_inherits_fn.h b/src/include/catalog/pg_inherits_fn.h
index 42c703ebe0..3fb318d875 100644
--- a/src/include/catalog/pg_inherits_fn.h
+++ b/src/include/catalog/pg_inherits_fn.h
@@ -4,7 +4,7 @@
* prototypes for functions in catalog/pg_inherits.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_inherits_fn.h
diff --git a/src/include/catalog/pg_language.h b/src/include/catalog/pg_language.h
index f9d7bda3c9..2ffd8c18fc 100644
--- a/src/include/catalog/pg_language.h
+++ b/src/include/catalog/pg_language.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_language.h
diff --git a/src/include/catalog/pg_largeobject.h b/src/include/catalog/pg_largeobject.h
index 87a02035f0..7672de7947 100644
--- a/src/include/catalog/pg_largeobject.h
+++ b/src/include/catalog/pg_largeobject.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_largeobject.h
diff --git a/src/include/catalog/pg_largeobject_metadata.h b/src/include/catalog/pg_largeobject_metadata.h
index b3dc19c610..5fe305736d 100644
--- a/src/include/catalog/pg_largeobject_metadata.h
+++ b/src/include/catalog/pg_largeobject_metadata.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_largeobject_metadata.h
diff --git a/src/include/catalog/pg_namespace.h b/src/include/catalog/pg_namespace.h
index 1d866d4dc6..680802d7fe 100644
--- a/src/include/catalog/pg_namespace.h
+++ b/src/include/catalog/pg_namespace.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_namespace.h
diff --git a/src/include/catalog/pg_opclass.h b/src/include/catalog/pg_opclass.h
index 7236ce60c2..d723b2561a 100644
--- a/src/include/catalog/pg_opclass.h
+++ b/src/include/catalog/pg_opclass.h
@@ -25,7 +25,7 @@
* AMs support this.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_opclass.h
diff --git a/src/include/catalog/pg_operator.h b/src/include/catalog/pg_operator.h
index b9405f9077..b69b60aa5b 100644
--- a/src/include/catalog/pg_operator.h
+++ b/src/include/catalog/pg_operator.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_operator.h
diff --git a/src/include/catalog/pg_opfamily.h b/src/include/catalog/pg_opfamily.h
index 252d3b9dbe..548727dbd2 100644
--- a/src/include/catalog/pg_opfamily.h
+++ b/src/include/catalog/pg_opfamily.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_opfamily.h
diff --git a/src/include/catalog/pg_pltemplate.h b/src/include/catalog/pg_pltemplate.h
index 6befcfad7f..d987ddc40e 100644
--- a/src/include/catalog/pg_pltemplate.h
+++ b/src/include/catalog/pg_pltemplate.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_pltemplate.h
diff --git a/src/include/catalog/pg_proc.h b/src/include/catalog/pg_proc.h
index c6242433b7..386c34a59a 100644
--- a/src/include/catalog/pg_proc.h
+++ b/src/include/catalog/pg_proc.h
@@ -4,7 +4,7 @@
* definition of the system "procedure" relation (pg_proc)
* along with the relation's initial contents.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_proc.h
diff --git a/src/include/catalog/pg_proc_fn.h b/src/include/catalog/pg_proc_fn.h
index 0843201355..09d779f321 100644
--- a/src/include/catalog/pg_proc_fn.h
+++ b/src/include/catalog/pg_proc_fn.h
@@ -4,7 +4,7 @@
* prototypes for functions in catalog/pg_proc.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_proc_fn.h
diff --git a/src/include/catalog/pg_rewrite.h b/src/include/catalog/pg_rewrite.h
index 028d6aa902..d370829ea4 100644
--- a/src/include/catalog/pg_rewrite.h
+++ b/src/include/catalog/pg_rewrite.h
@@ -8,7 +8,7 @@
* --- ie, rule names are only unique among the rules of a given table.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_rewrite.h
diff --git a/src/include/catalog/pg_seclabel.h b/src/include/catalog/pg_seclabel.h
index 67ad213beb..f41b85a368 100644
--- a/src/include/catalog/pg_seclabel.h
+++ b/src/include/catalog/pg_seclabel.h
@@ -3,7 +3,7 @@
* pg_seclabel.h
* definition of the system "security label" relation (pg_seclabel)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* -------------------------------------------------------------------------
diff --git a/src/include/catalog/pg_shdepend.h b/src/include/catalog/pg_shdepend.h
index d44fc574a6..20465ccd49 100644
--- a/src/include/catalog/pg_shdepend.h
+++ b/src/include/catalog/pg_shdepend.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_shdepend.h
diff --git a/src/include/catalog/pg_shdescription.h b/src/include/catalog/pg_shdescription.h
index 483aad280e..c7757feb58 100644
--- a/src/include/catalog/pg_shdescription.h
+++ b/src/include/catalog/pg_shdescription.h
@@ -12,7 +12,7 @@
* across tables.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_shdescription.h
diff --git a/src/include/catalog/pg_statistic.h b/src/include/catalog/pg_statistic.h
index 246a98d46e..f38921f1c6 100644
--- a/src/include/catalog/pg_statistic.h
+++ b/src/include/catalog/pg_statistic.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_statistic.h
diff --git a/src/include/catalog/pg_tablespace.h b/src/include/catalog/pg_tablespace.h
index e165dd0d73..a1f5688c46 100644
--- a/src/include/catalog/pg_tablespace.h
+++ b/src/include/catalog/pg_tablespace.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_tablespace.h
diff --git a/src/include/catalog/pg_trigger.h b/src/include/catalog/pg_trigger.h
index 4eb72f2091..4f26f8e0c5 100644
--- a/src/include/catalog/pg_trigger.h
+++ b/src/include/catalog/pg_trigger.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_trigger.h
diff --git a/src/include/catalog/pg_ts_config.h b/src/include/catalog/pg_ts_config.h
index 386402de97..2f07ccb047 100644
--- a/src/include/catalog/pg_ts_config.h
+++ b/src/include/catalog/pg_ts_config.h
@@ -4,7 +4,7 @@
* definition of configuration of tsearch
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_config.h
diff --git a/src/include/catalog/pg_ts_config_map.h b/src/include/catalog/pg_ts_config_map.h
index eb370ef437..0ce9a573b2 100644
--- a/src/include/catalog/pg_ts_config_map.h
+++ b/src/include/catalog/pg_ts_config_map.h
@@ -4,7 +4,7 @@
* definition of token mappings for configurations of tsearch
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_config_map.h
diff --git a/src/include/catalog/pg_ts_dict.h b/src/include/catalog/pg_ts_dict.h
index 1f03e87884..a4fdb7a16f 100644
--- a/src/include/catalog/pg_ts_dict.h
+++ b/src/include/catalog/pg_ts_dict.h
@@ -4,7 +4,7 @@
* definition of dictionaries for tsearch
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_dict.h
diff --git a/src/include/catalog/pg_ts_parser.h b/src/include/catalog/pg_ts_parser.h
index c70d6d5046..7b34f36b87 100644
--- a/src/include/catalog/pg_ts_parser.h
+++ b/src/include/catalog/pg_ts_parser.h
@@ -4,7 +4,7 @@
* definition of parsers for tsearch
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_parser.h
diff --git a/src/include/catalog/pg_ts_template.h b/src/include/catalog/pg_ts_template.h
index 510eec4430..1071c4414a 100644
--- a/src/include/catalog/pg_ts_template.h
+++ b/src/include/catalog/pg_ts_template.h
@@ -4,7 +4,7 @@
* definition of dictionary templates for tsearch
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_ts_template.h
diff --git a/src/include/catalog/pg_type.h b/src/include/catalog/pg_type.h
index 201e5dbc1f..620f7b4612 100644
--- a/src/include/catalog/pg_type.h
+++ b/src/include/catalog/pg_type.h
@@ -5,7 +5,7 @@
* along with the relation's initial contents.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_type.h
diff --git a/src/include/catalog/pg_type_fn.h b/src/include/catalog/pg_type_fn.h
index cc7235071e..836e216178 100644
--- a/src/include/catalog/pg_type_fn.h
+++ b/src/include/catalog/pg_type_fn.h
@@ -4,7 +4,7 @@
* prototypes for functions in catalog/pg_type.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_type_fn.h
diff --git a/src/include/catalog/pg_user_mapping.h b/src/include/catalog/pg_user_mapping.h
index 394ee181d6..9f7cc92105 100644
--- a/src/include/catalog/pg_user_mapping.h
+++ b/src/include/catalog/pg_user_mapping.h
@@ -3,7 +3,7 @@
* pg_user_mapping.h
* definition of the system "user mapping" relation (pg_user_mapping)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/pg_user_mapping.h
diff --git a/src/include/catalog/storage.h b/src/include/catalog/storage.h
index e2a1fecdf5..0b93b370bd 100644
--- a/src/include/catalog/storage.h
+++ b/src/include/catalog/storage.h
@@ -4,7 +4,7 @@
* prototypes for functions in backend/catalog/storage.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/storage.h
diff --git a/src/include/catalog/toasting.h b/src/include/catalog/toasting.h
index 68a0257742..de3623ac7a 100644
--- a/src/include/catalog/toasting.h
+++ b/src/include/catalog/toasting.h
@@ -4,7 +4,7 @@
* This file provides some definitions to support creation of toast tables
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/catalog/toasting.h
diff --git a/src/include/commands/alter.h b/src/include/commands/alter.h
index a833f19a73..74d5132636 100644
--- a/src/include/commands/alter.h
+++ b/src/include/commands/alter.h
@@ -4,7 +4,7 @@
* prototypes for commands/alter.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/alter.h
diff --git a/src/include/commands/async.h b/src/include/commands/async.h
index 58bb594254..9ca7a29ac7 100644
--- a/src/include/commands/async.h
+++ b/src/include/commands/async.h
@@ -3,7 +3,7 @@
* async.h
* Asynchronous notification: NOTIFY, LISTEN, UNLISTEN
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/async.h
diff --git a/src/include/commands/cluster.h b/src/include/commands/cluster.h
index 29a55be7f3..427d802a0b 100644
--- a/src/include/commands/cluster.h
+++ b/src/include/commands/cluster.h
@@ -3,7 +3,7 @@
* cluster.h
* header file for postgres cluster command stuff
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994-5, Regents of the University of California
*
* src/include/commands/cluster.h
diff --git a/src/include/commands/comment.h b/src/include/commands/comment.h
index bc16536805..1b12e81bdd 100644
--- a/src/include/commands/comment.h
+++ b/src/include/commands/comment.h
@@ -7,7 +7,7 @@
*
* Prototypes for functions in commands/comment.c
*
- * Copyright (c) 1999-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1999-2011, PostgreSQL Global Development Group
*
*-------------------------------------------------------------------------
*/
diff --git a/src/include/commands/conversioncmds.h b/src/include/commands/conversioncmds.h
index 41056ea320..6156c4a94e 100644
--- a/src/include/commands/conversioncmds.h
+++ b/src/include/commands/conversioncmds.h
@@ -4,7 +4,7 @@
* prototypes for conversioncmds.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/conversioncmds.h
diff --git a/src/include/commands/copy.h b/src/include/commands/copy.h
index 6d409e8bac..9e2bbe8d8e 100644
--- a/src/include/commands/copy.h
+++ b/src/include/commands/copy.h
@@ -4,7 +4,7 @@
* Definitions for using the POSTGRES copy command.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/copy.h
diff --git a/src/include/commands/dbcommands.h b/src/include/commands/dbcommands.h
index 3d767c8fd1..809754792a 100644
--- a/src/include/commands/dbcommands.h
+++ b/src/include/commands/dbcommands.h
@@ -4,7 +4,7 @@
* Database management commands (create/drop database).
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/dbcommands.h
diff --git a/src/include/commands/defrem.h b/src/include/commands/defrem.h
index 86d62af9ed..82ec446c0e 100644
--- a/src/include/commands/defrem.h
+++ b/src/include/commands/defrem.h
@@ -4,7 +4,7 @@
* POSTGRES define and remove utility definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/defrem.h
diff --git a/src/include/commands/discard.h b/src/include/commands/discard.h
index 6e2e52f13f..0413d93c99 100644
--- a/src/include/commands/discard.h
+++ b/src/include/commands/discard.h
@@ -4,7 +4,7 @@
* prototypes for discard.c.
*
*
- * Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/commands/discard.h
*
diff --git a/src/include/commands/explain.h b/src/include/commands/explain.h
index 760ba2273c..f17548338f 100644
--- a/src/include/commands/explain.h
+++ b/src/include/commands/explain.h
@@ -3,7 +3,7 @@
* explain.h
* prototypes for explain.c
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994-5, Regents of the University of California
*
* src/include/commands/explain.h
diff --git a/src/include/commands/lockcmds.h b/src/include/commands/lockcmds.h
index 52de59a448..f6506dee94 100644
--- a/src/include/commands/lockcmds.h
+++ b/src/include/commands/lockcmds.h
@@ -4,7 +4,7 @@
* prototypes for lockcmds.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/lockcmds.h
diff --git a/src/include/commands/portalcmds.h b/src/include/commands/portalcmds.h
index f7d4335be4..c64aabf0ba 100644
--- a/src/include/commands/portalcmds.h
+++ b/src/include/commands/portalcmds.h
@@ -4,7 +4,7 @@
* prototypes for portalcmds.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/portalcmds.h
diff --git a/src/include/commands/prepare.h b/src/include/commands/prepare.h
index 68251cd638..4375fdbafe 100644
--- a/src/include/commands/prepare.h
+++ b/src/include/commands/prepare.h
@@ -4,7 +4,7 @@
* PREPARE, EXECUTE and DEALLOCATE commands, and prepared-stmt storage
*
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* src/include/commands/prepare.h
*
diff --git a/src/include/commands/schemacmds.h b/src/include/commands/schemacmds.h
index 760d147e60..a9f8f6cb5d 100644
--- a/src/include/commands/schemacmds.h
+++ b/src/include/commands/schemacmds.h
@@ -4,7 +4,7 @@
* prototypes for schemacmds.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/schemacmds.h
diff --git a/src/include/commands/seclabel.h b/src/include/commands/seclabel.h
index 4c3854e60c..1ae922b7e9 100644
--- a/src/include/commands/seclabel.h
+++ b/src/include/commands/seclabel.h
@@ -3,7 +3,7 @@
*
* Prototypes for functions in commands/seclabel.c
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*/
#ifndef SECLABEL_H
diff --git a/src/include/commands/sequence.h b/src/include/commands/sequence.h
index b747125c77..932e20351c 100644
--- a/src/include/commands/sequence.h
+++ b/src/include/commands/sequence.h
@@ -3,7 +3,7 @@
* sequence.h
* prototypes for sequence.c.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/sequence.h
diff --git a/src/include/commands/tablecmds.h b/src/include/commands/tablecmds.h
index ad932d3979..d3deffb3b8 100644
--- a/src/include/commands/tablecmds.h
+++ b/src/include/commands/tablecmds.h
@@ -4,7 +4,7 @@
* prototypes for tablecmds.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/tablecmds.h
diff --git a/src/include/commands/tablespace.h b/src/include/commands/tablespace.h
index 1e3f6ca0c6..4692098a65 100644
--- a/src/include/commands/tablespace.h
+++ b/src/include/commands/tablespace.h
@@ -4,7 +4,7 @@
* Tablespace management commands (create/drop tablespace).
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/tablespace.h
diff --git a/src/include/commands/trigger.h b/src/include/commands/trigger.h
index 30dc314c00..c213ac7a4e 100644
--- a/src/include/commands/trigger.h
+++ b/src/include/commands/trigger.h
@@ -3,7 +3,7 @@
* trigger.h
* Declarations for trigger handling.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/trigger.h
diff --git a/src/include/commands/typecmds.h b/src/include/commands/typecmds.h
index 4c6e7e164e..b13363aaf7 100644
--- a/src/include/commands/typecmds.h
+++ b/src/include/commands/typecmds.h
@@ -4,7 +4,7 @@
* prototypes for typecmds.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/typecmds.h
diff --git a/src/include/commands/vacuum.h b/src/include/commands/vacuum.h
index ed50a399ca..93f894e639 100644
--- a/src/include/commands/vacuum.h
+++ b/src/include/commands/vacuum.h
@@ -4,7 +4,7 @@
* header file for postgres vacuum cleaner and statistics analyzer
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/vacuum.h
diff --git a/src/include/commands/variable.h b/src/include/commands/variable.h
index dbd1fa23f5..7ac8ed8f9f 100644
--- a/src/include/commands/variable.h
+++ b/src/include/commands/variable.h
@@ -2,7 +2,7 @@
* variable.h
* Routines for handling specialized SET variables.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/variable.h
diff --git a/src/include/commands/view.h b/src/include/commands/view.h
index cffd1a0e17..9751e32322 100644
--- a/src/include/commands/view.h
+++ b/src/include/commands/view.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/commands/view.h
diff --git a/src/include/executor/execdebug.h b/src/include/executor/execdebug.h
index 5f713a46e7..81cf3df605 100644
--- a/src/include/executor/execdebug.h
+++ b/src/include/executor/execdebug.h
@@ -7,7 +7,7 @@
* for debug printouts, because that's more flexible than printf().
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/execdebug.h
diff --git a/src/include/executor/execdesc.h b/src/include/executor/execdesc.h
index 4fb57d2148..1a636a0987 100644
--- a/src/include/executor/execdesc.h
+++ b/src/include/executor/execdesc.h
@@ -5,7 +5,7 @@
* and related modules.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/execdesc.h
diff --git a/src/include/executor/executor.h b/src/include/executor/executor.h
index 1dddb032b5..36f0e67797 100644
--- a/src/include/executor/executor.h
+++ b/src/include/executor/executor.h
@@ -4,7 +4,7 @@
* support for the POSTGRES executor module
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/executor.h
diff --git a/src/include/executor/functions.h b/src/include/executor/functions.h
index e9ed96c5fb..e725b24be2 100644
--- a/src/include/executor/functions.h
+++ b/src/include/executor/functions.h
@@ -4,7 +4,7 @@
* Declarations for execution of SQL-language functions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/functions.h
diff --git a/src/include/executor/hashjoin.h b/src/include/executor/hashjoin.h
index c4aa0d3726..5ea165434a 100644
--- a/src/include/executor/hashjoin.h
+++ b/src/include/executor/hashjoin.h
@@ -4,7 +4,7 @@
* internal structures for hash joins
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/hashjoin.h
diff --git a/src/include/executor/instrument.h b/src/include/executor/instrument.h
index 0634308f7d..286cd54063 100644
--- a/src/include/executor/instrument.h
+++ b/src/include/executor/instrument.h
@@ -4,7 +4,7 @@
* definitions for run-time statistics collection
*
*
- * Copyright (c) 2001-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2001-2011, PostgreSQL Global Development Group
*
* src/include/executor/instrument.h
*
diff --git a/src/include/executor/nodeAgg.h b/src/include/executor/nodeAgg.h
index e551fc82b5..644a217682 100644
--- a/src/include/executor/nodeAgg.h
+++ b/src/include/executor/nodeAgg.h
@@ -4,7 +4,7 @@
* prototypes for nodeAgg.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeAgg.h
diff --git a/src/include/executor/nodeAppend.h b/src/include/executor/nodeAppend.h
index b7848c8610..d51618ec01 100644
--- a/src/include/executor/nodeAppend.h
+++ b/src/include/executor/nodeAppend.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeAppend.h
diff --git a/src/include/executor/nodeBitmapAnd.h b/src/include/executor/nodeBitmapAnd.h
index 248c1cc001..3e702db43a 100644
--- a/src/include/executor/nodeBitmapAnd.h
+++ b/src/include/executor/nodeBitmapAnd.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeBitmapAnd.h
diff --git a/src/include/executor/nodeBitmapHeapscan.h b/src/include/executor/nodeBitmapHeapscan.h
index 11c306d05c..87abe8ede3 100644
--- a/src/include/executor/nodeBitmapHeapscan.h
+++ b/src/include/executor/nodeBitmapHeapscan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeBitmapHeapscan.h
diff --git a/src/include/executor/nodeBitmapIndexscan.h b/src/include/executor/nodeBitmapIndexscan.h
index d87db32798..2ea186bd35 100644
--- a/src/include/executor/nodeBitmapIndexscan.h
+++ b/src/include/executor/nodeBitmapIndexscan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeBitmapIndexscan.h
diff --git a/src/include/executor/nodeBitmapOr.h b/src/include/executor/nodeBitmapOr.h
index a62b41049d..5a449a778a 100644
--- a/src/include/executor/nodeBitmapOr.h
+++ b/src/include/executor/nodeBitmapOr.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeBitmapOr.h
diff --git a/src/include/executor/nodeCtescan.h b/src/include/executor/nodeCtescan.h
index 550ca722db..9b2c2bf7af 100644
--- a/src/include/executor/nodeCtescan.h
+++ b/src/include/executor/nodeCtescan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeCtescan.h
diff --git a/src/include/executor/nodeFunctionscan.h b/src/include/executor/nodeFunctionscan.h
index 74224eab35..86e04a7b7e 100644
--- a/src/include/executor/nodeFunctionscan.h
+++ b/src/include/executor/nodeFunctionscan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeFunctionscan.h
diff --git a/src/include/executor/nodeGroup.h b/src/include/executor/nodeGroup.h
index 4ec94497ae..4753b81304 100644
--- a/src/include/executor/nodeGroup.h
+++ b/src/include/executor/nodeGroup.h
@@ -4,7 +4,7 @@
* prototypes for nodeGroup.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeGroup.h
diff --git a/src/include/executor/nodeHash.h b/src/include/executor/nodeHash.h
index 8517d1cf28..4810f4be5e 100644
--- a/src/include/executor/nodeHash.h
+++ b/src/include/executor/nodeHash.h
@@ -4,7 +4,7 @@
* prototypes for nodeHash.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeHash.h
diff --git a/src/include/executor/nodeHashjoin.h b/src/include/executor/nodeHashjoin.h
index 6ce305788d..633fe94a2b 100644
--- a/src/include/executor/nodeHashjoin.h
+++ b/src/include/executor/nodeHashjoin.h
@@ -4,7 +4,7 @@
* prototypes for nodeHashjoin.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeHashjoin.h
diff --git a/src/include/executor/nodeIndexscan.h b/src/include/executor/nodeIndexscan.h
index d1e0f380c0..481a7df70f 100644
--- a/src/include/executor/nodeIndexscan.h
+++ b/src/include/executor/nodeIndexscan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeIndexscan.h
diff --git a/src/include/executor/nodeLimit.h b/src/include/executor/nodeLimit.h
index 078e677b1e..3b889b19ab 100644
--- a/src/include/executor/nodeLimit.h
+++ b/src/include/executor/nodeLimit.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeLimit.h
diff --git a/src/include/executor/nodeLockRows.h b/src/include/executor/nodeLockRows.h
index 6f0d7b2de0..7c704c8506 100644
--- a/src/include/executor/nodeLockRows.h
+++ b/src/include/executor/nodeLockRows.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeLockRows.h
diff --git a/src/include/executor/nodeMaterial.h b/src/include/executor/nodeMaterial.h
index 251779ec23..8f4fdd2b5c 100644
--- a/src/include/executor/nodeMaterial.h
+++ b/src/include/executor/nodeMaterial.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeMaterial.h
diff --git a/src/include/executor/nodeMergeAppend.h b/src/include/executor/nodeMergeAppend.h
index 7e7e494b71..63997eb57e 100644
--- a/src/include/executor/nodeMergeAppend.h
+++ b/src/include/executor/nodeMergeAppend.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeMergeAppend.h
diff --git a/src/include/executor/nodeMergejoin.h b/src/include/executor/nodeMergejoin.h
index 300d74f3d2..ef104ea205 100644
--- a/src/include/executor/nodeMergejoin.h
+++ b/src/include/executor/nodeMergejoin.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeMergejoin.h
diff --git a/src/include/executor/nodeModifyTable.h b/src/include/executor/nodeModifyTable.h
index a8a28a4fde..8d0b689555 100644
--- a/src/include/executor/nodeModifyTable.h
+++ b/src/include/executor/nodeModifyTable.h
@@ -3,7 +3,7 @@
* nodeModifyTable.h
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeModifyTable.h
diff --git a/src/include/executor/nodeNestloop.h b/src/include/executor/nodeNestloop.h
index 90a7389994..f249d9dda6 100644
--- a/src/include/executor/nodeNestloop.h
+++ b/src/include/executor/nodeNestloop.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeNestloop.h
diff --git a/src/include/executor/nodeRecursiveunion.h b/src/include/executor/nodeRecursiveunion.h
index c0dd58483d..d03745b340 100644
--- a/src/include/executor/nodeRecursiveunion.h
+++ b/src/include/executor/nodeRecursiveunion.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeRecursiveunion.h
diff --git a/src/include/executor/nodeResult.h b/src/include/executor/nodeResult.h
index 610e37c266..cf43de36bf 100644
--- a/src/include/executor/nodeResult.h
+++ b/src/include/executor/nodeResult.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeResult.h
diff --git a/src/include/executor/nodeSeqscan.h b/src/include/executor/nodeSeqscan.h
index 03b0d7cb4f..9f07472bef 100644
--- a/src/include/executor/nodeSeqscan.h
+++ b/src/include/executor/nodeSeqscan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeSeqscan.h
diff --git a/src/include/executor/nodeSetOp.h b/src/include/executor/nodeSetOp.h
index ae87ac8518..beb4b32a5c 100644
--- a/src/include/executor/nodeSetOp.h
+++ b/src/include/executor/nodeSetOp.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeSetOp.h
diff --git a/src/include/executor/nodeSort.h b/src/include/executor/nodeSort.h
index 32622bbc96..c8d4ab05b7 100644
--- a/src/include/executor/nodeSort.h
+++ b/src/include/executor/nodeSort.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeSort.h
diff --git a/src/include/executor/nodeSubplan.h b/src/include/executor/nodeSubplan.h
index f7536ea433..a8386b4d6f 100644
--- a/src/include/executor/nodeSubplan.h
+++ b/src/include/executor/nodeSubplan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeSubplan.h
diff --git a/src/include/executor/nodeSubqueryscan.h b/src/include/executor/nodeSubqueryscan.h
index e7f3e24fee..3b0295df62 100644
--- a/src/include/executor/nodeSubqueryscan.h
+++ b/src/include/executor/nodeSubqueryscan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeSubqueryscan.h
diff --git a/src/include/executor/nodeTidscan.h b/src/include/executor/nodeTidscan.h
index adceadf86c..c51850d4e8 100644
--- a/src/include/executor/nodeTidscan.h
+++ b/src/include/executor/nodeTidscan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeTidscan.h
diff --git a/src/include/executor/nodeUnique.h b/src/include/executor/nodeUnique.h
index 3ae950d901..d3227552dc 100644
--- a/src/include/executor/nodeUnique.h
+++ b/src/include/executor/nodeUnique.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeUnique.h
diff --git a/src/include/executor/nodeValuesscan.h b/src/include/executor/nodeValuesscan.h
index 5cb7889286..120946543a 100644
--- a/src/include/executor/nodeValuesscan.h
+++ b/src/include/executor/nodeValuesscan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeValuesscan.h
diff --git a/src/include/executor/nodeWindowAgg.h b/src/include/executor/nodeWindowAgg.h
index de8e35d2d5..17944030b7 100644
--- a/src/include/executor/nodeWindowAgg.h
+++ b/src/include/executor/nodeWindowAgg.h
@@ -4,7 +4,7 @@
* prototypes for nodeWindowAgg.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeWindowAgg.h
diff --git a/src/include/executor/nodeWorktablescan.h b/src/include/executor/nodeWorktablescan.h
index 2b163e7611..50a76344e8 100644
--- a/src/include/executor/nodeWorktablescan.h
+++ b/src/include/executor/nodeWorktablescan.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/nodeWorktablescan.h
diff --git a/src/include/executor/spi.h b/src/include/executor/spi.h
index 96e29b9994..98d194a37d 100644
--- a/src/include/executor/spi.h
+++ b/src/include/executor/spi.h
@@ -3,7 +3,7 @@
* spi.h
* Server Programming Interface public declarations
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/spi.h
diff --git a/src/include/executor/spi_priv.h b/src/include/executor/spi_priv.h
index f14a5e3bdc..5865f53280 100644
--- a/src/include/executor/spi_priv.h
+++ b/src/include/executor/spi_priv.h
@@ -3,7 +3,7 @@
* spi_priv.h
* Server Programming Interface private declarations
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/spi_priv.h
diff --git a/src/include/executor/tstoreReceiver.h b/src/include/executor/tstoreReceiver.h
index 2760cc73d6..d7d5eda74c 100644
--- a/src/include/executor/tstoreReceiver.h
+++ b/src/include/executor/tstoreReceiver.h
@@ -4,7 +4,7 @@
* prototypes for tstoreReceiver.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/tstoreReceiver.h
diff --git a/src/include/executor/tuptable.h b/src/include/executor/tuptable.h
index f72349bc20..f774f2d0ab 100644
--- a/src/include/executor/tuptable.h
+++ b/src/include/executor/tuptable.h
@@ -4,7 +4,7 @@
* tuple table support stuff
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/executor/tuptable.h
diff --git a/src/include/fmgr.h b/src/include/fmgr.h
index 2813b29af5..33369b02bc 100644
--- a/src/include/fmgr.h
+++ b/src/include/fmgr.h
@@ -8,7 +8,7 @@
* or call fmgr-callable functions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/fmgr.h
diff --git a/src/include/foreign/foreign.h b/src/include/foreign/foreign.h
index 2305929b35..2d1495cfe1 100644
--- a/src/include/foreign/foreign.h
+++ b/src/include/foreign/foreign.h
@@ -4,7 +4,7 @@
* support for foreign-data wrappers, servers and user mappings.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/foreign/foreign.h
*
diff --git a/src/include/funcapi.h b/src/include/funcapi.h
index aac4fe3d00..4366fe4187 100644
--- a/src/include/funcapi.h
+++ b/src/include/funcapi.h
@@ -7,7 +7,7 @@
* or call FUNCAPI-callable functions or macros.
*
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* src/include/funcapi.h
*
diff --git a/src/include/getaddrinfo.h b/src/include/getaddrinfo.h
index 249dfbed2c..21c0413247 100644
--- a/src/include/getaddrinfo.h
+++ b/src/include/getaddrinfo.h
@@ -13,7 +13,7 @@
* This code will also work on platforms where struct addrinfo is defined
* in the system headers but no getaddrinfo() can be located.
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* src/include/getaddrinfo.h
*
diff --git a/src/include/getopt_long.h b/src/include/getopt_long.h
index 0589ae67ca..5d16ca4b14 100644
--- a/src/include/getopt_long.h
+++ b/src/include/getopt_long.h
@@ -2,7 +2,7 @@
* Portions Copyright (c) 1987, 1993, 1994
* The Regents of the University of California. All rights reserved.
*
- * Portions Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* src/include/getopt_long.h
*/
diff --git a/src/include/lib/dllist.h b/src/include/lib/dllist.h
index 1e651ecedd..bad302dc18 100644
--- a/src/include/lib/dllist.h
+++ b/src/include/lib/dllist.h
@@ -31,7 +31,7 @@
* freeing the larger object!
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/lib/dllist.h
diff --git a/src/include/lib/stringinfo.h b/src/include/lib/stringinfo.h
index 72f873ebd4..a84988c3f1 100644
--- a/src/include/lib/stringinfo.h
+++ b/src/include/lib/stringinfo.h
@@ -7,7 +7,7 @@
* It can be used to buffer either ordinary C strings (null-terminated text)
* or arbitrary binary data. All storage is allocated with palloc().
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/lib/stringinfo.h
diff --git a/src/include/libpq/auth.h b/src/include/libpq/auth.h
index 32a0293dbd..7d15b73370 100644
--- a/src/include/libpq/auth.h
+++ b/src/include/libpq/auth.h
@@ -4,7 +4,7 @@
* Definitions for network authentication routines
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/auth.h
diff --git a/src/include/libpq/be-fsstubs.h b/src/include/libpq/be-fsstubs.h
index 6583f1c4df..416da75470 100644
--- a/src/include/libpq/be-fsstubs.h
+++ b/src/include/libpq/be-fsstubs.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/be-fsstubs.h
diff --git a/src/include/libpq/crypt.h b/src/include/libpq/crypt.h
index 7d88cccd89..2fdfb926e2 100644
--- a/src/include/libpq/crypt.h
+++ b/src/include/libpq/crypt.h
@@ -3,7 +3,7 @@
* crypt.h
* Interface to libpq/crypt.c
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/crypt.h
diff --git a/src/include/libpq/ip.h b/src/include/libpq/ip.h
index 2bcdbbc8d4..149c1ff9b4 100644
--- a/src/include/libpq/ip.h
+++ b/src/include/libpq/ip.h
@@ -6,7 +6,7 @@
* These definitions are used by both frontend and backend code. Be careful
* what you include here!
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* src/include/libpq/ip.h
*
diff --git a/src/include/libpq/libpq-be.h b/src/include/libpq/libpq-be.h
index 1bc597c6ac..4cdb15f064 100644
--- a/src/include/libpq/libpq-be.h
+++ b/src/include/libpq/libpq-be.h
@@ -8,7 +8,7 @@
* Structs that need to be client-visible are in pqcomm.h.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/libpq-be.h
diff --git a/src/include/libpq/libpq-fs.h b/src/include/libpq/libpq-fs.h
index 93c111bb7a..47053e0cba 100644
--- a/src/include/libpq/libpq-fs.h
+++ b/src/include/libpq/libpq-fs.h
@@ -4,7 +4,7 @@
* definitions for using Inversion file system routines (ie, large objects)
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/libpq-fs.h
diff --git a/src/include/libpq/libpq.h b/src/include/libpq/libpq.h
index 21eb29da2f..8ecab6d5ee 100644
--- a/src/include/libpq/libpq.h
+++ b/src/include/libpq/libpq.h
@@ -4,7 +4,7 @@
* POSTGRES LIBPQ buffer structure definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/libpq.h
diff --git a/src/include/libpq/md5.h b/src/include/libpq/md5.h
index 072ce33860..ffd18d032d 100644
--- a/src/include/libpq/md5.h
+++ b/src/include/libpq/md5.h
@@ -6,7 +6,7 @@
* These definitions are needed by both frontend and backend code to work
* with MD5-encrypted passwords.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/md5.h
diff --git a/src/include/libpq/pqcomm.h b/src/include/libpq/pqcomm.h
index 82d210bd01..bd0fa25077 100644
--- a/src/include/libpq/pqcomm.h
+++ b/src/include/libpq/pqcomm.h
@@ -6,7 +6,7 @@
* NOTE: for historical reasons, this does not correspond to pqcomm.c.
* pqcomm.c's routines are declared in libpq.h.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/pqcomm.h
diff --git a/src/include/libpq/pqformat.h b/src/include/libpq/pqformat.h
index d6c2e6b234..663da909bb 100644
--- a/src/include/libpq/pqformat.h
+++ b/src/include/libpq/pqformat.h
@@ -3,7 +3,7 @@
* pqformat.h
* Definitions for formatting and parsing frontend/backend messages
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/pqformat.h
diff --git a/src/include/libpq/pqsignal.h b/src/include/libpq/pqsignal.h
index 6e98d5329d..ed3b7c9a33 100644
--- a/src/include/libpq/pqsignal.h
+++ b/src/include/libpq/pqsignal.h
@@ -4,7 +4,7 @@
* prototypes for the reliable BSD-style signal(2) routine.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/libpq/pqsignal.h
diff --git a/src/include/mb/pg_wchar.h b/src/include/mb/pg_wchar.h
index 475cab0dc0..f110723da1 100644
--- a/src/include/mb/pg_wchar.h
+++ b/src/include/mb/pg_wchar.h
@@ -3,7 +3,7 @@
* pg_wchar.h
* multibyte-character support
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/mb/pg_wchar.h
diff --git a/src/include/miscadmin.h b/src/include/miscadmin.h
index b2a8d82079..382a5deced 100644
--- a/src/include/miscadmin.h
+++ b/src/include/miscadmin.h
@@ -10,7 +10,7 @@
* Over time, this has also become the preferred place for widely known
* resource-limitation stuff, such as work_mem and check_stack_depth().
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/miscadmin.h
diff --git a/src/include/nodes/bitmapset.h b/src/include/nodes/bitmapset.h
index e75aa03f64..844ef4683a 100644
--- a/src/include/nodes/bitmapset.h
+++ b/src/include/nodes/bitmapset.h
@@ -11,7 +11,7 @@
* bms_is_empty() in preference to testing for NULL.)
*
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* src/include/nodes/bitmapset.h
*
diff --git a/src/include/nodes/execnodes.h b/src/include/nodes/execnodes.h
index 2b53307ded..5a47dc9f82 100644
--- a/src/include/nodes/execnodes.h
+++ b/src/include/nodes/execnodes.h
@@ -4,7 +4,7 @@
* definitions for executor state nodes
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/execnodes.h
diff --git a/src/include/nodes/makefuncs.h b/src/include/nodes/makefuncs.h
index 8f1687fc44..7c41312587 100644
--- a/src/include/nodes/makefuncs.h
+++ b/src/include/nodes/makefuncs.h
@@ -4,7 +4,7 @@
* prototypes for the creator functions (for primitive nodes)
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/makefuncs.h
diff --git a/src/include/nodes/memnodes.h b/src/include/nodes/memnodes.h
index 74eff467c4..b62ed8f904 100644
--- a/src/include/nodes/memnodes.h
+++ b/src/include/nodes/memnodes.h
@@ -4,7 +4,7 @@
* POSTGRES memory context node definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/memnodes.h
diff --git a/src/include/nodes/nodeFuncs.h b/src/include/nodes/nodeFuncs.h
index 464dded60f..433fbfe857 100644
--- a/src/include/nodes/nodeFuncs.h
+++ b/src/include/nodes/nodeFuncs.h
@@ -3,7 +3,7 @@
* nodeFuncs.h
* Various general-purpose manipulations of Node trees
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/nodeFuncs.h
diff --git a/src/include/nodes/nodes.h b/src/include/nodes/nodes.h
index bc96ebf68e..1ce5d81b2c 100644
--- a/src/include/nodes/nodes.h
+++ b/src/include/nodes/nodes.h
@@ -4,7 +4,7 @@
* Definitions for tagged nodes.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/nodes.h
diff --git a/src/include/nodes/params.h b/src/include/nodes/params.h
index 9dd62617f5..824816e53d 100644
--- a/src/include/nodes/params.h
+++ b/src/include/nodes/params.h
@@ -4,7 +4,7 @@
* Support for finding the values associated with Param nodes.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/params.h
diff --git a/src/include/nodes/parsenodes.h b/src/include/nodes/parsenodes.h
index 8b34b76300..9225c3ad16 100644
--- a/src/include/nodes/parsenodes.h
+++ b/src/include/nodes/parsenodes.h
@@ -10,7 +10,7 @@
* the location.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/parsenodes.h
diff --git a/src/include/nodes/pg_list.h b/src/include/nodes/pg_list.h
index 4d6b440da3..2d4ef52b13 100644
--- a/src/include/nodes/pg_list.h
+++ b/src/include/nodes/pg_list.h
@@ -27,7 +27,7 @@
* always be so; try to be careful to maintain the distinction.)
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/pg_list.h
diff --git a/src/include/nodes/plannodes.h b/src/include/nodes/plannodes.h
index b89eb55ad7..1a67e0ff84 100644
--- a/src/include/nodes/plannodes.h
+++ b/src/include/nodes/plannodes.h
@@ -4,7 +4,7 @@
* definitions for query plan nodes
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/plannodes.h
diff --git a/src/include/nodes/primnodes.h b/src/include/nodes/primnodes.h
index ba5ae371c0..f8a398dc83 100644
--- a/src/include/nodes/primnodes.h
+++ b/src/include/nodes/primnodes.h
@@ -7,7 +7,7 @@
* and join trees.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/primnodes.h
diff --git a/src/include/nodes/print.h b/src/include/nodes/print.h
index 628b9588de..3b87e181bd 100644
--- a/src/include/nodes/print.h
+++ b/src/include/nodes/print.h
@@ -4,7 +4,7 @@
* definitions for nodes/print.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/print.h
diff --git a/src/include/nodes/readfuncs.h b/src/include/nodes/readfuncs.h
index c970ba0bf0..cadc8e0c35 100644
--- a/src/include/nodes/readfuncs.h
+++ b/src/include/nodes/readfuncs.h
@@ -4,7 +4,7 @@
* header file for read.c and readfuncs.c. These functions are internal
* to the stringToNode interface and should not be used by anyone else.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/readfuncs.h
diff --git a/src/include/nodes/relation.h b/src/include/nodes/relation.h
index e7ebcfcc81..8b14838625 100644
--- a/src/include/nodes/relation.h
+++ b/src/include/nodes/relation.h
@@ -4,7 +4,7 @@
* Definitions for planner's internal data structures.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/nodes/relation.h
diff --git a/src/include/nodes/tidbitmap.h b/src/include/nodes/tidbitmap.h
index 3710d4b62e..1c32b777d8 100644
--- a/src/include/nodes/tidbitmap.h
+++ b/src/include/nodes/tidbitmap.h
@@ -13,7 +13,7 @@
* fact that a particular page needs to be visited.
*
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* src/include/nodes/tidbitmap.h
*
diff --git a/src/include/nodes/value.h b/src/include/nodes/value.h
index d6009aa79e..d18f36eddc 100644
--- a/src/include/nodes/value.h
+++ b/src/include/nodes/value.h
@@ -4,7 +4,7 @@
* interface for Value nodes
*
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* src/include/nodes/value.h
*
diff --git a/src/include/optimizer/clauses.h b/src/include/optimizer/clauses.h
index 489414e063..945957244c 100644
--- a/src/include/optimizer/clauses.h
+++ b/src/include/optimizer/clauses.h
@@ -4,7 +4,7 @@
* prototypes for clauses.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/clauses.h
diff --git a/src/include/optimizer/cost.h b/src/include/optimizer/cost.h
index 48de2a989f..3112bf75cc 100644
--- a/src/include/optimizer/cost.h
+++ b/src/include/optimizer/cost.h
@@ -4,7 +4,7 @@
* prototypes for costsize.c and clausesel.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/cost.h
diff --git a/src/include/optimizer/geqo.h b/src/include/optimizer/geqo.h
index e9069a2f08..62f1fd9418 100644
--- a/src/include/optimizer/geqo.h
+++ b/src/include/optimizer/geqo.h
@@ -3,7 +3,7 @@
* geqo.h
* prototypes for various files in optimizer/geqo
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/geqo.h
diff --git a/src/include/optimizer/geqo_copy.h b/src/include/optimizer/geqo_copy.h
index 6f748a29e9..5ce07ad25d 100644
--- a/src/include/optimizer/geqo_copy.h
+++ b/src/include/optimizer/geqo_copy.h
@@ -3,7 +3,7 @@
* geqo_copy.h
* prototypes for copy functions in optimizer/geqo
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/geqo_copy.h
diff --git a/src/include/optimizer/geqo_gene.h b/src/include/optimizer/geqo_gene.h
index bbd8deeaee..682d088fae 100644
--- a/src/include/optimizer/geqo_gene.h
+++ b/src/include/optimizer/geqo_gene.h
@@ -3,7 +3,7 @@
* geqo_gene.h
* genome representation in optimizer/geqo
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/geqo_gene.h
diff --git a/src/include/optimizer/geqo_misc.h b/src/include/optimizer/geqo_misc.h
index 74aaad440c..83d80671f3 100644
--- a/src/include/optimizer/geqo_misc.h
+++ b/src/include/optimizer/geqo_misc.h
@@ -3,7 +3,7 @@
* geqo_misc.h
* prototypes for printout routines in optimizer/geqo
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/geqo_misc.h
diff --git a/src/include/optimizer/geqo_mutation.h b/src/include/optimizer/geqo_mutation.h
index 74a5b51db1..56c4b278ad 100644
--- a/src/include/optimizer/geqo_mutation.h
+++ b/src/include/optimizer/geqo_mutation.h
@@ -3,7 +3,7 @@
* geqo_mutation.h
* prototypes for mutation functions in optimizer/geqo
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/geqo_mutation.h
diff --git a/src/include/optimizer/geqo_pool.h b/src/include/optimizer/geqo_pool.h
index 04d98994e6..19385a2ba7 100644
--- a/src/include/optimizer/geqo_pool.h
+++ b/src/include/optimizer/geqo_pool.h
@@ -3,7 +3,7 @@
* geqo_pool.h
* pool representation in optimizer/geqo
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/geqo_pool.h
diff --git a/src/include/optimizer/geqo_random.h b/src/include/optimizer/geqo_random.h
index cf3340403e..afadaa3189 100644
--- a/src/include/optimizer/geqo_random.h
+++ b/src/include/optimizer/geqo_random.h
@@ -3,7 +3,7 @@
* geqo_random.h
* random number generator
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/geqo_random.h
diff --git a/src/include/optimizer/geqo_recombination.h b/src/include/optimizer/geqo_recombination.h
index 61eb245a27..7a82c548db 100644
--- a/src/include/optimizer/geqo_recombination.h
+++ b/src/include/optimizer/geqo_recombination.h
@@ -3,7 +3,7 @@
* geqo_recombination.h
* prototypes for recombination in the genetic query optimizer
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/geqo_recombination.h
diff --git a/src/include/optimizer/geqo_selection.h b/src/include/optimizer/geqo_selection.h
index 6ac427b1c2..1bdfa6ac37 100644
--- a/src/include/optimizer/geqo_selection.h
+++ b/src/include/optimizer/geqo_selection.h
@@ -3,7 +3,7 @@
* geqo_selection.h
* prototypes for selection routines in optimizer/geqo
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/geqo_selection.h
diff --git a/src/include/optimizer/joininfo.h b/src/include/optimizer/joininfo.h
index fad6d93f01..f7ee46b30b 100644
--- a/src/include/optimizer/joininfo.h
+++ b/src/include/optimizer/joininfo.h
@@ -4,7 +4,7 @@
* prototypes for joininfo.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/joininfo.h
diff --git a/src/include/optimizer/pathnode.h b/src/include/optimizer/pathnode.h
index 2dde5e07ef..ff220e32a7 100644
--- a/src/include/optimizer/pathnode.h
+++ b/src/include/optimizer/pathnode.h
@@ -4,7 +4,7 @@
* prototypes for pathnode.c, relnode.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/pathnode.h
diff --git a/src/include/optimizer/paths.h b/src/include/optimizer/paths.h
index c0ff0144fa..ef769bf04d 100644
--- a/src/include/optimizer/paths.h
+++ b/src/include/optimizer/paths.h
@@ -4,7 +4,7 @@
* prototypes for various files in optimizer/path
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/paths.h
diff --git a/src/include/optimizer/placeholder.h b/src/include/optimizer/placeholder.h
index 22d52411c2..976c5439ca 100644
--- a/src/include/optimizer/placeholder.h
+++ b/src/include/optimizer/placeholder.h
@@ -4,7 +4,7 @@
* prototypes for optimizer/util/placeholder.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/placeholder.h
diff --git a/src/include/optimizer/plancat.h b/src/include/optimizer/plancat.h
index ca7b2c6469..c0b8eda813 100644
--- a/src/include/optimizer/plancat.h
+++ b/src/include/optimizer/plancat.h
@@ -4,7 +4,7 @@
* prototypes for plancat.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/plancat.h
diff --git a/src/include/optimizer/planmain.h b/src/include/optimizer/planmain.h
index 919449b4e3..9ddd5c183e 100644
--- a/src/include/optimizer/planmain.h
+++ b/src/include/optimizer/planmain.h
@@ -4,7 +4,7 @@
* prototypes for various files in optimizer/plan
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/planmain.h
diff --git a/src/include/optimizer/planner.h b/src/include/optimizer/planner.h
index ef7287d8b5..01fc1fc5d4 100644
--- a/src/include/optimizer/planner.h
+++ b/src/include/optimizer/planner.h
@@ -4,7 +4,7 @@
* prototypes for planner.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/planner.h
diff --git a/src/include/optimizer/predtest.h b/src/include/optimizer/predtest.h
index c73b22b03a..222b7a3746 100644
--- a/src/include/optimizer/predtest.h
+++ b/src/include/optimizer/predtest.h
@@ -4,7 +4,7 @@
* prototypes for predtest.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/predtest.h
diff --git a/src/include/optimizer/prep.h b/src/include/optimizer/prep.h
index 9f8e379c24..5e94620537 100644
--- a/src/include/optimizer/prep.h
+++ b/src/include/optimizer/prep.h
@@ -4,7 +4,7 @@
* prototypes for files in optimizer/prep/
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/prep.h
diff --git a/src/include/optimizer/restrictinfo.h b/src/include/optimizer/restrictinfo.h
index 2e8cc24ed4..12d304f4dc 100644
--- a/src/include/optimizer/restrictinfo.h
+++ b/src/include/optimizer/restrictinfo.h
@@ -4,7 +4,7 @@
* prototypes for restrictinfo.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/restrictinfo.h
diff --git a/src/include/optimizer/subselect.h b/src/include/optimizer/subselect.h
index 1b7fbcd932..31a5d5f186 100644
--- a/src/include/optimizer/subselect.h
+++ b/src/include/optimizer/subselect.h
@@ -2,7 +2,7 @@
*
* subselect.h
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/subselect.h
diff --git a/src/include/optimizer/tlist.h b/src/include/optimizer/tlist.h
index 293471e291..f7606d79a3 100644
--- a/src/include/optimizer/tlist.h
+++ b/src/include/optimizer/tlist.h
@@ -4,7 +4,7 @@
* prototypes for tlist.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/tlist.h
diff --git a/src/include/optimizer/var.h b/src/include/optimizer/var.h
index 8fd99779d1..33340dda0f 100644
--- a/src/include/optimizer/var.h
+++ b/src/include/optimizer/var.h
@@ -4,7 +4,7 @@
* prototypes for optimizer/util/var.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/optimizer/var.h
diff --git a/src/include/parser/analyze.h b/src/include/parser/analyze.h
index 2db37876c5..88fc78bebc 100644
--- a/src/include/parser/analyze.h
+++ b/src/include/parser/analyze.h
@@ -4,7 +4,7 @@
* parse analysis for optimizable statements
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/analyze.h
diff --git a/src/include/parser/gramparse.h b/src/include/parser/gramparse.h
index e495aa360b..6657e07ca7 100644
--- a/src/include/parser/gramparse.h
+++ b/src/include/parser/gramparse.h
@@ -8,7 +8,7 @@
* outside the core parser should be in parser.h.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/gramparse.h
diff --git a/src/include/parser/keywords.h b/src/include/parser/keywords.h
index ad740de363..935348111c 100644
--- a/src/include/parser/keywords.h
+++ b/src/include/parser/keywords.h
@@ -4,7 +4,7 @@
* lexical token lookup for key words in PostgreSQL
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/keywords.h
diff --git a/src/include/parser/kwlist.h b/src/include/parser/kwlist.h
index 726daf5c07..578d3cd870 100644
--- a/src/include/parser/kwlist.h
+++ b/src/include/parser/kwlist.h
@@ -7,7 +7,7 @@
* by the PG_KEYWORD macro, which is not defined in this file; it can
* be defined by the caller for special purposes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/include/parser/parse_agg.h b/src/include/parser/parse_agg.h
index cedd26187a..716c3d2d13 100644
--- a/src/include/parser/parse_agg.h
+++ b/src/include/parser/parse_agg.h
@@ -3,7 +3,7 @@
* parse_agg.h
* handle aggregates and window functions in parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_agg.h
diff --git a/src/include/parser/parse_clause.h b/src/include/parser/parse_clause.h
index 0e8a80e04c..09ef450ac5 100644
--- a/src/include/parser/parse_clause.h
+++ b/src/include/parser/parse_clause.h
@@ -4,7 +4,7 @@
* handle clauses in parser
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_clause.h
diff --git a/src/include/parser/parse_coerce.h b/src/include/parser/parse_coerce.h
index 449d9d382c..ceaff2f9a9 100644
--- a/src/include/parser/parse_coerce.h
+++ b/src/include/parser/parse_coerce.h
@@ -4,7 +4,7 @@
* Routines for type coercion.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_coerce.h
diff --git a/src/include/parser/parse_cte.h b/src/include/parser/parse_cte.h
index 8998dfc6f1..d5fc455f27 100644
--- a/src/include/parser/parse_cte.h
+++ b/src/include/parser/parse_cte.h
@@ -4,7 +4,7 @@
* handle CTEs (common table expressions) in parser
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_cte.h
diff --git a/src/include/parser/parse_expr.h b/src/include/parser/parse_expr.h
index 654bf34ef1..95e34205dd 100644
--- a/src/include/parser/parse_expr.h
+++ b/src/include/parser/parse_expr.h
@@ -3,7 +3,7 @@
* parse_expr.h
* handle expressions in parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_expr.h
diff --git a/src/include/parser/parse_func.h b/src/include/parser/parse_func.h
index 7f42a6741a..a2011be52f 100644
--- a/src/include/parser/parse_func.h
+++ b/src/include/parser/parse_func.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_func.h
diff --git a/src/include/parser/parse_node.h b/src/include/parser/parse_node.h
index 7312188667..edae0527e6 100644
--- a/src/include/parser/parse_node.h
+++ b/src/include/parser/parse_node.h
@@ -4,7 +4,7 @@
* Internal definitions for parser
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_node.h
diff --git a/src/include/parser/parse_oper.h b/src/include/parser/parse_oper.h
index 4ef1d0c977..4ae8aef4a3 100644
--- a/src/include/parser/parse_oper.h
+++ b/src/include/parser/parse_oper.h
@@ -4,7 +4,7 @@
* handle operator things for parser
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_oper.h
diff --git a/src/include/parser/parse_param.h b/src/include/parser/parse_param.h
index 1d2b46542a..f1587863ac 100644
--- a/src/include/parser/parse_param.h
+++ b/src/include/parser/parse_param.h
@@ -3,7 +3,7 @@
* parse_param.h
* handle parameters in parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_param.h
diff --git a/src/include/parser/parse_relation.h b/src/include/parser/parse_relation.h
index b3348d0ed9..41f482c8df 100644
--- a/src/include/parser/parse_relation.h
+++ b/src/include/parser/parse_relation.h
@@ -4,7 +4,7 @@
* prototypes for parse_relation.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_relation.h
diff --git a/src/include/parser/parse_target.h b/src/include/parser/parse_target.h
index 9b4df398ac..a0604e1b83 100644
--- a/src/include/parser/parse_target.h
+++ b/src/include/parser/parse_target.h
@@ -4,7 +4,7 @@
* handle target lists
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_target.h
diff --git a/src/include/parser/parse_type.h b/src/include/parser/parse_type.h
index bab8c48e2f..dadcde790c 100644
--- a/src/include/parser/parse_type.h
+++ b/src/include/parser/parse_type.h
@@ -3,7 +3,7 @@
* parse_type.h
* handle type operations for parser
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_type.h
diff --git a/src/include/parser/parse_utilcmd.h b/src/include/parser/parse_utilcmd.h
index 3eb3127b5f..3c8b9ab881 100644
--- a/src/include/parser/parse_utilcmd.h
+++ b/src/include/parser/parse_utilcmd.h
@@ -4,7 +4,7 @@
* parse analysis for utility commands
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parse_utilcmd.h
diff --git a/src/include/parser/parser.h b/src/include/parser/parser.h
index a2a0ffe898..4d7f648568 100644
--- a/src/include/parser/parser.h
+++ b/src/include/parser/parser.h
@@ -5,7 +5,7 @@
*
* This is the external API for the raw lexing/parsing functions.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parser.h
diff --git a/src/include/parser/parsetree.h b/src/include/parser/parsetree.h
index 102e6138f9..efdbc1ab81 100644
--- a/src/include/parser/parsetree.h
+++ b/src/include/parser/parsetree.h
@@ -5,7 +5,7 @@
* parse trees.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/parsetree.h
diff --git a/src/include/parser/scanner.h b/src/include/parser/scanner.h
index cf024bb02e..2a88e970a0 100644
--- a/src/include/parser/scanner.h
+++ b/src/include/parser/scanner.h
@@ -8,7 +8,7 @@
* higher-level API provided by parser.h.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/scanner.h
diff --git a/src/include/parser/scansup.h b/src/include/parser/scansup.h
index f33766d339..54220ff2e7 100644
--- a/src/include/parser/scansup.h
+++ b/src/include/parser/scansup.h
@@ -4,7 +4,7 @@
* scanner support routines. used by both the bootstrap lexer
* as well as the normal lexer
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/parser/scansup.h
diff --git a/src/include/pg_trace.h b/src/include/pg_trace.h
index e9ec940493..e8112d3d58 100644
--- a/src/include/pg_trace.h
+++ b/src/include/pg_trace.h
@@ -3,7 +3,7 @@
*
* Definitions for the PostgreSQL tracing framework
*
- * Copyright (c) 2006-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2006-2011, PostgreSQL Global Development Group
*
* src/include/pg_trace.h
* ----------
diff --git a/src/include/pgstat.h b/src/include/pgstat.h
index 42bf9c4f3a..053dd4de0d 100644
--- a/src/include/pgstat.h
+++ b/src/include/pgstat.h
@@ -3,7 +3,7 @@
*
* Definitions for the PostgreSQL statistics collector daemon.
*
- * Copyright (c) 2001-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2001-2011, PostgreSQL Global Development Group
*
* src/include/pgstat.h
* ----------
diff --git a/src/include/pgtime.h b/src/include/pgtime.h
index 013b88611d..e73cfa51a4 100644
--- a/src/include/pgtime.h
+++ b/src/include/pgtime.h
@@ -3,7 +3,7 @@
* pgtime.h
* PostgreSQL internal timezone library
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/include/pgtime.h
diff --git a/src/include/port.h b/src/include/port.h
index 0dbc322392..2f5abdd334 100644
--- a/src/include/port.h
+++ b/src/include/port.h
@@ -3,7 +3,7 @@
* port.h
* Header for src/port/ compatibility functions.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/port.h
diff --git a/src/include/portability/instr_time.h b/src/include/portability/instr_time.h
index 60359b6e1a..af400b1dca 100644
--- a/src/include/portability/instr_time.h
+++ b/src/include/portability/instr_time.h
@@ -43,7 +43,7 @@
* Beware of multiple evaluations of the macro arguments.
*
*
- * Copyright (c) 2001-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2001-2011, PostgreSQL Global Development Group
*
* src/include/portability/instr_time.h
*
diff --git a/src/include/postgres.h b/src/include/postgres.h
index b8b80379ee..60a2bdb847 100644
--- a/src/include/postgres.h
+++ b/src/include/postgres.h
@@ -7,7 +7,7 @@
* Client-side code should include postgres_fe.h instead.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1995, Regents of the University of California
*
* src/include/postgres.h
diff --git a/src/include/postgres_fe.h b/src/include/postgres_fe.h
index f5fc8c6842..232a1907d4 100644
--- a/src/include/postgres_fe.h
+++ b/src/include/postgres_fe.h
@@ -8,7 +8,7 @@
* postgres.h.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1995, Regents of the University of California
*
* src/include/postgres_fe.h
diff --git a/src/include/postmaster/autovacuum.h b/src/include/postmaster/autovacuum.h
index 758eb01f23..cf82363ce7 100644
--- a/src/include/postmaster/autovacuum.h
+++ b/src/include/postmaster/autovacuum.h
@@ -4,7 +4,7 @@
* header file for integrated autovacuum daemon
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/postmaster/autovacuum.h
diff --git a/src/include/postmaster/bgwriter.h b/src/include/postmaster/bgwriter.h
index e251da6b58..eaf2206f5e 100644
--- a/src/include/postmaster/bgwriter.h
+++ b/src/include/postmaster/bgwriter.h
@@ -3,7 +3,7 @@
* bgwriter.h
* Exports from postmaster/bgwriter.c.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/postmaster/bgwriter.h
*
diff --git a/src/include/postmaster/fork_process.h b/src/include/postmaster/fork_process.h
index 8a3c5e18bb..0553fd2c40 100644
--- a/src/include/postmaster/fork_process.h
+++ b/src/include/postmaster/fork_process.h
@@ -3,7 +3,7 @@
* fork_process.h
* Exports from postmaster/fork_process.c.
*
- * Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/postmaster/fork_process.h
*
diff --git a/src/include/postmaster/pgarch.h b/src/include/postmaster/pgarch.h
index f6b2da6e1c..4b29087722 100644
--- a/src/include/postmaster/pgarch.h
+++ b/src/include/postmaster/pgarch.h
@@ -3,7 +3,7 @@
* pgarch.h
* Exports from postmaster/pgarch.c.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/postmaster/pgarch.h
diff --git a/src/include/postmaster/postmaster.h b/src/include/postmaster/postmaster.h
index b77cd82d25..25cc84a47f 100644
--- a/src/include/postmaster/postmaster.h
+++ b/src/include/postmaster/postmaster.h
@@ -3,7 +3,7 @@
* postmaster.h
* Exports from postmaster/postmaster.c.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/postmaster/postmaster.h
diff --git a/src/include/postmaster/syslogger.h b/src/include/postmaster/syslogger.h
index 502373ba53..97ab04257c 100644
--- a/src/include/postmaster/syslogger.h
+++ b/src/include/postmaster/syslogger.h
@@ -3,7 +3,7 @@
* syslogger.h
* Exports from postmaster/syslogger.c.
*
- * Copyright (c) 2004-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2004-2011, PostgreSQL Global Development Group
*
* src/include/postmaster/syslogger.h
*
diff --git a/src/include/postmaster/walwriter.h b/src/include/postmaster/walwriter.h
index 7678950bab..62260d658b 100644
--- a/src/include/postmaster/walwriter.h
+++ b/src/include/postmaster/walwriter.h
@@ -3,7 +3,7 @@
* walwriter.h
* Exports from postmaster/walwriter.c.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/postmaster/walwriter.h
*
diff --git a/src/include/replication/walprotocol.h b/src/include/replication/walprotocol.h
index 5c2cc70635..199385120a 100644
--- a/src/include/replication/walprotocol.h
+++ b/src/include/replication/walprotocol.h
@@ -3,7 +3,7 @@
* walprotocol.h
* Definitions relevant to the streaming WAL transmission protocol.
*
- * Portions Copyright (c) 2010-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2010-2011, PostgreSQL Global Development Group
*
* src/include/replication/walprotocol.h
*
diff --git a/src/include/replication/walreceiver.h b/src/include/replication/walreceiver.h
index 485df782ff..24ad43839f 100644
--- a/src/include/replication/walreceiver.h
+++ b/src/include/replication/walreceiver.h
@@ -3,7 +3,7 @@
* walreceiver.h
* Exports from replication/walreceiverfuncs.c.
*
- * Portions Copyright (c) 2010-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2010-2011, PostgreSQL Global Development Group
*
* src/include/replication/walreceiver.h
*
diff --git a/src/include/replication/walsender.h b/src/include/replication/walsender.h
index 6bc0864f95..6f543ae3f4 100644
--- a/src/include/replication/walsender.h
+++ b/src/include/replication/walsender.h
@@ -3,7 +3,7 @@
* walsender.h
* Exports from replication/walsender.c.
*
- * Portions Copyright (c) 2010-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2010-2011, PostgreSQL Global Development Group
*
* src/include/replication/walsender.h
*
diff --git a/src/include/rewrite/prs2lock.h b/src/include/rewrite/prs2lock.h
index 1c79765ca9..ede0f1cc97 100644
--- a/src/include/rewrite/prs2lock.h
+++ b/src/include/rewrite/prs2lock.h
@@ -3,7 +3,7 @@
* prs2lock.h
* data structures for POSTGRES Rule System II (rewrite rules only)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/rewrite/prs2lock.h
diff --git a/src/include/rewrite/rewriteDefine.h b/src/include/rewrite/rewriteDefine.h
index a739d81fa3..4bf474b2a1 100644
--- a/src/include/rewrite/rewriteDefine.h
+++ b/src/include/rewrite/rewriteDefine.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/rewrite/rewriteDefine.h
diff --git a/src/include/rewrite/rewriteHandler.h b/src/include/rewrite/rewriteHandler.h
index 8be2ace292..fa6add3b30 100644
--- a/src/include/rewrite/rewriteHandler.h
+++ b/src/include/rewrite/rewriteHandler.h
@@ -4,7 +4,7 @@
* External interface to query rewriter.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/rewrite/rewriteHandler.h
diff --git a/src/include/rewrite/rewriteManip.h b/src/include/rewrite/rewriteManip.h
index 8daea6e0d6..4f1026bf90 100644
--- a/src/include/rewrite/rewriteManip.h
+++ b/src/include/rewrite/rewriteManip.h
@@ -4,7 +4,7 @@
* Querytree manipulation subroutines for query rewriter.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/rewrite/rewriteManip.h
diff --git a/src/include/rewrite/rewriteRemove.h b/src/include/rewrite/rewriteRemove.h
index f8c0c32edf..90df04591f 100644
--- a/src/include/rewrite/rewriteRemove.h
+++ b/src/include/rewrite/rewriteRemove.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/rewrite/rewriteRemove.h
diff --git a/src/include/rewrite/rewriteSupport.h b/src/include/rewrite/rewriteSupport.h
index a483c6fcad..11e8173454 100644
--- a/src/include/rewrite/rewriteSupport.h
+++ b/src/include/rewrite/rewriteSupport.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/rewrite/rewriteSupport.h
diff --git a/src/include/rusagestub.h b/src/include/rusagestub.h
index dbfa494dd6..e67b78a37b 100644
--- a/src/include/rusagestub.h
+++ b/src/include/rusagestub.h
@@ -4,7 +4,7 @@
* Stubs for getrusage(3).
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/rusagestub.h
diff --git a/src/include/snowball/header.h b/src/include/snowball/header.h
index f551beb5b9..3ede1a0114 100644
--- a/src/include/snowball/header.h
+++ b/src/include/snowball/header.h
@@ -13,7 +13,7 @@
*
* NOTE: this file should not be included into any non-snowball sources!
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/snowball/header.h
*
diff --git a/src/include/storage/backendid.h b/src/include/storage/backendid.h
index df22264c3b..b702da2435 100644
--- a/src/include/storage/backendid.h
+++ b/src/include/storage/backendid.h
@@ -4,7 +4,7 @@
* POSTGRES backend id communication definitions
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/backendid.h
diff --git a/src/include/storage/block.h b/src/include/storage/block.h
index eb6124b3f4..6f33ed8c83 100644
--- a/src/include/storage/block.h
+++ b/src/include/storage/block.h
@@ -4,7 +4,7 @@
* POSTGRES disk block definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/block.h
diff --git a/src/include/storage/buf.h b/src/include/storage/buf.h
index 191bb59257..5347ab0d4a 100644
--- a/src/include/storage/buf.h
+++ b/src/include/storage/buf.h
@@ -4,7 +4,7 @@
* Basic buffer manager data types.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/buf.h
diff --git a/src/include/storage/buf_internals.h b/src/include/storage/buf_internals.h
index 823ca32766..0652bdf711 100644
--- a/src/include/storage/buf_internals.h
+++ b/src/include/storage/buf_internals.h
@@ -5,7 +5,7 @@
* strategy.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/buf_internals.h
diff --git a/src/include/storage/buffile.h b/src/include/storage/buffile.h
index 5dd73f629d..48b949d10d 100644
--- a/src/include/storage/buffile.h
+++ b/src/include/storage/buffile.h
@@ -15,7 +15,7 @@
* but currently we have no need for oversize temp files without buffered
* access.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/buffile.h
diff --git a/src/include/storage/bufmgr.h b/src/include/storage/bufmgr.h
index 58808f0b59..b8fc87ec57 100644
--- a/src/include/storage/bufmgr.h
+++ b/src/include/storage/bufmgr.h
@@ -4,7 +4,7 @@
* POSTGRES buffer manager definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/bufmgr.h
diff --git a/src/include/storage/bufpage.h b/src/include/storage/bufpage.h
index 52fe043eec..42d6b10dda 100644
--- a/src/include/storage/bufpage.h
+++ b/src/include/storage/bufpage.h
@@ -4,7 +4,7 @@
* Standard POSTGRES buffer page definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/bufpage.h
diff --git a/src/include/storage/copydir.h b/src/include/storage/copydir.h
index 7c577240f8..7e9f1f4596 100644
--- a/src/include/storage/copydir.h
+++ b/src/include/storage/copydir.h
@@ -3,7 +3,7 @@
* copydir.h
* Copy a directory.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/copydir.h
diff --git a/src/include/storage/fd.h b/src/include/storage/fd.h
index dbbe97bdeb..dc0aada35b 100644
--- a/src/include/storage/fd.h
+++ b/src/include/storage/fd.h
@@ -4,7 +4,7 @@
* Virtual file descriptor definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/fd.h
diff --git a/src/include/storage/freespace.h b/src/include/storage/freespace.h
index 0a1aa742a6..1c15db8f10 100644
--- a/src/include/storage/freespace.h
+++ b/src/include/storage/freespace.h
@@ -4,7 +4,7 @@
* POSTGRES free space map for quickly finding free space in relations
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/freespace.h
diff --git a/src/include/storage/fsm_internals.h b/src/include/storage/fsm_internals.h
index 8c53397bee..4508b7c9c6 100644
--- a/src/include/storage/fsm_internals.h
+++ b/src/include/storage/fsm_internals.h
@@ -4,7 +4,7 @@
* internal functions for free space map
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/fsm_internals.h
diff --git a/src/include/storage/indexfsm.h b/src/include/storage/indexfsm.h
index e8558a7847..343262c8be 100644
--- a/src/include/storage/indexfsm.h
+++ b/src/include/storage/indexfsm.h
@@ -4,7 +4,7 @@
* POSTGRES free space map for quickly finding an unused page in index
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/indexfsm.h
diff --git a/src/include/storage/ipc.h b/src/include/storage/ipc.h
index 61b1af758a..26b5ef6183 100644
--- a/src/include/storage/ipc.h
+++ b/src/include/storage/ipc.h
@@ -8,7 +8,7 @@
* exit-time cleanup for either a postmaster or a backend.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/ipc.h
diff --git a/src/include/storage/item.h b/src/include/storage/item.h
index c9e12ad471..bdd00aee57 100644
--- a/src/include/storage/item.h
+++ b/src/include/storage/item.h
@@ -4,7 +4,7 @@
* POSTGRES disk item definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/item.h
diff --git a/src/include/storage/itemid.h b/src/include/storage/itemid.h
index c77b455d1a..961d2c2f9f 100644
--- a/src/include/storage/itemid.h
+++ b/src/include/storage/itemid.h
@@ -4,7 +4,7 @@
* Standard POSTGRES buffer page item identifier definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/itemid.h
diff --git a/src/include/storage/itemptr.h b/src/include/storage/itemptr.h
index cb53ae41d9..20221d641e 100644
--- a/src/include/storage/itemptr.h
+++ b/src/include/storage/itemptr.h
@@ -4,7 +4,7 @@
* POSTGRES disk item pointer definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/itemptr.h
diff --git a/src/include/storage/large_object.h b/src/include/storage/large_object.h
index c6c983ccf2..33922ba5e2 100644
--- a/src/include/storage/large_object.h
+++ b/src/include/storage/large_object.h
@@ -5,7 +5,7 @@
* zillions of large objects (internal, external, jaquith, inversion).
* Now we only support inversion.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/large_object.h
diff --git a/src/include/storage/latch.h b/src/include/storage/latch.h
index 18946800d6..31744ff252 100644
--- a/src/include/storage/latch.h
+++ b/src/include/storage/latch.h
@@ -4,7 +4,7 @@
* Routines for interprocess latches
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/latch.h
diff --git a/src/include/storage/lmgr.h b/src/include/storage/lmgr.h
index 68ec7a36cb..bd44d92be3 100644
--- a/src/include/storage/lmgr.h
+++ b/src/include/storage/lmgr.h
@@ -4,7 +4,7 @@
* POSTGRES lock manager definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/lmgr.h
diff --git a/src/include/storage/lock.h b/src/include/storage/lock.h
index d9301f0620..7b52d2e6d1 100644
--- a/src/include/storage/lock.h
+++ b/src/include/storage/lock.h
@@ -4,7 +4,7 @@
* POSTGRES low-level lock mechanism
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/lock.h
diff --git a/src/include/storage/lwlock.h b/src/include/storage/lwlock.h
index 548e7e08cf..f5e267c988 100644
--- a/src/include/storage/lwlock.h
+++ b/src/include/storage/lwlock.h
@@ -4,7 +4,7 @@
* Lightweight lock manager
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/lwlock.h
diff --git a/src/include/storage/off.h b/src/include/storage/off.h
index d9b4cd7239..42ce6eba51 100644
--- a/src/include/storage/off.h
+++ b/src/include/storage/off.h
@@ -4,7 +4,7 @@
* POSTGRES disk "offset" definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/off.h
diff --git a/src/include/storage/pg_sema.h b/src/include/storage/pg_sema.h
index 041eca25c2..e07ddf6f19 100644
--- a/src/include/storage/pg_sema.h
+++ b/src/include/storage/pg_sema.h
@@ -10,7 +10,7 @@
* be provided by each port.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/pg_sema.h
diff --git a/src/include/storage/pg_shmem.h b/src/include/storage/pg_shmem.h
index 711773584f..3bbaf41c04 100644
--- a/src/include/storage/pg_shmem.h
+++ b/src/include/storage/pg_shmem.h
@@ -14,7 +14,7 @@
* only one ID number.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/pg_shmem.h
diff --git a/src/include/storage/pmsignal.h b/src/include/storage/pmsignal.h
index 6ab94de5a9..2deff728ec 100644
--- a/src/include/storage/pmsignal.h
+++ b/src/include/storage/pmsignal.h
@@ -4,7 +4,7 @@
* routines for signaling the postmaster from its child processes
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/pmsignal.h
diff --git a/src/include/storage/pos.h b/src/include/storage/pos.h
index 2862fb6b39..689be8c39c 100644
--- a/src/include/storage/pos.h
+++ b/src/include/storage/pos.h
@@ -4,7 +4,7 @@
* POSTGRES "position" definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/pos.h
diff --git a/src/include/storage/proc.h b/src/include/storage/proc.h
index b6a4b3e445..78dbadef4c 100644
--- a/src/include/storage/proc.h
+++ b/src/include/storage/proc.h
@@ -4,7 +4,7 @@
* per-process shared memory data structures
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/proc.h
diff --git a/src/include/storage/procarray.h b/src/include/storage/procarray.h
index ea030d695d..334f9a25c1 100644
--- a/src/include/storage/procarray.h
+++ b/src/include/storage/procarray.h
@@ -4,7 +4,7 @@
* POSTGRES process array definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/procarray.h
diff --git a/src/include/storage/procsignal.h b/src/include/storage/procsignal.h
index 9d47180fa7..2a27e0b7ed 100644
--- a/src/include/storage/procsignal.h
+++ b/src/include/storage/procsignal.h
@@ -4,7 +4,7 @@
* Routines for interprocess signalling
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/procsignal.h
diff --git a/src/include/storage/reinit.h b/src/include/storage/reinit.h
index 9999dff37d..92570a8a1e 100644
--- a/src/include/storage/reinit.h
+++ b/src/include/storage/reinit.h
@@ -4,7 +4,7 @@
* Reinitialization of unlogged relations
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/fd.h
diff --git a/src/include/storage/relfilenode.h b/src/include/storage/relfilenode.h
index f71b2331a5..d8eb4c6be9 100644
--- a/src/include/storage/relfilenode.h
+++ b/src/include/storage/relfilenode.h
@@ -4,7 +4,7 @@
* Physical access information for relations.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/relfilenode.h
diff --git a/src/include/storage/s_lock.h b/src/include/storage/s_lock.h
index d54a02c98f..7fe01aac61 100644
--- a/src/include/storage/s_lock.h
+++ b/src/include/storage/s_lock.h
@@ -63,7 +63,7 @@
* when using the SysV semaphore code.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/s_lock.h
diff --git a/src/include/storage/shmem.h b/src/include/storage/shmem.h
index cad2f401ac..61e3886bd3 100644
--- a/src/include/storage/shmem.h
+++ b/src/include/storage/shmem.h
@@ -11,7 +11,7 @@
* at the same address. This means shared memory pointers can be passed
* around directly between different processes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/shmem.h
diff --git a/src/include/storage/sinval.h b/src/include/storage/sinval.h
index e50e89165e..e9ce0257ac 100644
--- a/src/include/storage/sinval.h
+++ b/src/include/storage/sinval.h
@@ -4,7 +4,7 @@
* POSTGRES shared cache invalidation communication definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/sinval.h
diff --git a/src/include/storage/sinvaladt.h b/src/include/storage/sinvaladt.h
index bfd5282bca..c70355847a 100644
--- a/src/include/storage/sinvaladt.h
+++ b/src/include/storage/sinvaladt.h
@@ -12,7 +12,7 @@
* The struct type SharedInvalidationMessage, defining the contents of
* a single message, is defined in sinval.h.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/sinvaladt.h
diff --git a/src/include/storage/smgr.h b/src/include/storage/smgr.h
index 1e6b63ff43..13f7239c7e 100644
--- a/src/include/storage/smgr.h
+++ b/src/include/storage/smgr.h
@@ -4,7 +4,7 @@
* storage manager switch public interface declarations.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/smgr.h
diff --git a/src/include/storage/spin.h b/src/include/storage/spin.h
index c8e04db67b..832342c953 100644
--- a/src/include/storage/spin.h
+++ b/src/include/storage/spin.h
@@ -46,7 +46,7 @@
* be again.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/spin.h
diff --git a/src/include/storage/standby.h b/src/include/storage/standby.h
index dec1d71323..690b4070af 100644
--- a/src/include/storage/standby.h
+++ b/src/include/storage/standby.h
@@ -4,7 +4,7 @@
* Definitions for hot standby mode.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/storage/standby.h
diff --git a/src/include/tcop/dest.h b/src/include/tcop/dest.h
index 29f1ccc77f..e0890cc8b2 100644
--- a/src/include/tcop/dest.h
+++ b/src/include/tcop/dest.h
@@ -57,7 +57,7 @@
* calls in portal and cursor manipulations.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/tcop/dest.h
diff --git a/src/include/tcop/fastpath.h b/src/include/tcop/fastpath.h
index 844d16fb17..ed944bf425 100644
--- a/src/include/tcop/fastpath.h
+++ b/src/include/tcop/fastpath.h
@@ -3,7 +3,7 @@
* fastpath.h
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/tcop/fastpath.h
diff --git a/src/include/tcop/pquery.h b/src/include/tcop/pquery.h
index e1945079f4..2a5e871c92 100644
--- a/src/include/tcop/pquery.h
+++ b/src/include/tcop/pquery.h
@@ -4,7 +4,7 @@
* prototypes for pquery.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/tcop/pquery.h
diff --git a/src/include/tcop/tcopdebug.h b/src/include/tcop/tcopdebug.h
index b366bca447..234b9cc16d 100644
--- a/src/include/tcop/tcopdebug.h
+++ b/src/include/tcop/tcopdebug.h
@@ -4,7 +4,7 @@
* #defines governing debugging behaviour in the traffic cop
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/tcop/tcopdebug.h
diff --git a/src/include/tcop/tcopprot.h b/src/include/tcop/tcopprot.h
index f4026ecab1..3d26144d8a 100644
--- a/src/include/tcop/tcopprot.h
+++ b/src/include/tcop/tcopprot.h
@@ -4,7 +4,7 @@
* prototypes for postgres.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/tcop/tcopprot.h
diff --git a/src/include/tcop/utility.h b/src/include/tcop/utility.h
index fd61021468..c21857af4d 100644
--- a/src/include/tcop/utility.h
+++ b/src/include/tcop/utility.h
@@ -4,7 +4,7 @@
* prototypes for utility.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/tcop/utility.h
diff --git a/src/include/tsearch/dicts/regis.h b/src/include/tsearch/dicts/regis.h
index 8585311db7..7b2fd9c63a 100644
--- a/src/include/tsearch/dicts/regis.h
+++ b/src/include/tsearch/dicts/regis.h
@@ -4,7 +4,7 @@
*
* Declarations for for fast regex subset, used by ISpell
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/tsearch/dicts/regis.h
*
diff --git a/src/include/tsearch/dicts/spell.h b/src/include/tsearch/dicts/spell.h
index b41fbb6fd5..86c7e748e3 100644
--- a/src/include/tsearch/dicts/spell.h
+++ b/src/include/tsearch/dicts/spell.h
@@ -4,7 +4,7 @@
*
* Declarations for ISpell dictionary
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/tsearch/dicts/spell.h
*
diff --git a/src/include/tsearch/ts_cache.h b/src/include/tsearch/ts_cache.h
index 04592f477f..5ae38b2a43 100644
--- a/src/include/tsearch/ts_cache.h
+++ b/src/include/tsearch/ts_cache.h
@@ -3,7 +3,7 @@
* ts_cache.h
* Tsearch related object caches.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/tsearch/ts_cache.h
diff --git a/src/include/tsearch/ts_locale.h b/src/include/tsearch/ts_locale.h
index be717586d3..28fec55861 100644
--- a/src/include/tsearch/ts_locale.h
+++ b/src/include/tsearch/ts_locale.h
@@ -3,7 +3,7 @@
* ts_locale.h
* locale compatibility layer for tsearch
*
- * Copyright (c) 1998-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1998-2011, PostgreSQL Global Development Group
*
* src/include/tsearch/ts_locale.h
*
diff --git a/src/include/tsearch/ts_public.h b/src/include/tsearch/ts_public.h
index b8f43fbf0c..437f4369e2 100644
--- a/src/include/tsearch/ts_public.h
+++ b/src/include/tsearch/ts_public.h
@@ -4,7 +4,7 @@
* Public interface to various tsearch modules, such as
* parsers and dictionaries.
*
- * Copyright (c) 1998-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1998-2011, PostgreSQL Global Development Group
*
* src/include/tsearch/ts_public.h
*
diff --git a/src/include/tsearch/ts_type.h b/src/include/tsearch/ts_type.h
index 114352c492..6a33f851a3 100644
--- a/src/include/tsearch/ts_type.h
+++ b/src/include/tsearch/ts_type.h
@@ -3,7 +3,7 @@
* ts_type.h
* Definitions for the tsvector and tsquery types
*
- * Copyright (c) 1998-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1998-2011, PostgreSQL Global Development Group
*
* src/include/tsearch/ts_type.h
*
diff --git a/src/include/tsearch/ts_utils.h b/src/include/tsearch/ts_utils.h
index a41c2363b9..62890aabb7 100644
--- a/src/include/tsearch/ts_utils.h
+++ b/src/include/tsearch/ts_utils.h
@@ -3,7 +3,7 @@
* ts_utils.h
* helper utilities for tsearch
*
- * Copyright (c) 1998-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1998-2011, PostgreSQL Global Development Group
*
* src/include/tsearch/ts_utils.h
*
diff --git a/src/include/utils/acl.h b/src/include/utils/acl.h
index 430dc1f61e..d729e6f1d2 100644
--- a/src/include/utils/acl.h
+++ b/src/include/utils/acl.h
@@ -4,7 +4,7 @@
* Definition of (and support for) access control list data structures.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/acl.h
diff --git a/src/include/utils/array.h b/src/include/utils/array.h
index dba9c3d741..78a4c8a72f 100644
--- a/src/include/utils/array.h
+++ b/src/include/utils/array.h
@@ -46,7 +46,7 @@
* only work with varlena arrays.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/array.h
diff --git a/src/include/utils/ascii.h b/src/include/utils/ascii.h
index 3605d8464a..ad70e037bd 100644
--- a/src/include/utils/ascii.h
+++ b/src/include/utils/ascii.h
@@ -1,7 +1,7 @@
/*-----------------------------------------------------------------------
* ascii.h
*
- * Portions Copyright (c) 1999-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1999-2011, PostgreSQL Global Development Group
*
* src/include/utils/ascii.h
*
diff --git a/src/include/utils/attoptcache.h b/src/include/utils/attoptcache.h
index 8117bb1ffa..053e7ae691 100644
--- a/src/include/utils/attoptcache.h
+++ b/src/include/utils/attoptcache.h
@@ -3,7 +3,7 @@
* attoptcache.h
* Attribute options cache.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/attoptcache.h
diff --git a/src/include/utils/builtins.h b/src/include/utils/builtins.h
index 1888e312f8..07a72b208e 100644
--- a/src/include/utils/builtins.h
+++ b/src/include/utils/builtins.h
@@ -4,7 +4,7 @@
* Declarations for operations on built-in types.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/builtins.h
diff --git a/src/include/utils/bytea.h b/src/include/utils/bytea.h
index 09908a65ea..df247c40a9 100644
--- a/src/include/utils/bytea.h
+++ b/src/include/utils/bytea.h
@@ -4,7 +4,7 @@
* Declarations for BYTEA data type support.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/bytea.h
diff --git a/src/include/utils/catcache.h b/src/include/utils/catcache.h
index dba6922dc0..7a990528e7 100644
--- a/src/include/utils/catcache.h
+++ b/src/include/utils/catcache.h
@@ -10,7 +10,7 @@
* guarantee that there can only be one matching row for a key combination.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/catcache.h
diff --git a/src/include/utils/combocid.h b/src/include/utils/combocid.h
index 8355f14eaf..b21cac1904 100644
--- a/src/include/utils/combocid.h
+++ b/src/include/utils/combocid.h
@@ -4,7 +4,7 @@
* Combo command ID support routines
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/combocid.h
diff --git a/src/include/utils/date.h b/src/include/utils/date.h
index 9a6148b00d..9e10e1afce 100644
--- a/src/include/utils/date.h
+++ b/src/include/utils/date.h
@@ -4,7 +4,7 @@
* Definitions for the SQL92 "date" and "time" types.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/date.h
diff --git a/src/include/utils/datetime.h b/src/include/utils/datetime.h
index 65b6b2efdb..11672458f4 100644
--- a/src/include/utils/datetime.h
+++ b/src/include/utils/datetime.h
@@ -6,7 +6,7 @@
* including abstime, reltime, date, and time.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/datetime.h
diff --git a/src/include/utils/datum.h b/src/include/utils/datum.h
index a3d4c65d7c..5c11a22f63 100644
--- a/src/include/utils/datum.h
+++ b/src/include/utils/datum.h
@@ -8,7 +8,7 @@
* of the Datum. (We do it this way because in most situations the caller
* can look up the info just once and use it for many per-datum operations.)
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/datum.h
diff --git a/src/include/utils/dynahash.h b/src/include/utils/dynahash.h
index a2bba143cb..bf48491efc 100644
--- a/src/include/utils/dynahash.h
+++ b/src/include/utils/dynahash.h
@@ -4,7 +4,7 @@
* POSTGRES dynahash.h file definitions
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/dynahash.h
diff --git a/src/include/utils/dynamic_loader.h b/src/include/utils/dynamic_loader.h
index 3aa31387a3..42e0345645 100644
--- a/src/include/utils/dynamic_loader.h
+++ b/src/include/utils/dynamic_loader.h
@@ -4,7 +4,7 @@
*
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/dynamic_loader.h
diff --git a/src/include/utils/elog.h b/src/include/utils/elog.h
index 92641ba184..71a1cdbd78 100644
--- a/src/include/utils/elog.h
+++ b/src/include/utils/elog.h
@@ -4,7 +4,7 @@
* POSTGRES error reporting/logging definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/elog.h
diff --git a/src/include/utils/errcodes.h b/src/include/utils/errcodes.h
index 80a4ca1acc..7f2d589f14 100644
--- a/src/include/utils/errcodes.h
+++ b/src/include/utils/errcodes.h
@@ -9,7 +9,7 @@
* string is determined by the MAKE_SQLSTATE() macro, which is not defined
* in this file; it can be defined by the caller for special purposes.
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* src/include/utils/errcodes.h
*
diff --git a/src/include/utils/fmgrtab.h b/src/include/utils/fmgrtab.h
index 4cb3fcf4e4..266776003c 100644
--- a/src/include/utils/fmgrtab.h
+++ b/src/include/utils/fmgrtab.h
@@ -3,7 +3,7 @@
* fmgrtab.h
* The function manager's table of internal functions.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/fmgrtab.h
diff --git a/src/include/utils/formatting.h b/src/include/utils/formatting.h
index fcc5062cee..7cd3be1131 100644
--- a/src/include/utils/formatting.h
+++ b/src/include/utils/formatting.h
@@ -4,7 +4,7 @@
* src/include/utils/formatting.h
*
*
- * Portions Copyright (c) 1999-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1999-2011, PostgreSQL Global Development Group
*
* The PostgreSQL routines for a DateTime/int/float/numeric formatting,
* inspire with Oracle TO_CHAR() / TO_DATE() / TO_NUMBER() routines.
diff --git a/src/include/utils/geo_decls.h b/src/include/utils/geo_decls.h
index 24921fe460..bd61dd676a 100644
--- a/src/include/utils/geo_decls.h
+++ b/src/include/utils/geo_decls.h
@@ -3,7 +3,7 @@
* geo_decls.h - Declarations for various 2D constructs.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/geo_decls.h
diff --git a/src/include/utils/guc.h b/src/include/utils/guc.h
index 7143d42bdc..91ad65e721 100644
--- a/src/include/utils/guc.h
+++ b/src/include/utils/guc.h
@@ -4,7 +4,7 @@
* External declarations pertaining to backend/utils/misc/guc.c and
* backend/utils/misc/guc-file.l
*
- * Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2000-2011, PostgreSQL Global Development Group
* Written by Peter Eisentraut .
*
* src/include/utils/guc.h
diff --git a/src/include/utils/guc_tables.h b/src/include/utils/guc_tables.h
index 76dab79059..073b77d28c 100644
--- a/src/include/utils/guc_tables.h
+++ b/src/include/utils/guc_tables.h
@@ -5,7 +5,7 @@
*
* See src/backend/utils/misc/README for design notes.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/utils/guc_tables.h
*
diff --git a/src/include/utils/help_config.h b/src/include/utils/help_config.h
index cb411cbcfd..74b38beb84 100644
--- a/src/include/utils/help_config.h
+++ b/src/include/utils/help_config.h
@@ -3,7 +3,7 @@
* help_config.h
* Interface to the --help-config option of main.c
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/include/utils/help_config.h
*
diff --git a/src/include/utils/hsearch.h b/src/include/utils/hsearch.h
index b736278075..bca34d23e2 100644
--- a/src/include/utils/hsearch.h
+++ b/src/include/utils/hsearch.h
@@ -4,7 +4,7 @@
* exported definitions for utils/hash/dynahash.c; see notes therein
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/hsearch.h
diff --git a/src/include/utils/inet.h b/src/include/utils/inet.h
index 3a522e6485..9626a2de81 100644
--- a/src/include/utils/inet.h
+++ b/src/include/utils/inet.h
@@ -4,7 +4,7 @@
* Declarations for operations on INET datatypes.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/inet.h
diff --git a/src/include/utils/int8.h b/src/include/utils/int8.h
index 219fcdb946..5c39c7655c 100644
--- a/src/include/utils/int8.h
+++ b/src/include/utils/int8.h
@@ -4,7 +4,7 @@
* Declarations for operations on 64-bit integers.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/int8.h
diff --git a/src/include/utils/inval.h b/src/include/utils/inval.h
index 6bfea9d5e7..dda2a63d6e 100644
--- a/src/include/utils/inval.h
+++ b/src/include/utils/inval.h
@@ -4,7 +4,7 @@
* POSTGRES cache invalidation dispatcher definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/inval.h
diff --git a/src/include/utils/logtape.h b/src/include/utils/logtape.h
index 27db38d2df..425e3311e0 100644
--- a/src/include/utils/logtape.h
+++ b/src/include/utils/logtape.h
@@ -5,7 +5,7 @@
*
* See logtape.c for explanations.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/logtape.h
diff --git a/src/include/utils/lsyscache.h b/src/include/utils/lsyscache.h
index 7bf3f360f5..26c241c348 100644
--- a/src/include/utils/lsyscache.h
+++ b/src/include/utils/lsyscache.h
@@ -3,7 +3,7 @@
* lsyscache.h
* Convenience routines for common queries in the system catalog cache.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/lsyscache.h
diff --git a/src/include/utils/memutils.h b/src/include/utils/memutils.h
index 0914f77c4f..5ee533b30d 100644
--- a/src/include/utils/memutils.h
+++ b/src/include/utils/memutils.h
@@ -7,7 +7,7 @@
* of the API of the memory management subsystem.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/memutils.h
diff --git a/src/include/utils/nabstime.h b/src/include/utils/nabstime.h
index 35ec2de644..d750d2be2c 100644
--- a/src/include/utils/nabstime.h
+++ b/src/include/utils/nabstime.h
@@ -4,7 +4,7 @@
* Definitions for the "new" abstime code.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/nabstime.h
diff --git a/src/include/utils/numeric.h b/src/include/utils/numeric.h
index 3801ef6215..6147634817 100644
--- a/src/include/utils/numeric.h
+++ b/src/include/utils/numeric.h
@@ -5,7 +5,7 @@
*
* Original coding 1998, Jan Wieck. Heavily revised 2003, Tom Lane.
*
- * Copyright (c) 1998-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1998-2011, PostgreSQL Global Development Group
*
* src/include/utils/numeric.h
*
diff --git a/src/include/utils/palloc.h b/src/include/utils/palloc.h
index 275deba638..d0330a5727 100644
--- a/src/include/utils/palloc.h
+++ b/src/include/utils/palloc.h
@@ -18,7 +18,7 @@
* everything that should be freed. See utils/mmgr/README for more info.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/palloc.h
diff --git a/src/include/utils/pg_crc.h b/src/include/utils/pg_crc.h
index a6a1d81953..cc68acd6f8 100644
--- a/src/include/utils/pg_crc.h
+++ b/src/include/utils/pg_crc.h
@@ -14,7 +14,7 @@
* code for possible future use.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/pg_crc.h
diff --git a/src/include/utils/pg_locale.h b/src/include/utils/pg_locale.h
index 7a0115d141..d56bf38d2d 100644
--- a/src/include/utils/pg_locale.h
+++ b/src/include/utils/pg_locale.h
@@ -4,7 +4,7 @@
*
* src/include/utils/pg_locale.h
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
*-----------------------------------------------------------------------
*/
diff --git a/src/include/utils/pg_rusage.h b/src/include/utils/pg_rusage.h
index 3e13137c9a..cda4de29ef 100644
--- a/src/include/utils/pg_rusage.h
+++ b/src/include/utils/pg_rusage.h
@@ -4,7 +4,7 @@
* header file for resource usage measurement support routines
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/pg_rusage.h
diff --git a/src/include/utils/plancache.h b/src/include/utils/plancache.h
index 5381b70d0e..b8639a59a0 100644
--- a/src/include/utils/plancache.h
+++ b/src/include/utils/plancache.h
@@ -5,7 +5,7 @@
*
* See plancache.c for comments.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/plancache.h
diff --git a/src/include/utils/portal.h b/src/include/utils/portal.h
index 37dba762cc..639ccc4546 100644
--- a/src/include/utils/portal.h
+++ b/src/include/utils/portal.h
@@ -36,7 +36,7 @@
* to look like NO SCROLL cursors.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/portal.h
diff --git a/src/include/utils/rbtree.h b/src/include/utils/rbtree.h
index 3c3e7a5333..c506a689e0 100644
--- a/src/include/utils/rbtree.h
+++ b/src/include/utils/rbtree.h
@@ -3,7 +3,7 @@
* rbtree.h
* interface for PostgreSQL generic Red-Black binary tree package
*
- * Copyright (c) 2009-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2009-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/include/utils/rbtree.h
diff --git a/src/include/utils/rel.h b/src/include/utils/rel.h
index d5b5e58de3..5498df93ca 100644
--- a/src/include/utils/rel.h
+++ b/src/include/utils/rel.h
@@ -4,7 +4,7 @@
* POSTGRES relation descriptor (a/k/a relcache entry) definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/rel.h
diff --git a/src/include/utils/relcache.h b/src/include/utils/relcache.h
index 35000500c1..1f4def5684 100644
--- a/src/include/utils/relcache.h
+++ b/src/include/utils/relcache.h
@@ -4,7 +4,7 @@
* Relation descriptor cache definitions.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/relcache.h
diff --git a/src/include/utils/relmapper.h b/src/include/utils/relmapper.h
index 15cd49ec9f..e81b027870 100644
--- a/src/include/utils/relmapper.h
+++ b/src/include/utils/relmapper.h
@@ -4,7 +4,7 @@
* Catalog-to-filenode mapping
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/relmapper.h
diff --git a/src/include/utils/resowner.h b/src/include/utils/resowner.h
index 7ce1db5dd2..2d08312b34 100644
--- a/src/include/utils/resowner.h
+++ b/src/include/utils/resowner.h
@@ -9,7 +9,7 @@
* See utils/resowner/README for more info.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/resowner.h
diff --git a/src/include/utils/selfuncs.h b/src/include/utils/selfuncs.h
index 0c6e918af7..e9913aa049 100644
--- a/src/include/utils/selfuncs.h
+++ b/src/include/utils/selfuncs.h
@@ -5,7 +5,7 @@
* standard operators and index access methods.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/selfuncs.h
diff --git a/src/include/utils/snapmgr.h b/src/include/utils/snapmgr.h
index f03647befe..6d784d22c5 100644
--- a/src/include/utils/snapmgr.h
+++ b/src/include/utils/snapmgr.h
@@ -3,7 +3,7 @@
* snapmgr.h
* POSTGRES snapshot manager
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/snapmgr.h
diff --git a/src/include/utils/snapshot.h b/src/include/utils/snapshot.h
index 3d243258f9..859e52ac79 100644
--- a/src/include/utils/snapshot.h
+++ b/src/include/utils/snapshot.h
@@ -3,7 +3,7 @@
* snapshot.h
* POSTGRES snapshot definition
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/snapshot.h
diff --git a/src/include/utils/spccache.h b/src/include/utils/spccache.h
index 876b608433..aea396a28b 100644
--- a/src/include/utils/spccache.h
+++ b/src/include/utils/spccache.h
@@ -3,7 +3,7 @@
* spccache.h
* Tablespace cache.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/spccache.h
diff --git a/src/include/utils/syscache.h b/src/include/utils/syscache.h
index 30e0f8f3bd..48700e8a5b 100644
--- a/src/include/utils/syscache.h
+++ b/src/include/utils/syscache.h
@@ -6,7 +6,7 @@
* See also lsyscache.h, which provides convenience routines for
* common cache-lookup operations.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/syscache.h
diff --git a/src/include/utils/timestamp.h b/src/include/utils/timestamp.h
index db7b729ad3..9e51b58dde 100644
--- a/src/include/utils/timestamp.h
+++ b/src/include/utils/timestamp.h
@@ -3,7 +3,7 @@
* timestamp.h
* Definitions for the SQL92 "timestamp" and "interval" types.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/timestamp.h
diff --git a/src/include/utils/tqual.h b/src/include/utils/tqual.h
index df14f59e34..689f4825d5 100644
--- a/src/include/utils/tqual.h
+++ b/src/include/utils/tqual.h
@@ -5,7 +5,7 @@
*
* Should be moved/renamed... - vadim 07/28/98
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/tqual.h
diff --git a/src/include/utils/tuplesort.h b/src/include/utils/tuplesort.h
index 8a31dff34c..b38c260d50 100644
--- a/src/include/utils/tuplesort.h
+++ b/src/include/utils/tuplesort.h
@@ -10,7 +10,7 @@
* amounts are sorted using temporary files and a standard external sort
* algorithm.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/tuplesort.h
diff --git a/src/include/utils/tuplestore.h b/src/include/utils/tuplestore.h
index aa81e25e3e..0c3e2eaf9f 100644
--- a/src/include/utils/tuplestore.h
+++ b/src/include/utils/tuplestore.h
@@ -21,7 +21,7 @@
* Also, we have changed the API to return tuples in TupleTableSlots,
* so that there is a check to prevent attempted access to system columns.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/tuplestore.h
diff --git a/src/include/utils/typcache.h b/src/include/utils/typcache.h
index 313f781591..2154657d88 100644
--- a/src/include/utils/typcache.h
+++ b/src/include/utils/typcache.h
@@ -6,7 +6,7 @@
* The type cache exists to speed lookup of certain information about data
* types that is not directly available from a type's pg_type row.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/typcache.h
diff --git a/src/include/utils/tzparser.h b/src/include/utils/tzparser.h
index 6c262039ac..ba18819ef5 100644
--- a/src/include/utils/tzparser.h
+++ b/src/include/utils/tzparser.h
@@ -3,7 +3,7 @@
* tzparser.h
* Timezone offset file parsing definitions.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/tzparser.h
diff --git a/src/include/utils/uuid.h b/src/include/utils/uuid.h
index 5562018dc9..13fb18ab54 100644
--- a/src/include/utils/uuid.h
+++ b/src/include/utils/uuid.h
@@ -5,7 +5,7 @@
* to avoid conflicts with any uuid_t type that might be defined by
* the system headers.
*
- * Copyright (c) 2007-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2007-2011, PostgreSQL Global Development Group
*
* src/include/utils/uuid.h
*
diff --git a/src/include/utils/varbit.h b/src/include/utils/varbit.h
index 3f35b090a6..847a1d33e2 100644
--- a/src/include/utils/varbit.h
+++ b/src/include/utils/varbit.h
@@ -5,7 +5,7 @@
*
* Code originally contributed by Adriaan Joubert.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/varbit.h
diff --git a/src/include/utils/xml.h b/src/include/utils/xml.h
index 5b65ad392b..74464e82d6 100644
--- a/src/include/utils/xml.h
+++ b/src/include/utils/xml.h
@@ -4,7 +4,7 @@
* Declarations for XML data type support.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/include/utils/xml.h
diff --git a/src/include/windowapi.h b/src/include/windowapi.h
index ddb2fa098c..369f05c071 100644
--- a/src/include/windowapi.h
+++ b/src/include/windowapi.h
@@ -19,7 +19,7 @@
* function in nodeWindowAgg.c for details.
*
*
- * Portions Copyright (c) 2000-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 2000-2011, PostgreSQL Global Development Group
*
* src/include/windowapi.h
*
diff --git a/src/interfaces/ecpg/compatlib/Makefile b/src/interfaces/ecpg/compatlib/Makefile
index eb9a76ae74..5caf1dc080 100644
--- a/src/interfaces/ecpg/compatlib/Makefile
+++ b/src/interfaces/ecpg/compatlib/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for ecpg compatibility library
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/interfaces/ecpg/compatlib/Makefile
diff --git a/src/interfaces/ecpg/ecpglib/Makefile b/src/interfaces/ecpg/ecpglib/Makefile
index 9a29d150c7..cdf84c3b09 100644
--- a/src/interfaces/ecpg/ecpglib/Makefile
+++ b/src/interfaces/ecpg/ecpglib/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for ecpg library
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/interfaces/ecpg/ecpglib/Makefile
diff --git a/src/interfaces/ecpg/ecpglib/pg_type.h b/src/interfaces/ecpg/ecpglib/pg_type.h
index edfd7e02f9..11c68edd62 100644
--- a/src/interfaces/ecpg/ecpglib/pg_type.h
+++ b/src/interfaces/ecpg/ecpglib/pg_type.h
@@ -5,7 +5,7 @@
*
* XXX keep this in sync with src/include/catalog/pg_type.h
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/interfaces/ecpg/ecpglib/pg_type.h
diff --git a/src/interfaces/ecpg/pgtypeslib/Makefile b/src/interfaces/ecpg/pgtypeslib/Makefile
index 2a5cb33f8e..cab4db18bc 100644
--- a/src/interfaces/ecpg/pgtypeslib/Makefile
+++ b/src/interfaces/ecpg/pgtypeslib/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for ecpg pgtypes library
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/interfaces/ecpg/pgtypeslib/Makefile
diff --git a/src/interfaces/ecpg/preproc/Makefile b/src/interfaces/ecpg/preproc/Makefile
index 4c8f8d699d..8e85fe9e5a 100644
--- a/src/interfaces/ecpg/preproc/Makefile
+++ b/src/interfaces/ecpg/preproc/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/interfaces/ecpg/preproc
#
-# Copyright (c) 1998-2010, PostgreSQL Global Development Group
+# Copyright (c) 1998-2011, PostgreSQL Global Development Group
#
# src/interfaces/ecpg/preproc/Makefile
#
diff --git a/src/interfaces/ecpg/preproc/check_rules.pl b/src/interfaces/ecpg/preproc/check_rules.pl
index 3a796493d5..5e2b65fd82 100755
--- a/src/interfaces/ecpg/preproc/check_rules.pl
+++ b/src/interfaces/ecpg/preproc/check_rules.pl
@@ -3,7 +3,7 @@
# test parser generater for ecpg
# call with backend parser as stdin
#
-# Copyright (c) 2009-2010, PostgreSQL Global Development Group
+# Copyright (c) 2009-2011, PostgreSQL Global Development Group
#
# Written by Michael Meskes
#
diff --git a/src/interfaces/ecpg/preproc/ecpg.c b/src/interfaces/ecpg/preproc/ecpg.c
index 917200abd0..f198035a9a 100644
--- a/src/interfaces/ecpg/preproc/ecpg.c
+++ b/src/interfaces/ecpg/preproc/ecpg.c
@@ -1,7 +1,7 @@
/* src/interfaces/ecpg/preproc/ecpg.c */
/* Main for ecpg, the PostgreSQL embedded SQL precompiler. */
-/* Copyright (c) 1996-2010, PostgreSQL Global Development Group */
+/* Copyright (c) 1996-2011, PostgreSQL Global Development Group */
#include "postgres_fe.h"
diff --git a/src/interfaces/ecpg/preproc/keywords.c b/src/interfaces/ecpg/preproc/keywords.c
index 5c8a525def..3f17f24d98 100644
--- a/src/interfaces/ecpg/preproc/keywords.c
+++ b/src/interfaces/ecpg/preproc/keywords.c
@@ -4,7 +4,7 @@
* lexical token lookup for key words in PostgreSQL
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/ecpg/preproc/parse.pl b/src/interfaces/ecpg/preproc/parse.pl
index b765a58305..99c1931c94 100644
--- a/src/interfaces/ecpg/preproc/parse.pl
+++ b/src/interfaces/ecpg/preproc/parse.pl
@@ -3,7 +3,7 @@
# parser generater for ecpg
# call with backend parser as stdin
#
-# Copyright (c) 2007-2010, PostgreSQL Global Development Group
+# Copyright (c) 2007-2011, PostgreSQL Global Development Group
#
# Written by Mike Aubury
# Michael Meskes
diff --git a/src/interfaces/ecpg/preproc/parser.c b/src/interfaces/ecpg/preproc/parser.c
index e347977344..cd5323f6c1 100644
--- a/src/interfaces/ecpg/preproc/parser.c
+++ b/src/interfaces/ecpg/preproc/parser.c
@@ -10,7 +10,7 @@
* analyze.c and related files.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/interfaces/ecpg/preproc/pgc.l b/src/interfaces/ecpg/preproc/pgc.l
index f528f214c0..019b70bbaf 100644
--- a/src/interfaces/ecpg/preproc/pgc.l
+++ b/src/interfaces/ecpg/preproc/pgc.l
@@ -7,7 +7,7 @@
* This is a modified version of src/backend/parser/scan.l
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/ecpg/test/pg_regress_ecpg.c b/src/interfaces/ecpg/test/pg_regress_ecpg.c
index ba50808502..12b931edc8 100644
--- a/src/interfaces/ecpg/test/pg_regress_ecpg.c
+++ b/src/interfaces/ecpg/test/pg_regress_ecpg.c
@@ -8,7 +8,7 @@
*
* This code is released under the terms of the PostgreSQL License.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/interfaces/ecpg/test/pg_regress_ecpg.c
diff --git a/src/interfaces/libpq/Makefile b/src/interfaces/libpq/Makefile
index cebba4f1b8..f4111c4b76 100644
--- a/src/interfaces/libpq/Makefile
+++ b/src/interfaces/libpq/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/interfaces/libpq library
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/interfaces/libpq/Makefile
diff --git a/src/interfaces/libpq/fe-auth.c b/src/interfaces/libpq/fe-auth.c
index f7ca0aa302..0d3cad0b00 100644
--- a/src/interfaces/libpq/fe-auth.c
+++ b/src/interfaces/libpq/fe-auth.c
@@ -3,7 +3,7 @@
* fe-auth.c
* The front-end (client) authorization routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/interfaces/libpq/fe-auth.h b/src/interfaces/libpq/fe-auth.h
index 936e1880e2..bfe673e782 100644
--- a/src/interfaces/libpq/fe-auth.h
+++ b/src/interfaces/libpq/fe-auth.h
@@ -4,7 +4,7 @@
*
* Definitions for network authentication routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/interfaces/libpq/fe-auth.h
diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c
index bf8beb7b89..b8013ed42f 100644
--- a/src/interfaces/libpq/fe-connect.c
+++ b/src/interfaces/libpq/fe-connect.c
@@ -3,7 +3,7 @@
* fe-connect.c
* functions related to setting up a connection to the backend
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/libpq/fe-exec.c b/src/interfaces/libpq/fe-exec.c
index 7bb7fbe557..dcdb1a9351 100644
--- a/src/interfaces/libpq/fe-exec.c
+++ b/src/interfaces/libpq/fe-exec.c
@@ -3,7 +3,7 @@
* fe-exec.c
* functions related to sending a query down to the backend
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/libpq/fe-lobj.c b/src/interfaces/libpq/fe-lobj.c
index 816f5990a8..27f93e6af7 100644
--- a/src/interfaces/libpq/fe-lobj.c
+++ b/src/interfaces/libpq/fe-lobj.c
@@ -3,7 +3,7 @@
* fe-lobj.c
* Front-end large object interface
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/libpq/fe-misc.c b/src/interfaces/libpq/fe-misc.c
index 999f60b0d4..17dde4aecc 100644
--- a/src/interfaces/libpq/fe-misc.c
+++ b/src/interfaces/libpq/fe-misc.c
@@ -19,7 +19,7 @@
* routines.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/interfaces/libpq/fe-print.c b/src/interfaces/libpq/fe-print.c
index 0bf788f8a1..5fa3be0045 100644
--- a/src/interfaces/libpq/fe-print.c
+++ b/src/interfaces/libpq/fe-print.c
@@ -3,7 +3,7 @@
* fe-print.c
* functions for pretty-printing query results
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* These functions were formerly part of fe-exec.c, but they
diff --git a/src/interfaces/libpq/fe-protocol2.c b/src/interfaces/libpq/fe-protocol2.c
index ccf1342329..058a25b803 100644
--- a/src/interfaces/libpq/fe-protocol2.c
+++ b/src/interfaces/libpq/fe-protocol2.c
@@ -3,7 +3,7 @@
* fe-protocol2.c
* functions that are specific to frontend/backend protocol version 2
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/libpq/fe-protocol3.c b/src/interfaces/libpq/fe-protocol3.c
index c398304156..2a8dbdfd3a 100644
--- a/src/interfaces/libpq/fe-protocol3.c
+++ b/src/interfaces/libpq/fe-protocol3.c
@@ -3,7 +3,7 @@
* fe-protocol3.c
* functions that are specific to frontend/backend protocol version 3
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/libpq/fe-secure.c b/src/interfaces/libpq/fe-secure.c
index 1db020b3c3..8f5ba529fc 100644
--- a/src/interfaces/libpq/fe-secure.c
+++ b/src/interfaces/libpq/fe-secure.c
@@ -6,7 +6,7 @@
* message integrity and endpoint authentication.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/libpq/libpq-events.c b/src/interfaces/libpq/libpq-events.c
index 8be46cb87b..885b39bc99 100644
--- a/src/interfaces/libpq/libpq-events.c
+++ b/src/interfaces/libpq/libpq-events.c
@@ -3,7 +3,7 @@
* libpq-events.c
* functions for supporting the libpq "events" API
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/libpq/libpq-events.h b/src/interfaces/libpq/libpq-events.h
index 0f11f19c15..05417d0611 100644
--- a/src/interfaces/libpq/libpq-events.h
+++ b/src/interfaces/libpq/libpq-events.h
@@ -5,7 +5,7 @@
* that invoke the libpq "events" API, but are not interesting to
* ordinary users of libpq.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/interfaces/libpq/libpq-events.h
diff --git a/src/interfaces/libpq/libpq-fe.h b/src/interfaces/libpq/libpq-fe.h
index 4eea115f37..de13a03cf0 100644
--- a/src/interfaces/libpq/libpq-fe.h
+++ b/src/interfaces/libpq/libpq-fe.h
@@ -4,7 +4,7 @@
* This file contains definitions for structures and
* externs for functions used by frontend postgres applications.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/interfaces/libpq/libpq-fe.h
diff --git a/src/interfaces/libpq/libpq-int.h b/src/interfaces/libpq/libpq-int.h
index bac3d0b3bf..e9a2b718d3 100644
--- a/src/interfaces/libpq/libpq-int.h
+++ b/src/interfaces/libpq/libpq-int.h
@@ -9,7 +9,7 @@
* more likely to break across PostgreSQL releases than code that uses
* only the official API.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/interfaces/libpq/libpq-int.h
diff --git a/src/interfaces/libpq/libpq.rc.in b/src/interfaces/libpq/libpq.rc.in
index d8bd94d04b..adf00b1a28 100644
--- a/src/interfaces/libpq/libpq.rc.in
+++ b/src/interfaces/libpq/libpq.rc.in
@@ -17,7 +17,7 @@ BEGIN
VALUE "FileDescription", "PostgreSQL Access Library\0"
VALUE "FileVersion", "9.1.0\0"
VALUE "InternalName", "libpq\0"
- VALUE "LegalCopyright", "Copyright (C) 2010\0"
+ VALUE "LegalCopyright", "Copyright (C) 2011\0"
VALUE "LegalTrademarks", "\0"
VALUE "OriginalFilename", "libpq.dll\0"
VALUE "ProductName", "PostgreSQL\0"
diff --git a/src/interfaces/libpq/pqexpbuffer.c b/src/interfaces/libpq/pqexpbuffer.c
index fb296c31a6..1abfed7989 100644
--- a/src/interfaces/libpq/pqexpbuffer.c
+++ b/src/interfaces/libpq/pqexpbuffer.c
@@ -14,7 +14,7 @@
* a usable vsnprintf(), then a copy of our own implementation of it will
* be linked into libpq.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/interfaces/libpq/pqexpbuffer.c
diff --git a/src/interfaces/libpq/pqexpbuffer.h b/src/interfaces/libpq/pqexpbuffer.h
index f41a144310..be7cc61d1c 100644
--- a/src/interfaces/libpq/pqexpbuffer.h
+++ b/src/interfaces/libpq/pqexpbuffer.h
@@ -15,7 +15,7 @@
* a usable vsnprintf(), then a copy of our own implementation of it will
* be linked into libpq.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/interfaces/libpq/pqexpbuffer.h
diff --git a/src/interfaces/libpq/pqsignal.c b/src/interfaces/libpq/pqsignal.c
index 0ff6090ef2..04cee8d395 100644
--- a/src/interfaces/libpq/pqsignal.c
+++ b/src/interfaces/libpq/pqsignal.c
@@ -4,7 +4,7 @@
* reliable BSD-style signal(2) routine stolen from RWW who stole it
* from Stevens...
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/interfaces/libpq/pqsignal.h b/src/interfaces/libpq/pqsignal.h
index 302182a954..02966fd49e 100644
--- a/src/interfaces/libpq/pqsignal.h
+++ b/src/interfaces/libpq/pqsignal.h
@@ -4,7 +4,7 @@
* prototypes for the reliable BSD-style signal(2) routine.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/interfaces/libpq/pqsignal.h
diff --git a/src/interfaces/libpq/pthread-win32.c b/src/interfaces/libpq/pthread-win32.c
index 709ddecd77..e24a42dcd7 100644
--- a/src/interfaces/libpq/pthread-win32.c
+++ b/src/interfaces/libpq/pthread-win32.c
@@ -3,7 +3,7 @@
* pthread-win32.c
* partial pthread implementation for win32
*
-* Copyright (c) 2004-2010, PostgreSQL Global Development Group
+* Copyright (c) 2004-2011, PostgreSQL Global Development Group
* IDENTIFICATION
* src/interfaces/libpq/pthread-win32.c
*
diff --git a/src/interfaces/libpq/win32.c b/src/interfaces/libpq/win32.c
index 151751ca75..d77fc48b5e 100644
--- a/src/interfaces/libpq/win32.c
+++ b/src/interfaces/libpq/win32.c
@@ -15,7 +15,7 @@
* The error constants are taken from the Frambak Bakfram LGSOCKET
* library guys who in turn took them from the Winsock FAQ.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*/
diff --git a/src/pl/plperl/plperl.h b/src/pl/plperl/plperl.h
index 6b5f75156e..98d18e7723 100644
--- a/src/pl/plperl/plperl.h
+++ b/src/pl/plperl/plperl.h
@@ -5,7 +5,7 @@
*
* This should be included _AFTER_ postgres.h and system include files
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1995, Regents of the University of California
*
* src/pl/plperl/plperl.h
diff --git a/src/pl/plpgsql/src/gram.y b/src/pl/plpgsql/src/gram.y
index e4f485b553..eae9bbad6c 100644
--- a/src/pl/plpgsql/src/gram.y
+++ b/src/pl/plpgsql/src/gram.y
@@ -3,7 +3,7 @@
*
* gram.y - Parser for the PL/pgSQL procedural language
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/pl/plpgsql/src/pl_comp.c b/src/pl/plpgsql/src/pl_comp.c
index b80802576a..41188a2369 100644
--- a/src/pl/plpgsql/src/pl_comp.c
+++ b/src/pl/plpgsql/src/pl_comp.c
@@ -3,7 +3,7 @@
* pl_comp.c - Compiler part of the PL/pgSQL
* procedural language
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/pl/plpgsql/src/pl_exec.c b/src/pl/plpgsql/src/pl_exec.c
index 3d20fa72c2..3e40945e35 100644
--- a/src/pl/plpgsql/src/pl_exec.c
+++ b/src/pl/plpgsql/src/pl_exec.c
@@ -3,7 +3,7 @@
* pl_exec.c - Executor for the PL/pgSQL
* procedural language
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/pl/plpgsql/src/pl_funcs.c b/src/pl/plpgsql/src/pl_funcs.c
index 6153aa4ce2..e24f71ac6c 100644
--- a/src/pl/plpgsql/src/pl_funcs.c
+++ b/src/pl/plpgsql/src/pl_funcs.c
@@ -3,7 +3,7 @@
* pl_funcs.c - Misc functions for the PL/pgSQL
* procedural language
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/pl/plpgsql/src/pl_handler.c b/src/pl/plpgsql/src/pl_handler.c
index ee49d71d23..8f7080e88b 100644
--- a/src/pl/plpgsql/src/pl_handler.c
+++ b/src/pl/plpgsql/src/pl_handler.c
@@ -3,7 +3,7 @@
* pl_handler.c - Handler for the PL/pgSQL
* procedural language
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/pl/plpgsql/src/pl_scanner.c b/src/pl/plpgsql/src/pl_scanner.c
index aa7615beec..6675184d61 100644
--- a/src/pl/plpgsql/src/pl_scanner.c
+++ b/src/pl/plpgsql/src/pl_scanner.c
@@ -4,7 +4,7 @@
* lexical scanning for PL/pgSQL
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/pl/plpgsql/src/plerrcodes.h b/src/pl/plpgsql/src/plerrcodes.h
index 1bcc4d6deb..812446ffdf 100644
--- a/src/pl/plpgsql/src/plerrcodes.h
+++ b/src/pl/plpgsql/src/plerrcodes.h
@@ -7,7 +7,7 @@
* with some sort of sed hackery, but no time for that now. It's likely
* that an exact mapping will not be what's wanted anyhow ...
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* src/pl/plpgsql/src/plerrcodes.h
*
diff --git a/src/pl/plpgsql/src/plpgsql.h b/src/pl/plpgsql/src/plpgsql.h
index 155796be0f..0ad7e28136 100644
--- a/src/pl/plpgsql/src/plpgsql.h
+++ b/src/pl/plpgsql/src/plpgsql.h
@@ -3,7 +3,7 @@
* plpgsql.h - Definitions for the PL/pgSQL
* procedural language
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/chklocale.c b/src/port/chklocale.c
index 00f1ea817f..8fd092e2d6 100644
--- a/src/port/chklocale.c
+++ b/src/port/chklocale.c
@@ -4,7 +4,7 @@
* Functions for handling locale-related info
*
*
- * Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/port/dirent.c b/src/port/dirent.c
index 2efe855978..9e1d1317ef 100644
--- a/src/port/dirent.c
+++ b/src/port/dirent.c
@@ -3,7 +3,7 @@
* dirent.c
* opendir/readdir/closedir for win32/msvc
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/dirmod.c b/src/port/dirmod.c
index 7ab3c9a027..0d373a428b 100644
--- a/src/port/dirmod.c
+++ b/src/port/dirmod.c
@@ -3,7 +3,7 @@
* dirmod.c
* directory handling functions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* This includes replacement versions of functions that work on
diff --git a/src/port/exec.c b/src/port/exec.c
index 8aaee2bb5f..2405140128 100644
--- a/src/port/exec.c
+++ b/src/port/exec.c
@@ -4,7 +4,7 @@
* Functions for finding and validating executable files
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/fseeko.c b/src/port/fseeko.c
index 782e1679b4..84036e4d93 100644
--- a/src/port/fseeko.c
+++ b/src/port/fseeko.c
@@ -3,7 +3,7 @@
* fseeko.c
* 64-bit versions of fseeko/ftello()
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/getaddrinfo.c b/src/port/getaddrinfo.c
index 3d33706733..654858e639 100644
--- a/src/port/getaddrinfo.c
+++ b/src/port/getaddrinfo.c
@@ -13,7 +13,7 @@
* use the Windows native routines, but if not, we use our own.
*
*
- * Copyright (c) 2003-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2003-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/port/getaddrinfo.c
diff --git a/src/port/gethostname.c b/src/port/gethostname.c
index 4a6fdc6d92..a49fe20e57 100644
--- a/src/port/gethostname.c
+++ b/src/port/gethostname.c
@@ -3,7 +3,7 @@
* gethostname.c
* gethostname using uname
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/port/getrusage.c b/src/port/getrusage.c
index e9747640f9..677a6f9859 100644
--- a/src/port/getrusage.c
+++ b/src/port/getrusage.c
@@ -3,7 +3,7 @@
* getrusage.c
* get information about resource utilisation
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/isinf.c b/src/port/isinf.c
index dc5ebf9618..ec4d4d78e4 100644
--- a/src/port/isinf.c
+++ b/src/port/isinf.c
@@ -2,7 +2,7 @@
*
* isinf.c
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/kill.c b/src/port/kill.c
index 7e7f1b311c..e5e750a702 100644
--- a/src/port/kill.c
+++ b/src/port/kill.c
@@ -3,7 +3,7 @@
* kill.c
* kill()
*
- * Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* This is a replacement version of kill for Win32 which sends
* signals that the backend can recognize.
diff --git a/src/port/memcmp.c b/src/port/memcmp.c
index 365e3e3e28..185a9c59a8 100644
--- a/src/port/memcmp.c
+++ b/src/port/memcmp.c
@@ -3,7 +3,7 @@
* memcmp.c
* compares memory bytes
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/port/noblock.c b/src/port/noblock.c
index 8cd6a345a1..9a90f6826e 100644
--- a/src/port/noblock.c
+++ b/src/port/noblock.c
@@ -3,7 +3,7 @@
* noblock.c
* set a file descriptor as non-blocking
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
diff --git a/src/port/open.c b/src/port/open.c
index 9d66a38114..9831d1d69a 100644
--- a/src/port/open.c
+++ b/src/port/open.c
@@ -4,7 +4,7 @@
* Win32 open() replacement
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/port/open.c
*
diff --git a/src/port/path.c b/src/port/path.c
index 003368f96c..ed2241f9ec 100644
--- a/src/port/path.c
+++ b/src/port/path.c
@@ -3,7 +3,7 @@
* path.c
* portable path handling routines
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/pgcheckdir.c b/src/port/pgcheckdir.c
index 12ec8a6b73..9453bcb68a 100644
--- a/src/port/pgcheckdir.c
+++ b/src/port/pgcheckdir.c
@@ -5,7 +5,7 @@
* A simple subroutine to check whether a directory exists and is empty or not.
* Useful in both initdb and the backend.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*-------------------------------------------------------------------------
diff --git a/src/port/pgsleep.c b/src/port/pgsleep.c
index 744334e6af..988bfb05db 100644
--- a/src/port/pgsleep.c
+++ b/src/port/pgsleep.c
@@ -4,7 +4,7 @@
* Portable delay handling.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/port/pgsleep.c
*
diff --git a/src/port/pgstrcasecmp.c b/src/port/pgstrcasecmp.c
index f6359f25b3..1680124df0 100644
--- a/src/port/pgstrcasecmp.c
+++ b/src/port/pgstrcasecmp.c
@@ -14,7 +14,7 @@
* NB: this code should match downcase_truncate_identifier() in scansup.c.
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/port/pgstrcasecmp.c
*
diff --git a/src/port/pipe.c b/src/port/pipe.c
index a30edf613d..0963cbba78 100644
--- a/src/port/pipe.c
+++ b/src/port/pipe.c
@@ -3,7 +3,7 @@
* pipe.c
* pipe()
*
- * Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* This is a replacement version of pipe for Win32 which allows
* returned handles to be used in select(). Note that read/write calls
diff --git a/src/port/random.c b/src/port/random.c
index 525b2bea41..0fe492b2c6 100644
--- a/src/port/random.c
+++ b/src/port/random.c
@@ -3,7 +3,7 @@
* random.c
* random() wrapper
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/sprompt.c b/src/port/sprompt.c
index 856833b8bc..c917f91e00 100644
--- a/src/port/sprompt.c
+++ b/src/port/sprompt.c
@@ -3,7 +3,7 @@
* sprompt.c
* simple_prompt() routine
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/srandom.c b/src/port/srandom.c
index 94813dac94..d70e3d855f 100644
--- a/src/port/srandom.c
+++ b/src/port/srandom.c
@@ -3,7 +3,7 @@
* srandom.c
* srandom() wrapper
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/strdup.c b/src/port/strdup.c
index d86f052a54..e6274366ca 100644
--- a/src/port/strdup.c
+++ b/src/port/strdup.c
@@ -3,7 +3,7 @@
* strdup.c
* copies a null-terminated string.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/strlcpy.c b/src/port/strlcpy.c
index 8f751eb88b..b20af029cc 100644
--- a/src/port/strlcpy.c
+++ b/src/port/strlcpy.c
@@ -3,7 +3,7 @@
* strlcpy.c
* strncpy done right
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
*
* IDENTIFICATION
diff --git a/src/port/strtol.c b/src/port/strtol.c
index 8513858634..2689efdd46 100644
--- a/src/port/strtol.c
+++ b/src/port/strtol.c
@@ -2,7 +2,7 @@
* src/port/strtol.c
*
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1990 The Regents of the University of California.
* All rights reserved.
*
diff --git a/src/port/thread.c b/src/port/thread.c
index 2d54d228ba..bca5815a09 100644
--- a/src/port/thread.c
+++ b/src/port/thread.c
@@ -5,7 +5,7 @@
* Prototypes and macros around system calls, used to help make
* threaded libraries reentrant and safe to use from threaded applications.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* src/port/thread.c
*
diff --git a/src/port/unsetenv.c b/src/port/unsetenv.c
index 11100330ff..248cead79d 100644
--- a/src/port/unsetenv.c
+++ b/src/port/unsetenv.c
@@ -3,7 +3,7 @@
* unsetenv.c
* unsetenv() emulation for machines without it
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/win32env.c b/src/port/win32env.c
index 42f0326805..98c5b1452f 100644
--- a/src/port/win32env.c
+++ b/src/port/win32env.c
@@ -5,7 +5,7 @@
* environment and the cached versions in (potentially multiple)
* MSVCRT.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/port/win32error.c b/src/port/win32error.c
index 4ab3de3fa4..5dfb694180 100644
--- a/src/port/win32error.c
+++ b/src/port/win32error.c
@@ -3,7 +3,7 @@
* win32error.c
* Map win32 error codes to errno values
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/port/win32error.c
diff --git a/src/port/win32ver.rc b/src/port/win32ver.rc
index 633cfc58a8..a6fddc38bc 100644
--- a/src/port/win32ver.rc
+++ b/src/port/win32ver.rc
@@ -17,7 +17,7 @@ BEGIN
VALUE "CompanyName", "PostgreSQL Global Development Group"
VALUE "FileDescription", FILEDESC
VALUE "FileVersion", PG_VERSION
- VALUE "LegalCopyright", "Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group. Portions Copyright (c) 1994, Regents of the University of California."
+ VALUE "LegalCopyright", "Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group. Portions Copyright (c) 1994, Regents of the University of California."
VALUE "ProductName", "PostgreSQL"
VALUE "ProductVersion", PG_VERSION
END
diff --git a/src/test/examples/testlo.c b/src/test/examples/testlo.c
index 205bed7612..3fd97de995 100644
--- a/src/test/examples/testlo.c
+++ b/src/test/examples/testlo.c
@@ -3,7 +3,7 @@
* testlo.c
* test using large objects with libpq
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
diff --git a/src/test/regress/GNUmakefile b/src/test/regress/GNUmakefile
index 2869b4022c..cb67e5a12a 100644
--- a/src/test/regress/GNUmakefile
+++ b/src/test/regress/GNUmakefile
@@ -3,7 +3,7 @@
# GNUmakefile--
# Makefile for src/test/regress (the regression tests)
#
-# Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+# Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/test/regress/GNUmakefile
diff --git a/src/test/regress/pg_regress.c b/src/test/regress/pg_regress.c
index 84aff941f9..79655cd653 100644
--- a/src/test/regress/pg_regress.c
+++ b/src/test/regress/pg_regress.c
@@ -8,7 +8,7 @@
*
* This code is released under the terms of the PostgreSQL License.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/test/regress/pg_regress.c
diff --git a/src/test/regress/pg_regress.h b/src/test/regress/pg_regress.h
index 3f46037c8c..26069f642e 100644
--- a/src/test/regress/pg_regress.h
+++ b/src/test/regress/pg_regress.h
@@ -1,7 +1,7 @@
/*-------------------------------------------------------------------------
* pg_regress.h --- regression test driver
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/test/regress/pg_regress.h
diff --git a/src/test/regress/pg_regress_main.c b/src/test/regress/pg_regress_main.c
index c2114b9515..710e55841a 100644
--- a/src/test/regress/pg_regress_main.c
+++ b/src/test/regress/pg_regress_main.c
@@ -8,7 +8,7 @@
*
* This code is released under the terms of the PostgreSQL License.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/test/regress/pg_regress_main.c
diff --git a/src/test/thread/Makefile b/src/test/thread/Makefile
index b90bbd477d..571719feb4 100644
--- a/src/test/thread/Makefile
+++ b/src/test/thread/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for tools/thread
#
-# Copyright (c) 2003-2010, PostgreSQL Global Development Group
+# Copyright (c) 2003-2011, PostgreSQL Global Development Group
#
# src/test/thread/Makefile
#
diff --git a/src/test/thread/thread_test.c b/src/test/thread/thread_test.c
index bff7d5a263..0782e8c66b 100644
--- a/src/test/thread/thread_test.c
+++ b/src/test/thread/thread_test.c
@@ -3,7 +3,7 @@
* test_thread_funcs.c
* libc thread test program
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* src/test/thread/thread_test.c
diff --git a/src/timezone/pgtz.c b/src/timezone/pgtz.c
index 62cac7544c..d09d4ad736 100644
--- a/src/timezone/pgtz.c
+++ b/src/timezone/pgtz.c
@@ -3,7 +3,7 @@
* pgtz.c
* Timezone Library Integration Functions
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/timezone/pgtz.c
diff --git a/src/timezone/pgtz.h b/src/timezone/pgtz.h
index 78aa49db00..9d77492d1a 100644
--- a/src/timezone/pgtz.h
+++ b/src/timezone/pgtz.h
@@ -6,7 +6,7 @@
* Note: this file contains only definitions that are private to the
* timezone library. Public definitions are in pgtime.h.
*
- * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
*
* IDENTIFICATION
* src/timezone/pgtz.h
diff --git a/src/tools/findoidjoins/Makefile b/src/tools/findoidjoins/Makefile
index ac9f480124..b5e4fb73b1 100644
--- a/src/tools/findoidjoins/Makefile
+++ b/src/tools/findoidjoins/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/tools/findoidjoins
#
-# Copyright (c) 2003-2010, PostgreSQL Global Development Group
+# Copyright (c) 2003-2011, PostgreSQL Global Development Group
#
# src/tools/findoidjoins/Makefile
#
diff --git a/src/tools/findoidjoins/findoidjoins.c b/src/tools/findoidjoins/findoidjoins.c
index dbaaf257f8..3af97c7a09 100644
--- a/src/tools/findoidjoins/findoidjoins.c
+++ b/src/tools/findoidjoins/findoidjoins.c
@@ -1,7 +1,7 @@
/*
* findoidjoins.c
*
- * Copyright (c) 2002-2010, PostgreSQL Global Development Group
+ * Copyright (c) 2002-2011, PostgreSQL Global Development Group
*
* src/tools/findoidjoins/findoidjoins.c
*/
diff --git a/src/tools/fsync/Makefile b/src/tools/fsync/Makefile
index 252c087898..fe3e626223 100644
--- a/src/tools/fsync/Makefile
+++ b/src/tools/fsync/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/tools/fsync
#
-# Copyright (c) 2003-2010, PostgreSQL Global Development Group
+# Copyright (c) 2003-2011, PostgreSQL Global Development Group
#
# src/tools/fsync/Makefile
#
diff --git a/src/tools/ifaddrs/Makefile b/src/tools/ifaddrs/Makefile
index db482abcad..ab832afe58 100644
--- a/src/tools/ifaddrs/Makefile
+++ b/src/tools/ifaddrs/Makefile
@@ -2,7 +2,7 @@
#
# Makefile for src/tools/ifaddrs
#
-# Copyright (c) 2003-2010, PostgreSQL Global Development Group
+# Copyright (c) 2003-2011, PostgreSQL Global Development Group
#
# src/tools/ifaddrs/Makefile
#
diff --git a/src/tools/version_stamp.pl b/src/tools/version_stamp.pl
index f86e298c2d..ef945da2dd 100755
--- a/src/tools/version_stamp.pl
+++ b/src/tools/version_stamp.pl
@@ -3,7 +3,7 @@
#################################################################
# version_stamp.pl -- update version stamps throughout the source tree
#
-# Copyright (c) 2008-2010, PostgreSQL Global Development Group
+# Copyright (c) 2008-2011, PostgreSQL Global Development Group
#
# src/tools/version_stamp.pl
#################################################################
diff --git a/src/tools/win32tzlist.pl b/src/tools/win32tzlist.pl
index 01e1c06397..a5acee7cad 100755
--- a/src/tools/win32tzlist.pl
+++ b/src/tools/win32tzlist.pl
@@ -2,7 +2,7 @@
#
# win32tzlist.pl -- compare Windows timezone information
#
-# Copyright (c) 2008-2010, PostgreSQL Global Development Group
+# Copyright (c) 2008-2011, PostgreSQL Global Development Group
#
# src/tools/win32tzlist.pl
#################################################################
diff --git a/src/tutorial/complex.source b/src/tutorial/complex.source
index d893c2fef4..c3feae0acc 100644
--- a/src/tutorial/complex.source
+++ b/src/tutorial/complex.source
@@ -5,7 +5,7 @@
-- use this new type.
--
--
--- Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+-- Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
-- Portions Copyright (c) 1994, Regents of the University of California
--
-- src/tutorial/complex.source
diff --git a/src/tutorial/syscat.source b/src/tutorial/syscat.source
index 10edf62e16..b036b7ce45 100644
--- a/src/tutorial/syscat.source
+++ b/src/tutorial/syscat.source
@@ -4,7 +4,7 @@
-- sample queries to the system catalogs
--
--
--- Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
+-- Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
-- Portions Copyright (c) 1994, Regents of the University of California
--
-- src/tutorial/syscat.source
--
cgit v1.2.3
From bf50caf105a901c4f83ac1df3cdaf910c26694a4 Mon Sep 17 00:00:00 2001
From: Bruce Momjian
Date: Sun, 10 Apr 2011 11:42:00 -0400
Subject: pgindent run before PG 9.1 beta 1.
---
contrib/adminpack/adminpack.c | 13 +-
contrib/auth_delay/auth_delay.c | 6 +-
contrib/btree_gist/btree_cash.c | 2 +-
contrib/btree_gist/btree_date.c | 14 +-
contrib/btree_gist/btree_float4.c | 8 +-
contrib/btree_gist/btree_float8.c | 10 +-
contrib/btree_gist/btree_int2.c | 8 +-
contrib/btree_gist/btree_int4.c | 14 +-
contrib/btree_gist/btree_int8.c | 14 +-
contrib/btree_gist/btree_interval.c | 6 +-
contrib/btree_gist/btree_oid.c | 10 +-
contrib/btree_gist/btree_time.c | 6 +-
contrib/btree_gist/btree_ts.c | 33 +-
contrib/btree_gist/btree_utils_num.c | 8 +-
contrib/btree_gist/btree_utils_num.h | 6 +-
contrib/btree_gist/btree_utils_var.c | 2 +-
contrib/dummy_seclabel/dummy_seclabel.c | 2 +-
contrib/file_fdw/file_fdw.c | 91 ++-
contrib/fuzzystrmatch/levenshtein.c | 91 +--
contrib/hstore/hstore_gin.c | 4 +-
contrib/hstore/hstore_op.c | 4 +-
contrib/intarray/_int_bool.c | 6 +-
contrib/intarray/_int_gin.c | 7 +-
contrib/intarray/_int_tool.c | 4 +-
contrib/isn/ISBN.h | 1 -
contrib/pg_archivecleanup/pg_archivecleanup.c | 4 +-
contrib/pg_stat_statements/pg_stat_statements.c | 2 +-
contrib/pg_test_fsync/pg_test_fsync.c | 75 +--
contrib/pg_trgm/trgm.h | 7 +-
contrib/pg_trgm/trgm_gin.c | 20 +-
contrib/pg_trgm/trgm_gist.c | 46 +-
contrib/pg_trgm/trgm_op.c | 11 +-
contrib/pg_upgrade/check.c | 7 +-
contrib/pg_upgrade/controldata.c | 3 +-
contrib/pg_upgrade/exec.c | 2 +-
contrib/pg_upgrade/file.c | 1 +
contrib/pg_upgrade/function.c | 16 +-
contrib/pg_upgrade/info.c | 54 +-
contrib/pg_upgrade/pg_upgrade.c | 21 +-
contrib/pg_upgrade/pg_upgrade.h | 38 +-
contrib/pg_upgrade/relfilenode.c | 20 +-
contrib/pg_upgrade/server.c | 14 +-
contrib/pg_upgrade/tablespace.c | 4 +-
contrib/pg_upgrade/util.c | 2 +-
contrib/pg_upgrade/version_old_8_3.c | 2 +-
contrib/pg_upgrade_support/pg_upgrade_support.c | 8 +-
contrib/pgbench/pgbench.c | 36 +-
contrib/seg/seg.c | 2 +-
contrib/sepgsql/dml.c | 37 +-
contrib/sepgsql/hooks.c | 142 ++---
contrib/sepgsql/label.c | 121 ++--
contrib/sepgsql/proc.c | 28 +-
contrib/sepgsql/relation.c | 55 +-
contrib/sepgsql/schema.c | 18 +-
contrib/sepgsql/selinux.c | 740 +++++++++++++++++-------
contrib/sepgsql/sepgsql.h | 41 +-
contrib/spi/moddatetime.c | 2 +-
contrib/xml2/xpath.c | 12 +-
contrib/xml2/xslt_proc.c | 3 +-
src/backend/access/common/heaptuple.c | 2 +-
src/backend/access/common/indextuple.c | 2 +-
src/backend/access/gin/ginarrayproc.c | 13 +-
src/backend/access/gin/ginbulk.c | 10 +-
src/backend/access/gin/gindatapage.c | 10 +-
src/backend/access/gin/ginentrypage.c | 16 +-
src/backend/access/gin/ginfast.c | 18 +-
src/backend/access/gin/ginget.c | 143 +++--
src/backend/access/gin/gininsert.c | 12 +-
src/backend/access/gin/ginscan.c | 23 +-
src/backend/access/gin/ginutil.c | 38 +-
src/backend/access/gin/ginvacuum.c | 2 +-
src/backend/access/gin/ginxlog.c | 8 +-
src/backend/access/gist/gist.c | 152 ++---
src/backend/access/gist/gistget.c | 22 +-
src/backend/access/gist/gistproc.c | 6 +-
src/backend/access/gist/gistscan.c | 11 +-
src/backend/access/gist/gistutil.c | 3 +-
src/backend/access/gist/gistxlog.c | 17 +-
src/backend/access/hash/hash.c | 1 +
src/backend/access/heap/heapam.c | 36 +-
src/backend/access/heap/hio.c | 2 +-
src/backend/access/heap/rewriteheap.c | 4 +-
src/backend/access/index/indexam.c | 2 +-
src/backend/access/nbtree/nbtinsert.c | 20 +-
src/backend/access/nbtree/nbtpage.c | 6 +-
src/backend/access/nbtree/nbtree.c | 3 +-
src/backend/access/nbtree/nbtsearch.c | 6 +-
src/backend/access/nbtree/nbtsort.c | 2 +-
src/backend/access/nbtree/nbtutils.c | 8 +-
src/backend/access/transam/twophase.c | 14 +-
src/backend/access/transam/varsup.c | 6 +-
src/backend/access/transam/xact.c | 61 +-
src/backend/access/transam/xlog.c | 208 +++----
src/backend/catalog/aclchk.c | 16 +-
src/backend/catalog/catalog.c | 23 +-
src/backend/catalog/dependency.c | 22 +-
src/backend/catalog/heap.c | 60 +-
src/backend/catalog/index.c | 64 +-
src/backend/catalog/namespace.c | 24 +-
src/backend/catalog/objectaddress.c | 52 +-
src/backend/catalog/pg_collation.c | 16 +-
src/backend/catalog/pg_constraint.c | 6 +-
src/backend/catalog/pg_depend.c | 8 +-
src/backend/catalog/pg_enum.c | 88 +--
src/backend/catalog/pg_proc.c | 6 +-
src/backend/catalog/pg_type.c | 4 +-
src/backend/catalog/storage.c | 4 +-
src/backend/catalog/toasting.c | 2 +-
src/backend/commands/alter.c | 40 +-
src/backend/commands/analyze.c | 10 +-
src/backend/commands/cluster.c | 22 +-
src/backend/commands/collationcmds.c | 18 +-
src/backend/commands/comment.c | 20 +-
src/backend/commands/conversioncmds.c | 5 +-
src/backend/commands/copy.c | 108 ++--
src/backend/commands/dbcommands.c | 12 +-
src/backend/commands/explain.c | 26 +-
src/backend/commands/extension.c | 318 +++++-----
src/backend/commands/foreigncmds.c | 8 +-
src/backend/commands/functioncmds.c | 4 +-
src/backend/commands/indexcmds.c | 14 +-
src/backend/commands/opclasscmds.c | 32 +-
src/backend/commands/operatorcmds.c | 5 +-
src/backend/commands/portalcmds.c | 8 +-
src/backend/commands/prepare.c | 2 +-
src/backend/commands/seclabel.c | 43 +-
src/backend/commands/sequence.c | 4 +-
src/backend/commands/tablecmds.c | 295 +++++-----
src/backend/commands/tablespace.c | 14 +-
src/backend/commands/trigger.c | 36 +-
src/backend/commands/tsearchcmds.c | 20 +-
src/backend/commands/typecmds.c | 8 +-
src/backend/commands/user.c | 19 +-
src/backend/commands/vacuum.c | 10 +-
src/backend/commands/vacuumlazy.c | 7 +-
src/backend/commands/variable.c | 24 +-
src/backend/commands/view.c | 13 +-
src/backend/executor/execMain.c | 59 +-
src/backend/executor/execQual.c | 6 +-
src/backend/executor/execUtils.c | 6 +-
src/backend/executor/functions.c | 46 +-
src/backend/executor/nodeAgg.c | 8 +-
src/backend/executor/nodeBitmapIndexscan.c | 4 +-
src/backend/executor/nodeForeignscan.c | 2 +-
src/backend/executor/nodeHash.c | 16 +-
src/backend/executor/nodeHashjoin.c | 53 +-
src/backend/executor/nodeIndexscan.c | 20 +-
src/backend/executor/nodeLimit.c | 14 +-
src/backend/executor/nodeLockRows.c | 2 +-
src/backend/executor/nodeMergeAppend.c | 36 +-
src/backend/executor/nodeMergejoin.c | 2 +-
src/backend/executor/nodeModifyTable.c | 40 +-
src/backend/executor/nodeNestloop.c | 11 +-
src/backend/executor/nodeRecursiveunion.c | 2 +-
src/backend/executor/nodeSetOp.c | 2 +-
src/backend/executor/nodeWindowAgg.c | 2 +-
src/backend/executor/spi.c | 10 +-
src/backend/libpq/auth.c | 63 +-
src/backend/libpq/hba.c | 24 +-
src/backend/libpq/pqcomm.c | 57 +-
src/backend/main/main.c | 9 +-
src/backend/nodes/copyfuncs.c | 6 +-
src/backend/nodes/nodeFuncs.c | 43 +-
src/backend/nodes/params.c | 2 +-
src/backend/optimizer/path/allpaths.c | 38 +-
src/backend/optimizer/path/costsize.c | 28 +-
src/backend/optimizer/path/equivclass.c | 14 +-
src/backend/optimizer/path/indxpath.c | 42 +-
src/backend/optimizer/path/joinpath.c | 8 +-
src/backend/optimizer/path/joinrels.c | 10 +-
src/backend/optimizer/path/pathkeys.c | 14 +-
src/backend/optimizer/plan/analyzejoins.c | 15 +-
src/backend/optimizer/plan/createplan.c | 56 +-
src/backend/optimizer/plan/initsplan.c | 13 +-
src/backend/optimizer/plan/planagg.c | 40 +-
src/backend/optimizer/plan/planmain.c | 14 +-
src/backend/optimizer/plan/planner.c | 18 +-
src/backend/optimizer/prep/prepjointree.c | 22 +-
src/backend/optimizer/prep/prepqual.c | 39 +-
src/backend/optimizer/prep/preptlist.c | 4 +-
src/backend/optimizer/prep/prepunion.c | 2 +-
src/backend/optimizer/util/clauses.c | 64 +-
src/backend/optimizer/util/pathnode.c | 6 +-
src/backend/optimizer/util/placeholder.c | 4 +-
src/backend/optimizer/util/predtest.c | 2 +-
src/backend/optimizer/util/var.c | 2 +-
src/backend/parser/analyze.c | 28 +-
src/backend/parser/parse_agg.c | 10 +-
src/backend/parser/parse_clause.c | 8 +-
src/backend/parser/parse_coerce.c | 8 +-
src/backend/parser/parse_collate.c | 93 +--
src/backend/parser/parse_cte.c | 8 +-
src/backend/parser/parse_expr.c | 16 +-
src/backend/parser/parse_func.c | 8 +-
src/backend/parser/parse_node.c | 8 +-
src/backend/parser/parse_oper.c | 6 +-
src/backend/parser/parse_param.c | 4 +-
src/backend/parser/parse_relation.c | 10 +-
src/backend/parser/parse_target.c | 6 +-
src/backend/parser/parse_utilcmd.c | 71 +--
src/backend/port/dynloader/freebsd.c | 2 +-
src/backend/port/dynloader/netbsd.c | 2 +-
src/backend/port/dynloader/openbsd.c | 2 +-
src/backend/port/pipe.c | 8 +-
src/backend/port/sysv_shmem.c | 8 +-
src/backend/port/unix_latch.c | 80 +--
src/backend/port/win32/crashdump.c | 60 +-
src/backend/port/win32/timer.c | 2 +-
src/backend/port/win32_latch.c | 28 +-
src/backend/postmaster/autovacuum.c | 34 +-
src/backend/postmaster/bgwriter.c | 25 +-
src/backend/postmaster/pgstat.c | 13 +-
src/backend/postmaster/postmaster.c | 75 ++-
src/backend/postmaster/syslogger.c | 8 +-
src/backend/regex/regcomp.c | 2 +-
src/backend/replication/basebackup.c | 37 +-
src/backend/replication/syncrep.c | 136 ++---
src/backend/replication/walreceiver.c | 47 +-
src/backend/replication/walreceiverfuncs.c | 4 +-
src/backend/replication/walsender.c | 130 ++---
src/backend/rewrite/rewriteDefine.c | 6 +-
src/backend/rewrite/rewriteHandler.c | 36 +-
src/backend/rewrite/rewriteSupport.c | 2 +-
src/backend/storage/buffer/bufmgr.c | 16 +-
src/backend/storage/buffer/freelist.c | 2 +-
src/backend/storage/buffer/localbuf.c | 8 +-
src/backend/storage/file/fd.c | 20 +-
src/backend/storage/file/reinit.c | 60 +-
src/backend/storage/ipc/pmsignal.c | 10 +-
src/backend/storage/ipc/procarray.c | 42 +-
src/backend/storage/ipc/standby.c | 16 +-
src/backend/storage/large_object/inv_api.c | 4 +-
src/backend/storage/lmgr/lock.c | 3 +-
src/backend/storage/lmgr/predicate.c | 119 ++--
src/backend/storage/smgr/md.c | 10 +-
src/backend/storage/smgr/smgr.c | 6 +-
src/backend/tcop/postgres.c | 23 +-
src/backend/tcop/pquery.c | 6 +-
src/backend/tcop/utility.c | 7 +-
src/backend/tsearch/spell.c | 2 +-
src/backend/tsearch/ts_locale.c | 11 +-
src/backend/tsearch/ts_selfuncs.c | 8 +-
src/backend/tsearch/wparser_def.c | 709 ++++++++++++-----------
src/backend/utils/adt/acl.c | 4 +-
src/backend/utils/adt/arrayfuncs.c | 5 +-
src/backend/utils/adt/cash.c | 24 +-
src/backend/utils/adt/date.c | 2 +-
src/backend/utils/adt/datetime.c | 2 +-
src/backend/utils/adt/dbsize.c | 2 +-
src/backend/utils/adt/enum.c | 4 +-
src/backend/utils/adt/formatting.c | 24 +-
src/backend/utils/adt/genfile.c | 13 +-
src/backend/utils/adt/like.c | 24 +-
src/backend/utils/adt/nabstime.c | 6 +-
src/backend/utils/adt/network.c | 60 +-
src/backend/utils/adt/numeric.c | 53 +-
src/backend/utils/adt/numutils.c | 16 +-
src/backend/utils/adt/pg_locale.c | 41 +-
src/backend/utils/adt/pgstatfuncs.c | 18 +-
src/backend/utils/adt/ri_triggers.c | 20 +-
src/backend/utils/adt/ruleutils.c | 46 +-
src/backend/utils/adt/selfuncs.c | 157 +++--
src/backend/utils/adt/tsginidx.c | 10 +-
src/backend/utils/adt/tsvector_op.c | 1 +
src/backend/utils/adt/varbit.c | 1 +
src/backend/utils/adt/varlena.c | 108 ++--
src/backend/utils/adt/xml.c | 20 +-
src/backend/utils/cache/inval.c | 3 +-
src/backend/utils/cache/lsyscache.c | 10 +-
src/backend/utils/cache/plancache.c | 4 +-
src/backend/utils/cache/relcache.c | 8 +-
src/backend/utils/cache/syscache.c | 2 +-
src/backend/utils/cache/ts_cache.c | 2 +-
src/backend/utils/cache/typcache.c | 67 +--
src/backend/utils/error/elog.c | 11 +-
src/backend/utils/fmgr/fmgr.c | 12 +-
src/backend/utils/fmgr/funcapi.c | 6 +-
src/backend/utils/init/miscinit.c | 12 +-
src/backend/utils/init/postinit.c | 10 +-
src/backend/utils/mb/mbutils.c | 12 +-
src/backend/utils/misc/guc.c | 87 +--
src/backend/utils/misc/rbtree.c | 14 +-
src/backend/utils/misc/tzparser.c | 2 +-
src/backend/utils/mmgr/aset.c | 4 +-
src/backend/utils/mmgr/portalmem.c | 14 +-
src/backend/utils/resowner/resowner.c | 2 +-
src/backend/utils/sort/tuplesort.c | 18 +-
src/backend/utils/time/snapmgr.c | 6 +-
src/bin/initdb/initdb.c | 67 ++-
src/bin/pg_basebackup/pg_basebackup.c | 11 +-
src/bin/pg_ctl/pg_ctl.c | 47 +-
src/bin/pg_dump/compress_io.c | 134 +++--
src/bin/pg_dump/compress_io.h | 22 +-
src/bin/pg_dump/dumputils.c | 2 +-
src/bin/pg_dump/dumputils.h | 2 +-
src/bin/pg_dump/pg_backup_archiver.c | 30 +-
src/bin/pg_dump/pg_backup_archiver.h | 9 +-
src/bin/pg_dump/pg_backup_custom.c | 5 +-
src/bin/pg_dump/pg_backup_directory.c | 73 +--
src/bin/pg_dump/pg_backup_tar.c | 2 +-
src/bin/pg_dump/pg_dump.c | 266 ++++-----
src/bin/pg_dump/pg_dump.h | 10 +-
src/bin/pg_dump/pg_dumpall.c | 2 +-
src/bin/psql/command.c | 18 +-
src/bin/psql/describe.c | 239 ++++----
src/bin/psql/tab-complete.c | 53 +-
src/bin/scripts/droplang.c | 4 +-
src/include/access/gin.h | 6 +-
src/include/access/gin_private.h | 48 +-
src/include/access/gist.h | 2 +-
src/include/access/gist_private.h | 20 +-
src/include/access/hio.h | 4 +-
src/include/access/htup.h | 2 +-
src/include/access/itup.h | 2 +-
src/include/access/relscan.h | 12 +-
src/include/access/tupdesc.h | 4 +-
src/include/access/xact.h | 10 +-
src/include/access/xlog.h | 12 +-
src/include/access/xlogdefs.h | 2 +-
src/include/catalog/catalog.h | 6 +-
src/include/catalog/dependency.h | 4 +-
src/include/catalog/namespace.h | 2 +-
src/include/catalog/objectaccess.h | 12 +-
src/include/catalog/pg_am.h | 2 +-
src/include/catalog/pg_amop.h | 62 +-
src/include/catalog/pg_authid.h | 2 +-
src/include/catalog/pg_class.h | 4 +-
src/include/catalog/pg_collation.h | 2 +-
src/include/catalog/pg_collation_fn.h | 6 +-
src/include/catalog/pg_constraint.h | 6 +-
src/include/catalog/pg_control.h | 6 +-
src/include/catalog/pg_enum.h | 2 +-
src/include/catalog/pg_extension.h | 8 +-
src/include/catalog/pg_index.h | 2 +-
src/include/catalog/pg_operator.h | 2 +-
src/include/catalog/pg_proc.h | 30 +-
src/include/catalog/pg_seclabel.h | 14 +-
src/include/catalog/pg_type.h | 9 +-
src/include/catalog/storage.h | 2 +-
src/include/commands/alter.h | 2 +-
src/include/commands/collationcmds.h | 2 +-
src/include/commands/copy.h | 6 +-
src/include/commands/dbcommands.h | 4 +-
src/include/commands/defrem.h | 14 +-
src/include/commands/explain.h | 10 +-
src/include/commands/extension.h | 4 +-
src/include/commands/proclang.h | 2 +-
src/include/commands/seclabel.h | 10 +-
src/include/commands/trigger.h | 2 +-
src/include/commands/typecmds.h | 2 +-
src/include/commands/vacuum.h | 2 +-
src/include/executor/executor.h | 6 +-
src/include/executor/functions.h | 2 +-
src/include/executor/hashjoin.h | 4 +-
src/include/executor/nodeHash.h | 4 +-
src/include/fmgr.h | 16 +-
src/include/foreign/fdwapi.h | 30 +-
src/include/foreign/foreign.h | 4 +-
src/include/libpq/auth.h | 2 +-
src/include/libpq/libpq-be.h | 12 +-
src/include/libpq/libpq.h | 2 +-
src/include/nodes/execnodes.h | 12 +-
src/include/nodes/makefuncs.h | 4 +-
src/include/nodes/params.h | 2 +-
src/include/nodes/parsenodes.h | 24 +-
src/include/nodes/pg_list.h | 2 +-
src/include/nodes/plannodes.h | 10 +-
src/include/nodes/primnodes.h | 9 +-
src/include/nodes/relation.h | 10 +-
src/include/optimizer/cost.h | 2 +-
src/include/optimizer/pathnode.h | 6 +-
src/include/optimizer/paths.h | 6 +-
src/include/optimizer/placeholder.h | 2 +-
src/include/optimizer/subselect.h | 2 +-
src/include/parser/parse_collate.h | 2 +-
src/include/parser/parse_func.h | 2 +-
src/include/parser/parse_type.h | 8 +-
src/include/parser/parser.h | 2 +-
src/include/pgstat.h | 4 +-
src/include/port/win32.h | 14 +-
src/include/replication/replnodes.h | 6 +-
src/include/replication/syncrep.h | 2 +-
src/include/replication/walprotocol.h | 14 +-
src/include/replication/walreceiver.h | 14 +-
src/include/replication/walsender.h | 26 +-
src/include/rewrite/rewriteSupport.h | 4 +-
src/include/storage/backendid.h | 2 +-
src/include/storage/buf_internals.h | 3 +-
src/include/storage/latch.h | 11 +-
src/include/storage/pmsignal.h | 2 +-
src/include/storage/predicate_internals.h | 14 +-
src/include/storage/proc.h | 8 +-
src/include/storage/procarray.h | 2 +-
src/include/storage/relfilenode.h | 4 +-
src/include/tsearch/dicts/spell.h | 6 +-
src/include/utils/acl.h | 2 +-
src/include/utils/builtins.h | 2 +-
src/include/utils/bytea.h | 2 +-
src/include/utils/datetime.h | 2 +-
src/include/utils/elog.h | 5 +-
src/include/utils/guc.h | 6 +-
src/include/utils/lsyscache.h | 4 +-
src/include/utils/numeric.h | 2 +-
src/include/utils/portal.h | 4 +-
src/include/utils/rbtree.h | 6 +-
src/include/utils/rel.h | 8 +-
src/include/utils/tuplesort.h | 14 +-
src/include/utils/typcache.h | 6 +-
src/include/utils/varbit.h | 1 +
src/include/utils/xml.h | 4 +-
src/interfaces/ecpg/compatlib/informix.c | 20 +-
src/interfaces/ecpg/ecpglib/connect.c | 2 +-
src/interfaces/ecpg/ecpglib/memory.c | 2 +-
src/interfaces/ecpg/ecpglib/prepare.c | 4 +-
src/interfaces/ecpg/preproc/ecpg.c | 4 +-
src/interfaces/ecpg/preproc/extern.h | 4 +-
src/interfaces/libpq/fe-auth.c | 15 +-
src/interfaces/libpq/fe-connect.c | 93 ++-
src/interfaces/libpq/fe-exec.c | 14 +-
src/interfaces/libpq/fe-protocol2.c | 15 +-
src/interfaces/libpq/fe-protocol3.c | 4 +-
src/interfaces/libpq/fe-secure.c | 10 +-
src/interfaces/libpq/libpq-fe.h | 2 +-
src/interfaces/libpq/libpq-int.h | 7 +-
src/pl/plperl/plperl.c | 2 +-
src/pl/plperl/plperl.h | 8 +-
src/pl/plperl/plperl_helpers.h | 14 +-
src/pl/plpgsql/src/pl_comp.c | 26 +-
src/pl/plpgsql/src/pl_exec.c | 64 +-
src/pl/plpgsql/src/plpgsql.h | 4 +-
src/pl/plpython/plpython.c | 202 +++----
src/pl/tcl/pltcl.c | 17 +-
src/port/chklocale.c | 2 +-
src/port/crypt.c | 2 +-
src/port/dirmod.c | 2 +-
src/port/exec.c | 2 +-
src/port/getaddrinfo.c | 8 +-
src/port/inet_net_ntop.c | 10 +-
src/port/path.c | 19 +-
src/port/pgmkdirp.c | 12 +-
src/port/snprintf.c | 50 +-
src/port/unsetenv.c | 4 +-
src/test/isolation/isolation_main.c | 6 +-
src/test/isolation/isolationtester.c | 116 ++--
src/test/isolation/isolationtester.h | 10 +-
src/test/regress/pg_regress.c | 4 +-
446 files changed, 5742 insertions(+), 5263 deletions(-)
(limited to 'src/backend/access/gist/gistxlog.c')
diff --git a/contrib/adminpack/adminpack.c b/contrib/adminpack/adminpack.c
index c149dd6c63..99fa02e813 100644
--- a/contrib/adminpack/adminpack.c
+++ b/contrib/adminpack/adminpack.c
@@ -78,18 +78,19 @@ convert_and_check_filename(text *arg, bool logAllowed)
/* Disallow '/a/b/data/..' */
if (path_contains_parent_reference(filename))
ereport(ERROR,
- (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- (errmsg("reference to parent directory (\"..\") not allowed"))));
+ (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
+ (errmsg("reference to parent directory (\"..\") not allowed"))));
+
/*
- * Allow absolute paths if within DataDir or Log_directory, even
- * though Log_directory might be outside DataDir.
+ * Allow absolute paths if within DataDir or Log_directory, even
+ * though Log_directory might be outside DataDir.
*/
if (!path_is_prefix_of_path(DataDir, filename) &&
(!logAllowed || !is_absolute_path(Log_directory) ||
!path_is_prefix_of_path(Log_directory, filename)))
ereport(ERROR,
- (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- (errmsg("absolute path not allowed"))));
+ (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
+ (errmsg("absolute path not allowed"))));
}
else if (!path_is_relative_and_below_cwd(filename))
ereport(ERROR,
diff --git a/contrib/auth_delay/auth_delay.c b/contrib/auth_delay/auth_delay.c
index ca388c4498..4e0d5959d1 100644
--- a/contrib/auth_delay/auth_delay.c
+++ b/contrib/auth_delay/auth_delay.c
@@ -18,13 +18,13 @@
PG_MODULE_MAGIC;
-void _PG_init(void);
+void _PG_init(void);
/* GUC Variables */
static int auth_delay_milliseconds;
/* Original Hook */
-static ClientAuthentication_hook_type original_client_auth_hook = NULL;
+static ClientAuthentication_hook_type original_client_auth_hook = NULL;
/*
* Check authentication
@@ -55,7 +55,7 @@ _PG_init(void)
{
/* Define custom GUC variables */
DefineCustomIntVariable("auth_delay.milliseconds",
- "Milliseconds to delay before reporting authentication failure",
+ "Milliseconds to delay before reporting authentication failure",
NULL,
&auth_delay_milliseconds,
0,
diff --git a/contrib/btree_gist/btree_cash.c b/contrib/btree_gist/btree_cash.c
index 7938a70f17..2664a26870 100644
--- a/contrib/btree_gist/btree_cash.c
+++ b/contrib/btree_gist/btree_cash.c
@@ -169,7 +169,7 @@ gbt_cash_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_date.c b/contrib/btree_gist/btree_date.c
index ccd7e2ad3f..8a675e2f1d 100644
--- a/contrib/btree_gist/btree_date.c
+++ b/contrib/btree_gist/btree_date.c
@@ -90,9 +90,9 @@ static float8
gdb_date_dist(const void *a, const void *b)
{
/* we assume the difference can't overflow */
- Datum diff = DirectFunctionCall2(date_mi,
+ Datum diff = DirectFunctionCall2(date_mi,
DateADTGetDatum(*((const DateADT *) a)),
- DateADTGetDatum(*((const DateADT *) b)));
+ DateADTGetDatum(*((const DateADT *) b)));
return (float8) Abs(DatumGetInt32(diff));
}
@@ -113,14 +113,14 @@ static const gbtree_ninfo tinfo =
PG_FUNCTION_INFO_V1(date_dist);
-Datum date_dist(PG_FUNCTION_ARGS);
+Datum date_dist(PG_FUNCTION_ARGS);
Datum
date_dist(PG_FUNCTION_ARGS)
{
/* we assume the difference can't overflow */
- Datum diff = DirectFunctionCall2(date_mi,
- PG_GETARG_DATUM(0),
- PG_GETARG_DATUM(1));
+ Datum diff = DirectFunctionCall2(date_mi,
+ PG_GETARG_DATUM(0),
+ PG_GETARG_DATUM(1));
PG_RETURN_INT32(Abs(DatumGetInt32(diff)));
}
@@ -181,7 +181,7 @@ gbt_date_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_float4.c b/contrib/btree_gist/btree_float4.c
index 932a941f88..266256b23c 100644
--- a/contrib/btree_gist/btree_float4.c
+++ b/contrib/btree_gist/btree_float4.c
@@ -94,18 +94,18 @@ static const gbtree_ninfo tinfo =
PG_FUNCTION_INFO_V1(float4_dist);
-Datum float4_dist(PG_FUNCTION_ARGS);
+Datum float4_dist(PG_FUNCTION_ARGS);
Datum
float4_dist(PG_FUNCTION_ARGS)
{
- float4 a = PG_GETARG_FLOAT4(0);
+ float4 a = PG_GETARG_FLOAT4(0);
float4 b = PG_GETARG_FLOAT4(1);
float4 r;
r = a - b;
CHECKFLOATVAL(r, isinf(a) || isinf(b), true);
- PG_RETURN_FLOAT4( Abs(r) );
+ PG_RETURN_FLOAT4(Abs(r));
}
@@ -162,7 +162,7 @@ gbt_float4_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_float8.c b/contrib/btree_gist/btree_float8.c
index 0c39980ba1..efbee0f3e4 100644
--- a/contrib/btree_gist/btree_float8.c
+++ b/contrib/btree_gist/btree_float8.c
@@ -76,8 +76,8 @@ gbt_float8key_cmp(const void *a, const void *b)
static float8
gbt_float8_dist(const void *a, const void *b)
{
- float8 arg1 = *(const float8 *)a;
- float8 arg2 = *(const float8 *)b;
+ float8 arg1 = *(const float8 *) a;
+ float8 arg2 = *(const float8 *) b;
float8 r;
r = arg1 - arg2;
@@ -102,7 +102,7 @@ static const gbtree_ninfo tinfo =
PG_FUNCTION_INFO_V1(float8_dist);
-Datum float8_dist(PG_FUNCTION_ARGS);
+Datum float8_dist(PG_FUNCTION_ARGS);
Datum
float8_dist(PG_FUNCTION_ARGS)
{
@@ -113,7 +113,7 @@ float8_dist(PG_FUNCTION_ARGS)
r = a - b;
CHECKFLOATVAL(r, isinf(a) || isinf(b), true);
- PG_RETURN_FLOAT8( Abs(r) );
+ PG_RETURN_FLOAT8(Abs(r));
}
/**************************************************
@@ -169,7 +169,7 @@ gbt_float8_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_int2.c b/contrib/btree_gist/btree_int2.c
index c06d170a5e..7841145b53 100644
--- a/contrib/btree_gist/btree_int2.c
+++ b/contrib/btree_gist/btree_int2.c
@@ -94,12 +94,12 @@ static const gbtree_ninfo tinfo =
PG_FUNCTION_INFO_V1(int2_dist);
-Datum int2_dist(PG_FUNCTION_ARGS);
+Datum int2_dist(PG_FUNCTION_ARGS);
Datum
int2_dist(PG_FUNCTION_ARGS)
{
- int2 a = PG_GETARG_INT16(0);
- int2 b = PG_GETARG_INT16(1);
+ int2 a = PG_GETARG_INT16(0);
+ int2 b = PG_GETARG_INT16(1);
int2 r;
int2 ra;
@@ -169,7 +169,7 @@ gbt_int2_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_int4.c b/contrib/btree_gist/btree_int4.c
index ef7af524e7..0e4b4f85b0 100644
--- a/contrib/btree_gist/btree_int4.c
+++ b/contrib/btree_gist/btree_int4.c
@@ -95,14 +95,14 @@ static const gbtree_ninfo tinfo =
PG_FUNCTION_INFO_V1(int4_dist);
-Datum int4_dist(PG_FUNCTION_ARGS);
+Datum int4_dist(PG_FUNCTION_ARGS);
Datum
int4_dist(PG_FUNCTION_ARGS)
{
- int4 a = PG_GETARG_INT32(0);
- int4 b = PG_GETARG_INT32(1);
- int4 r;
- int4 ra;
+ int4 a = PG_GETARG_INT32(0);
+ int4 b = PG_GETARG_INT32(1);
+ int4 r;
+ int4 ra;
r = a - b;
ra = Abs(r);
@@ -111,7 +111,7 @@ int4_dist(PG_FUNCTION_ARGS)
if (ra < 0 || (!SAMESIGN(a, b) && !SAMESIGN(r, a)))
ereport(ERROR,
(errcode(ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE),
- errmsg("integer out of range")));
+ errmsg("integer out of range")));
PG_RETURN_INT32(ra);
}
@@ -170,7 +170,7 @@ gbt_int4_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_int8.c b/contrib/btree_gist/btree_int8.c
index 1f14d82891..d54113d393 100644
--- a/contrib/btree_gist/btree_int8.c
+++ b/contrib/btree_gist/btree_int8.c
@@ -95,14 +95,14 @@ static const gbtree_ninfo tinfo =
PG_FUNCTION_INFO_V1(int8_dist);
-Datum int8_dist(PG_FUNCTION_ARGS);
+Datum int8_dist(PG_FUNCTION_ARGS);
Datum
int8_dist(PG_FUNCTION_ARGS)
{
- int64 a = PG_GETARG_INT64(0);
- int64 b = PG_GETARG_INT64(1);
- int64 r;
- int64 ra;
+ int64 a = PG_GETARG_INT64(0);
+ int64 b = PG_GETARG_INT64(1);
+ int64 r;
+ int64 ra;
r = a - b;
ra = Abs(r);
@@ -111,7 +111,7 @@ int8_dist(PG_FUNCTION_ARGS)
if (ra < 0 || (!SAMESIGN(a, b) && !SAMESIGN(r, a)))
ereport(ERROR,
(errcode(ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE),
- errmsg("bigint out of range")));
+ errmsg("bigint out of range")));
PG_RETURN_INT64(ra);
}
@@ -170,7 +170,7 @@ gbt_int8_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_interval.c b/contrib/btree_gist/btree_interval.c
index 5195284afa..137a5fcd7f 100644
--- a/contrib/btree_gist/btree_interval.c
+++ b/contrib/btree_gist/btree_interval.c
@@ -88,7 +88,7 @@ intr2num(const Interval *i)
static float8
gbt_intv_dist(const void *a, const void *b)
{
- return (float8)Abs(intr2num((Interval*)a) - intr2num((Interval*)b));
+ return (float8) Abs(intr2num((Interval *) a) - intr2num((Interval *) b));
}
/*
@@ -127,7 +127,7 @@ abs_interval(Interval *a)
}
PG_FUNCTION_INFO_V1(interval_dist);
-Datum interval_dist(PG_FUNCTION_ARGS);
+Datum interval_dist(PG_FUNCTION_ARGS);
Datum
interval_dist(PG_FUNCTION_ARGS)
{
@@ -240,7 +240,7 @@ gbt_intv_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_oid.c b/contrib/btree_gist/btree_oid.c
index c81dd31799..3b0929b42b 100644
--- a/contrib/btree_gist/btree_oid.c
+++ b/contrib/btree_gist/btree_oid.c
@@ -101,13 +101,13 @@ static const gbtree_ninfo tinfo =
PG_FUNCTION_INFO_V1(oid_dist);
-Datum oid_dist(PG_FUNCTION_ARGS);
+Datum oid_dist(PG_FUNCTION_ARGS);
Datum
oid_dist(PG_FUNCTION_ARGS)
{
- Oid a = PG_GETARG_OID(0);
- Oid b = PG_GETARG_OID(1);
- Oid res;
+ Oid a = PG_GETARG_OID(0);
+ Oid b = PG_GETARG_OID(1);
+ Oid res;
if (a < b)
res = b - a;
@@ -170,7 +170,7 @@ gbt_oid_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_time.c b/contrib/btree_gist/btree_time.c
index 44f6923409..e9cfe33f45 100644
--- a/contrib/btree_gist/btree_time.c
+++ b/contrib/btree_gist/btree_time.c
@@ -119,7 +119,7 @@ gbt_time_dist(const void *a, const void *b)
{
const TimeADT *aa = (const TimeADT *) a;
const TimeADT *bb = (const TimeADT *) b;
- Interval *i;
+ Interval *i;
i = DatumGetIntervalP(DirectFunctionCall2(time_mi_time,
TimeADTGetDatumFast(*aa),
@@ -143,7 +143,7 @@ static const gbtree_ninfo tinfo =
PG_FUNCTION_INFO_V1(time_dist);
-Datum time_dist(PG_FUNCTION_ARGS);
+Datum time_dist(PG_FUNCTION_ARGS);
Datum
time_dist(PG_FUNCTION_ARGS)
{
@@ -239,7 +239,7 @@ gbt_time_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_ts.c b/contrib/btree_gist/btree_ts.c
index 9a0ec07a1e..9d3a5919a0 100644
--- a/contrib/btree_gist/btree_ts.c
+++ b/contrib/btree_gist/btree_ts.c
@@ -120,7 +120,7 @@ gbt_ts_dist(const void *a, const void *b)
{
const Timestamp *aa = (const Timestamp *) a;
const Timestamp *bb = (const Timestamp *) b;
- Interval *i;
+ Interval *i;
if (TIMESTAMP_NOT_FINITE(*aa) || TIMESTAMP_NOT_FINITE(*bb))
return get_float8_infinity();
@@ -147,17 +147,17 @@ static const gbtree_ninfo tinfo =
PG_FUNCTION_INFO_V1(ts_dist);
-Datum ts_dist(PG_FUNCTION_ARGS);
+Datum ts_dist(PG_FUNCTION_ARGS);
Datum
ts_dist(PG_FUNCTION_ARGS)
{
Timestamp a = PG_GETARG_TIMESTAMP(0);
Timestamp b = PG_GETARG_TIMESTAMP(1);
- Interval *r;
+ Interval *r;
if (TIMESTAMP_NOT_FINITE(a) || TIMESTAMP_NOT_FINITE(b))
{
- Interval *p = palloc(sizeof(Interval));
+ Interval *p = palloc(sizeof(Interval));
p->day = INT_MAX;
p->month = INT_MAX;
@@ -169,25 +169,24 @@ ts_dist(PG_FUNCTION_ARGS)
PG_RETURN_INTERVAL_P(p);
}
else
-
- r = DatumGetIntervalP(DirectFunctionCall2(timestamp_mi,
- PG_GETARG_DATUM(0),
- PG_GETARG_DATUM(1)));
- PG_RETURN_INTERVAL_P( abs_interval(r) );
+ r = DatumGetIntervalP(DirectFunctionCall2(timestamp_mi,
+ PG_GETARG_DATUM(0),
+ PG_GETARG_DATUM(1)));
+ PG_RETURN_INTERVAL_P(abs_interval(r));
}
PG_FUNCTION_INFO_V1(tstz_dist);
-Datum tstz_dist(PG_FUNCTION_ARGS);
+Datum tstz_dist(PG_FUNCTION_ARGS);
Datum
tstz_dist(PG_FUNCTION_ARGS)
{
- TimestampTz a = PG_GETARG_TIMESTAMPTZ(0);
- TimestampTz b = PG_GETARG_TIMESTAMPTZ(1);
- Interval *r;
+ TimestampTz a = PG_GETARG_TIMESTAMPTZ(0);
+ TimestampTz b = PG_GETARG_TIMESTAMPTZ(1);
+ Interval *r;
if (TIMESTAMP_NOT_FINITE(a) || TIMESTAMP_NOT_FINITE(b))
{
- Interval *p = palloc(sizeof(Interval));
+ Interval *p = palloc(sizeof(Interval));
p->day = INT_MAX;
p->month = INT_MAX;
@@ -202,7 +201,7 @@ tstz_dist(PG_FUNCTION_ARGS)
r = DatumGetIntervalP(DirectFunctionCall2(timestamp_mi,
PG_GETARG_DATUM(0),
PG_GETARG_DATUM(1)));
- PG_RETURN_INTERVAL_P( abs_interval(r) );
+ PG_RETURN_INTERVAL_P(abs_interval(r));
}
@@ -309,7 +308,7 @@ gbt_ts_distance(PG_FUNCTION_ARGS)
key.upper = (GBT_NUMKEY *) &kkk->upper;
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &query, GIST_LEAF(entry), &tinfo)
);
}
@@ -354,7 +353,7 @@ gbt_tstz_distance(PG_FUNCTION_ARGS)
qqq = tstz_to_ts_gmt(query);
PG_RETURN_FLOAT8(
- gbt_num_distance(&key, (void *) &qqq, GIST_LEAF(entry), &tinfo)
+ gbt_num_distance(&key, (void *) &qqq, GIST_LEAF(entry), &tinfo)
);
}
diff --git a/contrib/btree_gist/btree_utils_num.c b/contrib/btree_gist/btree_utils_num.c
index 17440a191b..64c95854df 100644
--- a/contrib/btree_gist/btree_utils_num.c
+++ b/contrib/btree_gist/btree_utils_num.c
@@ -223,8 +223,8 @@ gbt_num_consistent(const GBT_NUMKEY_R *key,
retval = (*tinfo->f_le) (query, key->upper);
break;
case BtreeGistNotEqualStrategyNumber:
- retval = (! ((*tinfo->f_eq) (query, key->lower) &&
- (*tinfo->f_eq) (query, key->upper))) ? true : false;
+ retval = (!((*tinfo->f_eq) (query, key->lower) &&
+ (*tinfo->f_eq) (query, key->upper))) ? true : false;
break;
default:
retval = false;
@@ -249,9 +249,9 @@ gbt_num_distance(const GBT_NUMKEY_R *key,
if (tinfo->f_dist == NULL)
elog(ERROR, "KNN search is not supported for btree_gist type %d",
(int) tinfo->t);
- if ( tinfo->f_le(query, key->lower) )
+ if (tinfo->f_le(query, key->lower))
retval = tinfo->f_dist(query, key->lower);
- else if ( tinfo->f_ge(query, key->upper) )
+ else if (tinfo->f_ge(query, key->upper))
retval = tinfo->f_dist(query, key->upper);
else
retval = 0.0;
diff --git a/contrib/btree_gist/btree_utils_num.h b/contrib/btree_gist/btree_utils_num.h
index 243d3b5cb9..8935ed6630 100644
--- a/contrib/btree_gist/btree_utils_num.h
+++ b/contrib/btree_gist/btree_utils_num.h
@@ -46,7 +46,7 @@ typedef struct
bool (*f_le) (const void *, const void *); /* less or equal */
bool (*f_lt) (const void *, const void *); /* less than */
int (*f_cmp) (const void *, const void *); /* key compare function */
- float8 (*f_dist) (const void *, const void *); /* key distance function */
+ float8 (*f_dist) (const void *, const void *); /* key distance function */
} gbtree_ninfo;
@@ -94,7 +94,7 @@ typedef struct
#define GET_FLOAT_DISTANCE(t, arg1, arg2) Abs( ((float8) *((const t *) (arg1))) - ((float8) *((const t *) (arg2))) )
-#define SAMESIGN(a,b) (((a) < 0) == ((b) < 0))
+#define SAMESIGN(a,b) (((a) < 0) == ((b) < 0))
/*
* check to see if a float4/8 val has underflowed or overflowed
@@ -121,7 +121,7 @@ extern bool gbt_num_consistent(const GBT_NUMKEY_R *key, const void *query,
const gbtree_ninfo *tinfo);
extern float8 gbt_num_distance(const GBT_NUMKEY_R *key, const void *query,
- bool is_leaf, const gbtree_ninfo *tinfo);
+ bool is_leaf, const gbtree_ninfo *tinfo);
extern GIST_SPLITVEC *gbt_num_picksplit(const GistEntryVector *entryvec, GIST_SPLITVEC *v,
const gbtree_ninfo *tinfo);
diff --git a/contrib/btree_gist/btree_utils_var.c b/contrib/btree_gist/btree_utils_var.c
index 8f3173e499..d74013af88 100644
--- a/contrib/btree_gist/btree_utils_var.c
+++ b/contrib/btree_gist/btree_utils_var.c
@@ -598,7 +598,7 @@ gbt_var_consistent(
|| gbt_var_node_pf_match(key, query, tinfo);
break;
case BtreeGistNotEqualStrategyNumber:
- retval = ! ((*tinfo->f_eq) (query, key->lower) && (*tinfo->f_eq) (query, key->upper));
+ retval = !((*tinfo->f_eq) (query, key->lower) && (*tinfo->f_eq) (query, key->upper));
break;
default:
retval = FALSE;
diff --git a/contrib/dummy_seclabel/dummy_seclabel.c b/contrib/dummy_seclabel/dummy_seclabel.c
index 974806f1b6..5deb43fa9b 100644
--- a/contrib/dummy_seclabel/dummy_seclabel.c
+++ b/contrib/dummy_seclabel/dummy_seclabel.c
@@ -18,7 +18,7 @@
PG_MODULE_MAGIC;
/* Entrypoint of the module */
-void _PG_init(void);
+void _PG_init(void);
static void
dummy_object_relabel(const ObjectAddress *object, const char *seclabel)
diff --git a/contrib/file_fdw/file_fdw.c b/contrib/file_fdw/file_fdw.c
index 6a84a00e8d..466c015107 100644
--- a/contrib/file_fdw/file_fdw.c
+++ b/contrib/file_fdw/file_fdw.c
@@ -45,17 +45,17 @@ struct FileFdwOption
*/
static struct FileFdwOption valid_options[] = {
/* File options */
- { "filename", ForeignTableRelationId },
+ {"filename", ForeignTableRelationId},
/* Format options */
/* oids option is not supported */
- { "format", ForeignTableRelationId },
- { "header", ForeignTableRelationId },
- { "delimiter", ForeignTableRelationId },
- { "quote", ForeignTableRelationId },
- { "escape", ForeignTableRelationId },
- { "null", ForeignTableRelationId },
- { "encoding", ForeignTableRelationId },
+ {"format", ForeignTableRelationId},
+ {"header", ForeignTableRelationId},
+ {"delimiter", ForeignTableRelationId},
+ {"quote", ForeignTableRelationId},
+ {"escape", ForeignTableRelationId},
+ {"null", ForeignTableRelationId},
+ {"encoding", ForeignTableRelationId},
/*
* force_quote is not supported by file_fdw because it's for COPY TO.
@@ -68,7 +68,7 @@ static struct FileFdwOption valid_options[] = {
*/
/* Sentinel */
- { NULL, InvalidOid }
+ {NULL, InvalidOid}
};
/*
@@ -76,9 +76,9 @@ static struct FileFdwOption valid_options[] = {
*/
typedef struct FileFdwExecutionState
{
- char *filename; /* file to read */
- List *options; /* merged COPY options, excluding filename */
- CopyState cstate; /* state of reading file */
+ char *filename; /* file to read */
+ List *options; /* merged COPY options, excluding filename */
+ CopyState cstate; /* state of reading file */
} FileFdwExecutionState;
/*
@@ -94,8 +94,8 @@ PG_FUNCTION_INFO_V1(file_fdw_validator);
* FDW callback routines
*/
static FdwPlan *filePlanForeignScan(Oid foreigntableid,
- PlannerInfo *root,
- RelOptInfo *baserel);
+ PlannerInfo *root,
+ RelOptInfo *baserel);
static void fileExplainForeignScan(ForeignScanState *node, ExplainState *es);
static void fileBeginForeignScan(ForeignScanState *node, int eflags);
static TupleTableSlot *fileIterateForeignScan(ForeignScanState *node);
@@ -109,8 +109,8 @@ static bool is_valid_option(const char *option, Oid context);
static void fileGetOptions(Oid foreigntableid,
char **filename, List **other_options);
static void estimate_costs(PlannerInfo *root, RelOptInfo *baserel,
- const char *filename,
- Cost *startup_cost, Cost *total_cost);
+ const char *filename,
+ Cost *startup_cost, Cost *total_cost);
/*
@@ -149,16 +149,16 @@ file_fdw_validator(PG_FUNCTION_ARGS)
/*
* Only superusers are allowed to set options of a file_fdw foreign table.
- * This is because the filename is one of those options, and we don't
- * want non-superusers to be able to determine which file gets read.
+ * This is because the filename is one of those options, and we don't want
+ * non-superusers to be able to determine which file gets read.
*
* Putting this sort of permissions check in a validator is a bit of a
* crock, but there doesn't seem to be any other place that can enforce
* the check more cleanly.
*
- * Note that the valid_options[] array disallows setting filename at
- * any options level other than foreign table --- otherwise there'd
- * still be a security hole.
+ * Note that the valid_options[] array disallows setting filename at any
+ * options level other than foreign table --- otherwise there'd still be a
+ * security hole.
*/
if (catalog == ForeignTableRelationId && !superuser())
ereport(ERROR,
@@ -171,7 +171,7 @@ file_fdw_validator(PG_FUNCTION_ARGS)
*/
foreach(cell, options_list)
{
- DefElem *def = (DefElem *) lfirst(cell);
+ DefElem *def = (DefElem *) lfirst(cell);
if (!is_valid_option(def->defname, catalog))
{
@@ -276,7 +276,7 @@ fileGetOptions(Oid foreigntableid,
prev = NULL;
foreach(lc, options)
{
- DefElem *def = (DefElem *) lfirst(lc);
+ DefElem *def = (DefElem *) lfirst(lc);
if (strcmp(def->defname, "filename") == 0)
{
@@ -302,7 +302,7 @@ filePlanForeignScan(Oid foreigntableid,
PlannerInfo *root,
RelOptInfo *baserel)
{
- FdwPlan *fdwplan;
+ FdwPlan *fdwplan;
char *filename;
List *options;
@@ -313,7 +313,7 @@ filePlanForeignScan(Oid foreigntableid,
fdwplan = makeNode(FdwPlan);
estimate_costs(root, baserel, filename,
&fdwplan->startup_cost, &fdwplan->total_cost);
- fdwplan->fdw_private = NIL; /* not used */
+ fdwplan->fdw_private = NIL; /* not used */
return fdwplan;
}
@@ -337,7 +337,7 @@ fileExplainForeignScan(ForeignScanState *node, ExplainState *es)
/* Suppress file size if we're not showing cost details */
if (es->costs)
{
- struct stat stat_buf;
+ struct stat stat_buf;
if (stat(filename, &stat_buf) == 0)
ExplainPropertyLong("Foreign File Size", (long) stat_buf.st_size,
@@ -368,8 +368,8 @@ fileBeginForeignScan(ForeignScanState *node, int eflags)
&filename, &options);
/*
- * Create CopyState from FDW options. We always acquire all columns,
- * so as to match the expected ScanTupleSlot signature.
+ * Create CopyState from FDW options. We always acquire all columns, so
+ * as to match the expected ScanTupleSlot signature.
*/
cstate = BeginCopyFrom(node->ss.ss_currentRelation,
filename,
@@ -398,7 +398,7 @@ fileIterateForeignScan(ForeignScanState *node)
{
FileFdwExecutionState *festate = (FileFdwExecutionState *) node->fdw_state;
TupleTableSlot *slot = node->ss.ss_ScanTupleSlot;
- bool found;
+ bool found;
ErrorContextCallback errcontext;
/* Set up callback to identify error line number. */
@@ -410,8 +410,8 @@ fileIterateForeignScan(ForeignScanState *node)
/*
* The protocol for loading a virtual tuple into a slot is first
* ExecClearTuple, then fill the values/isnull arrays, then
- * ExecStoreVirtualTuple. If we don't find another row in the file,
- * we just skip the last step, leaving the slot empty as required.
+ * ExecStoreVirtualTuple. If we don't find another row in the file, we
+ * just skip the last step, leaving the slot empty as required.
*
* We can pass ExprContext = NULL because we read all columns from the
* file, so no need to evaluate default expressions.
@@ -471,17 +471,17 @@ estimate_costs(PlannerInfo *root, RelOptInfo *baserel,
const char *filename,
Cost *startup_cost, Cost *total_cost)
{
- struct stat stat_buf;
- BlockNumber pages;
- int tuple_width;
- double ntuples;
- double nrows;
- Cost run_cost = 0;
- Cost cpu_per_tuple;
+ struct stat stat_buf;
+ BlockNumber pages;
+ int tuple_width;
+ double ntuples;
+ double nrows;
+ Cost run_cost = 0;
+ Cost cpu_per_tuple;
/*
- * Get size of the file. It might not be there at plan time, though,
- * in which case we have to use a default estimate.
+ * Get size of the file. It might not be there at plan time, though, in
+ * which case we have to use a default estimate.
*/
if (stat(filename, &stat_buf) < 0)
stat_buf.st_size = 10 * BLCKSZ;
@@ -489,7 +489,7 @@ estimate_costs(PlannerInfo *root, RelOptInfo *baserel,
/*
* Convert size to pages for use in I/O cost estimate below.
*/
- pages = (stat_buf.st_size + (BLCKSZ-1)) / BLCKSZ;
+ pages = (stat_buf.st_size + (BLCKSZ - 1)) / BLCKSZ;
if (pages < 1)
pages = 1;
@@ -505,10 +505,9 @@ estimate_costs(PlannerInfo *root, RelOptInfo *baserel,
ntuples = clamp_row_est((double) stat_buf.st_size / (double) tuple_width);
/*
- * Now estimate the number of rows returned by the scan after applying
- * the baserestrictinfo quals. This is pretty bogus too, since the
- * planner will have no stats about the relation, but it's better than
- * nothing.
+ * Now estimate the number of rows returned by the scan after applying the
+ * baserestrictinfo quals. This is pretty bogus too, since the planner
+ * will have no stats about the relation, but it's better than nothing.
*/
nrows = ntuples *
clauselist_selectivity(root,
@@ -523,7 +522,7 @@ estimate_costs(PlannerInfo *root, RelOptInfo *baserel,
baserel->rows = nrows;
/*
- * Now estimate costs. We estimate costs almost the same way as
+ * Now estimate costs. We estimate costs almost the same way as
* cost_seqscan(), thus assuming that I/O costs are equivalent to a
* regular table file of the same size. However, we take per-tuple CPU
* costs as 10x of a seqscan, to account for the cost of parsing records.
diff --git a/contrib/fuzzystrmatch/levenshtein.c b/contrib/fuzzystrmatch/levenshtein.c
index 3d85d4175f..a84c46a4a4 100644
--- a/contrib/fuzzystrmatch/levenshtein.c
+++ b/contrib/fuzzystrmatch/levenshtein.c
@@ -23,7 +23,7 @@
*/
#ifdef LEVENSHTEIN_LESS_EQUAL
static int levenshtein_less_equal_internal(text *s, text *t,
- int ins_c, int del_c, int sub_c, int max_d);
+ int ins_c, int del_c, int sub_c, int max_d);
#else
static int levenshtein_internal(text *s, text *t,
int ins_c, int del_c, int sub_c);
@@ -50,7 +50,7 @@ static int levenshtein_internal(text *s, text *t,
* array.
*
* If max_d >= 0, we only need to provide an accurate answer when that answer
- * is less than or equal to the bound. From any cell in the matrix, there is
+ * is less than or equal to the bound. From any cell in the matrix, there is
* theoretical "minimum residual distance" from that cell to the last column
* of the final row. This minimum residual distance is zero when the
* untransformed portions of the strings are of equal length (because we might
@@ -87,11 +87,13 @@ levenshtein_internal(text *s, text *t,
/*
* For levenshtein_less_equal_internal, we have real variables called
- * start_column and stop_column; otherwise it's just short-hand for 0
- * and m.
+ * start_column and stop_column; otherwise it's just short-hand for 0 and
+ * m.
*/
#ifdef LEVENSHTEIN_LESS_EQUAL
- int start_column, stop_column;
+ int start_column,
+ stop_column;
+
#undef START_COLUMN
#undef STOP_COLUMN
#define START_COLUMN start_column
@@ -139,16 +141,16 @@ levenshtein_internal(text *s, text *t,
stop_column = m + 1;
/*
- * If max_d >= 0, determine whether the bound is impossibly tight. If so,
+ * If max_d >= 0, determine whether the bound is impossibly tight. If so,
* return max_d + 1 immediately. Otherwise, determine whether it's tight
* enough to limit the computation we must perform. If so, figure out
* initial stop column.
*/
if (max_d >= 0)
{
- int min_theo_d; /* Theoretical minimum distance. */
- int max_theo_d; /* Theoretical maximum distance. */
- int net_inserts = n - m;
+ int min_theo_d; /* Theoretical minimum distance. */
+ int max_theo_d; /* Theoretical maximum distance. */
+ int net_inserts = n - m;
min_theo_d = net_inserts < 0 ?
-net_inserts * del_c : net_inserts * ins_c;
@@ -162,20 +164,20 @@ levenshtein_internal(text *s, text *t,
else if (ins_c + del_c > 0)
{
/*
- * Figure out how much of the first row of the notional matrix
- * we need to fill in. If the string is growing, the theoretical
+ * Figure out how much of the first row of the notional matrix we
+ * need to fill in. If the string is growing, the theoretical
* minimum distance already incorporates the cost of deleting the
- * number of characters necessary to make the two strings equal
- * in length. Each additional deletion forces another insertion,
- * so the best-case total cost increases by ins_c + del_c.
- * If the string is shrinking, the minimum theoretical cost
- * assumes no excess deletions; that is, we're starting no futher
- * right than column n - m. If we do start further right, the
- * best-case total cost increases by ins_c + del_c for each move
- * right.
+ * number of characters necessary to make the two strings equal in
+ * length. Each additional deletion forces another insertion, so
+ * the best-case total cost increases by ins_c + del_c. If the
+ * string is shrinking, the minimum theoretical cost assumes no
+ * excess deletions; that is, we're starting no futher right than
+ * column n - m. If we do start further right, the best-case
+ * total cost increases by ins_c + del_c for each move right.
*/
- int slack_d = max_d - min_theo_d;
- int best_column = net_inserts < 0 ? -net_inserts : 0;
+ int slack_d = max_d - min_theo_d;
+ int best_column = net_inserts < 0 ? -net_inserts : 0;
+
stop_column = best_column + (slack_d / (ins_c + del_c)) + 1;
if (stop_column > m)
stop_column = m + 1;
@@ -185,15 +187,15 @@ levenshtein_internal(text *s, text *t,
/*
* In order to avoid calling pg_mblen() repeatedly on each character in s,
- * we cache all the lengths before starting the main loop -- but if all the
- * characters in both strings are single byte, then we skip this and use
- * a fast-path in the main loop. If only one string contains multi-byte
- * characters, we still build the array, so that the fast-path needn't
- * deal with the case where the array hasn't been initialized.
+ * we cache all the lengths before starting the main loop -- but if all
+ * the characters in both strings are single byte, then we skip this and
+ * use a fast-path in the main loop. If only one string contains
+ * multi-byte characters, we still build the array, so that the fast-path
+ * needn't deal with the case where the array hasn't been initialized.
*/
if (m != s_bytes || n != t_bytes)
{
- int i;
+ int i;
const char *cp = s_data;
s_char_len = (int *) palloc((m + 1) * sizeof(int));
@@ -214,8 +216,8 @@ levenshtein_internal(text *s, text *t,
curr = prev + m;
/*
- * To transform the first i characters of s into the first 0 characters
- * of t, we must perform i deletions.
+ * To transform the first i characters of s into the first 0 characters of
+ * t, we must perform i deletions.
*/
for (i = START_COLUMN; i < STOP_COLUMN; i++)
prev[i] = i * del_c;
@@ -228,6 +230,7 @@ levenshtein_internal(text *s, text *t,
int y_char_len = n != t_bytes + 1 ? pg_mblen(y) : 1;
#ifdef LEVENSHTEIN_LESS_EQUAL
+
/*
* In the best case, values percolate down the diagonal unchanged, so
* we must increment stop_column unless it's already on the right end
@@ -241,10 +244,10 @@ levenshtein_internal(text *s, text *t,
}
/*
- * The main loop fills in curr, but curr[0] needs a special case:
- * to transform the first 0 characters of s into the first j
- * characters of t, we must perform j insertions. However, if
- * start_column > 0, this special case does not apply.
+ * The main loop fills in curr, but curr[0] needs a special case: to
+ * transform the first 0 characters of s into the first j characters
+ * of t, we must perform j insertions. However, if start_column > 0,
+ * this special case does not apply.
*/
if (start_column == 0)
{
@@ -285,7 +288,7 @@ levenshtein_internal(text *s, text *t,
*/
ins = prev[i] + ins_c;
del = curr[i - 1] + del_c;
- if (x[x_char_len-1] == y[y_char_len-1]
+ if (x[x_char_len - 1] == y[y_char_len - 1]
&& x_char_len == y_char_len &&
(x_char_len == 1 || rest_of_char_same(x, y, x_char_len)))
sub = prev[i - 1];
@@ -331,6 +334,7 @@ levenshtein_internal(text *s, text *t,
y += y_char_len;
#ifdef LEVENSHTEIN_LESS_EQUAL
+
/*
* This chunk of code represents a significant performance hit if used
* in the case where there is no max_d bound. This is probably not
@@ -348,15 +352,16 @@ levenshtein_internal(text *s, text *t,
* string, so we want to find the value for zp where where (n - 1)
* - j = (m - 1) - zp.
*/
- int zp = j - (n - m);
+ int zp = j - (n - m);
/* Check whether the stop column can slide left. */
while (stop_column > 0)
{
- int ii = stop_column - 1;
- int net_inserts = ii - zp;
+ int ii = stop_column - 1;
+ int net_inserts = ii - zp;
+
if (prev[ii] + (net_inserts > 0 ? net_inserts * ins_c :
- -net_inserts * del_c) <= max_d)
+ -net_inserts * del_c) <= max_d)
break;
stop_column--;
}
@@ -364,14 +369,16 @@ levenshtein_internal(text *s, text *t,
/* Check whether the start column can slide right. */
while (start_column < stop_column)
{
- int net_inserts = start_column - zp;
+ int net_inserts = start_column - zp;
+
if (prev[start_column] +
(net_inserts > 0 ? net_inserts * ins_c :
- -net_inserts * del_c) <= max_d)
+ -net_inserts * del_c) <= max_d)
break;
+
/*
- * We'll never again update these values, so we must make
- * sure there's nothing here that could confuse any future
+ * We'll never again update these values, so we must make sure
+ * there's nothing here that could confuse any future
* iteration of the outer loop.
*/
prev[start_column] = max_d + 1;
diff --git a/contrib/hstore/hstore_gin.c b/contrib/hstore/hstore_gin.c
index d55674c79f..2007801cf0 100644
--- a/contrib/hstore/hstore_gin.c
+++ b/contrib/hstore/hstore_gin.c
@@ -13,7 +13,7 @@
/*
* When using a GIN index for hstore, we choose to index both keys and values.
* The storage format is "text" values, with K, V, or N prepended to the string
- * to indicate key, value, or null values. (As of 9.1 it might be better to
+ * to indicate key, value, or null values. (As of 9.1 it might be better to
* store null values as nulls, but we'll keep it this way for on-disk
* compatibility.)
*/
@@ -168,7 +168,7 @@ gin_consistent_hstore(PG_FUNCTION_ARGS)
{
/*
* Index doesn't have information about correspondence of keys and
- * values, so we need recheck. However, if not all the keys are
+ * values, so we need recheck. However, if not all the keys are
* present, we can fail at once.
*/
*recheck = true;
diff --git a/contrib/hstore/hstore_op.c b/contrib/hstore/hstore_op.c
index cb6200ab1d..5b278c14ff 100644
--- a/contrib/hstore/hstore_op.c
+++ b/contrib/hstore/hstore_op.c
@@ -437,7 +437,7 @@ hstore_delete_hstore(PG_FUNCTION_ARGS)
if (snullval != HS_VALISNULL(es2, j)
|| (!snullval
&& (svallen != HS_VALLEN(es2, j)
- || memcmp(HS_VAL(es, ps, i), HS_VAL(es2, ps2, j), svallen) != 0)))
+ || memcmp(HS_VAL(es, ps, i), HS_VAL(es2, ps2, j), svallen) != 0)))
{
HS_COPYITEM(ed, bufd, pd,
HS_KEY(es, ps, i), HS_KEYLEN(es, i),
@@ -1000,7 +1000,7 @@ hstore_contains(PG_FUNCTION_ARGS)
if (nullval != HS_VALISNULL(ve, idx)
|| (!nullval
&& (vallen != HS_VALLEN(ve, idx)
- || memcmp(HS_VAL(te, tstr, i), HS_VAL(ve, vstr, idx), vallen))))
+ || memcmp(HS_VAL(te, tstr, i), HS_VAL(ve, vstr, idx), vallen))))
res = false;
}
else
diff --git a/contrib/intarray/_int_bool.c b/contrib/intarray/_int_bool.c
index 072e8cc897..4e63f6d66c 100644
--- a/contrib/intarray/_int_bool.c
+++ b/contrib/intarray/_int_bool.c
@@ -98,7 +98,7 @@ gettoken(WORKSTATE *state, int4 *val)
}
else
{
- long lval;
+ long lval;
nnn[innn] = '\0';
errno = 0;
@@ -355,8 +355,8 @@ gin_bool_consistent(QUERYTYPE *query, bool *check)
return FALSE;
/*
- * Set up data for checkcondition_gin. This must agree with the
- * query extraction code in ginint4_queryextract.
+ * Set up data for checkcondition_gin. This must agree with the query
+ * extraction code in ginint4_queryextract.
*/
gcv.first = items;
gcv.mapped_check = (bool *) palloc(sizeof(bool) * query->size);
diff --git a/contrib/intarray/_int_gin.c b/contrib/intarray/_int_gin.c
index 3ef5c4635a..9abe54e55f 100644
--- a/contrib/intarray/_int_gin.c
+++ b/contrib/intarray/_int_gin.c
@@ -34,8 +34,8 @@ ginint4_queryextract(PG_FUNCTION_ARGS)
/*
* If the query doesn't have any required primitive values (for
- * instance, it's something like '! 42'), we have to do a full
- * index scan.
+ * instance, it's something like '! 42'), we have to do a full index
+ * scan.
*/
if (query_has_required_values(query))
*searchMode = GIN_SEARCH_MODE_DEFAULT;
@@ -95,7 +95,7 @@ ginint4_queryextract(PG_FUNCTION_ARGS)
case RTOldContainsStrategyNumber:
if (*nentries > 0)
*searchMode = GIN_SEARCH_MODE_DEFAULT;
- else /* everything contains the empty set */
+ else /* everything contains the empty set */
*searchMode = GIN_SEARCH_MODE_ALL;
break;
default:
@@ -116,6 +116,7 @@ ginint4_consistent(PG_FUNCTION_ARGS)
bool *check = (bool *) PG_GETARG_POINTER(0);
StrategyNumber strategy = PG_GETARG_UINT16(1);
int32 nkeys = PG_GETARG_INT32(3);
+
/* Pointer *extra_data = (Pointer *) PG_GETARG_POINTER(4); */
bool *recheck = (bool *) PG_GETARG_POINTER(5);
bool res = FALSE;
diff --git a/contrib/intarray/_int_tool.c b/contrib/intarray/_int_tool.c
index ddf07f042b..bfc55501db 100644
--- a/contrib/intarray/_int_tool.c
+++ b/contrib/intarray/_int_tool.c
@@ -183,7 +183,7 @@ rt__int_size(ArrayType *a, float *size)
*size = (float) ARRNELEMS(a);
}
-/* Sort the given data (len >= 2). Return true if any duplicates found */
+/* Sort the given data (len >= 2). Return true if any duplicates found */
bool
isort(int4 *a, int len)
{
@@ -195,7 +195,7 @@ isort(int4 *a, int len)
bool r = FALSE;
/*
- * We use a simple insertion sort. While this is O(N^2) in the worst
+ * We use a simple insertion sort. While this is O(N^2) in the worst
* case, it's quite fast if the input is already sorted or nearly so.
* Also, for not-too-large inputs it's faster than more complex methods
* anyhow.
diff --git a/contrib/isn/ISBN.h b/contrib/isn/ISBN.h
index c0301ced1e..dbda6fb724 100644
--- a/contrib/isn/ISBN.h
+++ b/contrib/isn/ISBN.h
@@ -988,4 +988,3 @@ const char *ISBN_range_new[][2] = {
{"10-976000", "10-999999"},
{NULL, NULL},
};
-
diff --git a/contrib/pg_archivecleanup/pg_archivecleanup.c b/contrib/pg_archivecleanup/pg_archivecleanup.c
index 79892077c8..d96eef2c5a 100644
--- a/contrib/pg_archivecleanup/pg_archivecleanup.c
+++ b/contrib/pg_archivecleanup/pg_archivecleanup.c
@@ -25,9 +25,9 @@
#ifdef HAVE_GETOPT_H
#include
#endif
-#else /* WIN32 */
+#else /* WIN32 */
extern int getopt(int argc, char *const argv[], const char *optstring);
-#endif /* ! WIN32 */
+#endif /* ! WIN32 */
extern char *optarg;
extern int optind;
diff --git a/contrib/pg_stat_statements/pg_stat_statements.c b/contrib/pg_stat_statements/pg_stat_statements.c
index 87cf8c55cf..0236b87498 100644
--- a/contrib/pg_stat_statements/pg_stat_statements.c
+++ b/contrib/pg_stat_statements/pg_stat_statements.c
@@ -137,7 +137,7 @@ typedef enum
PGSS_TRACK_NONE, /* track no statements */
PGSS_TRACK_TOP, /* only top level statements */
PGSS_TRACK_ALL /* all statements, including nested ones */
-} PGSSTrackLevel;
+} PGSSTrackLevel;
static const struct config_enum_entry track_options[] =
{
diff --git a/contrib/pg_test_fsync/pg_test_fsync.c b/contrib/pg_test_fsync/pg_test_fsync.c
index 49a7b3c2c0..305b3d0723 100644
--- a/contrib/pg_test_fsync/pg_test_fsync.c
+++ b/contrib/pg_test_fsync/pg_test_fsync.c
@@ -28,24 +28,28 @@
static const char *progname;
-static int ops_per_test = 2000;
-static char full_buf[XLOG_SEG_SIZE], *buf, *filename = FSYNC_FILENAME;
-static struct timeval start_t, stop_t;
-
-
-static void handle_args(int argc, char *argv[]);
-static void prepare_buf(void);
-static void test_open(void);
-static void test_non_sync(void);
-static void test_sync(int writes_per_op);
-static void test_open_syncs(void);
-static void test_open_sync(const char *msg, int writes_size);
-static void test_file_descriptor_sync(void);
+static int ops_per_test = 2000;
+static char full_buf[XLOG_SEG_SIZE],
+ *buf,
+ *filename = FSYNC_FILENAME;
+static struct timeval start_t,
+ stop_t;
+
+
+static void handle_args(int argc, char *argv[]);
+static void prepare_buf(void);
+static void test_open(void);
+static void test_non_sync(void);
+static void test_sync(int writes_per_op);
+static void test_open_syncs(void);
+static void test_open_sync(const char *msg, int writes_size);
+static void test_file_descriptor_sync(void);
+
#ifdef HAVE_FSYNC_WRITETHROUGH
static int pg_fsync_writethrough(int fd);
#endif
-static void print_elapse(struct timeval start_t, struct timeval stop_t);
-static void die(const char *str);
+static void print_elapse(struct timeval start_t, struct timeval stop_t);
+static void die(const char *str);
int
@@ -103,7 +107,7 @@ handle_args(int argc, char *argv[])
}
while ((option = getopt_long(argc, argv, "f:o:",
- long_options, &optindex)) != -1)
+ long_options, &optindex)) != -1)
{
switch (option)
{
@@ -176,7 +180,9 @@ test_open(void)
static void
test_sync(int writes_per_op)
{
- int tmpfile, ops, writes;
+ int tmpfile,
+ ops,
+ writes;
bool fs_warning = false;
if (writes_per_op == 1)
@@ -353,7 +359,9 @@ test_open_syncs(void)
static void
test_open_sync(const char *msg, int writes_size)
{
- int tmpfile, ops, writes;
+ int tmpfile,
+ ops,
+ writes;
printf(LABEL_FORMAT, msg);
fflush(stdout);
@@ -377,7 +385,6 @@ test_open_sync(const char *msg, int writes_size)
close(tmpfile);
print_elapse(start_t, stop_t);
}
-
#else
printf(NA_FORMAT, "n/a\n");
#endif
@@ -386,22 +393,22 @@ test_open_sync(const char *msg, int writes_size)
static void
test_file_descriptor_sync(void)
{
- int tmpfile, ops;
+ int tmpfile,
+ ops;
/*
- * Test whether fsync can sync data written on a different
- * descriptor for the same file. This checks the efficiency
- * of multi-process fsyncs against the same file.
- * Possibly this should be done with writethrough on platforms
- * which support it.
+ * Test whether fsync can sync data written on a different descriptor for
+ * the same file. This checks the efficiency of multi-process fsyncs
+ * against the same file. Possibly this should be done with writethrough
+ * on platforms which support it.
*/
printf("\nTest if fsync on non-write file descriptor is honored:\n");
printf("(If the times are similar, fsync() can sync data written\n");
printf("on a different descriptor.)\n");
/*
- * first write, fsync and close, which is the
- * normal behavior without multiple descriptors
+ * first write, fsync and close, which is the normal behavior without
+ * multiple descriptors
*/
printf(LABEL_FORMAT, "write, fsync, close");
fflush(stdout);
@@ -416,9 +423,10 @@ test_file_descriptor_sync(void)
if (fsync(tmpfile) != 0)
die("fsync failed");
close(tmpfile);
+
/*
- * open and close the file again to be consistent
- * with the following test
+ * open and close the file again to be consistent with the following
+ * test
*/
if ((tmpfile = open(filename, O_RDWR, 0)) == -1)
die("could not open output file");
@@ -428,9 +436,8 @@ test_file_descriptor_sync(void)
print_elapse(start_t, stop_t);
/*
- * Now open, write, close, open again and fsync
- * This simulates processes fsyncing each other's
- * writes.
+ * Now open, write, close, open again and fsync This simulates processes
+ * fsyncing each other's writes.
*/
printf(LABEL_FORMAT, "write, close, fsync");
fflush(stdout);
@@ -458,7 +465,8 @@ test_file_descriptor_sync(void)
static void
test_non_sync(void)
{
- int tmpfile, ops;
+ int tmpfile,
+ ops;
/*
* Test a simple write without fsync
@@ -494,7 +502,6 @@ pg_fsync_writethrough(int fd)
return -1;
#endif
}
-
#endif
/*
diff --git a/contrib/pg_trgm/trgm.h b/contrib/pg_trgm/trgm.h
index f3644fcce7..61de5d89d1 100644
--- a/contrib/pg_trgm/trgm.h
+++ b/contrib/pg_trgm/trgm.h
@@ -51,8 +51,9 @@ uint32 trgm2int(trgm *ptr);
#endif
#define ISPRINTABLETRGM(t) ( ISPRINTABLECHAR( ((char*)(t)) ) && ISPRINTABLECHAR( ((char*)(t))+1 ) && ISPRINTABLECHAR( ((char*)(t))+2 ) )
-#define ISESCAPECHAR(x) (*(x) == '\\') /* Wildcard escape character */
-#define ISWILDCARDCHAR(x) (*(x) == '_' || *(x) == '%') /* Wildcard meta-character */
+#define ISESCAPECHAR(x) (*(x) == '\\') /* Wildcard escape character */
+#define ISWILDCARDCHAR(x) (*(x) == '_' || *(x) == '%') /* Wildcard
+ * meta-character */
typedef struct
{
@@ -105,4 +106,4 @@ TRGM *generate_wildcard_trgm(const char *str, int slen);
float4 cnt_sml(TRGM *trg1, TRGM *trg2);
bool trgm_contained_by(TRGM *trg1, TRGM *trg2);
-#endif /* __TRGM_H__ */
+#endif /* __TRGM_H__ */
diff --git a/contrib/pg_trgm/trgm_gin.c b/contrib/pg_trgm/trgm_gin.c
index aaca1f9737..43ac0b0c65 100644
--- a/contrib/pg_trgm/trgm_gin.c
+++ b/contrib/pg_trgm/trgm_gin.c
@@ -67,7 +67,7 @@ gin_extract_value_trgm(PG_FUNCTION_ARGS)
ptr = GETARR(trg);
for (i = 0; i < trglen; i++)
{
- int32 item = trgm2int(ptr);
+ int32 item = trgm2int(ptr);
entries[i] = Int32GetDatum(item);
ptr++;
@@ -83,10 +83,11 @@ gin_extract_query_trgm(PG_FUNCTION_ARGS)
text *val = (text *) PG_GETARG_TEXT_P(0);
int32 *nentries = (int32 *) PG_GETARG_POINTER(1);
StrategyNumber strategy = PG_GETARG_UINT16(2);
- /* bool **pmatch = (bool **) PG_GETARG_POINTER(3); */
- /* Pointer *extra_data = (Pointer *) PG_GETARG_POINTER(4); */
- /* bool **nullFlags = (bool **) PG_GETARG_POINTER(5); */
- int32 *searchMode = (int32 *) PG_GETARG_POINTER(6);
+
+ /* bool **pmatch = (bool **) PG_GETARG_POINTER(3); */
+ /* Pointer *extra_data = (Pointer *) PG_GETARG_POINTER(4); */
+ /* bool **nullFlags = (bool **) PG_GETARG_POINTER(5); */
+ int32 *searchMode = (int32 *) PG_GETARG_POINTER(6);
Datum *entries = NULL;
TRGM *trg;
int32 trglen;
@@ -104,6 +105,7 @@ gin_extract_query_trgm(PG_FUNCTION_ARGS)
#endif
/* FALL THRU */
case LikeStrategyNumber:
+
/*
* For wildcard search we extract all the trigrams that every
* potentially-matching string must include.
@@ -112,7 +114,7 @@ gin_extract_query_trgm(PG_FUNCTION_ARGS)
break;
default:
elog(ERROR, "unrecognized strategy number: %d", strategy);
- trg = NULL; /* keep compiler quiet */
+ trg = NULL; /* keep compiler quiet */
break;
}
@@ -125,7 +127,7 @@ gin_extract_query_trgm(PG_FUNCTION_ARGS)
ptr = GETARR(trg);
for (i = 0; i < trglen; i++)
{
- int32 item = trgm2int(ptr);
+ int32 item = trgm2int(ptr);
entries[i] = Int32GetDatum(item);
ptr++;
@@ -146,9 +148,11 @@ gin_trgm_consistent(PG_FUNCTION_ARGS)
{
bool *check = (bool *) PG_GETARG_POINTER(0);
StrategyNumber strategy = PG_GETARG_UINT16(1);
+
/* text *query = PG_GETARG_TEXT_P(2); */
int32 nkeys = PG_GETARG_INT32(3);
- /* Pointer *extra_data = (Pointer *) PG_GETARG_POINTER(4); */
+
+ /* Pointer *extra_data = (Pointer *) PG_GETARG_POINTER(4); */
bool *recheck = (bool *) PG_GETARG_POINTER(5);
bool res;
int32 i,
diff --git a/contrib/pg_trgm/trgm_gist.c b/contrib/pg_trgm/trgm_gist.c
index d83265c11c..b328a09f41 100644
--- a/contrib/pg_trgm/trgm_gist.c
+++ b/contrib/pg_trgm/trgm_gist.c
@@ -190,17 +190,18 @@ gtrgm_consistent(PG_FUNCTION_ARGS)
GISTENTRY *entry = (GISTENTRY *) PG_GETARG_POINTER(0);
text *query = PG_GETARG_TEXT_P(1);
StrategyNumber strategy = (StrategyNumber) PG_GETARG_UINT16(2);
+
/* Oid subtype = PG_GETARG_OID(3); */
bool *recheck = (bool *) PG_GETARG_POINTER(4);
TRGM *key = (TRGM *) DatumGetPointer(entry->key);
TRGM *qtrg;
bool res;
char *cache = (char *) fcinfo->flinfo->fn_extra,
- *cacheContents = cache + MAXALIGN(sizeof(StrategyNumber));
+ *cacheContents = cache + MAXALIGN(sizeof(StrategyNumber));
/*
* Store both the strategy number and extracted trigrams in cache, because
- * trigram extraction is relatively CPU-expensive. We must include
+ * trigram extraction is relatively CPU-expensive. We must include
* strategy number because trigram extraction depends on strategy.
*/
if (cache == NULL || strategy != *((StrategyNumber *) cache) ||
@@ -222,7 +223,7 @@ gtrgm_consistent(PG_FUNCTION_ARGS)
break;
default:
elog(ERROR, "unrecognized strategy number: %d", strategy);
- qtrg = NULL; /* keep compiler quiet */
+ qtrg = NULL; /* keep compiler quiet */
break;
}
@@ -251,20 +252,20 @@ gtrgm_consistent(PG_FUNCTION_ARGS)
*recheck = false;
if (GIST_LEAF(entry))
- { /* all leafs contains orig trgm */
- float4 tmpsml = cnt_sml(key, qtrg);
+ { /* all leafs contains orig trgm */
+ float4 tmpsml = cnt_sml(key, qtrg);
/* strange bug at freebsd 5.2.1 and gcc 3.3.3 */
res = (*(int *) &tmpsml == *(int *) &trgm_limit || tmpsml > trgm_limit) ? true : false;
}
else if (ISALLTRUE(key))
- { /* non-leaf contains signature */
+ { /* non-leaf contains signature */
res = true;
}
else
- { /* non-leaf contains signature */
- int4 count = cnt_sml_sign_common(qtrg, GETSIGN(key));
- int4 len = ARRNELEM(qtrg);
+ { /* non-leaf contains signature */
+ int4 count = cnt_sml_sign_common(qtrg, GETSIGN(key));
+ int4 len = ARRNELEM(qtrg);
if (len == 0)
res = false;
@@ -286,20 +287,20 @@ gtrgm_consistent(PG_FUNCTION_ARGS)
* nodes.
*/
if (GIST_LEAF(entry))
- { /* all leafs contains orig trgm */
+ { /* all leafs contains orig trgm */
res = trgm_contained_by(qtrg, key);
}
else if (ISALLTRUE(key))
- { /* non-leaf contains signature */
+ { /* non-leaf contains signature */
res = true;
}
else
- { /* non-leaf contains signature */
- int32 k,
- tmp = 0,
- len = ARRNELEM(qtrg);
- trgm *ptr = GETARR(qtrg);
- BITVECP sign = GETSIGN(key);
+ { /* non-leaf contains signature */
+ int32 k,
+ tmp = 0,
+ len = ARRNELEM(qtrg);
+ trgm *ptr = GETARR(qtrg);
+ BITVECP sign = GETSIGN(key);
res = true;
for (k = 0; k < len; k++)
@@ -328,6 +329,7 @@ gtrgm_distance(PG_FUNCTION_ARGS)
GISTENTRY *entry = (GISTENTRY *) PG_GETARG_POINTER(0);
text *query = PG_GETARG_TEXT_P(1);
StrategyNumber strategy = (StrategyNumber) PG_GETARG_UINT16(2);
+
/* Oid subtype = PG_GETARG_OID(3); */
TRGM *key = (TRGM *) DatumGetPointer(entry->key);
TRGM *qtrg;
@@ -355,17 +357,17 @@ gtrgm_distance(PG_FUNCTION_ARGS)
{
case DistanceStrategyNumber:
if (GIST_LEAF(entry))
- { /* all leafs contains orig trgm */
+ { /* all leafs contains orig trgm */
res = 1.0 - cnt_sml(key, qtrg);
}
else if (ISALLTRUE(key))
- { /* all leafs contains orig trgm */
+ { /* all leafs contains orig trgm */
res = 0.0;
}
else
- { /* non-leaf contains signature */
- int4 count = cnt_sml_sign_common(qtrg, GETSIGN(key));
- int4 len = ARRNELEM(qtrg);
+ { /* non-leaf contains signature */
+ int4 count = cnt_sml_sign_common(qtrg, GETSIGN(key));
+ int4 len = ARRNELEM(qtrg);
res = (len == 0) ? -1.0 : 1.0 - ((float8) count) / ((float8) len);
}
diff --git a/contrib/pg_trgm/trgm_op.c b/contrib/pg_trgm/trgm_op.c
index 52f9172f6d..dfb2df5048 100644
--- a/contrib/pg_trgm/trgm_op.c
+++ b/contrib/pg_trgm/trgm_op.c
@@ -273,9 +273,9 @@ get_wildcard_part(const char *str, int lenstr,
const char *beginword = str;
const char *endword;
char *s = buf;
- bool in_wildcard_meta = false;
- bool in_escape = false;
- int clen;
+ bool in_wildcard_meta = false;
+ bool in_escape = false;
+ int clen;
/*
* Find the first word character remembering whether last character was
@@ -410,14 +410,14 @@ generate_wildcard_trgm(const char *str, int slen)
{
TRGM *trg;
char *buf,
- *buf2;
+ *buf2;
trgm *tptr;
int len,
charlen,
bytelen;
const char *eword;
- trg = (TRGM *) palloc(TRGMHDRSIZE + sizeof(trgm) * (slen / 2 + 1) * 3);
+ trg = (TRGM *) palloc(TRGMHDRSIZE + sizeof(trgm) * (slen / 2 + 1) *3);
trg->flag = ARRKEY;
SET_VARSIZE(trg, TRGMHDRSIZE);
@@ -638,6 +638,7 @@ similarity_dist(PG_FUNCTION_ARGS)
float4 res = DatumGetFloat4(DirectFunctionCall2(similarity,
PG_GETARG_DATUM(0),
PG_GETARG_DATUM(1)));
+
PG_RETURN_FLOAT4(1.0 - res);
}
diff --git a/contrib/pg_upgrade/check.c b/contrib/pg_upgrade/check.c
index 05aac8fde9..747244072d 100644
--- a/contrib/pg_upgrade/check.c
+++ b/contrib/pg_upgrade/check.c
@@ -212,7 +212,10 @@ check_cluster_versions(void)
old_cluster.major_version = get_major_server_version(&old_cluster);
new_cluster.major_version = get_major_server_version(&new_cluster);
- /* We allow upgrades from/to the same major version for alpha/beta upgrades */
+ /*
+ * We allow upgrades from/to the same major version for alpha/beta
+ * upgrades
+ */
if (GET_MAJOR_VERSION(old_cluster.major_version) < 803)
pg_log(PG_FATAL, "This utility can only upgrade from PostgreSQL version 8.3 and later.\n");
@@ -516,7 +519,7 @@ check_for_isn_and_int8_passing_mismatch(ClusterInfo *cluster)
}
if (script)
- fclose(script);
+ fclose(script);
if (found)
{
diff --git a/contrib/pg_upgrade/controldata.c b/contrib/pg_upgrade/controldata.c
index 78c75e8a84..3ac2180d49 100644
--- a/contrib/pg_upgrade/controldata.c
+++ b/contrib/pg_upgrade/controldata.c
@@ -505,8 +505,7 @@ check_control_data(ControlData *oldctrl,
"\nOld and new pg_controldata date/time storage types do not match.\n");
/*
- * This is a common 8.3 -> 8.4 upgrade problem, so we are more
- * verbose
+ * This is a common 8.3 -> 8.4 upgrade problem, so we are more verbose
*/
pg_log(PG_FATAL,
"You will need to rebuild the new server with configure\n"
diff --git a/contrib/pg_upgrade/exec.c b/contrib/pg_upgrade/exec.c
index 7095ba62a8..59a76bc8ae 100644
--- a/contrib/pg_upgrade/exec.c
+++ b/contrib/pg_upgrade/exec.c
@@ -15,7 +15,7 @@
static void check_data_dir(const char *pg_data);
static void check_bin_dir(ClusterInfo *cluster);
-static void validate_exec(const char *dir, const char *cmdName);
+static void validate_exec(const char *dir, const char *cmdName);
/*
diff --git a/contrib/pg_upgrade/file.c b/contrib/pg_upgrade/file.c
index 0024b6ee00..f8f7233593 100644
--- a/contrib/pg_upgrade/file.c
+++ b/contrib/pg_upgrade/file.c
@@ -377,4 +377,5 @@ win32_pghardlink(const char *src, const char *dst)
else
return 0;
}
+
#endif
diff --git a/contrib/pg_upgrade/function.c b/contrib/pg_upgrade/function.c
index c01ff046bb..322014cd23 100644
--- a/contrib/pg_upgrade/function.c
+++ b/contrib/pg_upgrade/function.c
@@ -21,13 +21,13 @@
void
install_support_functions_in_new_db(const char *db_name)
{
- PGconn *conn = connectToServer(&new_cluster, db_name);
-
+ PGconn *conn = connectToServer(&new_cluster, db_name);
+
/* suppress NOTICE of dropped objects */
PQclear(executeQueryOrDie(conn,
"SET client_min_messages = warning;"));
PQclear(executeQueryOrDie(conn,
- "DROP SCHEMA IF EXISTS binary_upgrade CASCADE;"));
+ "DROP SCHEMA IF EXISTS binary_upgrade CASCADE;"));
PQclear(executeQueryOrDie(conn,
"RESET client_min_messages;"));
@@ -42,31 +42,31 @@ install_support_functions_in_new_db(const char *db_name)
"LANGUAGE C STRICT;"));
PQclear(executeQueryOrDie(conn,
"CREATE OR REPLACE FUNCTION "
- "binary_upgrade.set_next_array_pg_type_oid(OID) "
+ "binary_upgrade.set_next_array_pg_type_oid(OID) "
"RETURNS VOID "
"AS '$libdir/pg_upgrade_support' "
"LANGUAGE C STRICT;"));
PQclear(executeQueryOrDie(conn,
"CREATE OR REPLACE FUNCTION "
- "binary_upgrade.set_next_toast_pg_type_oid(OID) "
+ "binary_upgrade.set_next_toast_pg_type_oid(OID) "
"RETURNS VOID "
"AS '$libdir/pg_upgrade_support' "
"LANGUAGE C STRICT;"));
PQclear(executeQueryOrDie(conn,
"CREATE OR REPLACE FUNCTION "
- "binary_upgrade.set_next_heap_pg_class_oid(OID) "
+ "binary_upgrade.set_next_heap_pg_class_oid(OID) "
"RETURNS VOID "
"AS '$libdir/pg_upgrade_support' "
"LANGUAGE C STRICT;"));
PQclear(executeQueryOrDie(conn,
"CREATE OR REPLACE FUNCTION "
- "binary_upgrade.set_next_index_pg_class_oid(OID) "
+ "binary_upgrade.set_next_index_pg_class_oid(OID) "
"RETURNS VOID "
"AS '$libdir/pg_upgrade_support' "
"LANGUAGE C STRICT;"));
PQclear(executeQueryOrDie(conn,
"CREATE OR REPLACE FUNCTION "
- "binary_upgrade.set_next_toast_pg_class_oid(OID) "
+ "binary_upgrade.set_next_toast_pg_class_oid(OID) "
"RETURNS VOID "
"AS '$libdir/pg_upgrade_support' "
"LANGUAGE C STRICT;"));
diff --git a/contrib/pg_upgrade/info.c b/contrib/pg_upgrade/info.c
index ceb1601cc6..f0cd8e5ede 100644
--- a/contrib/pg_upgrade/info.c
+++ b/contrib/pg_upgrade/info.c
@@ -13,9 +13,9 @@
static void create_rel_filename_map(const char *old_data, const char *new_data,
- const DbInfo *old_db, const DbInfo *new_db,
- const RelInfo *old_rel, const RelInfo *new_rel,
- FileNameMap *map);
+ const DbInfo *old_db, const DbInfo *new_db,
+ const RelInfo *old_rel, const RelInfo *new_rel,
+ FileNameMap *map);
static void get_db_infos(ClusterInfo *cluster);
static void get_rel_infos(ClusterInfo *cluster, DbInfo *dbinfo);
static void free_rel_infos(RelInfoArr *rel_arr);
@@ -40,7 +40,7 @@ gen_db_file_maps(DbInfo *old_db, DbInfo *new_db,
if (old_db->rel_arr.nrels != new_db->rel_arr.nrels)
pg_log(PG_FATAL, "old and new databases \"%s\" have a different number of relations\n",
- old_db->db_name);
+ old_db->db_name);
maps = (FileNameMap *) pg_malloc(sizeof(FileNameMap) *
old_db->rel_arr.nrels);
@@ -52,24 +52,24 @@ gen_db_file_maps(DbInfo *old_db, DbInfo *new_db,
if (old_rel->reloid != new_rel->reloid)
pg_log(PG_FATAL, "Mismatch of relation id: database \"%s\", old relid %d, new relid %d\n",
- old_db->db_name, old_rel->reloid, new_rel->reloid);
+ old_db->db_name, old_rel->reloid, new_rel->reloid);
/*
- * In pre-8.4, TOAST table names change during CLUSTER; in >= 8.4
- * TOAST relation names always use heap table oids, hence we
- * cannot check relation names when upgrading from pre-8.4.
+ * In pre-8.4, TOAST table names change during CLUSTER; in >= 8.4
+ * TOAST relation names always use heap table oids, hence we cannot
+ * check relation names when upgrading from pre-8.4.
*/
if (strcmp(old_rel->nspname, new_rel->nspname) != 0 ||
((GET_MAJOR_VERSION(old_cluster.major_version) >= 804 ||
strcmp(old_rel->nspname, "pg_toast") != 0) &&
strcmp(old_rel->relname, new_rel->relname) != 0))
pg_log(PG_FATAL, "Mismatch of relation names: database \"%s\", "
- "old rel %s.%s, new rel %s.%s\n",
- old_db->db_name, old_rel->nspname, old_rel->relname,
- new_rel->nspname, new_rel->relname);
+ "old rel %s.%s, new rel %s.%s\n",
+ old_db->db_name, old_rel->nspname, old_rel->relname,
+ new_rel->nspname, new_rel->relname);
create_rel_filename_map(old_pgdata, new_pgdata, old_db, new_db,
- old_rel, new_rel, maps + num_maps);
+ old_rel, new_rel, maps + num_maps);
num_maps++;
}
@@ -85,9 +85,9 @@ gen_db_file_maps(DbInfo *old_db, DbInfo *new_db,
*/
static void
create_rel_filename_map(const char *old_data, const char *new_data,
- const DbInfo *old_db, const DbInfo *new_db,
- const RelInfo *old_rel, const RelInfo *new_rel,
- FileNameMap *map)
+ const DbInfo *old_db, const DbInfo *new_db,
+ const RelInfo *old_rel, const RelInfo *new_rel,
+ FileNameMap *map)
{
if (strlen(old_rel->tablespace) == 0)
{
@@ -110,8 +110,8 @@ create_rel_filename_map(const char *old_data, const char *new_data,
}
/*
- * old_relfilenode might differ from pg_class.oid (and hence
- * new_relfilenode) because of CLUSTER, REINDEX, or VACUUM FULL.
+ * old_relfilenode might differ from pg_class.oid (and hence
+ * new_relfilenode) because of CLUSTER, REINDEX, or VACUUM FULL.
*/
map->old_relfilenode = old_rel->relfilenode;
@@ -185,7 +185,9 @@ get_db_infos(ClusterInfo *cluster)
int ntups;
int tupnum;
DbInfo *dbinfos;
- int i_datname, i_oid, i_spclocation;
+ int i_datname,
+ i_oid,
+ i_spclocation;
res = executeQueryOrDie(conn,
"SELECT d.oid, d.datname, t.spclocation "
@@ -241,15 +243,19 @@ get_rel_infos(ClusterInfo *cluster, DbInfo *dbinfo)
int num_rels = 0;
char *nspname = NULL;
char *relname = NULL;
- int i_spclocation, i_nspname, i_relname, i_oid, i_relfilenode;
+ int i_spclocation,
+ i_nspname,
+ i_relname,
+ i_oid,
+ i_relfilenode;
char query[QUERY_ALLOC];
/*
* pg_largeobject contains user data that does not appear in pg_dumpall
* --schema-only output, so we have to copy that system table heap and
- * index. We could grab the pg_largeobject oids from template1, but
- * it is easy to treat it as a normal table.
- * Order by oid so we can join old/new structures efficiently.
+ * index. We could grab the pg_largeobject oids from template1, but it is
+ * easy to treat it as a normal table. Order by oid so we can join old/new
+ * structures efficiently.
*/
snprintf(query, sizeof(query),
@@ -263,7 +269,7 @@ get_rel_infos(ClusterInfo *cluster, DbInfo *dbinfo)
" ((n.nspname NOT IN ('pg_catalog', 'information_schema', 'binary_upgrade') AND "
" c.oid >= %u) "
" OR (n.nspname = 'pg_catalog' AND "
- " relname IN ('pg_largeobject', 'pg_largeobject_loid_pn_index'%s) )) "
+ " relname IN ('pg_largeobject', 'pg_largeobject_loid_pn_index'%s) )) "
/* we preserve pg_class.oid so we sort by it to match old/new */
"ORDER BY 1;",
/* see the comment at the top of old_8_3_create_sequence_script() */
@@ -273,7 +279,7 @@ get_rel_infos(ClusterInfo *cluster, DbInfo *dbinfo)
FirstNormalObjectId,
/* does pg_largeobject_metadata need to be migrated? */
(GET_MAJOR_VERSION(old_cluster.major_version) <= 804) ?
- "" : ", 'pg_largeobject_metadata', 'pg_largeobject_metadata_oid_index'");
+ "" : ", 'pg_largeobject_metadata', 'pg_largeobject_metadata_oid_index'");
res = executeQueryOrDie(conn, query);
diff --git a/contrib/pg_upgrade/pg_upgrade.c b/contrib/pg_upgrade/pg_upgrade.c
index 061544cac8..e435aaef08 100644
--- a/contrib/pg_upgrade/pg_upgrade.c
+++ b/contrib/pg_upgrade/pg_upgrade.c
@@ -18,7 +18,7 @@
* FYI, while pg_class.oid and pg_class.relfilenode are intially the same
* in a cluster, but they can diverge due to CLUSTER, REINDEX, or VACUUM
* FULL. The new cluster will have matching pg_class.oid and
- * pg_class.relfilenode values and be based on the old oid value. This can
+ * pg_class.relfilenode values and be based on the old oid value. This can
* cause the old and new pg_class.relfilenode values to differ. In summary,
* old and new pg_class.oid and new pg_class.relfilenode will have the
* same value, and old pg_class.relfilenode might differ.
@@ -34,7 +34,7 @@
*/
-
+
#include "pg_upgrade.h"
#ifdef HAVE_LANGINFO_H
@@ -53,7 +53,8 @@ static void cleanup(void);
/* This is the database used by pg_dumpall to restore global tables */
#define GLOBAL_DUMP_DB "postgres"
-ClusterInfo old_cluster, new_cluster;
+ClusterInfo old_cluster,
+ new_cluster;
OSInfo os_info;
int
@@ -192,7 +193,7 @@ prepare_new_cluster(void)
exec_prog(true,
SYSTEMQUOTE "\"%s/vacuumdb\" --port %d --username \"%s\" "
"--all --analyze >> %s 2>&1" SYSTEMQUOTE,
- new_cluster.bindir, new_cluster.port, os_info.user, log_opts.filename);
+ new_cluster.bindir, new_cluster.port, os_info.user, log_opts.filename);
check_ok();
/*
@@ -205,7 +206,7 @@ prepare_new_cluster(void)
exec_prog(true,
SYSTEMQUOTE "\"%s/vacuumdb\" --port %d --username \"%s\" "
"--all --freeze >> %s 2>&1" SYSTEMQUOTE,
- new_cluster.bindir, new_cluster.port, os_info.user, log_opts.filename);
+ new_cluster.bindir, new_cluster.port, os_info.user, log_opts.filename);
check_ok();
get_pg_database_relfilenode(&new_cluster);
@@ -229,16 +230,16 @@ prepare_new_databases(void)
prep_status("Creating databases in the new cluster");
/*
- * Install support functions in the global-restore database
- * to preserve pg_authid.oid.
+ * Install support functions in the global-restore database to preserve
+ * pg_authid.oid.
*/
install_support_functions_in_new_db(GLOBAL_DUMP_DB);
/*
* We have to create the databases first so we can install support
- * functions in all the other databases. Ideally we could create
- * the support functions in template1 but pg_dumpall creates database
- * using the template0 template.
+ * functions in all the other databases. Ideally we could create the
+ * support functions in template1 but pg_dumpall creates database using
+ * the template0 template.
*/
exec_prog(true,
SYSTEMQUOTE "\"%s/psql\" --set ON_ERROR_STOP=on "
diff --git a/contrib/pg_upgrade/pg_upgrade.h b/contrib/pg_upgrade/pg_upgrade.h
index 8f72ea80d7..5ca570eb15 100644
--- a/contrib/pg_upgrade/pg_upgrade.h
+++ b/contrib/pg_upgrade/pg_upgrade.h
@@ -85,6 +85,7 @@ typedef struct
{
char old_dir[MAXPGPATH];
char new_dir[MAXPGPATH];
+
/*
* old/new relfilenodes might differ for pg_largeobject(_metadata) indexes
* due to VACUUM FULL or REINDEX. Other relfilenodes are preserved.
@@ -92,7 +93,7 @@ typedef struct
Oid old_relfilenode;
Oid new_relfilenode;
/* the rest are used only for logging and error reporting */
- char nspname[NAMEDATALEN]; /* namespaces */
+ char nspname[NAMEDATALEN]; /* namespaces */
char relname[NAMEDATALEN];
} FileNameMap;
@@ -180,7 +181,7 @@ typedef struct
char *bindir; /* pathname for cluster's executable directory */
unsigned short port; /* port number where postmaster is waiting */
uint32 major_version; /* PG_VERSION of cluster */
- char major_version_str[64]; /* string PG_VERSION of cluster */
+ char major_version_str[64]; /* string PG_VERSION of cluster */
Oid pg_database_oid; /* OID of pg_database relation */
char *libpath; /* pathname for cluster's pkglibdir */
char *tablespace_suffix; /* directory specification */
@@ -232,9 +233,10 @@ typedef struct
/*
* Global variables
*/
-extern LogOpts log_opts;
+extern LogOpts log_opts;
extern UserOpts user_opts;
-extern ClusterInfo old_cluster, new_cluster;
+extern ClusterInfo old_cluster,
+ new_cluster;
extern OSInfo os_info;
extern char scandir_file_pattern[];
@@ -246,8 +248,8 @@ void check_old_cluster(bool live_check,
char **sequence_script_file_name);
void check_new_cluster(void);
void report_clusters_compatible(void);
-void issue_warnings(char *sequence_script_file_name);
-void output_completion_banner(char *deletion_script_file_name);
+void issue_warnings(char *sequence_script_file_name);
+void output_completion_banner(char *deletion_script_file_name);
void check_cluster_versions(void);
void check_cluster_compatibility(bool live_check);
void create_script_for_old_cluster_deletion(char **deletion_script_file_name);
@@ -309,11 +311,11 @@ typedef void *pageCnvCtx;
int dir_matching_filenames(const struct dirent * scan_ent);
int pg_scandir(const char *dirname, struct dirent *** namelist,
- int (*selector) (const struct dirent *));
+ int (*selector) (const struct dirent *));
const char *copyAndUpdateFile(pageCnvCtx *pageConverter, const char *src,
const char *dst, bool force);
const char *linkAndUpdateFile(pageCnvCtx *pageConverter, const char *src,
- const char *dst);
+ const char *dst);
void check_hard_link(void);
@@ -329,10 +331,10 @@ void check_loadable_libraries(void);
FileNameMap *gen_db_file_maps(DbInfo *old_db,
DbInfo *new_db, int *nmaps, const char *old_pgdata,
const char *new_pgdata);
-void get_db_and_rel_infos(ClusterInfo *cluster);
+void get_db_and_rel_infos(ClusterInfo *cluster);
void free_db_and_rel_infos(DbInfoArr *db_arr);
-void print_maps(FileNameMap *maps, int n,
- const char *db_name);
+void print_maps(FileNameMap *maps, int n,
+ const char *db_name);
/* option.c */
@@ -352,12 +354,12 @@ void init_tablespaces(void);
/* server.c */
-PGconn *connectToServer(ClusterInfo *cluster, const char *db_name);
-PGresult *executeQueryOrDie(PGconn *conn, const char *fmt,...);
+PGconn *connectToServer(ClusterInfo *cluster, const char *db_name);
+PGresult *executeQueryOrDie(PGconn *conn, const char *fmt,...);
void start_postmaster(ClusterInfo *cluster, bool quiet);
void stop_postmaster(bool fast, bool quiet);
-uint32 get_major_server_version(ClusterInfo *cluster);
+uint32 get_major_server_version(ClusterInfo *cluster);
void check_for_libpq_envvars(void);
@@ -380,14 +382,14 @@ unsigned int str2uint(const char *str);
/* version.c */
void new_9_0_populate_pg_largeobject_metadata(ClusterInfo *cluster,
- bool check_mode);
+ bool check_mode);
/* version_old_8_3.c */
void old_8_3_check_for_name_data_type_usage(ClusterInfo *cluster);
void old_8_3_check_for_tsquery_usage(ClusterInfo *cluster);
-void old_8_3_rebuild_tsvector_tables(ClusterInfo *cluster, bool check_mode);
-void old_8_3_invalidate_hash_gin_indexes(ClusterInfo *cluster, bool check_mode);
+void old_8_3_rebuild_tsvector_tables(ClusterInfo *cluster, bool check_mode);
+void old_8_3_invalidate_hash_gin_indexes(ClusterInfo *cluster, bool check_mode);
void old_8_3_invalidate_bpchar_pattern_ops_indexes(ClusterInfo *cluster,
- bool check_mode);
+ bool check_mode);
char *old_8_3_create_sequence_script(ClusterInfo *cluster);
diff --git a/contrib/pg_upgrade/relfilenode.c b/contrib/pg_upgrade/relfilenode.c
index d111b13de9..9a0a3ac18d 100644
--- a/contrib/pg_upgrade/relfilenode.c
+++ b/contrib/pg_upgrade/relfilenode.c
@@ -30,7 +30,7 @@ char scandir_file_pattern[MAXPGPATH];
*/
const char *
transfer_all_new_dbs(DbInfoArr *old_db_arr,
- DbInfoArr *new_db_arr, char *old_pgdata, char *new_pgdata)
+ DbInfoArr *new_db_arr, char *old_pgdata, char *new_pgdata)
{
int dbnum;
const char *msg = NULL;
@@ -39,7 +39,7 @@ transfer_all_new_dbs(DbInfoArr *old_db_arr,
if (old_db_arr->ndbs != new_db_arr->ndbs)
pg_log(PG_FATAL, "old and new clusters have a different number of databases\n");
-
+
for (dbnum = 0; dbnum < old_db_arr->ndbs; dbnum++)
{
DbInfo *old_db = &old_db_arr->dbs[dbnum];
@@ -50,8 +50,8 @@ transfer_all_new_dbs(DbInfoArr *old_db_arr,
if (strcmp(old_db->db_name, new_db->db_name) != 0)
pg_log(PG_FATAL, "old and new databases have different names: old \"%s\", new \"%s\"\n",
- old_db->db_name, new_db->db_name);
-
+ old_db->db_name, new_db->db_name);
+
n_maps = 0;
mappings = gen_db_file_maps(old_db, new_db, &n_maps, old_pgdata,
new_pgdata);
@@ -169,7 +169,7 @@ transfer_single_new_db(pageCnvCtx *pageConverter,
for (fileno = 0; fileno < numFiles; fileno++)
{
if (strncmp(namelist[fileno]->d_name, scandir_file_pattern,
- strlen(scandir_file_pattern)) == 0)
+ strlen(scandir_file_pattern)) == 0)
{
snprintf(old_file, sizeof(old_file), "%s/%s", maps[mapnum].old_dir,
namelist[fileno]->d_name);
@@ -178,7 +178,7 @@ transfer_single_new_db(pageCnvCtx *pageConverter,
unlink(new_file);
transfer_relfile(pageConverter, old_file, new_file,
- maps[mapnum].nspname, maps[mapnum].relname);
+ maps[mapnum].nspname, maps[mapnum].relname);
}
}
}
@@ -196,7 +196,7 @@ transfer_single_new_db(pageCnvCtx *pageConverter,
for (fileno = 0; fileno < numFiles; fileno++)
{
if (strncmp(namelist[fileno]->d_name, scandir_file_pattern,
- strlen(scandir_file_pattern)) == 0)
+ strlen(scandir_file_pattern)) == 0)
{
snprintf(old_file, sizeof(old_file), "%s/%s", maps[mapnum].old_dir,
namelist[fileno]->d_name);
@@ -205,7 +205,7 @@ transfer_single_new_db(pageCnvCtx *pageConverter,
unlink(new_file);
transfer_relfile(pageConverter, old_file, new_file,
- maps[mapnum].nspname, maps[mapnum].relname);
+ maps[mapnum].nspname, maps[mapnum].relname);
}
}
}
@@ -227,7 +227,7 @@ transfer_single_new_db(pageCnvCtx *pageConverter,
*/
static void
transfer_relfile(pageCnvCtx *pageConverter, const char *old_file,
- const char *new_file, const char *nspname, const char *relname)
+ const char *new_file, const char *nspname, const char *relname)
{
const char *msg;
@@ -249,7 +249,7 @@ transfer_relfile(pageCnvCtx *pageConverter, const char *old_file,
if ((msg = linkAndUpdateFile(pageConverter, old_file, new_file)) != NULL)
pg_log(PG_FATAL,
- "error while creating link from %s.%s (%s to %s): %s\n",
+ "error while creating link from %s.%s (%s to %s): %s\n",
nspname, relname, old_file, new_file, msg);
}
return;
diff --git a/contrib/pg_upgrade/server.c b/contrib/pg_upgrade/server.c
index a7d5787234..2a0f50eb2a 100644
--- a/contrib/pg_upgrade/server.c
+++ b/contrib/pg_upgrade/server.c
@@ -194,12 +194,12 @@ start_postmaster(ClusterInfo *cluster, bool quiet)
* because it is being used by another process." so we have to send all
* other output to 'nul'.
*
- * Using autovacuum=off disables cleanup vacuum and analyze, but
- * freeze vacuums can still happen, so we set
- * autovacuum_freeze_max_age to its maximum. We assume all datfrozenxid
- * and relfrozen values are less than a gap of 2000000000 from the current
- * xid counter, so autovacuum will not touch them.
- */
+ * Using autovacuum=off disables cleanup vacuum and analyze, but freeze
+ * vacuums can still happen, so we set autovacuum_freeze_max_age to its
+ * maximum. We assume all datfrozenxid and relfrozen values are less than
+ * a gap of 2000000000 from the current xid counter, so autovacuum will
+ * not touch them.
+ */
snprintf(cmd, sizeof(cmd),
SYSTEMQUOTE "\"%s/pg_ctl\" -l \"%s\" -D \"%s\" "
"-o \"-p %d -c autovacuum=off "
@@ -251,7 +251,7 @@ stop_postmaster(bool fast, bool quiet)
"\"%s\" 2>&1" SYSTEMQUOTE,
bindir,
#ifndef WIN32
- log_opts.filename, datadir, fast ? "-m fast" : "", log_opts.filename);
+ log_opts.filename, datadir, fast ? "-m fast" : "", log_opts.filename);
#else
DEVNULL, datadir, fast ? "-m fast" : "", DEVNULL);
#endif
diff --git a/contrib/pg_upgrade/tablespace.c b/contrib/pg_upgrade/tablespace.c
index a575487621..6cdae51cf1 100644
--- a/contrib/pg_upgrade/tablespace.c
+++ b/contrib/pg_upgrade/tablespace.c
@@ -78,8 +78,8 @@ set_tablespace_directory_suffix(ClusterInfo *cluster)
{
/* This cluster has a version-specific subdirectory */
cluster->tablespace_suffix = pg_malloc(4 +
- strlen(cluster->major_version_str) +
- 10 /* OIDCHARS */ + 1);
+ strlen(cluster->major_version_str) +
+ 10 /* OIDCHARS */ + 1);
/* The leading slash is needed to start a new directory. */
sprintf(cluster->tablespace_suffix, "/PG_%s_%d", cluster->major_version_str,
diff --git a/contrib/pg_upgrade/util.c b/contrib/pg_upgrade/util.c
index 804aa0d1e5..9a6691ce75 100644
--- a/contrib/pg_upgrade/util.c
+++ b/contrib/pg_upgrade/util.c
@@ -12,7 +12,7 @@
#include
-LogOpts log_opts;
+LogOpts log_opts;
/*
* report_status()
diff --git a/contrib/pg_upgrade/version_old_8_3.c b/contrib/pg_upgrade/version_old_8_3.c
index 3ec4b59a05..0a60eec926 100644
--- a/contrib/pg_upgrade/version_old_8_3.c
+++ b/contrib/pg_upgrade/version_old_8_3.c
@@ -288,7 +288,7 @@ old_8_3_rebuild_tsvector_tables(ClusterInfo *cluster, bool check_mode)
/* Rebuild all tsvector collumns with one ALTER TABLE command */
if (strcmp(PQgetvalue(res, rowno, i_nspname), nspname) != 0 ||
- strcmp(PQgetvalue(res, rowno, i_relname), relname) != 0)
+ strcmp(PQgetvalue(res, rowno, i_relname), relname) != 0)
{
if (strlen(nspname) != 0 || strlen(relname) != 0)
fprintf(script, ";\n\n");
diff --git a/contrib/pg_upgrade_support/pg_upgrade_support.c b/contrib/pg_upgrade_support/pg_upgrade_support.c
index 02d1512719..2c23cbab9d 100644
--- a/contrib/pg_upgrade_support/pg_upgrade_support.c
+++ b/contrib/pg_upgrade_support/pg_upgrade_support.c
@@ -178,9 +178,9 @@ create_empty_extension(PG_FUNCTION_ARGS)
&textDatums, NULL, &ndatums);
for (i = 0; i < ndatums; i++)
{
- text *txtname = DatumGetTextPP(textDatums[i]);
- char *extName = text_to_cstring(txtname);
- Oid extOid = get_extension_oid(extName, false);
+ text *txtname = DatumGetTextPP(textDatums[i]);
+ char *extName = text_to_cstring(txtname);
+ Oid extOid = get_extension_oid(extName, false);
requiredExtensions = lappend_oid(requiredExtensions, extOid);
}
@@ -188,7 +188,7 @@ create_empty_extension(PG_FUNCTION_ARGS)
InsertExtensionTuple(text_to_cstring(extName),
GetUserId(),
- get_namespace_oid(text_to_cstring(schemaName), false),
+ get_namespace_oid(text_to_cstring(schemaName), false),
relocatable,
text_to_cstring(extVersion),
extConfig,
diff --git a/contrib/pgbench/pgbench.c b/contrib/pgbench/pgbench.c
index 7c2ca6e84d..0a3e5fd928 100644
--- a/contrib/pgbench/pgbench.c
+++ b/contrib/pgbench/pgbench.c
@@ -69,7 +69,7 @@
typedef struct win32_pthread *pthread_t;
typedef int pthread_attr_t;
-static int pthread_create(pthread_t *thread, pthread_attr_t *attr, void *(*start_routine) (void *), void *arg);
+static int pthread_create(pthread_t *thread, pthread_attr_t * attr, void *(*start_routine) (void *), void *arg);
static int pthread_join(pthread_t th, void **thread_return);
#elif defined(ENABLE_THREAD_SAFETY)
/* Use platform-dependent pthread capability */
@@ -87,7 +87,7 @@ static int pthread_join(pthread_t th, void **thread_return);
typedef struct fork_pthread *pthread_t;
typedef int pthread_attr_t;
-static int pthread_create(pthread_t *thread, pthread_attr_t *attr, void *(*start_routine) (void *), void *arg);
+static int pthread_create(pthread_t *thread, pthread_attr_t * attr, void *(*start_routine) (void *), void *arg);
static int pthread_join(pthread_t th, void **thread_return);
#endif
@@ -817,7 +817,7 @@ top:
INSTR_TIME_SET_CURRENT(now);
INSTR_TIME_ACCUM_DIFF(thread->exec_elapsed[cnum],
- now, st->stmt_begin);
+ now, st->stmt_begin);
thread->exec_count[cnum]++;
}
@@ -850,8 +850,8 @@ top:
if (commands[st->state]->type == SQL_COMMAND)
{
/*
- * Read and discard the query result; note this is not included
- * in the statement latency numbers.
+ * Read and discard the query result; note this is not included in
+ * the statement latency numbers.
*/
res = PQgetResult(st->con);
switch (PQresultStatus(res))
@@ -1716,16 +1716,16 @@ printResults(int ttype, int normal_xacts, int nclients,
for (i = 0; i < num_files; i++)
{
- Command **commands;
+ Command **commands;
if (num_files > 1)
- printf("statement latencies in milliseconds, file %d:\n", i+1);
+ printf("statement latencies in milliseconds, file %d:\n", i + 1);
else
printf("statement latencies in milliseconds:\n");
for (commands = sql_files[i]; *commands != NULL; commands++)
{
- Command *command = *commands;
+ Command *command = *commands;
int cnum = command->command_num;
double total_time;
instr_time total_exec_elapsed;
@@ -1737,7 +1737,7 @@ printResults(int ttype, int normal_xacts, int nclients,
total_exec_count = 0;
for (t = 0; t < nthreads; t++)
{
- TState *thread = &threads[t];
+ TState *thread = &threads[t];
INSTR_TIME_ADD(total_exec_elapsed,
thread->exec_elapsed[cnum]);
@@ -2014,9 +2014,9 @@ main(int argc, char **argv)
* is_latencies only works with multiple threads in thread-based
* implementations, not fork-based ones, because it supposes that the
* parent can see changes made to the per-thread execution stats by child
- * threads. It seems useful enough to accept despite this limitation,
- * but perhaps we should FIXME someday (by passing the stats data back
- * up through the parent-to-child pipes).
+ * threads. It seems useful enough to accept despite this limitation, but
+ * perhaps we should FIXME someday (by passing the stats data back up
+ * through the parent-to-child pipes).
*/
#ifndef ENABLE_THREAD_SAFETY
if (is_latencies && nthreads > 1)
@@ -2161,7 +2161,7 @@ main(int argc, char **argv)
threads = (TState *) xmalloc(sizeof(TState) * nthreads);
for (i = 0; i < nthreads; i++)
{
- TState *thread = &threads[i];
+ TState *thread = &threads[i];
thread->tid = i;
thread->state = &state[nclients / nthreads * i];
@@ -2170,7 +2170,7 @@ main(int argc, char **argv)
if (is_latencies)
{
/* Reserve memory for the thread to store per-command latencies */
- int t;
+ int t;
thread->exec_elapsed = (instr_time *)
xmalloc(sizeof(instr_time) * num_commands);
@@ -2200,7 +2200,7 @@ main(int argc, char **argv)
/* start threads */
for (i = 0; i < nthreads; i++)
{
- TState *thread = &threads[i];
+ TState *thread = &threads[i];
INSTR_TIME_SET_CURRENT(thread->start_time);
@@ -2472,7 +2472,7 @@ typedef struct fork_pthread
static int
pthread_create(pthread_t *thread,
- pthread_attr_t *attr,
+ pthread_attr_t * attr,
void *(*start_routine) (void *),
void *arg)
{
@@ -2586,7 +2586,7 @@ typedef struct win32_pthread
void *(*routine) (void *);
void *arg;
void *result;
-} win32_pthread;
+} win32_pthread;
static unsigned __stdcall
win32_pthread_run(void *arg)
@@ -2600,7 +2600,7 @@ win32_pthread_run(void *arg)
static int
pthread_create(pthread_t *thread,
- pthread_attr_t *attr,
+ pthread_attr_t * attr,
void *(*start_routine) (void *),
void *arg)
{
diff --git a/contrib/seg/seg.c b/contrib/seg/seg.c
index afada2a0aa..fd284e0c07 100644
--- a/contrib/seg/seg.c
+++ b/contrib/seg/seg.c
@@ -356,7 +356,7 @@ gseg_picksplit(GistEntryVector *entryvec,
{
seg = (SEG *) DatumGetPointer(entryvec->vector[i].key);
/* center calculation is done this way to avoid possible overflow */
- sort_items[i - 1].center = seg->lower*0.5f + seg->upper*0.5f;
+ sort_items[i - 1].center = seg->lower * 0.5f + seg->upper * 0.5f;
sort_items[i - 1].index = i;
sort_items[i - 1].data = seg;
}
diff --git a/contrib/sepgsql/dml.c b/contrib/sepgsql/dml.c
index 358a2643ca..22666b708e 100644
--- a/contrib/sepgsql/dml.c
+++ b/contrib/sepgsql/dml.c
@@ -59,7 +59,7 @@ fixup_whole_row_references(Oid relOid, Bitmapset *columns)
result = bms_copy(columns);
result = bms_del_member(result, index);
- for (attno=1; attno <= natts; attno++)
+ for (attno = 1; attno <= natts; attno++)
{
tuple = SearchSysCache2(ATTNUM,
ObjectIdGetDatum(relOid),
@@ -108,6 +108,7 @@ fixup_inherited_columns(Oid parentId, Oid childId, Bitmapset *columns)
while ((index = bms_first_member(tmpset)) > 0)
{
attno = index + FirstLowInvalidHeapAttributeNumber;
+
/*
* whole-row-reference shall be fixed-up later
*/
@@ -158,14 +159,13 @@ check_relation_privileges(Oid relOid,
bool result = true;
/*
- * Hardwired Policies:
- * SE-PostgreSQL enforces
- * - clients cannot modify system catalogs using DMLs
- * - clients cannot reference/modify toast relations using DMLs
+ * Hardwired Policies: SE-PostgreSQL enforces - clients cannot modify
+ * system catalogs using DMLs - clients cannot reference/modify toast
+ * relations using DMLs
*/
if (sepgsql_getenforce() > 0)
{
- Oid relnamespace = get_rel_namespace(relOid);
+ Oid relnamespace = get_rel_namespace(relOid);
if (IsSystemNamespace(relnamespace) &&
(required & (SEPG_DB_TABLE__UPDATE |
@@ -242,7 +242,7 @@ check_relation_privileges(Oid relOid,
{
AttrNumber attnum;
uint32 column_perms = 0;
- ObjectAddress object;
+ ObjectAddress object;
if (bms_is_member(index, selected))
column_perms |= SEPG_DB_COLUMN__SELECT;
@@ -290,12 +290,12 @@ sepgsql_dml_privileges(List *rangeTabls, bool abort)
{
ListCell *lr;
- foreach (lr, rangeTabls)
+ foreach(lr, rangeTabls)
{
- RangeTblEntry *rte = lfirst(lr);
- uint32 required = 0;
- List *tableIds;
- ListCell *li;
+ RangeTblEntry *rte = lfirst(lr);
+ uint32 required = 0;
+ List *tableIds;
+ ListCell *li;
/*
* Only regular relations shall be checked
@@ -328,25 +328,24 @@ sepgsql_dml_privileges(List *rangeTabls, bool abort)
/*
* If this RangeTblEntry is also supposed to reference inherited
- * tables, we need to check security label of the child tables.
- * So, we expand rte->relid into list of OIDs of inheritance
- * hierarchy, then checker routine will be invoked for each
- * relations.
+ * tables, we need to check security label of the child tables. So, we
+ * expand rte->relid into list of OIDs of inheritance hierarchy, then
+ * checker routine will be invoked for each relations.
*/
if (!rte->inh)
tableIds = list_make1_oid(rte->relid);
else
tableIds = find_all_inheritors(rte->relid, NoLock, NULL);
- foreach (li, tableIds)
+ foreach(li, tableIds)
{
Oid tableOid = lfirst_oid(li);
Bitmapset *selectedCols;
Bitmapset *modifiedCols;
/*
- * child table has different attribute numbers, so we need
- * to fix up them.
+ * child table has different attribute numbers, so we need to fix
+ * up them.
*/
selectedCols = fixup_inherited_columns(rte->relid, tableOid,
rte->selectedCols);
diff --git a/contrib/sepgsql/hooks.c b/contrib/sepgsql/hooks.c
index 5dc8a3ecaa..7797ccb199 100644
--- a/contrib/sepgsql/hooks.c
+++ b/contrib/sepgsql/hooks.c
@@ -29,17 +29,17 @@ PG_MODULE_MAGIC;
/*
* Declarations
*/
-void _PG_init(void);
+void _PG_init(void);
/*
* Saved hook entries (if stacked)
*/
-static object_access_hook_type next_object_access_hook = NULL;
-static ClientAuthentication_hook_type next_client_auth_hook = NULL;
-static ExecutorCheckPerms_hook_type next_exec_check_perms_hook = NULL;
-static needs_fmgr_hook_type next_needs_fmgr_hook = NULL;
-static fmgr_hook_type next_fmgr_hook = NULL;
-static ProcessUtility_hook_type next_ProcessUtility_hook = NULL;
+static object_access_hook_type next_object_access_hook = NULL;
+static ClientAuthentication_hook_type next_client_auth_hook = NULL;
+static ExecutorCheckPerms_hook_type next_exec_check_perms_hook = NULL;
+static needs_fmgr_hook_type next_needs_fmgr_hook = NULL;
+static fmgr_hook_type next_fmgr_hook = NULL;
+static ProcessUtility_hook_type next_ProcessUtility_hook = NULL;
/*
* GUC: sepgsql.permissive = (on|off)
@@ -73,14 +73,14 @@ sepgsql_get_debug_audit(void)
static void
sepgsql_client_auth(Port *port, int status)
{
- char *context;
+ char *context;
if (next_client_auth_hook)
- (*next_client_auth_hook)(port, status);
+ (*next_client_auth_hook) (port, status);
/*
- * In the case when authentication failed, the supplied socket
- * shall be closed soon, so we don't need to do anything here.
+ * In the case when authentication failed, the supplied socket shall be
+ * closed soon, so we don't need to do anything here.
*/
if (status != STATUS_OK)
return;
@@ -96,8 +96,8 @@ sepgsql_client_auth(Port *port, int status)
sepgsql_set_client_label(context);
/*
- * Switch the current performing mode from INTERNAL to either
- * DEFAULT or PERMISSIVE.
+ * Switch the current performing mode from INTERNAL to either DEFAULT or
+ * PERMISSIVE.
*/
if (sepgsql_permissive)
sepgsql_set_mode(SEPGSQL_MODE_PERMISSIVE);
@@ -113,12 +113,12 @@ sepgsql_client_auth(Port *port, int status)
*/
static void
sepgsql_object_access(ObjectAccessType access,
- Oid classId,
- Oid objectId,
- int subId)
+ Oid classId,
+ Oid objectId,
+ int subId)
{
if (next_object_access_hook)
- (*next_object_access_hook)(access, classId, objectId, subId);
+ (*next_object_access_hook) (access, classId, objectId, subId);
switch (access)
{
@@ -147,7 +147,7 @@ sepgsql_object_access(ObjectAccessType access,
break;
default:
- elog(ERROR, "unexpected object access type: %d", (int)access);
+ elog(ERROR, "unexpected object access type: %d", (int) access);
break;
}
}
@@ -161,11 +161,11 @@ static bool
sepgsql_exec_check_perms(List *rangeTabls, bool abort)
{
/*
- * If security provider is stacking and one of them replied 'false'
- * at least, we don't need to check any more.
+ * If security provider is stacking and one of them replied 'false' at
+ * least, we don't need to check any more.
*/
if (next_exec_check_perms_hook &&
- !(*next_exec_check_perms_hook)(rangeTabls, abort))
+ !(*next_exec_check_perms_hook) (rangeTabls, abort))
return false;
if (!sepgsql_dml_privileges(rangeTabls, abort))
@@ -184,20 +184,19 @@ sepgsql_exec_check_perms(List *rangeTabls, bool abort)
static bool
sepgsql_needs_fmgr_hook(Oid functionId)
{
- char *old_label;
- char *new_label;
- char *function_label;
+ char *old_label;
+ char *new_label;
+ char *function_label;
if (next_needs_fmgr_hook &&
- (*next_needs_fmgr_hook)(functionId))
+ (*next_needs_fmgr_hook) (functionId))
return true;
/*
- * SELinux needs the function to be called via security_definer
- * wrapper, if this invocation will take a domain-transition.
- * We call these functions as trusted-procedure, if the security
- * policy has a rule that switches security label of the client
- * on execution.
+ * SELinux needs the function to be called via security_definer wrapper,
+ * if this invocation will take a domain-transition. We call these
+ * functions as trusted-procedure, if the security policy has a rule that
+ * switches security label of the client on execution.
*/
old_label = sepgsql_get_client_label();
new_label = sepgsql_proc_get_domtrans(functionId);
@@ -210,9 +209,9 @@ sepgsql_needs_fmgr_hook(Oid functionId)
/*
* Even if not a trusted-procedure, this function should not be inlined
- * unless the client has db_procedure:{execute} permission.
- * Please note that it shall be actually failed later because of same
- * reason with ACL_EXECUTE.
+ * unless the client has db_procedure:{execute} permission. Please note
+ * that it shall be actually failed later because of same reason with
+ * ACL_EXECUTE.
*/
function_label = sepgsql_get_label(ProcedureRelationId, functionId, 0);
if (sepgsql_check_perms(sepgsql_get_client_label(),
@@ -238,20 +237,21 @@ static void
sepgsql_fmgr_hook(FmgrHookEventType event,
FmgrInfo *flinfo, Datum *private)
{
- struct {
- char *old_label;
- char *new_label;
- Datum next_private;
- } *stack;
+ struct
+ {
+ char *old_label;
+ char *new_label;
+ Datum next_private;
+ } *stack;
switch (event)
{
case FHET_START:
- stack = (void *)DatumGetPointer(*private);
+ stack = (void *) DatumGetPointer(*private);
if (!stack)
{
- MemoryContext oldcxt;
- const char *cur_label = sepgsql_get_client_label();
+ MemoryContext oldcxt;
+ const char *cur_label = sepgsql_get_client_label();
oldcxt = MemoryContextSwitchTo(flinfo->fn_mcxt);
stack = palloc(sizeof(*stack));
@@ -265,8 +265,8 @@ sepgsql_fmgr_hook(FmgrHookEventType event,
{
/*
* process:transition permission between old and new
- * label, when user tries to switch security label of
- * the client on execution of trusted procedure.
+ * label, when user tries to switch security label of the
+ * client on execution of trusted procedure.
*/
sepgsql_check_perms(cur_label, stack->new_label,
SEPG_CLASS_PROCESS,
@@ -280,22 +280,22 @@ sepgsql_fmgr_hook(FmgrHookEventType event,
stack->old_label = sepgsql_set_client_label(stack->new_label);
if (next_fmgr_hook)
- (*next_fmgr_hook)(event, flinfo, &stack->next_private);
+ (*next_fmgr_hook) (event, flinfo, &stack->next_private);
break;
case FHET_END:
case FHET_ABORT:
- stack = (void *)DatumGetPointer(*private);
+ stack = (void *) DatumGetPointer(*private);
if (next_fmgr_hook)
- (*next_fmgr_hook)(event, flinfo, &stack->next_private);
+ (*next_fmgr_hook) (event, flinfo, &stack->next_private);
sepgsql_set_client_label(stack->old_label);
stack->old_label = NULL;
break;
default:
- elog(ERROR, "unexpected event type: %d", (int)event);
+ elog(ERROR, "unexpected event type: %d", (int) event);
break;
}
}
@@ -315,8 +315,8 @@ sepgsql_utility_command(Node *parsetree,
char *completionTag)
{
if (next_ProcessUtility_hook)
- (*next_ProcessUtility_hook)(parsetree, queryString, params,
- isTopLevel, dest, completionTag);
+ (*next_ProcessUtility_hook) (parsetree, queryString, params,
+ isTopLevel, dest, completionTag);
/*
* Check command tag to avoid nefarious operations
@@ -324,6 +324,7 @@ sepgsql_utility_command(Node *parsetree,
switch (nodeTag(parsetree))
{
case T_LoadStmt:
+
/*
* We reject LOAD command across the board on enforcing mode,
* because a binary module can arbitrarily override hooks.
@@ -336,11 +337,12 @@ sepgsql_utility_command(Node *parsetree,
}
break;
default:
+
/*
- * Right now we don't check any other utility commands,
- * because it needs more detailed information to make
- * access control decision here, but we don't want to
- * have two parse and analyze routines individually.
+ * Right now we don't check any other utility commands, because it
+ * needs more detailed information to make access control decision
+ * here, but we don't want to have two parse and analyze routines
+ * individually.
*/
break;
}
@@ -358,7 +360,7 @@ sepgsql_utility_command(Node *parsetree,
void
_PG_init(void)
{
- char *context;
+ char *context;
/*
* We allow to load the SE-PostgreSQL module on single-user-mode or
@@ -367,12 +369,12 @@ _PG_init(void)
if (IsUnderPostmaster)
ereport(ERROR,
(errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
- errmsg("sepgsql must be loaded via shared_preload_libraries")));
+ errmsg("sepgsql must be loaded via shared_preload_libraries")));
/*
- * Check availability of SELinux on the platform.
- * If disabled, we cannot activate any SE-PostgreSQL features,
- * and we have to skip rest of initialization.
+ * Check availability of SELinux on the platform. If disabled, we cannot
+ * activate any SE-PostgreSQL features, and we have to skip rest of
+ * initialization.
*/
if (is_selinux_enabled() < 1)
{
@@ -383,8 +385,8 @@ _PG_init(void)
/*
* sepgsql.permissive = (on|off)
*
- * This variable controls performing mode of SE-PostgreSQL
- * on user's session.
+ * This variable controls performing mode of SE-PostgreSQL on user's
+ * session.
*/
DefineCustomBoolVariable("sepgsql.permissive",
"Turn on/off permissive mode in SE-PostgreSQL",
@@ -400,10 +402,9 @@ _PG_init(void)
/*
* sepgsql.debug_audit = (on|off)
*
- * This variable allows users to turn on/off audit logs on access
- * control decisions, independent from auditallow/auditdeny setting
- * in the security policy.
- * We intend to use this option for debugging purpose.
+ * This variable allows users to turn on/off audit logs on access control
+ * decisions, independent from auditallow/auditdeny setting in the
+ * security policy. We intend to use this option for debugging purpose.
*/
DefineCustomBoolVariable("sepgsql.debug_audit",
"Turn on/off debug audit messages",
@@ -419,13 +420,12 @@ _PG_init(void)
/*
* Set up dummy client label.
*
- * XXX - note that PostgreSQL launches background worker process
- * like autovacuum without authentication steps. So, we initialize
- * sepgsql_mode with SEPGSQL_MODE_INTERNAL, and client_label with
- * the security context of server process.
- * Later, it also launches background of user session. In this case,
- * the process is always hooked on post-authentication, and we can
- * initialize the sepgsql_mode and client_label correctly.
+ * XXX - note that PostgreSQL launches background worker process like
+ * autovacuum without authentication steps. So, we initialize sepgsql_mode
+ * with SEPGSQL_MODE_INTERNAL, and client_label with the security context
+ * of server process. Later, it also launches background of user session.
+ * In this case, the process is always hooked on post-authentication, and
+ * we can initialize the sepgsql_mode and client_label correctly.
*/
if (getcon_raw(&context) < 0)
ereport(ERROR,
diff --git a/contrib/sepgsql/label.c b/contrib/sepgsql/label.c
index 828512a961..669ee35ac3 100644
--- a/contrib/sepgsql/label.c
+++ b/contrib/sepgsql/label.c
@@ -38,7 +38,7 @@
*
* security label of the client process
*/
-static char *client_label = NULL;
+static char *client_label = NULL;
char *
sepgsql_get_client_label(void)
@@ -49,7 +49,7 @@ sepgsql_get_client_label(void)
char *
sepgsql_set_client_label(char *new_label)
{
- char *old_label = client_label;
+ char *old_label = client_label;
client_label = new_label;
@@ -66,22 +66,22 @@ sepgsql_set_client_label(char *new_label)
char *
sepgsql_get_label(Oid classId, Oid objectId, int32 subId)
{
- ObjectAddress object;
- char *label;
+ ObjectAddress object;
+ char *label;
- object.classId = classId;
- object.objectId = objectId;
- object.objectSubId = subId;
+ object.classId = classId;
+ object.objectId = objectId;
+ object.objectSubId = subId;
label = GetSecurityLabel(&object, SEPGSQL_LABEL_TAG);
- if (!label || security_check_context_raw((security_context_t)label))
+ if (!label || security_check_context_raw((security_context_t) label))
{
- security_context_t unlabeled;
+ security_context_t unlabeled;
if (security_get_initial_context_raw("unlabeled", &unlabeled) < 0)
ereport(ERROR,
(errcode(ERRCODE_INTERNAL_ERROR),
- errmsg("SELinux: failed to get initial security label: %m")));
+ errmsg("SELinux: failed to get initial security label: %m")));
PG_TRY();
{
label = pstrdup(unlabeled);
@@ -107,21 +107,22 @@ void
sepgsql_object_relabel(const ObjectAddress *object, const char *seclabel)
{
/*
- * validate format of the supplied security label,
- * if it is security context of selinux.
+ * validate format of the supplied security label, if it is security
+ * context of selinux.
*/
if (seclabel &&
security_check_context_raw((security_context_t) seclabel) < 0)
ereport(ERROR,
(errcode(ERRCODE_INVALID_NAME),
- errmsg("SELinux: invalid security label: \"%s\"", seclabel)));
+ errmsg("SELinux: invalid security label: \"%s\"", seclabel)));
+
/*
* Do actual permission checks for each object classes
*/
switch (object->classId)
{
case NamespaceRelationId:
- sepgsql_schema_relabel(object->objectId, seclabel);
+ sepgsql_schema_relabel(object->objectId, seclabel);
break;
case RelationRelationId:
if (object->objectSubId == 0)
@@ -151,7 +152,7 @@ PG_FUNCTION_INFO_V1(sepgsql_getcon);
Datum
sepgsql_getcon(PG_FUNCTION_ARGS)
{
- char *client_label;
+ char *client_label;
if (!sepgsql_is_enabled())
PG_RETURN_NULL();
@@ -171,9 +172,9 @@ PG_FUNCTION_INFO_V1(sepgsql_mcstrans_in);
Datum
sepgsql_mcstrans_in(PG_FUNCTION_ARGS)
{
- text *label = PG_GETARG_TEXT_P(0);
- char *raw_label;
- char *result;
+ text *label = PG_GETARG_TEXT_P(0);
+ char *raw_label;
+ char *result;
if (!sepgsql_is_enabled())
ereport(ERROR,
@@ -211,9 +212,9 @@ PG_FUNCTION_INFO_V1(sepgsql_mcstrans_out);
Datum
sepgsql_mcstrans_out(PG_FUNCTION_ARGS)
{
- text *label = PG_GETARG_TEXT_P(0);
- char *qual_label;
- char *result;
+ text *label = PG_GETARG_TEXT_P(0);
+ char *qual_label;
+ char *result;
if (!sepgsql_is_enabled())
ereport(ERROR,
@@ -250,8 +251,8 @@ static char *
quote_object_name(const char *src1, const char *src2,
const char *src3, const char *src4)
{
- StringInfoData result;
- const char *temp;
+ StringInfoData result;
+ const char *temp;
initStringInfo(&result);
@@ -260,28 +261,28 @@ quote_object_name(const char *src1, const char *src2,
temp = quote_identifier(src1);
appendStringInfo(&result, "%s", temp);
if (src1 != temp)
- pfree((void *)temp);
+ pfree((void *) temp);
}
if (src2)
{
temp = quote_identifier(src2);
appendStringInfo(&result, ".%s", temp);
if (src2 != temp)
- pfree((void *)temp);
+ pfree((void *) temp);
}
if (src3)
{
temp = quote_identifier(src3);
appendStringInfo(&result, ".%s", temp);
if (src3 != temp)
- pfree((void *)temp);
+ pfree((void *) temp);
}
if (src4)
{
temp = quote_identifier(src4);
appendStringInfo(&result, ".%s", temp);
if (src4 != temp)
- pfree((void *)temp);
+ pfree((void *) temp);
}
return result.data;
}
@@ -294,19 +295,19 @@ quote_object_name(const char *src1, const char *src2,
* catalog OID.
*/
static void
-exec_object_restorecon(struct selabel_handle *sehnd, Oid catalogId)
+exec_object_restorecon(struct selabel_handle * sehnd, Oid catalogId)
{
- Relation rel;
- SysScanDesc sscan;
- HeapTuple tuple;
- char *database_name = get_database_name(MyDatabaseId);
- char *namespace_name;
- Oid namespace_id;
- char *relation_name;
+ Relation rel;
+ SysScanDesc sscan;
+ HeapTuple tuple;
+ char *database_name = get_database_name(MyDatabaseId);
+ char *namespace_name;
+ Oid namespace_id;
+ char *relation_name;
/*
- * Open the target catalog. We don't want to allow writable
- * accesses by other session during initial labeling.
+ * Open the target catalog. We don't want to allow writable accesses by
+ * other session during initial labeling.
*/
rel = heap_open(catalogId, AccessShareLock);
@@ -314,18 +315,18 @@ exec_object_restorecon(struct selabel_handle *sehnd, Oid catalogId)
SnapshotNow, 0, NULL);
while (HeapTupleIsValid(tuple = systable_getnext(sscan)))
{
- Form_pg_namespace nspForm;
- Form_pg_class relForm;
- Form_pg_attribute attForm;
- Form_pg_proc proForm;
- char *objname;
- int objtype = 1234;
- ObjectAddress object;
- security_context_t context;
+ Form_pg_namespace nspForm;
+ Form_pg_class relForm;
+ Form_pg_attribute attForm;
+ Form_pg_proc proForm;
+ char *objname;
+ int objtype = 1234;
+ ObjectAddress object;
+ security_context_t context;
/*
- * The way to determine object name depends on object classes.
- * So, any branches set up `objtype', `objname' and `object' here.
+ * The way to determine object name depends on object classes. So, any
+ * branches set up `objtype', `objname' and `object' here.
*/
switch (catalogId)
{
@@ -409,7 +410,7 @@ exec_object_restorecon(struct selabel_handle *sehnd, Oid catalogId)
default:
elog(ERROR, "unexpected catalog id: %u", catalogId);
- objname = NULL; /* for compiler quiet */
+ objname = NULL; /* for compiler quiet */
break;
}
@@ -464,8 +465,8 @@ PG_FUNCTION_INFO_V1(sepgsql_restorecon);
Datum
sepgsql_restorecon(PG_FUNCTION_ARGS)
{
- struct selabel_handle *sehnd;
- struct selinux_opt seopts;
+ struct selabel_handle *sehnd;
+ struct selinux_opt seopts;
/*
* SELinux has to be enabled on the running platform.
@@ -474,19 +475,19 @@ sepgsql_restorecon(PG_FUNCTION_ARGS)
ereport(ERROR,
(errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
errmsg("sepgsql is not currently enabled")));
+
/*
- * Check DAC permission. Only superuser can set up initial
- * security labels, like root-user in filesystems
+ * Check DAC permission. Only superuser can set up initial security
+ * labels, like root-user in filesystems
*/
if (!superuser())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- errmsg("SELinux: must be superuser to restore initial contexts")));
+ errmsg("SELinux: must be superuser to restore initial contexts")));
/*
- * Open selabel_lookup(3) stuff. It provides a set of mapping
- * between an initial security label and object class/name due
- * to the system setting.
+ * Open selabel_lookup(3) stuff. It provides a set of mapping between an
+ * initial security label and object class/name due to the system setting.
*/
if (PG_ARGISNULL(0))
{
@@ -502,12 +503,12 @@ sepgsql_restorecon(PG_FUNCTION_ARGS)
if (!sehnd)
ereport(ERROR,
(errcode(ERRCODE_INTERNAL_ERROR),
- errmsg("SELinux: failed to initialize labeling handle: %m")));
+ errmsg("SELinux: failed to initialize labeling handle: %m")));
PG_TRY();
{
/*
- * Right now, we have no support labeling on the shared
- * database objects, such as database, role, or tablespace.
+ * Right now, we have no support labeling on the shared database
+ * objects, such as database, role, or tablespace.
*/
exec_object_restorecon(sehnd, NamespaceRelationId);
exec_object_restorecon(sehnd, RelationRelationId);
@@ -519,7 +520,7 @@ sepgsql_restorecon(PG_FUNCTION_ARGS)
selabel_close(sehnd);
PG_RE_THROW();
}
- PG_END_TRY();
+ PG_END_TRY();
selabel_close(sehnd);
diff --git a/contrib/sepgsql/proc.c b/contrib/sepgsql/proc.c
index 5a0c4947f7..3b8bf23ba3 100644
--- a/contrib/sepgsql/proc.c
+++ b/contrib/sepgsql/proc.c
@@ -33,15 +33,15 @@
void
sepgsql_proc_post_create(Oid functionId)
{
- Relation rel;
- ScanKeyData skey;
- SysScanDesc sscan;
- HeapTuple tuple;
- Oid namespaceId;
- ObjectAddress object;
- char *scontext;
- char *tcontext;
- char *ncontext;
+ Relation rel;
+ ScanKeyData skey;
+ SysScanDesc sscan;
+ HeapTuple tuple;
+ Oid namespaceId;
+ ObjectAddress object;
+ char *scontext;
+ char *tcontext;
+ char *ncontext;
/*
* Fetch namespace of the new procedure. Because pg_proc entry is not
@@ -67,8 +67,8 @@ sepgsql_proc_post_create(Oid functionId)
heap_close(rel, AccessShareLock);
/*
- * Compute a default security label when we create a new procedure
- * object under the specified namespace.
+ * Compute a default security label when we create a new procedure object
+ * under the specified namespace.
*/
scontext = sepgsql_get_client_label();
tcontext = sepgsql_get_label(NamespaceRelationId, namespaceId, 0);
@@ -144,9 +144,9 @@ sepgsql_proc_relabel(Oid functionId, const char *seclabel)
char *
sepgsql_proc_get_domtrans(Oid functionId)
{
- char *scontext = sepgsql_get_client_label();
- char *tcontext;
- char *ncontext;
+ char *scontext = sepgsql_get_client_label();
+ char *tcontext;
+ char *ncontext;
tcontext = sepgsql_get_label(ProcedureRelationId, functionId, 0);
diff --git a/contrib/sepgsql/relation.c b/contrib/sepgsql/relation.c
index ed5e3adc0e..963cfdf9f1 100644
--- a/contrib/sepgsql/relation.c
+++ b/contrib/sepgsql/relation.c
@@ -36,26 +36,27 @@
void
sepgsql_attribute_post_create(Oid relOid, AttrNumber attnum)
{
- char *scontext = sepgsql_get_client_label();
- char *tcontext;
- char *ncontext;
- ObjectAddress object;
+ char *scontext = sepgsql_get_client_label();
+ char *tcontext;
+ char *ncontext;
+ ObjectAddress object;
/*
- * Only attributes within regular relation have individual
- * security labels.
+ * Only attributes within regular relation have individual security
+ * labels.
*/
if (get_rel_relkind(relOid) != RELKIND_RELATION)
return;
/*
- * Compute a default security label when we create a new procedure
- * object under the specified namespace.
+ * Compute a default security label when we create a new procedure object
+ * under the specified namespace.
*/
scontext = sepgsql_get_client_label();
tcontext = sepgsql_get_label(RelationRelationId, relOid, 0);
ncontext = sepgsql_compute_create(scontext, tcontext,
SEPG_CLASS_DB_COLUMN);
+
/*
* Assign the default security label on a new procedure
*/
@@ -81,7 +82,7 @@ sepgsql_attribute_relabel(Oid relOid, AttrNumber attnum,
char *scontext = sepgsql_get_client_label();
char *tcontext;
char *audit_name;
- ObjectAddress object;
+ ObjectAddress object;
if (get_rel_relkind(relOid) != RELKIND_RELATION)
ereport(ERROR,
@@ -127,21 +128,21 @@ sepgsql_attribute_relabel(Oid relOid, AttrNumber attnum,
void
sepgsql_relation_post_create(Oid relOid)
{
- Relation rel;
- ScanKeyData skey;
- SysScanDesc sscan;
- HeapTuple tuple;
- Form_pg_class classForm;
- ObjectAddress object;
- uint16 tclass;
- char *scontext; /* subject */
- char *tcontext; /* schema */
- char *rcontext; /* relation */
- char *ccontext; /* column */
+ Relation rel;
+ ScanKeyData skey;
+ SysScanDesc sscan;
+ HeapTuple tuple;
+ Form_pg_class classForm;
+ ObjectAddress object;
+ uint16 tclass;
+ char *scontext; /* subject */
+ char *tcontext; /* schema */
+ char *rcontext; /* relation */
+ char *ccontext; /* column */
/*
- * Fetch catalog record of the new relation. Because pg_class entry is
- * not visible right now, we need to scan the catalog using SnapshotSelf.
+ * Fetch catalog record of the new relation. Because pg_class entry is not
+ * visible right now, we need to scan the catalog using SnapshotSelf.
*/
rel = heap_open(RelationRelationId, AccessShareLock);
@@ -166,11 +167,11 @@ sepgsql_relation_post_create(Oid relOid)
else if (classForm->relkind == RELKIND_VIEW)
tclass = SEPG_CLASS_DB_VIEW;
else
- goto out; /* No need to assign individual labels */
+ goto out; /* No need to assign individual labels */
/*
- * Compute a default security label when we create a new relation
- * object under the specified namespace.
+ * Compute a default security label when we create a new relation object
+ * under the specified namespace.
*/
scontext = sepgsql_get_client_label();
tcontext = sepgsql_get_label(NamespaceRelationId,
@@ -186,8 +187,8 @@ sepgsql_relation_post_create(Oid relOid)
SetSecurityLabel(&object, SEPGSQL_LABEL_TAG, rcontext);
/*
- * We also assigns a default security label on columns of the new
- * regular tables.
+ * We also assigns a default security label on columns of the new regular
+ * tables.
*/
if (classForm->relkind == RELKIND_RELATION)
{
diff --git a/contrib/sepgsql/schema.c b/contrib/sepgsql/schema.c
index 8538d18ac9..0de89971fb 100644
--- a/contrib/sepgsql/schema.c
+++ b/contrib/sepgsql/schema.c
@@ -26,21 +26,21 @@
void
sepgsql_schema_post_create(Oid namespaceId)
{
- char *scontext = sepgsql_get_client_label();
- char *tcontext;
- char *ncontext;
- ObjectAddress object;
+ char *scontext = sepgsql_get_client_label();
+ char *tcontext;
+ char *ncontext;
+ ObjectAddress object;
/*
- * FIXME: Right now, we assume pg_database object has a fixed
- * security label, because pg_seclabel does not support to store
- * label of shared database objects.
+ * FIXME: Right now, we assume pg_database object has a fixed security
+ * label, because pg_seclabel does not support to store label of shared
+ * database objects.
*/
tcontext = "system_u:object_r:sepgsql_db_t:s0";
/*
- * Compute a default security label when we create a new schema
- * object under the working database.
+ * Compute a default security label when we create a new schema object
+ * under the working database.
*/
ncontext = sepgsql_compute_create(scontext, tcontext,
SEPG_CLASS_DB_SCHEMA);
diff --git a/contrib/sepgsql/selinux.c b/contrib/sepgsql/selinux.c
index 03ba25cef0..1f5a97e878 100644
--- a/contrib/sepgsql/selinux.c
+++ b/contrib/sepgsql/selinux.c
@@ -29,255 +29,563 @@
*/
static struct
{
- const char *class_name;
- uint16 class_code;
+ const char *class_name;
+ uint16 class_code;
struct
{
- const char *av_name;
- uint32 av_code;
- } av[32];
-} selinux_catalog[] = {
+ const char *av_name;
+ uint32 av_code;
+ } av[32];
+} selinux_catalog[] =
+
+{
{
- "process", SEPG_CLASS_PROCESS,
+ "process", SEPG_CLASS_PROCESS,
{
- { "transition", SEPG_PROCESS__TRANSITION },
- { NULL, 0UL }
+ {
+ "transition", SEPG_PROCESS__TRANSITION
+ },
+ {
+ NULL, 0UL
+ }
}
},
{
- "file", SEPG_CLASS_FILE,
+ "file", SEPG_CLASS_FILE,
{
- { "read", SEPG_FILE__READ },
- { "write", SEPG_FILE__WRITE },
- { "create", SEPG_FILE__CREATE },
- { "getattr", SEPG_FILE__GETATTR },
- { "unlink", SEPG_FILE__UNLINK },
- { "rename", SEPG_FILE__RENAME },
- { "append", SEPG_FILE__APPEND },
- { NULL, 0UL }
+ {
+ "read", SEPG_FILE__READ
+ },
+ {
+ "write", SEPG_FILE__WRITE
+ },
+ {
+ "create", SEPG_FILE__CREATE
+ },
+ {
+ "getattr", SEPG_FILE__GETATTR
+ },
+ {
+ "unlink", SEPG_FILE__UNLINK
+ },
+ {
+ "rename", SEPG_FILE__RENAME
+ },
+ {
+ "append", SEPG_FILE__APPEND
+ },
+ {
+ NULL, 0UL
+ }
}
},
{
- "dir", SEPG_CLASS_DIR,
+ "dir", SEPG_CLASS_DIR,
{
- { "read", SEPG_DIR__READ },
- { "write", SEPG_DIR__WRITE },
- { "create", SEPG_DIR__CREATE },
- { "getattr", SEPG_DIR__GETATTR },
- { "unlink", SEPG_DIR__UNLINK },
- { "rename", SEPG_DIR__RENAME },
- { "search", SEPG_DIR__SEARCH },
- { "add_name", SEPG_DIR__ADD_NAME },
- { "remove_name", SEPG_DIR__REMOVE_NAME },
- { "rmdir", SEPG_DIR__RMDIR },
- { "reparent", SEPG_DIR__REPARENT },
- { NULL, 0UL }
+ {
+ "read", SEPG_DIR__READ
+ },
+ {
+ "write", SEPG_DIR__WRITE
+ },
+ {
+ "create", SEPG_DIR__CREATE
+ },
+ {
+ "getattr", SEPG_DIR__GETATTR
+ },
+ {
+ "unlink", SEPG_DIR__UNLINK
+ },
+ {
+ "rename", SEPG_DIR__RENAME
+ },
+ {
+ "search", SEPG_DIR__SEARCH
+ },
+ {
+ "add_name", SEPG_DIR__ADD_NAME
+ },
+ {
+ "remove_name", SEPG_DIR__REMOVE_NAME
+ },
+ {
+ "rmdir", SEPG_DIR__RMDIR
+ },
+ {
+ "reparent", SEPG_DIR__REPARENT
+ },
+ {
+ NULL, 0UL
+ }
}
},
{
- "lnk_file", SEPG_CLASS_LNK_FILE,
+ "lnk_file", SEPG_CLASS_LNK_FILE,
{
- { "read", SEPG_LNK_FILE__READ },
- { "write", SEPG_LNK_FILE__WRITE },
- { "create", SEPG_LNK_FILE__CREATE },
- { "getattr", SEPG_LNK_FILE__GETATTR },
- { "unlink", SEPG_LNK_FILE__UNLINK },
- { "rename", SEPG_LNK_FILE__RENAME },
- { NULL, 0UL }
+ {
+ "read", SEPG_LNK_FILE__READ
+ },
+ {
+ "write", SEPG_LNK_FILE__WRITE
+ },
+ {
+ "create", SEPG_LNK_FILE__CREATE
+ },
+ {
+ "getattr", SEPG_LNK_FILE__GETATTR
+ },
+ {
+ "unlink", SEPG_LNK_FILE__UNLINK
+ },
+ {
+ "rename", SEPG_LNK_FILE__RENAME
+ },
+ {
+ NULL, 0UL
+ }
}
},
{
- "chr_file", SEPG_CLASS_CHR_FILE,
+ "chr_file", SEPG_CLASS_CHR_FILE,
{
- { "read", SEPG_CHR_FILE__READ },
- { "write", SEPG_CHR_FILE__WRITE },
- { "create", SEPG_CHR_FILE__CREATE },
- { "getattr", SEPG_CHR_FILE__GETATTR },
- { "unlink", SEPG_CHR_FILE__UNLINK },
- { "rename", SEPG_CHR_FILE__RENAME },
- { NULL, 0UL }
+ {
+ "read", SEPG_CHR_FILE__READ
+ },
+ {
+ "write", SEPG_CHR_FILE__WRITE
+ },
+ {
+ "create", SEPG_CHR_FILE__CREATE
+ },
+ {
+ "getattr", SEPG_CHR_FILE__GETATTR
+ },
+ {
+ "unlink", SEPG_CHR_FILE__UNLINK
+ },
+ {
+ "rename", SEPG_CHR_FILE__RENAME
+ },
+ {
+ NULL, 0UL
+ }
}
},
{
- "blk_file", SEPG_CLASS_BLK_FILE,
+ "blk_file", SEPG_CLASS_BLK_FILE,
{
- { "read", SEPG_BLK_FILE__READ },
- { "write", SEPG_BLK_FILE__WRITE },
- { "create", SEPG_BLK_FILE__CREATE },
- { "getattr", SEPG_BLK_FILE__GETATTR },
- { "unlink", SEPG_BLK_FILE__UNLINK },
- { "rename", SEPG_BLK_FILE__RENAME },
- { NULL, 0UL }
+ {
+ "read", SEPG_BLK_FILE__READ
+ },
+ {
+ "write", SEPG_BLK_FILE__WRITE
+ },
+ {
+ "create", SEPG_BLK_FILE__CREATE
+ },
+ {
+ "getattr", SEPG_BLK_FILE__GETATTR
+ },
+ {
+ "unlink", SEPG_BLK_FILE__UNLINK
+ },
+ {
+ "rename", SEPG_BLK_FILE__RENAME
+ },
+ {
+ NULL, 0UL
+ }
}
},
{
- "sock_file", SEPG_CLASS_SOCK_FILE,
+ "sock_file", SEPG_CLASS_SOCK_FILE,
{
- { "read", SEPG_SOCK_FILE__READ },
- { "write", SEPG_SOCK_FILE__WRITE },
- { "create", SEPG_SOCK_FILE__CREATE },
- { "getattr", SEPG_SOCK_FILE__GETATTR },
- { "unlink", SEPG_SOCK_FILE__UNLINK },
- { "rename", SEPG_SOCK_FILE__RENAME },
- { NULL, 0UL }
+ {
+ "read", SEPG_SOCK_FILE__READ
+ },
+ {
+ "write", SEPG_SOCK_FILE__WRITE
+ },
+ {
+ "create", SEPG_SOCK_FILE__CREATE
+ },
+ {
+ "getattr", SEPG_SOCK_FILE__GETATTR
+ },
+ {
+ "unlink", SEPG_SOCK_FILE__UNLINK
+ },
+ {
+ "rename", SEPG_SOCK_FILE__RENAME
+ },
+ {
+ NULL, 0UL
+ }
}
},
{
- "fifo_file", SEPG_CLASS_FIFO_FILE,
+ "fifo_file", SEPG_CLASS_FIFO_FILE,
{
- { "read", SEPG_FIFO_FILE__READ },
- { "write", SEPG_FIFO_FILE__WRITE },
- { "create", SEPG_FIFO_FILE__CREATE },
- { "getattr", SEPG_FIFO_FILE__GETATTR },
- { "unlink", SEPG_FIFO_FILE__UNLINK },
- { "rename", SEPG_FIFO_FILE__RENAME },
- { NULL, 0UL }
+ {
+ "read", SEPG_FIFO_FILE__READ
+ },
+ {
+ "write", SEPG_FIFO_FILE__WRITE
+ },
+ {
+ "create", SEPG_FIFO_FILE__CREATE
+ },
+ {
+ "getattr", SEPG_FIFO_FILE__GETATTR
+ },
+ {
+ "unlink", SEPG_FIFO_FILE__UNLINK
+ },
+ {
+ "rename", SEPG_FIFO_FILE__RENAME
+ },
+ {
+ NULL, 0UL
+ }
}
},
{
- "db_database", SEPG_CLASS_DB_DATABASE,
+ "db_database", SEPG_CLASS_DB_DATABASE,
{
- { "create", SEPG_DB_DATABASE__CREATE },
- { "drop", SEPG_DB_DATABASE__DROP },
- { "getattr", SEPG_DB_DATABASE__GETATTR },
- { "setattr", SEPG_DB_DATABASE__SETATTR },
- { "relabelfrom", SEPG_DB_DATABASE__RELABELFROM },
- { "relabelto", SEPG_DB_DATABASE__RELABELTO },
- { "access", SEPG_DB_DATABASE__ACCESS },
- { "load_module", SEPG_DB_DATABASE__LOAD_MODULE },
- { NULL, 0UL },
+ {
+ "create", SEPG_DB_DATABASE__CREATE
+ },
+ {
+ "drop", SEPG_DB_DATABASE__DROP
+ },
+ {
+ "getattr", SEPG_DB_DATABASE__GETATTR
+ },
+ {
+ "setattr", SEPG_DB_DATABASE__SETATTR
+ },
+ {
+ "relabelfrom", SEPG_DB_DATABASE__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_DATABASE__RELABELTO
+ },
+ {
+ "access", SEPG_DB_DATABASE__ACCESS
+ },
+ {
+ "load_module", SEPG_DB_DATABASE__LOAD_MODULE
+ },
+ {
+ NULL, 0UL
+ },
}
},
{
- "db_schema", SEPG_CLASS_DB_SCHEMA,
+ "db_schema", SEPG_CLASS_DB_SCHEMA,
{
- { "create", SEPG_DB_SCHEMA__CREATE },
- { "drop", SEPG_DB_SCHEMA__DROP },
- { "getattr", SEPG_DB_SCHEMA__GETATTR },
- { "setattr", SEPG_DB_SCHEMA__SETATTR },
- { "relabelfrom", SEPG_DB_SCHEMA__RELABELFROM },
- { "relabelto", SEPG_DB_SCHEMA__RELABELTO },
- { "search", SEPG_DB_SCHEMA__SEARCH },
- { "add_name", SEPG_DB_SCHEMA__ADD_NAME },
- { "remove_name", SEPG_DB_SCHEMA__REMOVE_NAME },
- { NULL, 0UL },
+ {
+ "create", SEPG_DB_SCHEMA__CREATE
+ },
+ {
+ "drop", SEPG_DB_SCHEMA__DROP
+ },
+ {
+ "getattr", SEPG_DB_SCHEMA__GETATTR
+ },
+ {
+ "setattr", SEPG_DB_SCHEMA__SETATTR
+ },
+ {
+ "relabelfrom", SEPG_DB_SCHEMA__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_SCHEMA__RELABELTO
+ },
+ {
+ "search", SEPG_DB_SCHEMA__SEARCH
+ },
+ {
+ "add_name", SEPG_DB_SCHEMA__ADD_NAME
+ },
+ {
+ "remove_name", SEPG_DB_SCHEMA__REMOVE_NAME
+ },
+ {
+ NULL, 0UL
+ },
}
},
{
- "db_table", SEPG_CLASS_DB_TABLE,
+ "db_table", SEPG_CLASS_DB_TABLE,
{
- { "create", SEPG_DB_TABLE__CREATE },
- { "drop", SEPG_DB_TABLE__DROP },
- { "getattr", SEPG_DB_TABLE__GETATTR },
- { "setattr", SEPG_DB_TABLE__SETATTR },
- { "relabelfrom", SEPG_DB_TABLE__RELABELFROM },
- { "relabelto", SEPG_DB_TABLE__RELABELTO },
- { "select", SEPG_DB_TABLE__SELECT },
- { "update", SEPG_DB_TABLE__UPDATE },
- { "insert", SEPG_DB_TABLE__INSERT },
- { "delete", SEPG_DB_TABLE__DELETE },
- { "lock", SEPG_DB_TABLE__LOCK },
- { NULL, 0UL },
+ {
+ "create", SEPG_DB_TABLE__CREATE
+ },
+ {
+ "drop", SEPG_DB_TABLE__DROP
+ },
+ {
+ "getattr", SEPG_DB_TABLE__GETATTR
+ },
+ {
+ "setattr", SEPG_DB_TABLE__SETATTR
+ },
+ {
+ "relabelfrom", SEPG_DB_TABLE__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_TABLE__RELABELTO
+ },
+ {
+ "select", SEPG_DB_TABLE__SELECT
+ },
+ {
+ "update", SEPG_DB_TABLE__UPDATE
+ },
+ {
+ "insert", SEPG_DB_TABLE__INSERT
+ },
+ {
+ "delete", SEPG_DB_TABLE__DELETE
+ },
+ {
+ "lock", SEPG_DB_TABLE__LOCK
+ },
+ {
+ NULL, 0UL
+ },
}
},
{
- "db_sequence", SEPG_CLASS_DB_SEQUENCE,
+ "db_sequence", SEPG_CLASS_DB_SEQUENCE,
{
- { "create", SEPG_DB_SEQUENCE__CREATE },
- { "drop", SEPG_DB_SEQUENCE__DROP },
- { "getattr", SEPG_DB_SEQUENCE__GETATTR },
- { "setattr", SEPG_DB_SEQUENCE__SETATTR },
- { "relabelfrom", SEPG_DB_SEQUENCE__RELABELFROM },
- { "relabelto", SEPG_DB_SEQUENCE__RELABELTO },
- { "get_value", SEPG_DB_SEQUENCE__GET_VALUE },
- { "next_value", SEPG_DB_SEQUENCE__NEXT_VALUE },
- { "set_value", SEPG_DB_SEQUENCE__SET_VALUE },
- { NULL, 0UL },
+ {
+ "create", SEPG_DB_SEQUENCE__CREATE
+ },
+ {
+ "drop", SEPG_DB_SEQUENCE__DROP
+ },
+ {
+ "getattr", SEPG_DB_SEQUENCE__GETATTR
+ },
+ {
+ "setattr", SEPG_DB_SEQUENCE__SETATTR
+ },
+ {
+ "relabelfrom", SEPG_DB_SEQUENCE__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_SEQUENCE__RELABELTO
+ },
+ {
+ "get_value", SEPG_DB_SEQUENCE__GET_VALUE
+ },
+ {
+ "next_value", SEPG_DB_SEQUENCE__NEXT_VALUE
+ },
+ {
+ "set_value", SEPG_DB_SEQUENCE__SET_VALUE
+ },
+ {
+ NULL, 0UL
+ },
}
},
{
- "db_procedure", SEPG_CLASS_DB_PROCEDURE,
+ "db_procedure", SEPG_CLASS_DB_PROCEDURE,
{
- { "create", SEPG_DB_PROCEDURE__CREATE },
- { "drop", SEPG_DB_PROCEDURE__DROP },
- { "getattr", SEPG_DB_PROCEDURE__GETATTR },
- { "setattr", SEPG_DB_PROCEDURE__SETATTR },
- { "relabelfrom", SEPG_DB_PROCEDURE__RELABELFROM },
- { "relabelto", SEPG_DB_PROCEDURE__RELABELTO },
- { "execute", SEPG_DB_PROCEDURE__EXECUTE },
- { "entrypoint", SEPG_DB_PROCEDURE__ENTRYPOINT },
- { "install", SEPG_DB_PROCEDURE__INSTALL },
- { NULL, 0UL },
+ {
+ "create", SEPG_DB_PROCEDURE__CREATE
+ },
+ {
+ "drop", SEPG_DB_PROCEDURE__DROP
+ },
+ {
+ "getattr", SEPG_DB_PROCEDURE__GETATTR
+ },
+ {
+ "setattr", SEPG_DB_PROCEDURE__SETATTR
+ },
+ {
+ "relabelfrom", SEPG_DB_PROCEDURE__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_PROCEDURE__RELABELTO
+ },
+ {
+ "execute", SEPG_DB_PROCEDURE__EXECUTE
+ },
+ {
+ "entrypoint", SEPG_DB_PROCEDURE__ENTRYPOINT
+ },
+ {
+ "install", SEPG_DB_PROCEDURE__INSTALL
+ },
+ {
+ NULL, 0UL
+ },
}
},
{
- "db_column", SEPG_CLASS_DB_COLUMN,
+ "db_column", SEPG_CLASS_DB_COLUMN,
{
- { "create", SEPG_DB_COLUMN__CREATE },
- { "drop", SEPG_DB_COLUMN__DROP },
- { "getattr", SEPG_DB_COLUMN__GETATTR },
- { "setattr", SEPG_DB_COLUMN__SETATTR },
- { "relabelfrom", SEPG_DB_COLUMN__RELABELFROM },
- { "relabelto", SEPG_DB_COLUMN__RELABELTO },
- { "select", SEPG_DB_COLUMN__SELECT },
- { "update", SEPG_DB_COLUMN__UPDATE },
- { "insert", SEPG_DB_COLUMN__INSERT },
- { NULL, 0UL },
+ {
+ "create", SEPG_DB_COLUMN__CREATE
+ },
+ {
+ "drop", SEPG_DB_COLUMN__DROP
+ },
+ {
+ "getattr", SEPG_DB_COLUMN__GETATTR
+ },
+ {
+ "setattr", SEPG_DB_COLUMN__SETATTR
+ },
+ {
+ "relabelfrom", SEPG_DB_COLUMN__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_COLUMN__RELABELTO
+ },
+ {
+ "select", SEPG_DB_COLUMN__SELECT
+ },
+ {
+ "update", SEPG_DB_COLUMN__UPDATE
+ },
+ {
+ "insert", SEPG_DB_COLUMN__INSERT
+ },
+ {
+ NULL, 0UL
+ },
}
},
{
- "db_tuple", SEPG_CLASS_DB_TUPLE,
+ "db_tuple", SEPG_CLASS_DB_TUPLE,
{
- { "relabelfrom", SEPG_DB_TUPLE__RELABELFROM },
- { "relabelto", SEPG_DB_TUPLE__RELABELTO },
- { "select", SEPG_DB_TUPLE__SELECT },
- { "update", SEPG_DB_TUPLE__UPDATE },
- { "insert", SEPG_DB_TUPLE__INSERT },
- { "delete", SEPG_DB_TUPLE__DELETE },
- { NULL, 0UL },
+ {
+ "relabelfrom", SEPG_DB_TUPLE__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_TUPLE__RELABELTO
+ },
+ {
+ "select", SEPG_DB_TUPLE__SELECT
+ },
+ {
+ "update", SEPG_DB_TUPLE__UPDATE
+ },
+ {
+ "insert", SEPG_DB_TUPLE__INSERT
+ },
+ {
+ "delete", SEPG_DB_TUPLE__DELETE
+ },
+ {
+ NULL, 0UL
+ },
}
},
{
- "db_blob", SEPG_CLASS_DB_BLOB,
+ "db_blob", SEPG_CLASS_DB_BLOB,
{
- { "create", SEPG_DB_BLOB__CREATE },
- { "drop", SEPG_DB_BLOB__DROP },
- { "getattr", SEPG_DB_BLOB__GETATTR },
- { "setattr", SEPG_DB_BLOB__SETATTR },
- { "relabelfrom", SEPG_DB_BLOB__RELABELFROM },
- { "relabelto", SEPG_DB_BLOB__RELABELTO },
- { "read", SEPG_DB_BLOB__READ },
- { "write", SEPG_DB_BLOB__WRITE },
- { "import", SEPG_DB_BLOB__IMPORT },
- { "export", SEPG_DB_BLOB__EXPORT },
- { NULL, 0UL },
+ {
+ "create", SEPG_DB_BLOB__CREATE
+ },
+ {
+ "drop", SEPG_DB_BLOB__DROP
+ },
+ {
+ "getattr", SEPG_DB_BLOB__GETATTR
+ },
+ {
+ "setattr", SEPG_DB_BLOB__SETATTR
+ },
+ {
+ "relabelfrom", SEPG_DB_BLOB__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_BLOB__RELABELTO
+ },
+ {
+ "read", SEPG_DB_BLOB__READ
+ },
+ {
+ "write", SEPG_DB_BLOB__WRITE
+ },
+ {
+ "import", SEPG_DB_BLOB__IMPORT
+ },
+ {
+ "export", SEPG_DB_BLOB__EXPORT
+ },
+ {
+ NULL, 0UL
+ },
}
},
{
- "db_language", SEPG_CLASS_DB_LANGUAGE,
+ "db_language", SEPG_CLASS_DB_LANGUAGE,
{
- { "create", SEPG_DB_LANGUAGE__CREATE },
- { "drop", SEPG_DB_LANGUAGE__DROP },
- { "getattr", SEPG_DB_LANGUAGE__GETATTR },
- { "setattr", SEPG_DB_LANGUAGE__SETATTR },
- { "relabelfrom", SEPG_DB_LANGUAGE__RELABELFROM },
- { "relabelto", SEPG_DB_LANGUAGE__RELABELTO },
- { "implement", SEPG_DB_LANGUAGE__IMPLEMENT },
- { "execute", SEPG_DB_LANGUAGE__EXECUTE },
- { NULL, 0UL },
+ {
+ "create", SEPG_DB_LANGUAGE__CREATE
+ },
+ {
+ "drop", SEPG_DB_LANGUAGE__DROP
+ },
+ {
+ "getattr", SEPG_DB_LANGUAGE__GETATTR
+ },
+ {
+ "setattr", SEPG_DB_LANGUAGE__SETATTR
+ },
+ {
+ "relabelfrom", SEPG_DB_LANGUAGE__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_LANGUAGE__RELABELTO
+ },
+ {
+ "implement", SEPG_DB_LANGUAGE__IMPLEMENT
+ },
+ {
+ "execute", SEPG_DB_LANGUAGE__EXECUTE
+ },
+ {
+ NULL, 0UL
+ },
}
},
{
- "db_view", SEPG_CLASS_DB_VIEW,
+ "db_view", SEPG_CLASS_DB_VIEW,
{
- { "create", SEPG_DB_VIEW__CREATE },
- { "drop", SEPG_DB_VIEW__DROP },
- { "getattr", SEPG_DB_VIEW__GETATTR },
- { "setattr", SEPG_DB_VIEW__SETATTR },
- { "relabelfrom", SEPG_DB_VIEW__RELABELFROM },
- { "relabelto", SEPG_DB_VIEW__RELABELTO },
- { "expand", SEPG_DB_VIEW__EXPAND },
- { NULL, 0UL },
+ {
+ "create", SEPG_DB_VIEW__CREATE
+ },
+ {
+ "drop", SEPG_DB_VIEW__DROP
+ },
+ {
+ "getattr", SEPG_DB_VIEW__GETATTR
+ },
+ {
+ "setattr", SEPG_DB_VIEW__SETATTR
+ },
+ {
+ "relabelfrom", SEPG_DB_VIEW__RELABELFROM
+ },
+ {
+ "relabelto", SEPG_DB_VIEW__RELABELTO
+ },
+ {
+ "expand", SEPG_DB_VIEW__EXPAND
+ },
+ {
+ NULL, 0UL
+ },
}
},
};
@@ -316,7 +624,7 @@ sepgsql_get_mode(void)
int
sepgsql_set_mode(int new_mode)
{
- int old_mode = sepgsql_mode;
+ int old_mode = sepgsql_mode;
sepgsql_mode = new_mode;
@@ -367,10 +675,10 @@ sepgsql_audit_log(bool denied,
uint32 audited,
const char *audit_name)
{
- StringInfoData buf;
- const char *class_name;
- const char *av_name;
- int i;
+ StringInfoData buf;
+ const char *class_name;
+ const char *av_name;
+ int i;
/* lookup name of the object class */
Assert(tclass < SEPG_CLASS_MAX);
@@ -380,7 +688,7 @@ sepgsql_audit_log(bool denied,
initStringInfo(&buf);
appendStringInfo(&buf, "%s {",
(denied ? "denied" : "allowed"));
- for (i=0; selinux_catalog[tclass].av[i].av_name; i++)
+ for (i = 0; selinux_catalog[tclass].av[i].av_name; i++)
{
if (audited & (1UL << i))
{
@@ -418,14 +726,15 @@ void
sepgsql_compute_avd(const char *scontext,
const char *tcontext,
uint16 tclass,
- struct av_decision *avd)
+ struct av_decision * avd)
{
- const char *tclass_name;
- security_class_t tclass_ex;
- struct av_decision avd_ex;
- int i, deny_unknown = security_deny_unknown();
+ const char *tclass_name;
+ security_class_t tclass_ex;
+ struct av_decision avd_ex;
+ int i,
+ deny_unknown = security_deny_unknown();
- /* Get external code of the object class*/
+ /* Get external code of the object class */
Assert(tclass < SEPG_CLASS_MAX);
Assert(tclass == selinux_catalog[tclass].class_code);
@@ -436,14 +745,13 @@ sepgsql_compute_avd(const char *scontext,
{
/*
* If the current security policy does not support permissions
- * corresponding to database objects, we fill up them with dummy
- * data.
+ * corresponding to database objects, we fill up them with dummy data.
* If security_deny_unknown() returns positive value, undefined
* permissions should be denied. Otherwise, allowed
*/
avd->allowed = (security_deny_unknown() > 0 ? 0 : ~0);
avd->auditallow = 0U;
- avd->auditdeny = ~0U;
+ avd->auditdeny = ~0U;
avd->flags = 0;
return;
@@ -453,8 +761,8 @@ sepgsql_compute_avd(const char *scontext,
* Ask SELinux what is allowed set of permissions on a pair of the
* security contexts and the given object class.
*/
- if (security_compute_av_flags_raw((security_context_t)scontext,
- (security_context_t)tcontext,
+ if (security_compute_av_flags_raw((security_context_t) scontext,
+ (security_context_t) tcontext,
tclass_ex, 0, &avd_ex) < 0)
ereport(ERROR,
(errcode(ERRCODE_INTERNAL_ERROR),
@@ -464,17 +772,17 @@ sepgsql_compute_avd(const char *scontext,
/*
* SELinux returns its access control decision as a set of permissions
- * represented in external code which depends on run-time environment.
- * So, we need to translate it to the internal representation before
- * returning results for the caller.
+ * represented in external code which depends on run-time environment. So,
+ * we need to translate it to the internal representation before returning
+ * results for the caller.
*/
memset(avd, 0, sizeof(struct av_decision));
- for (i=0; selinux_catalog[tclass].av[i].av_name; i++)
+ for (i = 0; selinux_catalog[tclass].av[i].av_name; i++)
{
- access_vector_t av_code_ex;
- const char *av_name = selinux_catalog[tclass].av[i].av_name;
- uint32 av_code = selinux_catalog[tclass].av[i].av_code;
+ access_vector_t av_code_ex;
+ const char *av_name = selinux_catalog[tclass].av[i].av_name;
+ uint32 av_code = selinux_catalog[tclass].av[i].av_code;
av_code_ex = string_to_av_perm(tclass_ex, av_name);
if (av_code_ex == 0)
@@ -524,23 +832,23 @@ sepgsql_compute_create(const char *scontext,
const char *tcontext,
uint16 tclass)
{
- security_context_t ncontext;
- security_class_t tclass_ex;
- const char *tclass_name;
- char *result;
+ security_context_t ncontext;
+ security_class_t tclass_ex;
+ const char *tclass_name;
+ char *result;
- /* Get external code of the object class*/
+ /* Get external code of the object class */
Assert(tclass < SEPG_CLASS_MAX);
tclass_name = selinux_catalog[tclass].class_name;
tclass_ex = string_to_security_class(tclass_name);
/*
- * Ask SELinux what is the default context for the given object class
- * on a pair of security contexts
+ * Ask SELinux what is the default context for the given object class on a
+ * pair of security contexts
*/
- if (security_compute_create_raw((security_context_t)scontext,
- (security_context_t)tcontext,
+ if (security_compute_create_raw((security_context_t) scontext,
+ (security_context_t) tcontext,
tclass_ex, &ncontext) < 0)
ereport(ERROR,
(errcode(ERRCODE_INTERNAL_ERROR),
@@ -549,8 +857,8 @@ sepgsql_compute_create(const char *scontext,
scontext, tcontext, tclass_name)));
/*
- * libselinux returns malloc()'ed string, so we need to copy it
- * on the palloc()'ed region.
+ * libselinux returns malloc()'ed string, so we need to copy it on the
+ * palloc()'ed region.
*/
PG_TRY();
{
@@ -589,7 +897,7 @@ sepgsql_check_perms(const char *scontext,
const char *audit_name,
bool abort)
{
- struct av_decision avd;
+ struct av_decision avd;
uint32 denied;
uint32 audited;
bool result = true;
@@ -602,7 +910,7 @@ sepgsql_check_perms(const char *scontext,
audited = (denied ? denied : required);
else
audited = (denied ? (denied & avd.auditdeny)
- : (required & avd.auditallow));
+ : (required & avd.auditallow));
if (denied &&
sepgsql_getenforce() > 0 &&
@@ -610,8 +918,8 @@ sepgsql_check_perms(const char *scontext,
result = false;
/*
- * It records a security audit for the request, if needed.
- * But, when SE-PgSQL performs 'internal' mode, it needs to keep silent.
+ * It records a security audit for the request, if needed. But, when
+ * SE-PgSQL performs 'internal' mode, it needs to keep silent.
*/
if (audited && sepgsql_mode != SEPGSQL_MODE_INTERNAL)
{
diff --git a/contrib/sepgsql/sepgsql.h b/contrib/sepgsql/sepgsql.h
index ba7b2d1597..71688ab784 100644
--- a/contrib/sepgsql/sepgsql.h
+++ b/contrib/sepgsql/sepgsql.h
@@ -218,33 +218,34 @@ extern bool sepgsql_get_debug_audit(void);
/*
* selinux.c
*/
-extern bool sepgsql_is_enabled(void);
+extern bool sepgsql_is_enabled(void);
extern int sepgsql_get_mode(void);
extern int sepgsql_set_mode(int new_mode);
extern bool sepgsql_getenforce(void);
extern void sepgsql_audit_log(bool denied,
- const char *scontext,
- const char *tcontext,
- uint16 tclass,
- uint32 audited,
- const char *audit_name);
+ const char *scontext,
+ const char *tcontext,
+ uint16 tclass,
+ uint32 audited,
+ const char *audit_name);
extern void sepgsql_compute_avd(const char *scontext,
- const char *tcontext,
- uint16 tclass,
- struct av_decision *avd);
+ const char *tcontext,
+ uint16 tclass,
+ struct av_decision * avd);
extern char *sepgsql_compute_create(const char *scontext,
- const char *tcontext,
- uint16 tclass);
+ const char *tcontext,
+ uint16 tclass);
extern bool sepgsql_check_perms(const char *scontext,
- const char *tcontext,
- uint16 tclass,
- uint32 required,
- const char *audit_name,
- bool abort);
+ const char *tcontext,
+ uint16 tclass,
+ uint32 required,
+ const char *audit_name,
+ bool abort);
+
/*
* label.c
*/
@@ -252,8 +253,8 @@ extern char *sepgsql_get_client_label(void);
extern char *sepgsql_set_client_label(char *new_label);
extern char *sepgsql_get_label(Oid relOid, Oid objOid, int32 subId);
-extern void sepgsql_object_relabel(const ObjectAddress *object,
- const char *seclabel);
+extern void sepgsql_object_relabel(const ObjectAddress *object,
+ const char *seclabel);
extern Datum sepgsql_getcon(PG_FUNCTION_ARGS);
extern Datum sepgsql_mcstrans_in(PG_FUNCTION_ARGS);
@@ -276,7 +277,7 @@ extern void sepgsql_schema_relabel(Oid namespaceId, const char *seclabel);
*/
extern void sepgsql_attribute_post_create(Oid relOid, AttrNumber attnum);
extern void sepgsql_attribute_relabel(Oid relOid, AttrNumber attnum,
- const char *seclabel);
+ const char *seclabel);
extern void sepgsql_relation_post_create(Oid relOid);
extern void sepgsql_relation_relabel(Oid relOid, const char *seclabel);
@@ -287,4 +288,4 @@ extern void sepgsql_proc_post_create(Oid functionId);
extern void sepgsql_proc_relabel(Oid functionId, const char *seclabel);
extern char *sepgsql_proc_get_domtrans(Oid functionId);
-#endif /* SEPGSQL_H */
+#endif /* SEPGSQL_H */
diff --git a/contrib/spi/moddatetime.c b/contrib/spi/moddatetime.c
index f5a0d93ef5..d02560c298 100644
--- a/contrib/spi/moddatetime.c
+++ b/contrib/spi/moddatetime.c
@@ -84,7 +84,7 @@ moddatetime(PG_FUNCTION_ARGS)
/*
* This is where we check to see if the field we are supposed to update
- * even exists. The above function must return -1 if name not found?
+ * even exists. The above function must return -1 if name not found?
*/
if (attnum < 0)
ereport(ERROR,
diff --git a/contrib/xml2/xpath.c b/contrib/xml2/xpath.c
index e92ab66491..44c600e134 100644
--- a/contrib/xml2/xpath.c
+++ b/contrib/xml2/xpath.c
@@ -61,7 +61,7 @@ static text *pgxml_result_to_text(xmlXPathObjectPtr res, xmlChar *toptag,
static xmlChar *pgxml_texttoxmlchar(text *textstring);
static xmlXPathObjectPtr pgxml_xpath(text *document, xmlChar *xpath,
- xpath_workspace *workspace);
+ xpath_workspace *workspace);
static void cleanup_workspace(xpath_workspace *workspace);
@@ -234,7 +234,7 @@ Datum
xpath_nodeset(PG_FUNCTION_ARGS)
{
text *document = PG_GETARG_TEXT_P(0);
- text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
+ text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
xmlChar *toptag = pgxml_texttoxmlchar(PG_GETARG_TEXT_P(2));
xmlChar *septag = pgxml_texttoxmlchar(PG_GETARG_TEXT_P(3));
xmlChar *xpath;
@@ -267,7 +267,7 @@ Datum
xpath_list(PG_FUNCTION_ARGS)
{
text *document = PG_GETARG_TEXT_P(0);
- text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
+ text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
xmlChar *plainsep = pgxml_texttoxmlchar(PG_GETARG_TEXT_P(2));
xmlChar *xpath;
text *xpres;
@@ -296,7 +296,7 @@ Datum
xpath_string(PG_FUNCTION_ARGS)
{
text *document = PG_GETARG_TEXT_P(0);
- text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
+ text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
xmlChar *xpath;
int32 pathsize;
text *xpres;
@@ -337,7 +337,7 @@ Datum
xpath_number(PG_FUNCTION_ARGS)
{
text *document = PG_GETARG_TEXT_P(0);
- text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
+ text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
xmlChar *xpath;
float4 fRes;
xmlXPathObjectPtr res;
@@ -369,7 +369,7 @@ Datum
xpath_bool(PG_FUNCTION_ARGS)
{
text *document = PG_GETARG_TEXT_P(0);
- text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
+ text *xpathsupp = PG_GETARG_TEXT_P(1); /* XPath expression */
xmlChar *xpath;
int bRes;
xmlXPathObjectPtr res;
diff --git a/contrib/xml2/xslt_proc.c b/contrib/xml2/xslt_proc.c
index a90104d17a..f8f7d7263f 100644
--- a/contrib/xml2/xslt_proc.c
+++ b/contrib/xml2/xslt_proc.c
@@ -42,7 +42,6 @@ extern void pgxml_parser_init(void);
/* local defs */
static const char **parse_params(text *paramstr);
-
#endif /* USE_LIBXSLT */
@@ -166,7 +165,7 @@ parse_params(text *paramstr)
{
max_params *= 2;
params = (const char **) repalloc(params,
- (max_params + 1) * sizeof(char *));
+ (max_params + 1) * sizeof(char *));
}
params[nparams++] = pos;
pos = strstr(pos, nvsep);
diff --git a/src/backend/access/common/heaptuple.c b/src/backend/access/common/heaptuple.c
index 6d608fed89..175e6ea2f2 100644
--- a/src/backend/access/common/heaptuple.c
+++ b/src/backend/access/common/heaptuple.c
@@ -350,7 +350,7 @@ nocachegetattr(HeapTuple tuple,
*
* check to see if any preceding bits are null...
*/
- int byte = attnum >> 3;
+ int byte = attnum >> 3;
int finalbit = attnum & 0x07;
/* check for nulls "before" final bit of last byte */
diff --git a/src/backend/access/common/indextuple.c b/src/backend/access/common/indextuple.c
index 9ea87360f9..85c43199aa 100644
--- a/src/backend/access/common/indextuple.c
+++ b/src/backend/access/common/indextuple.c
@@ -237,7 +237,7 @@ nocache_index_getattr(IndexTuple tup,
* Now check to see if any preceding bits are null...
*/
{
- int byte = attnum >> 3;
+ int byte = attnum >> 3;
int finalbit = attnum & 0x07;
/* check for nulls "before" final bit of last byte */
diff --git a/src/backend/access/gin/ginarrayproc.c b/src/backend/access/gin/ginarrayproc.c
index ce9abae6aa..2de58604ee 100644
--- a/src/backend/access/gin/ginarrayproc.c
+++ b/src/backend/access/gin/ginarrayproc.c
@@ -82,7 +82,8 @@ ginqueryarrayextract(PG_FUNCTION_ARGS)
ArrayType *array = PG_GETARG_ARRAYTYPE_P_COPY(0);
int32 *nkeys = (int32 *) PG_GETARG_POINTER(1);
StrategyNumber strategy = PG_GETARG_UINT16(2);
- /* bool **pmatch = (bool **) PG_GETARG_POINTER(3); */
+
+ /* bool **pmatch = (bool **) PG_GETARG_POINTER(3); */
/* Pointer *extra_data = (Pointer *) PG_GETARG_POINTER(4); */
bool **nullFlags = (bool **) PG_GETARG_POINTER(5);
int32 *searchMode = (int32 *) PG_GETARG_POINTER(6);
@@ -112,7 +113,7 @@ ginqueryarrayextract(PG_FUNCTION_ARGS)
case GinContainsStrategy:
if (nelems > 0)
*searchMode = GIN_SEARCH_MODE_DEFAULT;
- else /* everything contains the empty set */
+ else /* everything contains the empty set */
*searchMode = GIN_SEARCH_MODE_ALL;
break;
case GinContainedStrategy:
@@ -142,10 +143,13 @@ ginarrayconsistent(PG_FUNCTION_ARGS)
{
bool *check = (bool *) PG_GETARG_POINTER(0);
StrategyNumber strategy = PG_GETARG_UINT16(1);
+
/* ArrayType *query = PG_GETARG_ARRAYTYPE_P(2); */
int32 nkeys = PG_GETARG_INT32(3);
+
/* Pointer *extra_data = (Pointer *) PG_GETARG_POINTER(4); */
bool *recheck = (bool *) PG_GETARG_POINTER(5);
+
/* Datum *queryKeys = (Datum *) PG_GETARG_POINTER(6); */
bool *nullFlags = (bool *) PG_GETARG_POINTER(7);
bool res;
@@ -190,10 +194,11 @@ ginarrayconsistent(PG_FUNCTION_ARGS)
case GinEqualStrategy:
/* we will need recheck */
*recheck = true;
+
/*
* Must have all elements in check[] true; no discrimination
- * against nulls here. This is because array_contain_compare
- * and array_eq handle nulls differently ...
+ * against nulls here. This is because array_contain_compare and
+ * array_eq handle nulls differently ...
*/
res = true;
for (i = 0; i < nkeys; i++)
diff --git a/src/backend/access/gin/ginbulk.c b/src/backend/access/gin/ginbulk.c
index f0c8c8e37f..9e5bab194d 100644
--- a/src/backend/access/gin/ginbulk.c
+++ b/src/backend/access/gin/ginbulk.c
@@ -80,8 +80,8 @@ ginAllocEntryAccumulator(void *arg)
GinEntryAccumulator *ea;
/*
- * Allocate memory by rather big chunks to decrease overhead. We have
- * no need to reclaim RBNodes individually, so this costs nothing.
+ * Allocate memory by rather big chunks to decrease overhead. We have no
+ * need to reclaim RBNodes individually, so this costs nothing.
*/
if (accum->entryallocator == NULL || accum->eas_used >= DEF_NENTRY)
{
@@ -108,7 +108,7 @@ ginInitBA(BuildAccumulator *accum)
cmpEntryAccumulator,
ginCombineData,
ginAllocEntryAccumulator,
- NULL, /* no freefunc needed */
+ NULL, /* no freefunc needed */
(void *) accum);
}
@@ -145,8 +145,8 @@ ginInsertBAEntry(BuildAccumulator *accum,
bool isNew;
/*
- * For the moment, fill only the fields of eatmp that will be looked at
- * by cmpEntryAccumulator or ginCombineData.
+ * For the moment, fill only the fields of eatmp that will be looked at by
+ * cmpEntryAccumulator or ginCombineData.
*/
eatmp.attnum = attnum;
eatmp.key = key;
diff --git a/src/backend/access/gin/gindatapage.c b/src/backend/access/gin/gindatapage.c
index 4a1e754800..41dbe9fd11 100644
--- a/src/backend/access/gin/gindatapage.c
+++ b/src/backend/access/gin/gindatapage.c
@@ -21,13 +21,13 @@
int
ginCompareItemPointers(ItemPointer a, ItemPointer b)
{
- BlockNumber ba = GinItemPointerGetBlockNumber(a);
- BlockNumber bb = GinItemPointerGetBlockNumber(b);
+ BlockNumber ba = GinItemPointerGetBlockNumber(a);
+ BlockNumber bb = GinItemPointerGetBlockNumber(b);
if (ba == bb)
{
- OffsetNumber oa = GinItemPointerGetOffsetNumber(a);
- OffsetNumber ob = GinItemPointerGetOffsetNumber(b);
+ OffsetNumber oa = GinItemPointerGetOffsetNumber(a);
+ OffsetNumber ob = GinItemPointerGetOffsetNumber(b);
if (oa == ob)
return 0;
@@ -383,6 +383,7 @@ dataPlaceToPage(GinBtree btree, Buffer buf, OffsetNumber off, XLogRecData **prda
Page page = BufferGetPage(buf);
int sizeofitem = GinSizeOfDataPageItem(page);
int cnt = 0;
+
/* these must be static so they can be returned to caller */
static XLogRecData rdata[3];
static ginxlogInsert data;
@@ -474,6 +475,7 @@ dataSplitPage(GinBtree btree, Buffer lbuf, Buffer rbuf, OffsetNumber off, XLogRe
Size pageSize = PageGetPageSize(lpage);
Size freeSpace;
uint32 nCopied = 1;
+
/* these must be static so they can be returned to caller */
static ginxlogSplit data;
static XLogRecData rdata[4];
diff --git a/src/backend/access/gin/ginentrypage.c b/src/backend/access/gin/ginentrypage.c
index 9749a1be78..fa134f9fc3 100644
--- a/src/backend/access/gin/ginentrypage.c
+++ b/src/backend/access/gin/ginentrypage.c
@@ -98,11 +98,11 @@ GinFormTuple(GinState *ginstate,
if (errorTooBig)
ereport(ERROR,
(errcode(ERRCODE_PROGRAM_LIMIT_EXCEEDED),
- errmsg("index row size %lu exceeds maximum %lu for index \"%s\"",
- (unsigned long) newsize,
- (unsigned long) Min(INDEX_SIZE_MASK,
- GinMaxItemSize),
- RelationGetRelationName(ginstate->index))));
+ errmsg("index row size %lu exceeds maximum %lu for index \"%s\"",
+ (unsigned long) newsize,
+ (unsigned long) Min(INDEX_SIZE_MASK,
+ GinMaxItemSize),
+ RelationGetRelationName(ginstate->index))));
pfree(itup);
return NULL;
}
@@ -164,7 +164,7 @@ GinShortenTuple(IndexTuple itup, uint32 nipd)
* Form a non-leaf entry tuple by copying the key data from the given tuple,
* which can be either a leaf or non-leaf entry tuple.
*
- * Any posting list in the source tuple is not copied. The specified child
+ * Any posting list in the source tuple is not copied. The specified child
* block number is inserted into t_tid.
*/
static IndexTuple
@@ -225,7 +225,7 @@ entryIsMoveRight(GinBtree btree, Page page)
key = gintuple_get_key(btree->ginstate, itup, &category);
if (ginCompareAttEntries(btree->ginstate,
- btree->entryAttnum, btree->entryKey, btree->entryCategory,
+ btree->entryAttnum, btree->entryKey, btree->entryCategory,
attnum, key, category) > 0)
return TRUE;
@@ -488,6 +488,7 @@ entryPlaceToPage(GinBtree btree, Buffer buf, OffsetNumber off, XLogRecData **prd
Page page = BufferGetPage(buf);
OffsetNumber placed;
int cnt = 0;
+
/* these must be static so they can be returned to caller */
static XLogRecData rdata[3];
static ginxlogInsert data;
@@ -561,6 +562,7 @@ entrySplitPage(GinBtree btree, Buffer lbuf, Buffer rbuf, OffsetNumber off, XLogR
Page lpage = PageGetTempPageCopy(BufferGetPage(lbuf));
Page rpage = BufferGetPage(rbuf);
Size pageSize = PageGetPageSize(lpage);
+
/* these must be static so they can be returned to caller */
static XLogRecData rdata[2];
static ginxlogSplit data;
diff --git a/src/backend/access/gin/ginfast.c b/src/backend/access/gin/ginfast.c
index 9960c786c9..82419e37ac 100644
--- a/src/backend/access/gin/ginfast.c
+++ b/src/backend/access/gin/ginfast.c
@@ -88,9 +88,9 @@ writeListPage(Relation index, Buffer buffer,
GinPageGetOpaque(page)->rightlink = rightlink;
/*
- * tail page may contain only whole row(s) or final part of row placed
- * on previous pages (a "row" here meaning all the index tuples generated
- * for one heap tuple)
+ * tail page may contain only whole row(s) or final part of row placed on
+ * previous pages (a "row" here meaning all the index tuples generated for
+ * one heap tuple)
*/
if (rightlink == InvalidBlockNumber)
{
@@ -437,7 +437,7 @@ ginHeapTupleFastInsert(GinState *ginstate, GinTupleCollector *collector)
* Create temporary index tuples for a single indexable item (one index column
* for the heap tuple specified by ht_ctid), and append them to the array
* in *collector. They will subsequently be written out using
- * ginHeapTupleFastInsert. Note that to guarantee consistent state, all
+ * ginHeapTupleFastInsert. Note that to guarantee consistent state, all
* temp tuples for a given heap tuple must be written in one call to
* ginHeapTupleFastInsert.
*/
@@ -475,8 +475,8 @@ ginHeapTupleFastCollect(GinState *ginstate,
}
/*
- * Build an index tuple for each key value, and add to array. In
- * pending tuples we just stick the heap TID into t_tid.
+ * Build an index tuple for each key value, and add to array. In pending
+ * tuples we just stick the heap TID into t_tid.
*/
for (i = 0; i < nentries; i++)
{
@@ -665,7 +665,7 @@ processPendingPage(BuildAccumulator *accum, KeyArray *ka,
{
IndexTuple itup = (IndexTuple) PageGetItem(page, PageGetItemId(page, i));
OffsetNumber curattnum;
- Datum curkey;
+ Datum curkey;
GinNullCategory curcategory;
/* Check for change of heap TID or attnum */
@@ -830,7 +830,7 @@ ginInsertCleanup(GinState *ginstate,
*/
ginBeginBAScan(&accum);
while ((list = ginGetBAEntry(&accum,
- &attnum, &key, &category, &nlist)) != NULL)
+ &attnum, &key, &category, &nlist)) != NULL)
{
ginEntryInsert(ginstate, attnum, key, category,
list, nlist, NULL);
@@ -867,7 +867,7 @@ ginInsertCleanup(GinState *ginstate,
ginBeginBAScan(&accum);
while ((list = ginGetBAEntry(&accum,
- &attnum, &key, &category, &nlist)) != NULL)
+ &attnum, &key, &category, &nlist)) != NULL)
ginEntryInsert(ginstate, attnum, key, category,
list, nlist, NULL);
}
diff --git a/src/backend/access/gin/ginget.c b/src/backend/access/gin/ginget.c
index e07dc0a6ce..a4771654a6 100644
--- a/src/backend/access/gin/ginget.c
+++ b/src/backend/access/gin/ginget.c
@@ -40,8 +40,8 @@ static bool
callConsistentFn(GinState *ginstate, GinScanKey key)
{
/*
- * If we're dealing with a dummy EVERYTHING key, we don't want to call
- * the consistentFn; just claim it matches.
+ * If we're dealing with a dummy EVERYTHING key, we don't want to call the
+ * consistentFn; just claim it matches.
*/
if (key->searchMode == GIN_SEARCH_MODE_EVERYTHING)
{
@@ -174,14 +174,14 @@ scanPostingTree(Relation index, GinScanEntry scanEntry,
/*
* Collects TIDs into scanEntry->matchBitmap for all heap tuples that
- * match the search entry. This supports three different match modes:
+ * match the search entry. This supports three different match modes:
*
* 1. Partial-match support: scan from current point until the
- * comparePartialFn says we're done.
+ * comparePartialFn says we're done.
* 2. SEARCH_MODE_ALL: scan from current point (which should be first
- * key for the current attnum) until we hit null items or end of attnum
+ * key for the current attnum) until we hit null items or end of attnum
* 3. SEARCH_MODE_EVERYTHING: scan from current point (which should be first
- * key for the current attnum) until we hit end of attnum
+ * key for the current attnum) until we hit end of attnum
*
* Returns true if done, false if it's necessary to restart scan from scratch
*/
@@ -189,7 +189,7 @@ static bool
collectMatchBitmap(GinBtreeData *btree, GinBtreeStack *stack,
GinScanEntry scanEntry)
{
- OffsetNumber attnum;
+ OffsetNumber attnum;
Form_pg_attribute attr;
/* Initialize empty bitmap result */
@@ -253,8 +253,8 @@ collectMatchBitmap(GinBtreeData *btree, GinBtreeStack *stack,
cmp = DatumGetInt32(FunctionCall4(&btree->ginstate->comparePartialFn[attnum - 1],
scanEntry->queryKey,
idatum,
- UInt16GetDatum(scanEntry->strategy),
- PointerGetDatum(scanEntry->extra_data)));
+ UInt16GetDatum(scanEntry->strategy),
+ PointerGetDatum(scanEntry->extra_data)));
if (cmp > 0)
return true;
@@ -269,7 +269,7 @@ collectMatchBitmap(GinBtreeData *btree, GinBtreeStack *stack,
/*
* In ALL mode, we are not interested in null items, so we can
* stop if we get to a null-item placeholder (which will be the
- * last entry for a given attnum). We do want to include NULL_KEY
+ * last entry for a given attnum). We do want to include NULL_KEY
* and EMPTY_ITEM entries, though.
*/
if (icategory == GIN_CAT_NULL_ITEM)
@@ -287,8 +287,8 @@ collectMatchBitmap(GinBtreeData *btree, GinBtreeStack *stack,
* We should unlock current page (but not unpin) during tree scan
* to prevent deadlock with vacuum processes.
*
- * We save current entry value (idatum) to be able to re-find
- * our tuple after re-locking
+ * We save current entry value (idatum) to be able to re-find our
+ * tuple after re-locking
*/
if (icategory == GIN_CAT_NORM_KEY)
idatum = datumCopy(idatum, attr->attbyval, attr->attlen);
@@ -442,11 +442,11 @@ restartScanEntry:
Page page;
/*
- * We should unlock entry page before touching posting tree
- * to prevent deadlocks with vacuum processes. Because entry is
- * never deleted from page and posting tree is never reduced to
- * the posting list, we can unlock page after getting BlockNumber
- * of root of posting tree.
+ * We should unlock entry page before touching posting tree to
+ * prevent deadlocks with vacuum processes. Because entry is never
+ * deleted from page and posting tree is never reduced to the
+ * posting list, we can unlock page after getting BlockNumber of
+ * root of posting tree.
*/
LockBuffer(stackEntry->buffer, GIN_UNLOCK);
needUnlock = FALSE;
@@ -596,7 +596,7 @@ entryGetNextItem(GinState *ginstate, GinScanEntry entry)
if (!ItemPointerIsValid(&entry->curItem) ||
ginCompareItemPointers(&entry->curItem,
- entry->list + entry->offset - 1) == 0)
+ entry->list + entry->offset - 1) == 0)
{
/*
* First pages are deleted or empty, or we found exact
@@ -656,10 +656,10 @@ entryGetItem(GinState *ginstate, GinScanEntry entry)
}
/*
- * Reset counter to the beginning of entry->matchResult.
- * Note: entry->offset is still greater than
- * matchResult->ntuples if matchResult is lossy. So, on next
- * call we will get next result from TIDBitmap.
+ * Reset counter to the beginning of entry->matchResult. Note:
+ * entry->offset is still greater than matchResult->ntuples if
+ * matchResult is lossy. So, on next call we will get next
+ * result from TIDBitmap.
*/
entry->offset = 0;
}
@@ -745,10 +745,10 @@ keyGetItem(GinState *ginstate, MemoryContext tempCtx, GinScanKey key)
/*
* Find the minimum of the active entry curItems.
*
- * Note: a lossy-page entry is encoded by a ItemPointer with max value
- * for offset (0xffff), so that it will sort after any exact entries
- * for the same page. So we'll prefer to return exact pointers not
- * lossy pointers, which is good.
+ * Note: a lossy-page entry is encoded by a ItemPointer with max value for
+ * offset (0xffff), so that it will sort after any exact entries for the
+ * same page. So we'll prefer to return exact pointers not lossy
+ * pointers, which is good.
*/
ItemPointerSetMax(&minItem);
@@ -782,28 +782,27 @@ keyGetItem(GinState *ginstate, MemoryContext tempCtx, GinScanKey key)
/*
* Lossy-page entries pose a problem, since we don't know the correct
- * entryRes state to pass to the consistentFn, and we also don't know
- * what its combining logic will be (could be AND, OR, or even NOT).
- * If the logic is OR then the consistentFn might succeed for all
- * items in the lossy page even when none of the other entries match.
+ * entryRes state to pass to the consistentFn, and we also don't know what
+ * its combining logic will be (could be AND, OR, or even NOT). If the
+ * logic is OR then the consistentFn might succeed for all items in the
+ * lossy page even when none of the other entries match.
*
* If we have a single lossy-page entry then we check to see if the
- * consistentFn will succeed with only that entry TRUE. If so,
- * we return a lossy-page pointer to indicate that the whole heap
- * page must be checked. (On subsequent calls, we'll do nothing until
- * minItem is past the page altogether, thus ensuring that we never return
- * both regular and lossy pointers for the same page.)
+ * consistentFn will succeed with only that entry TRUE. If so, we return
+ * a lossy-page pointer to indicate that the whole heap page must be
+ * checked. (On subsequent calls, we'll do nothing until minItem is past
+ * the page altogether, thus ensuring that we never return both regular
+ * and lossy pointers for the same page.)
*
- * This idea could be generalized to more than one lossy-page entry,
- * but ideally lossy-page entries should be infrequent so it would
- * seldom be the case that we have more than one at once. So it
- * doesn't seem worth the extra complexity to optimize that case.
- * If we do find more than one, we just punt and return a lossy-page
- * pointer always.
+ * This idea could be generalized to more than one lossy-page entry, but
+ * ideally lossy-page entries should be infrequent so it would seldom be
+ * the case that we have more than one at once. So it doesn't seem worth
+ * the extra complexity to optimize that case. If we do find more than
+ * one, we just punt and return a lossy-page pointer always.
*
- * Note that only lossy-page entries pointing to the current item's
- * page should trigger this processing; we might have future lossy
- * pages in the entry array, but they aren't relevant yet.
+ * Note that only lossy-page entries pointing to the current item's page
+ * should trigger this processing; we might have future lossy pages in the
+ * entry array, but they aren't relevant yet.
*/
ItemPointerSetLossyPage(&curPageLossy,
GinItemPointerGetBlockNumber(&key->curItem));
@@ -853,15 +852,14 @@ keyGetItem(GinState *ginstate, MemoryContext tempCtx, GinScanKey key)
}
/*
- * At this point we know that we don't need to return a lossy
- * whole-page pointer, but we might have matches for individual exact
- * item pointers, possibly in combination with a lossy pointer. Our
- * strategy if there's a lossy pointer is to try the consistentFn both
- * ways and return a hit if it accepts either one (forcing the hit to
- * be marked lossy so it will be rechecked). An exception is that
- * we don't need to try it both ways if the lossy pointer is in a
- * "hidden" entry, because the consistentFn's result can't depend on
- * that.
+ * At this point we know that we don't need to return a lossy whole-page
+ * pointer, but we might have matches for individual exact item pointers,
+ * possibly in combination with a lossy pointer. Our strategy if there's
+ * a lossy pointer is to try the consistentFn both ways and return a hit
+ * if it accepts either one (forcing the hit to be marked lossy so it will
+ * be rechecked). An exception is that we don't need to try it both ways
+ * if the lossy pointer is in a "hidden" entry, because the consistentFn's
+ * result can't depend on that.
*
* Prepare entryRes array to be passed to consistentFn.
*/
@@ -960,7 +958,7 @@ scanGetItem(IndexScanDesc scan, ItemPointer advancePast,
keyGetItem(&so->ginstate, so->tempCtx, key);
if (key->isFinished)
- return false; /* finished one of keys */
+ return false; /* finished one of keys */
if (ginCompareItemPointers(&key->curItem, item) < 0)
*item = key->curItem;
@@ -975,7 +973,7 @@ scanGetItem(IndexScanDesc scan, ItemPointer advancePast,
* that exact TID, or a lossy reference to the same page.
*
* This logic works only if a keyGetItem stream can never contain both
- * exact and lossy pointers for the same page. Else we could have a
+ * exact and lossy pointers for the same page. Else we could have a
* case like
*
* stream 1 stream 2
@@ -1011,8 +1009,8 @@ scanGetItem(IndexScanDesc scan, ItemPointer advancePast,
break;
/*
- * No hit. Update myAdvancePast to this TID, so that on the next
- * pass we'll move to the next possible entry.
+ * No hit. Update myAdvancePast to this TID, so that on the next pass
+ * we'll move to the next possible entry.
*/
myAdvancePast = *item;
}
@@ -1118,8 +1116,8 @@ scanGetCandidate(IndexScanDesc scan, pendingPosition *pos)
/*
* Now pos->firstOffset points to the first tuple of current heap
- * row, pos->lastOffset points to the first tuple of next heap
- * row (or to the end of page)
+ * row, pos->lastOffset points to the first tuple of next heap row
+ * (or to the end of page)
*/
break;
}
@@ -1181,7 +1179,7 @@ matchPartialInPendingList(GinState *ginstate, Page page,
entry->queryKey,
datum[off - 1],
UInt16GetDatum(entry->strategy),
- PointerGetDatum(entry->extra_data)));
+ PointerGetDatum(entry->extra_data)));
if (cmp == 0)
return true;
else if (cmp > 0)
@@ -1227,8 +1225,8 @@ collectMatchesForHeapRow(IndexScanDesc scan, pendingPosition *pos)
memset(pos->hasMatchKey, FALSE, so->nkeys);
/*
- * Outer loop iterates over multiple pending-list pages when a single
- * heap row has entries spanning those pages.
+ * Outer loop iterates over multiple pending-list pages when a single heap
+ * row has entries spanning those pages.
*/
for (;;)
{
@@ -1322,11 +1320,11 @@ collectMatchesForHeapRow(IndexScanDesc scan, pendingPosition *pos)
if (res == 0)
{
/*
- * Found exact match (there can be only one, except
- * in EMPTY_QUERY mode).
+ * Found exact match (there can be only one, except in
+ * EMPTY_QUERY mode).
*
- * If doing partial match, scan forward from
- * here to end of page to check for matches.
+ * If doing partial match, scan forward from here to
+ * end of page to check for matches.
*
* See comment above about tuple's ordering.
*/
@@ -1355,13 +1353,12 @@ collectMatchesForHeapRow(IndexScanDesc scan, pendingPosition *pos)
if (StopLow >= StopHigh && entry->isPartialMatch)
{
/*
- * No exact match on this page. If doing partial
- * match, scan from the first tuple greater than
- * target value to end of page. Note that since we
- * don't remember whether the comparePartialFn told us
- * to stop early on a previous page, we will uselessly
- * apply comparePartialFn to the first tuple on each
- * subsequent page.
+ * No exact match on this page. If doing partial match,
+ * scan from the first tuple greater than target value to
+ * end of page. Note that since we don't remember whether
+ * the comparePartialFn told us to stop early on a
+ * previous page, we will uselessly apply comparePartialFn
+ * to the first tuple on each subsequent page.
*/
key->entryRes[j] =
matchPartialInPendingList(&so->ginstate,
diff --git a/src/backend/access/gin/gininsert.c b/src/backend/access/gin/gininsert.c
index af5068906f..3e32af94a9 100644
--- a/src/backend/access/gin/gininsert.c
+++ b/src/backend/access/gin/gininsert.c
@@ -97,7 +97,7 @@ createPostingTree(Relation index, ItemPointerData *items, uint32 nitems)
* Adds array of item pointers to tuple's posting list, or
* creates posting tree and tuple pointing to tree in case
* of not enough space. Max size of tuple is defined in
- * GinFormTuple(). Returns a new, modified index tuple.
+ * GinFormTuple(). Returns a new, modified index tuple.
* items[] must be in sorted order with no duplicates.
*/
static IndexTuple
@@ -195,14 +195,14 @@ buildFreshLeafTuple(GinState *ginstate,
BlockNumber postingRoot;
/*
- * Build posting-tree-only result tuple. We do this first so as
- * to fail quickly if the key is too big.
+ * Build posting-tree-only result tuple. We do this first so as to
+ * fail quickly if the key is too big.
*/
res = GinFormTuple(ginstate, attnum, key, category, NULL, 0, true);
/*
- * Initialize posting tree with as many TIDs as will fit on the
- * first page.
+ * Initialize posting tree with as many TIDs as will fit on the first
+ * page.
*/
postingRoot = createPostingTree(ginstate->index,
items,
@@ -361,7 +361,7 @@ ginBuildCallback(Relation index, HeapTuple htup, Datum *values,
ginBeginBAScan(&buildstate->accum);
while ((list = ginGetBAEntry(&buildstate->accum,
- &attnum, &key, &category, &nlist)) != NULL)
+ &attnum, &key, &category, &nlist)) != NULL)
{
/* there could be many entries, so be willing to abort here */
CHECK_FOR_INTERRUPTS();
diff --git a/src/backend/access/gin/ginscan.c b/src/backend/access/gin/ginscan.c
index 25f60e15a0..37b08c0df6 100644
--- a/src/backend/access/gin/ginscan.c
+++ b/src/backend/access/gin/ginscan.c
@@ -199,7 +199,7 @@ ginFillScanKey(GinScanOpaque so, OffsetNumber attnum,
break;
default:
elog(ERROR, "unexpected searchMode: %d", searchMode);
- queryCategory = 0; /* keep compiler quiet */
+ queryCategory = 0; /* keep compiler quiet */
break;
}
isPartialMatch = false;
@@ -294,8 +294,8 @@ ginNewScanKey(IndexScanDesc scan)
int32 searchMode = GIN_SEARCH_MODE_DEFAULT;
/*
- * We assume that GIN-indexable operators are strict, so a null
- * query argument means an unsatisfiable query.
+ * We assume that GIN-indexable operators are strict, so a null query
+ * argument means an unsatisfiable query.
*/
if (skey->sk_flags & SK_ISNULL)
{
@@ -315,8 +315,8 @@ ginNewScanKey(IndexScanDesc scan)
PointerGetDatum(&searchMode)));
/*
- * If bogus searchMode is returned, treat as GIN_SEARCH_MODE_ALL;
- * note in particular we don't allow extractQueryFn to select
+ * If bogus searchMode is returned, treat as GIN_SEARCH_MODE_ALL; note
+ * in particular we don't allow extractQueryFn to select
* GIN_SEARCH_MODE_EVERYTHING.
*/
if (searchMode < GIN_SEARCH_MODE_DEFAULT ||
@@ -344,20 +344,20 @@ ginNewScanKey(IndexScanDesc scan)
* If the extractQueryFn didn't create a nullFlags array, create one,
* assuming that everything's non-null. Otherwise, run through the
* array and make sure each value is exactly 0 or 1; this ensures
- * binary compatibility with the GinNullCategory representation.
- * While at it, detect whether any null keys are present.
+ * binary compatibility with the GinNullCategory representation. While
+ * at it, detect whether any null keys are present.
*/
if (nullFlags == NULL)
nullFlags = (bool *) palloc0(nQueryValues * sizeof(bool));
else
{
- int32 j;
+ int32 j;
for (j = 0; j < nQueryValues; j++)
{
if (nullFlags[j])
{
- nullFlags[j] = true; /* not any other nonzero value */
+ nullFlags[j] = true; /* not any other nonzero value */
hasNullQuery = true;
}
}
@@ -387,11 +387,11 @@ ginNewScanKey(IndexScanDesc scan)
/*
* If the index is version 0, it may be missing null and placeholder
* entries, which would render searches for nulls and full-index scans
- * unreliable. Throw an error if so.
+ * unreliable. Throw an error if so.
*/
if (hasNullQuery && !so->isVoidRes)
{
- GinStatsData ginStats;
+ GinStatsData ginStats;
ginGetStats(scan->indexRelation, &ginStats);
if (ginStats.ginVersion < 1)
@@ -410,6 +410,7 @@ ginrescan(PG_FUNCTION_ARGS)
{
IndexScanDesc scan = (IndexScanDesc) PG_GETARG_POINTER(0);
ScanKey scankey = (ScanKey) PG_GETARG_POINTER(1);
+
/* remaining arguments are ignored */
GinScanOpaque so = (GinScanOpaque) scan->opaque;
diff --git a/src/backend/access/gin/ginutil.c b/src/backend/access/gin/ginutil.c
index 392c12d47a..716cf3a734 100644
--- a/src/backend/access/gin/ginutil.c
+++ b/src/backend/access/gin/ginutil.c
@@ -70,7 +70,7 @@ initGinState(GinState *state, Relation index)
* However, we may have a collatable storage type for a noncollatable
* indexed data type (for instance, hstore uses text index entries).
* If there's no index collation then specify default collation in
- * case the comparison function needs one. This is harmless if the
+ * case the comparison function needs one. This is harmless if the
* comparison function doesn't care about collation, so we just do it
* unconditionally. (We could alternatively call get_typcollation,
* but that seems like expensive overkill --- there aren't going to be
@@ -359,9 +359,9 @@ cmpEntries(const void *a, const void *b, void *arg)
aa->datum, bb->datum));
/*
- * Detect if we have any duplicates. If there are equal keys, qsort
- * must compare them at some point, else it wouldn't know whether one
- * should go before or after the other.
+ * Detect if we have any duplicates. If there are equal keys, qsort must
+ * compare them at some point, else it wouldn't know whether one should go
+ * before or after the other.
*/
if (res == 0)
data->haveDups = true;
@@ -422,9 +422,9 @@ ginExtractEntries(GinState *ginstate, OffsetNumber attnum,
/*
* If the extractValueFn didn't create a nullFlags array, create one,
- * assuming that everything's non-null. Otherwise, run through the
- * array and make sure each value is exactly 0 or 1; this ensures
- * binary compatibility with the GinNullCategory representation.
+ * assuming that everything's non-null. Otherwise, run through the array
+ * and make sure each value is exactly 0 or 1; this ensures binary
+ * compatibility with the GinNullCategory representation.
*/
if (nullFlags == NULL)
nullFlags = (bool *) palloc0(*nentries * sizeof(bool));
@@ -440,8 +440,8 @@ ginExtractEntries(GinState *ginstate, OffsetNumber attnum,
* If there's more than one key, sort and unique-ify.
*
* XXX Using qsort here is notationally painful, and the overhead is
- * pretty bad too. For small numbers of keys it'd likely be better to
- * use a simple insertion sort.
+ * pretty bad too. For small numbers of keys it'd likely be better to use
+ * a simple insertion sort.
*/
if (*nentries > 1)
{
@@ -470,7 +470,7 @@ ginExtractEntries(GinState *ginstate, OffsetNumber attnum,
j = 1;
for (i = 1; i < *nentries; i++)
{
- if (cmpEntries(&keydata[i-1], &keydata[i], &arg) != 0)
+ if (cmpEntries(&keydata[i - 1], &keydata[i], &arg) != 0)
{
entries[j] = keydata[i].datum;
nullFlags[j] = keydata[i].isnull;
@@ -533,9 +533,9 @@ ginoptions(PG_FUNCTION_ARGS)
void
ginGetStats(Relation index, GinStatsData *stats)
{
- Buffer metabuffer;
- Page metapage;
- GinMetaPageData *metadata;
+ Buffer metabuffer;
+ Page metapage;
+ GinMetaPageData *metadata;
metabuffer = ReadBuffer(index, GIN_METAPAGE_BLKNO);
LockBuffer(metabuffer, GIN_SHARE);
@@ -560,9 +560,9 @@ ginGetStats(Relation index, GinStatsData *stats)
void
ginUpdateStats(Relation index, const GinStatsData *stats)
{
- Buffer metabuffer;
- Page metapage;
- GinMetaPageData *metadata;
+ Buffer metabuffer;
+ Page metapage;
+ GinMetaPageData *metadata;
metabuffer = ReadBuffer(index, GIN_METAPAGE_BLKNO);
LockBuffer(metabuffer, GIN_EXCLUSIVE);
@@ -580,9 +580,9 @@ ginUpdateStats(Relation index, const GinStatsData *stats)
if (RelationNeedsWAL(index))
{
- XLogRecPtr recptr;
- ginxlogUpdateMeta data;
- XLogRecData rdata;
+ XLogRecPtr recptr;
+ ginxlogUpdateMeta data;
+ XLogRecData rdata;
data.node = index->rd_node;
data.ntuples = 0;
diff --git a/src/backend/access/gin/ginvacuum.c b/src/backend/access/gin/ginvacuum.c
index 41ad382df0..79c54f16b8 100644
--- a/src/backend/access/gin/ginvacuum.c
+++ b/src/backend/access/gin/ginvacuum.c
@@ -783,7 +783,7 @@ ginvacuumcleanup(PG_FUNCTION_ARGS)
{
idxStat.nEntryPages++;
- if ( GinPageIsLeaf(page) )
+ if (GinPageIsLeaf(page))
idxStat.nEntries += PageGetMaxOffsetNumber(page);
}
diff --git a/src/backend/access/gin/ginxlog.c b/src/backend/access/gin/ginxlog.c
index e410959b85..c954bcb12f 100644
--- a/src/backend/access/gin/ginxlog.c
+++ b/src/backend/access/gin/ginxlog.c
@@ -388,7 +388,7 @@ ginRedoVacuumPage(XLogRecPtr lsn, XLogRecord *record)
else
{
OffsetNumber i,
- *tod;
+ *tod;
IndexTuple itup = (IndexTuple) (XLogRecGetData(record) + sizeof(ginxlogVacuumPage));
tod = (OffsetNumber *) palloc(sizeof(OffsetNumber) * PageGetMaxOffsetNumber(page));
@@ -513,10 +513,10 @@ ginRedoUpdateMetapage(XLogRecPtr lsn, XLogRecord *record)
if (!XLByteLE(lsn, PageGetLSN(page)))
{
OffsetNumber l,
- off = (PageIsEmpty(page)) ? FirstOffsetNumber :
- OffsetNumberNext(PageGetMaxOffsetNumber(page));
+ off = (PageIsEmpty(page)) ? FirstOffsetNumber :
+ OffsetNumberNext(PageGetMaxOffsetNumber(page));
int i,
- tupsize;
+ tupsize;
IndexTuple tuples = (IndexTuple) (XLogRecGetData(record) + sizeof(ginxlogUpdateMeta));
for (i = 0; i < data->ntuples; i++)
diff --git a/src/backend/access/gist/gist.c b/src/backend/access/gist/gist.c
index 9529413e80..fae3464600 100644
--- a/src/backend/access/gist/gist.c
+++ b/src/backend/access/gist/gist.c
@@ -34,8 +34,8 @@ typedef struct
/* A List of these is used represent a split-in-progress. */
typedef struct
{
- Buffer buf; /* the split page "half" */
- IndexTuple downlink; /* downlink for this half. */
+ Buffer buf; /* the split page "half" */
+ IndexTuple downlink; /* downlink for this half. */
} GISTPageSplitInfo;
/* non-export function prototypes */
@@ -306,13 +306,13 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
bool is_split;
/*
- * Refuse to modify a page that's incompletely split. This should
- * not happen because we finish any incomplete splits while we walk
- * down the tree. However, it's remotely possible that another
- * concurrent inserter splits a parent page, and errors out before
- * completing the split. We will just throw an error in that case,
- * and leave any split we had in progress unfinished too. The next
- * insert that comes along will clean up the mess.
+ * Refuse to modify a page that's incompletely split. This should not
+ * happen because we finish any incomplete splits while we walk down the
+ * tree. However, it's remotely possible that another concurrent inserter
+ * splits a parent page, and errors out before completing the split. We
+ * will just throw an error in that case, and leave any split we had in
+ * progress unfinished too. The next insert that comes along will clean up
+ * the mess.
*/
if (GistFollowRight(page))
elog(ERROR, "concurrent GiST page split was incomplete");
@@ -338,7 +338,7 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
SplitedPageLayout *dist = NULL,
*ptr;
BlockNumber oldrlink = InvalidBlockNumber;
- GistNSN oldnsn = { 0, 0 };
+ GistNSN oldnsn = {0, 0};
SplitedPageLayout rootpg;
BlockNumber blkno = BufferGetBlockNumber(buffer);
bool is_rootsplit;
@@ -364,8 +364,8 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
/*
* Set up pages to work with. Allocate new buffers for all but the
- * leftmost page. The original page becomes the new leftmost page,
- * and is just replaced with the new contents.
+ * leftmost page. The original page becomes the new leftmost page, and
+ * is just replaced with the new contents.
*
* For a root-split, allocate new buffers for all child pages, the
* original page is overwritten with new root page containing
@@ -414,8 +414,8 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
if (is_rootsplit)
{
IndexTuple *downlinks;
- int ndownlinks = 0;
- int i;
+ int ndownlinks = 0;
+ int i;
rootpg.buffer = buffer;
rootpg.page = PageGetTempPageCopySpecial(BufferGetPage(rootpg.buffer));
@@ -443,6 +443,7 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
for (ptr = dist; ptr; ptr = ptr->next)
{
GISTPageSplitInfo *si = palloc(sizeof(GISTPageSplitInfo));
+
si->buf = ptr->buffer;
si->downlink = ptr->itup;
*splitinfo = lappend(*splitinfo, si);
@@ -455,7 +456,8 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
*/
for (ptr = dist; ptr; ptr = ptr->next)
{
- char *data = (char *) (ptr->list);
+ char *data = (char *) (ptr->list);
+
for (i = 0; i < ptr->block.num; i++)
{
if (PageAddItem(ptr->page, (Item) data, IndexTupleSize((IndexTuple) data), i + FirstOffsetNumber, false, false) == InvalidOffsetNumber)
@@ -495,8 +497,8 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
MarkBufferDirty(leftchildbuf);
/*
- * The first page in the chain was a temporary working copy meant
- * to replace the old page. Copy it over the old page.
+ * The first page in the chain was a temporary working copy meant to
+ * replace the old page. Copy it over the old page.
*/
PageRestoreTempPage(dist->page, BufferGetPage(dist->buffer));
dist->page = BufferGetPage(dist->buffer);
@@ -518,8 +520,8 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
* Return the new child buffers to the caller.
*
* If this was a root split, we've already inserted the downlink
- * pointers, in the form of a new root page. Therefore we can
- * release all the new buffers, and keep just the root page locked.
+ * pointers, in the form of a new root page. Therefore we can release
+ * all the new buffers, and keep just the root page locked.
*/
if (is_rootsplit)
{
@@ -572,20 +574,20 @@ gistplacetopage(GISTInsertState *state, GISTSTATE *giststate,
/*
* If we inserted the downlink for a child page, set NSN and clear
- * F_FOLLOW_RIGHT flag on the left child, so that concurrent scans know
- * to follow the rightlink if and only if they looked at the parent page
+ * F_FOLLOW_RIGHT flag on the left child, so that concurrent scans know to
+ * follow the rightlink if and only if they looked at the parent page
* before we inserted the downlink.
*
* Note that we do this *after* writing the WAL record. That means that
- * the possible full page image in the WAL record does not include
- * these changes, and they must be replayed even if the page is restored
- * from the full page image. There's a chicken-and-egg problem: if we
- * updated the child pages first, we wouldn't know the recptr of the WAL
- * record we're about to write.
+ * the possible full page image in the WAL record does not include these
+ * changes, and they must be replayed even if the page is restored from
+ * the full page image. There's a chicken-and-egg problem: if we updated
+ * the child pages first, we wouldn't know the recptr of the WAL record
+ * we're about to write.
*/
if (BufferIsValid(leftchildbuf))
{
- Page leftpg = BufferGetPage(leftchildbuf);
+ Page leftpg = BufferGetPage(leftchildbuf);
GistPageGetOpaque(leftpg)->nsn = recptr;
GistClearFollowRight(leftpg);
@@ -636,8 +638,8 @@ gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
stack->buffer = ReadBuffer(state.r, stack->blkno);
/*
- * Be optimistic and grab shared lock first. Swap it for an
- * exclusive lock later if we need to update the page.
+ * Be optimistic and grab shared lock first. Swap it for an exclusive
+ * lock later if we need to update the page.
*/
if (!xlocked)
{
@@ -650,9 +652,9 @@ gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
Assert(!RelationNeedsWAL(state.r) || !XLogRecPtrIsInvalid(stack->lsn));
/*
- * If this page was split but the downlink was never inserted to
- * the parent because the inserting backend crashed before doing
- * that, fix that now.
+ * If this page was split but the downlink was never inserted to the
+ * parent because the inserting backend crashed before doing that, fix
+ * that now.
*/
if (GistFollowRight(stack->page))
{
@@ -680,8 +682,8 @@ gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
/*
* Concurrent split detected. There's no guarantee that the
* downlink for this page is consistent with the tuple we're
- * inserting anymore, so go back to parent and rechoose the
- * best child.
+ * inserting anymore, so go back to parent and rechoose the best
+ * child.
*/
UnlockReleaseBuffer(stack->buffer);
xlocked = false;
@@ -696,7 +698,7 @@ gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
* Find the child node that has the minimum insertion penalty.
*/
BlockNumber childblkno;
- IndexTuple newtup;
+ IndexTuple newtup;
GISTInsertStack *item;
stack->childoffnum = gistchoose(state.r, stack->page, itup, giststate);
@@ -722,8 +724,8 @@ gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
if (newtup)
{
/*
- * Swap shared lock for an exclusive one. Beware, the page
- * may change while we unlock/lock the page...
+ * Swap shared lock for an exclusive one. Beware, the page may
+ * change while we unlock/lock the page...
*/
if (!xlocked)
{
@@ -738,6 +740,7 @@ gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
continue;
}
}
+
/*
* Update the tuple.
*
@@ -752,8 +755,8 @@ gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
stack->childoffnum, InvalidBuffer))
{
/*
- * If this was a root split, the root page continues to
- * be the parent and the updated tuple went to one of the
+ * If this was a root split, the root page continues to be
+ * the parent and the updated tuple went to one of the
* child pages, so we just need to retry from the root
* page.
*/
@@ -779,13 +782,13 @@ gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
{
/*
* Leaf page. Insert the new key. We've already updated all the
- * parents on the way down, but we might have to split the page
- * if it doesn't fit. gistinserthere() will take care of that.
+ * parents on the way down, but we might have to split the page if
+ * it doesn't fit. gistinserthere() will take care of that.
*/
/*
- * Swap shared lock for an exclusive one. Be careful, the page
- * may change while we unlock/lock the page...
+ * Swap shared lock for an exclusive one. Be careful, the page may
+ * change while we unlock/lock the page...
*/
if (!xlocked)
{
@@ -798,8 +801,8 @@ gistdoinsert(Relation r, IndexTuple itup, Size freespace, GISTSTATE *giststate)
if (stack->blkno == GIST_ROOT_BLKNO)
{
/*
- * the only page that can become inner instead of leaf
- * is the root page, so for root we should recheck it
+ * the only page that can become inner instead of leaf is
+ * the root page, so for root we should recheck it
*/
if (!GistPageIsLeaf(stack->page))
{
@@ -1059,21 +1062,23 @@ static IndexTuple
gistformdownlink(Relation rel, Buffer buf, GISTSTATE *giststate,
GISTInsertStack *stack)
{
- Page page = BufferGetPage(buf);
+ Page page = BufferGetPage(buf);
OffsetNumber maxoff;
OffsetNumber offset;
- IndexTuple downlink = NULL;
+ IndexTuple downlink = NULL;
maxoff = PageGetMaxOffsetNumber(page);
for (offset = FirstOffsetNumber; offset <= maxoff; offset = OffsetNumberNext(offset))
{
IndexTuple ituple = (IndexTuple)
- PageGetItem(page, PageGetItemId(page, offset));
+ PageGetItem(page, PageGetItemId(page, offset));
+
if (downlink == NULL)
downlink = CopyIndexTuple(ituple);
else
{
- IndexTuple newdownlink;
+ IndexTuple newdownlink;
+
newdownlink = gistgetadjusted(rel, downlink, ituple,
giststate);
if (newdownlink)
@@ -1082,19 +1087,18 @@ gistformdownlink(Relation rel, Buffer buf, GISTSTATE *giststate,
}
/*
- * If the page is completely empty, we can't form a meaningful
- * downlink for it. But we have to insert a downlink for the page.
- * Any key will do, as long as its consistent with the downlink of
- * parent page, so that we can legally insert it to the parent.
- * A minimal one that matches as few scans as possible would be best,
- * to keep scans from doing useless work, but we don't know how to
- * construct that. So we just use the downlink of the original page
- * that was split - that's as far from optimal as it can get but will
- * do..
+ * If the page is completely empty, we can't form a meaningful downlink
+ * for it. But we have to insert a downlink for the page. Any key will do,
+ * as long as its consistent with the downlink of parent page, so that we
+ * can legally insert it to the parent. A minimal one that matches as few
+ * scans as possible would be best, to keep scans from doing useless work,
+ * but we don't know how to construct that. So we just use the downlink of
+ * the original page that was split - that's as far from optimal as it can
+ * get but will do..
*/
if (!downlink)
{
- ItemId iid;
+ ItemId iid;
LockBuffer(stack->parent->buffer, GIST_EXCLUSIVE);
gistFindCorrectParent(rel, stack);
@@ -1131,13 +1135,13 @@ gistfixsplit(GISTInsertState *state, GISTSTATE *giststate)
buf = stack->buffer;
/*
- * Read the chain of split pages, following the rightlinks. Construct
- * a downlink tuple for each page.
+ * Read the chain of split pages, following the rightlinks. Construct a
+ * downlink tuple for each page.
*/
for (;;)
{
GISTPageSplitInfo *si = palloc(sizeof(GISTPageSplitInfo));
- IndexTuple downlink;
+ IndexTuple downlink;
page = BufferGetPage(buf);
@@ -1182,8 +1186,8 @@ gistinserttuples(GISTInsertState *state, GISTInsertStack *stack,
IndexTuple *tuples, int ntup, OffsetNumber oldoffnum,
Buffer leftchild)
{
- List *splitinfo;
- bool is_split;
+ List *splitinfo;
+ bool is_split;
is_split = gistplacetopage(state, giststate, stack->buffer,
tuples, ntup, oldoffnum,
@@ -1204,21 +1208,21 @@ static void
gistfinishsplit(GISTInsertState *state, GISTInsertStack *stack,
GISTSTATE *giststate, List *splitinfo)
{
- ListCell *lc;
- List *reversed;
+ ListCell *lc;
+ List *reversed;
GISTPageSplitInfo *right;
GISTPageSplitInfo *left;
- IndexTuple tuples[2];
+ IndexTuple tuples[2];
/* A split always contains at least two halves */
Assert(list_length(splitinfo) >= 2);
/*
- * We need to insert downlinks for each new page, and update the
- * downlink for the original (leftmost) page in the split. Begin at
- * the rightmost page, inserting one downlink at a time until there's
- * only two pages left. Finally insert the downlink for the last new
- * page and update the downlink for the original page as one operation.
+ * We need to insert downlinks for each new page, and update the downlink
+ * for the original (leftmost) page in the split. Begin at the rightmost
+ * page, inserting one downlink at a time until there's only two pages
+ * left. Finally insert the downlink for the last new page and update the
+ * downlink for the original page as one operation.
*/
/* for convenience, create a copy of the list in reverse order */
@@ -1231,7 +1235,7 @@ gistfinishsplit(GISTInsertState *state, GISTInsertStack *stack,
LockBuffer(stack->parent->buffer, GIST_EXCLUSIVE);
gistFindCorrectParent(state->r, stack);
- while(list_length(reversed) > 2)
+ while (list_length(reversed) > 2)
{
right = (GISTPageSplitInfo *) linitial(reversed);
left = (GISTPageSplitInfo *) lsecond(reversed);
@@ -1386,7 +1390,7 @@ initGISTstate(GISTSTATE *giststate, Relation index)
/* opclasses are not required to provide a Distance method */
if (OidIsValid(index_getprocid(index, i + 1, GIST_DISTANCE_PROC)))
fmgr_info_copy(&(giststate->distanceFn[i]),
- index_getprocinfo(index, i + 1, GIST_DISTANCE_PROC),
+ index_getprocinfo(index, i + 1, GIST_DISTANCE_PROC),
CurrentMemoryContext);
else
giststate->distanceFn[i].fn_oid = InvalidOid;
diff --git a/src/backend/access/gist/gistget.c b/src/backend/access/gist/gistget.c
index 8355081553..e4488a925d 100644
--- a/src/backend/access/gist/gistget.c
+++ b/src/backend/access/gist/gistget.c
@@ -32,7 +32,7 @@
*
* On success return for a heap tuple, *recheck_p is set to indicate
* whether recheck is needed. We recheck if any of the consistent() functions
- * request it. recheck is not interesting when examining a non-leaf entry,
+ * request it. recheck is not interesting when examining a non-leaf entry,
* since we must visit the lower index page if there's any doubt.
*
* If we are doing an ordered scan, so->distances[] is filled with distance
@@ -62,15 +62,15 @@ gistindex_keytest(IndexScanDesc scan,
*recheck_p = false;
/*
- * If it's a leftover invalid tuple from pre-9.1, treat it as a match
- * with minimum possible distances. This means we'll always follow it
- * to the referenced page.
+ * If it's a leftover invalid tuple from pre-9.1, treat it as a match with
+ * minimum possible distances. This means we'll always follow it to the
+ * referenced page.
*/
if (GistTupleIsInvalid(tuple))
{
- int i;
+ int i;
- if (GistPageIsLeaf(page)) /* shouldn't happen */
+ if (GistPageIsLeaf(page)) /* shouldn't happen */
elog(ERROR, "invalid GIST tuple found on leaf page");
for (i = 0; i < scan->numberOfOrderBys; i++)
so->distances[i] = -get_float8_infinity();
@@ -191,8 +191,8 @@ gistindex_keytest(IndexScanDesc scan,
* always be zero, but might as well pass it for possible future
* use.)
*
- * Note that Distance functions don't get a recheck argument.
- * We can't tolerate lossy distance calculations on leaf tuples;
+ * Note that Distance functions don't get a recheck argument. We
+ * can't tolerate lossy distance calculations on leaf tuples;
* there is no opportunity to re-sort the tuples afterwards.
*/
dist = FunctionCall4(&key->sk_func,
@@ -223,7 +223,7 @@ gistindex_keytest(IndexScanDesc scan,
* ntids: if not NULL, gistgetbitmap's output tuple counter
*
* If tbm/ntids aren't NULL, we are doing an amgetbitmap scan, and heap
- * tuples should be reported directly into the bitmap. If they are NULL,
+ * tuples should be reported directly into the bitmap. If they are NULL,
* we're doing a plain or ordered indexscan. For a plain indexscan, heap
* tuple TIDs are returned into so->pageData[]. For an ordered indexscan,
* heap tuple TIDs are pushed into individual search queue items.
@@ -525,8 +525,8 @@ gistgettuple(PG_FUNCTION_ARGS)
/*
* While scanning a leaf page, ItemPointers of matching heap
* tuples are stored in so->pageData. If there are any on
- * this page, we fall out of the inner "do" and loop around
- * to return them.
+ * this page, we fall out of the inner "do" and loop around to
+ * return them.
*/
gistScanPage(scan, item, so->curTreeItem->distances, NULL, NULL);
diff --git a/src/backend/access/gist/gistproc.c b/src/backend/access/gist/gistproc.c
index 86a5d90f95..43c4b1251b 100644
--- a/src/backend/access/gist/gistproc.c
+++ b/src/backend/access/gist/gistproc.c
@@ -904,7 +904,7 @@ gist_point_compress(PG_FUNCTION_ARGS)
PG_RETURN_POINTER(entry);
}
-#define point_point_distance(p1,p2) \
+#define point_point_distance(p1,p2) \
DatumGetFloat8(DirectFunctionCall2(point_distance, \
PointPGetDatum(p1), PointPGetDatum(p2)))
@@ -949,8 +949,8 @@ computeDistance(bool isLeaf, BOX *box, Point *point)
else
{
/* closest point will be a vertex */
- Point p;
- double subresult;
+ Point p;
+ double subresult;
result = point_point_distance(point, &box->low);
diff --git a/src/backend/access/gist/gistscan.c b/src/backend/access/gist/gistscan.c
index 0a125e772d..67308ed37e 100644
--- a/src/backend/access/gist/gistscan.c
+++ b/src/backend/access/gist/gistscan.c
@@ -57,9 +57,9 @@ GISTSearchTreeItemCombiner(RBNode *existing, const RBNode *newrb, void *arg)
/*
* If new item is heap tuple, it goes to front of chain; otherwise insert
- * it before the first index-page item, so that index pages are visited
- * in LIFO order, ensuring depth-first search of index pages. See
- * comments in gist_private.h.
+ * it before the first index-page item, so that index pages are visited in
+ * LIFO order, ensuring depth-first search of index pages. See comments
+ * in gist_private.h.
*/
if (GISTSearchItemIsHeap(*newitem))
{
@@ -136,6 +136,7 @@ gistrescan(PG_FUNCTION_ARGS)
IndexScanDesc scan = (IndexScanDesc) PG_GETARG_POINTER(0);
ScanKey key = (ScanKey) PG_GETARG_POINTER(1);
ScanKey orderbys = (ScanKey) PG_GETARG_POINTER(3);
+
/* nkeys and norderbys arguments are ignored */
GISTScanOpaque so = (GISTScanOpaque) scan->opaque;
int i;
@@ -164,8 +165,8 @@ gistrescan(PG_FUNCTION_ARGS)
scan->numberOfKeys * sizeof(ScanKeyData));
/*
- * Modify the scan key so that the Consistent method is called for
- * all comparisons. The original operator is passed to the Consistent
+ * Modify the scan key so that the Consistent method is called for all
+ * comparisons. The original operator is passed to the Consistent
* function in the form of its strategy number, which is available
* from the sk_strategy field, and its subtype from the sk_subtype
* field. Also, preserve sk_func.fn_collation which is the input
diff --git a/src/backend/access/gist/gistutil.c b/src/backend/access/gist/gistutil.c
index 6736fd166c..e8bbd564c7 100644
--- a/src/backend/access/gist/gistutil.c
+++ b/src/backend/access/gist/gistutil.c
@@ -503,11 +503,12 @@ gistFormTuple(GISTSTATE *giststate, Relation r,
}
res = index_form_tuple(giststate->tupdesc, compatt, isnull);
+
/*
* The offset number on tuples on internal pages is unused. For historical
* reasons, it is set 0xffff.
*/
- ItemPointerSetOffsetNumber( &(res->t_tid), 0xffff);
+ ItemPointerSetOffsetNumber(&(res->t_tid), 0xffff);
return res;
}
diff --git a/src/backend/access/gist/gistxlog.c b/src/backend/access/gist/gistxlog.c
index 0f406e16c4..51354c1c18 100644
--- a/src/backend/access/gist/gistxlog.c
+++ b/src/backend/access/gist/gistxlog.c
@@ -41,12 +41,12 @@ static void
gistRedoClearFollowRight(RelFileNode node, XLogRecPtr lsn,
BlockNumber leftblkno)
{
- Buffer buffer;
+ Buffer buffer;
buffer = XLogReadBuffer(node, leftblkno, false);
if (BufferIsValid(buffer))
{
- Page page = (Page) BufferGetPage(buffer);
+ Page page = (Page) BufferGetPage(buffer);
/*
* Note that we still update the page even if page LSN is equal to the
@@ -103,6 +103,7 @@ gistRedoPageUpdateRecord(XLogRecPtr lsn, XLogRecord *record)
{
int i;
OffsetNumber *todelete = (OffsetNumber *) data;
+
data += sizeof(OffsetNumber) * xldata->ntodelete;
for (i = 0; i < xldata->ntodelete; i++)
@@ -115,12 +116,14 @@ gistRedoPageUpdateRecord(XLogRecPtr lsn, XLogRecord *record)
if (data - begin < record->xl_len)
{
OffsetNumber off = (PageIsEmpty(page)) ? FirstOffsetNumber :
- OffsetNumberNext(PageGetMaxOffsetNumber(page));
+ OffsetNumberNext(PageGetMaxOffsetNumber(page));
+
while (data - begin < record->xl_len)
{
- IndexTuple itup = (IndexTuple) data;
+ IndexTuple itup = (IndexTuple) data;
Size sz = IndexTupleSize(itup);
OffsetNumber l;
+
data += sz;
l = PageAddItem(page, (Item) itup, sz, off, false, false);
@@ -418,7 +421,7 @@ gistXLogSplit(RelFileNode node, BlockNumber blkno, bool page_is_leaf,
SplitedPageLayout *ptr;
int npage = 0,
cur;
- XLogRecPtr recptr;
+ XLogRecPtr recptr;
for (ptr = dist; ptr; ptr = ptr->next)
npage++;
@@ -540,8 +543,8 @@ gistXLogUpdate(RelFileNode node, Buffer buffer,
}
/*
- * Include a full page image of the child buf. (only necessary if
- * a checkpoint happened since the child page was split)
+ * Include a full page image of the child buf. (only necessary if a
+ * checkpoint happened since the child page was split)
*/
if (BufferIsValid(leftchildbuf))
{
diff --git a/src/backend/access/hash/hash.c b/src/backend/access/hash/hash.c
index f19e5627f8..4cb29b2bb4 100644
--- a/src/backend/access/hash/hash.c
+++ b/src/backend/access/hash/hash.c
@@ -413,6 +413,7 @@ hashrescan(PG_FUNCTION_ARGS)
{
IndexScanDesc scan = (IndexScanDesc) PG_GETARG_POINTER(0);
ScanKey scankey = (ScanKey) PG_GETARG_POINTER(1);
+
/* remaining arguments are ignored */
HashScanOpaque so = (HashScanOpaque) scan->opaque;
Relation rel = scan->indexRelation;
diff --git a/src/backend/access/heap/heapam.c b/src/backend/access/heap/heapam.c
index 89697f6ff5..1fbd8b39b4 100644
--- a/src/backend/access/heap/heapam.c
+++ b/src/backend/access/heap/heapam.c
@@ -1070,7 +1070,7 @@ relation_close(Relation relation, LOCKMODE lockmode)
* This is essentially relation_open plus check that the relation
* is not an index nor a composite type. (The caller should also
* check that it's not a view or foreign table before assuming it has
- * storage.)
+ * storage.)
* ----------------
*/
Relation
@@ -1922,8 +1922,8 @@ heap_insert(Relation relation, HeapTuple tup, CommandId cid,
/*
* We're about to do the actual insert -- check for conflict at the
- * relation or buffer level first, to avoid possibly having to roll
- * back work we've just done.
+ * relation or buffer level first, to avoid possibly having to roll back
+ * work we've just done.
*/
CheckForSerializableConflictIn(relation, NULL, buffer);
@@ -2228,8 +2228,8 @@ l1:
}
/*
- * We're about to do the actual delete -- check for conflict first,
- * to avoid possibly having to roll back work we've just done.
+ * We're about to do the actual delete -- check for conflict first, to
+ * avoid possibly having to roll back work we've just done.
*/
CheckForSerializableConflictIn(relation, &tp, buffer);
@@ -2587,8 +2587,8 @@ l2:
}
/*
- * We're about to do the actual update -- check for conflict first,
- * to avoid possibly having to roll back work we've just done.
+ * We're about to do the actual update -- check for conflict first, to
+ * avoid possibly having to roll back work we've just done.
*/
CheckForSerializableConflictIn(relation, &oldtup, buffer);
@@ -2737,8 +2737,8 @@ l2:
}
/*
- * We're about to create the new tuple -- check for conflict first,
- * to avoid possibly having to roll back work we've just done.
+ * We're about to create the new tuple -- check for conflict first, to
+ * avoid possibly having to roll back work we've just done.
*
* NOTE: For a tuple insert, we only need to check for table locks, since
* predicate locking at the index level will cover ranges for anything
@@ -3860,12 +3860,12 @@ HeapTupleHeaderAdvanceLatestRemovedXid(HeapTupleHeader tuple,
}
/*
- * Ignore tuples inserted by an aborted transaction or
- * if the tuple was updated/deleted by the inserting transaction.
+ * Ignore tuples inserted by an aborted transaction or if the tuple was
+ * updated/deleted by the inserting transaction.
*
* Look for a committed hint bit, or if no xmin bit is set, check clog.
- * This needs to work on both master and standby, where it is used
- * to assess btree delete records.
+ * This needs to work on both master and standby, where it is used to
+ * assess btree delete records.
*/
if ((tuple->t_infomask & HEAP_XMIN_COMMITTED) ||
(!(tuple->t_infomask & HEAP_XMIN_COMMITTED) &&
@@ -3874,7 +3874,7 @@ HeapTupleHeaderAdvanceLatestRemovedXid(HeapTupleHeader tuple,
{
if (xmax != xmin &&
TransactionIdFollows(xmax, *latestRemovedXid))
- *latestRemovedXid = xmax;
+ *latestRemovedXid = xmax;
}
/* *latestRemovedXid may still be invalid at end */
@@ -4158,8 +4158,8 @@ log_newpage(RelFileNode *rnode, ForkNumber forkNum, BlockNumber blkno,
recptr = XLogInsert(RM_HEAP_ID, XLOG_HEAP_NEWPAGE, rdata);
/*
- * The page may be uninitialized. If so, we can't set the LSN
- * and TLI because that would corrupt the page.
+ * The page may be uninitialized. If so, we can't set the LSN and TLI
+ * because that would corrupt the page.
*/
if (!PageIsNew(page))
{
@@ -4352,8 +4352,8 @@ heap_xlog_newpage(XLogRecPtr lsn, XLogRecord *record)
memcpy(page, (char *) xlrec + SizeOfHeapNewpage, BLCKSZ);
/*
- * The page may be uninitialized. If so, we can't set the LSN
- * and TLI because that would corrupt the page.
+ * The page may be uninitialized. If so, we can't set the LSN and TLI
+ * because that would corrupt the page.
*/
if (!PageIsNew(page))
{
diff --git a/src/backend/access/heap/hio.c b/src/backend/access/heap/hio.c
index 2849992528..72a69e52b0 100644
--- a/src/backend/access/heap/hio.c
+++ b/src/backend/access/heap/hio.c
@@ -150,7 +150,7 @@ ReadBufferBI(Relation relation, BlockNumber targetBlock,
Buffer
RelationGetBufferForTuple(Relation relation, Size len,
Buffer otherBuffer, int options,
- struct BulkInsertStateData *bistate)
+ struct BulkInsertStateData * bistate)
{
bool use_fsm = !(options & HEAP_INSERT_SKIP_FSM);
Buffer buffer = InvalidBuffer;
diff --git a/src/backend/access/heap/rewriteheap.c b/src/backend/access/heap/rewriteheap.c
index c710f1d316..e56140950a 100644
--- a/src/backend/access/heap/rewriteheap.c
+++ b/src/backend/access/heap/rewriteheap.c
@@ -131,7 +131,7 @@ typedef struct RewriteStateData
* them */
HTAB *rs_unresolved_tups; /* unmatched A tuples */
HTAB *rs_old_new_tid_map; /* unmatched B tuples */
-} RewriteStateData;
+} RewriteStateData;
/*
* The lookup keys for the hash tables are tuple TID and xmin (we must check
@@ -277,7 +277,7 @@ end_heap_rewrite(RewriteState state)
}
/*
- * If the rel is WAL-logged, must fsync before commit. We use heap_sync
+ * If the rel is WAL-logged, must fsync before commit. We use heap_sync
* to ensure that the toast table gets fsync'd too.
*
* It's obvious that we must do this when not WAL-logging. It's less
diff --git a/src/backend/access/index/indexam.c b/src/backend/access/index/indexam.c
index 88f73e8241..66af2c37c5 100644
--- a/src/backend/access/index/indexam.c
+++ b/src/backend/access/index/indexam.c
@@ -872,7 +872,7 @@ index_getprocinfo(Relation irel,
procnum, attnum, RelationGetRelationName(irel));
fmgr_info_cxt(procId, locinfo, irel->rd_indexcxt);
- fmgr_info_set_collation(irel->rd_indcollation[attnum-1], locinfo);
+ fmgr_info_set_collation(irel->rd_indcollation[attnum - 1], locinfo);
}
return locinfo;
diff --git a/src/backend/access/nbtree/nbtinsert.c b/src/backend/access/nbtree/nbtinsert.c
index 0dd745f19a..219f94fd0d 100644
--- a/src/backend/access/nbtree/nbtinsert.c
+++ b/src/backend/access/nbtree/nbtinsert.c
@@ -179,8 +179,8 @@ top:
* The only conflict predicate locking cares about for indexes is when
* an index tuple insert conflicts with an existing lock. Since the
* actual location of the insert is hard to predict because of the
- * random search used to prevent O(N^2) performance when there are many
- * duplicate entries, we can just use the "first valid" page.
+ * random search used to prevent O(N^2) performance when there are
+ * many duplicate entries, we can just use the "first valid" page.
*/
CheckForSerializableConflictIn(rel, NULL, buf);
/* do the insertion */
@@ -915,13 +915,13 @@ _bt_split(Relation rel, Buffer buf, OffsetNumber firstright,
/*
* origpage is the original page to be split. leftpage is a temporary
* buffer that receives the left-sibling data, which will be copied back
- * into origpage on success. rightpage is the new page that receives
- * the right-sibling data. If we fail before reaching the critical
- * section, origpage hasn't been modified and leftpage is only workspace.
- * In principle we shouldn't need to worry about rightpage either,
- * because it hasn't been linked into the btree page structure; but to
- * avoid leaving possibly-confusing junk behind, we are careful to rewrite
- * rightpage as zeroes before throwing any error.
+ * into origpage on success. rightpage is the new page that receives the
+ * right-sibling data. If we fail before reaching the critical section,
+ * origpage hasn't been modified and leftpage is only workspace. In
+ * principle we shouldn't need to worry about rightpage either, because it
+ * hasn't been linked into the btree page structure; but to avoid leaving
+ * possibly-confusing junk behind, we are careful to rewrite rightpage as
+ * zeroes before throwing any error.
*/
origpage = BufferGetPage(buf);
leftpage = PageGetTempPage(origpage);
@@ -1118,7 +1118,7 @@ _bt_split(Relation rel, Buffer buf, OffsetNumber firstright,
{
memset(rightpage, 0, BufferGetPageSize(rbuf));
elog(ERROR, "right sibling's left-link doesn't match: "
- "block %u links to %u instead of expected %u in index \"%s\"",
+ "block %u links to %u instead of expected %u in index \"%s\"",
oopaque->btpo_next, sopaque->btpo_prev, origpagenumber,
RelationGetRelationName(rel));
}
diff --git a/src/backend/access/nbtree/nbtpage.c b/src/backend/access/nbtree/nbtpage.c
index 27964455f7..2477736281 100644
--- a/src/backend/access/nbtree/nbtpage.c
+++ b/src/backend/access/nbtree/nbtpage.c
@@ -1268,9 +1268,9 @@ _bt_pagedel(Relation rel, Buffer buf, BTStack stack)
/*
* Check that the parent-page index items we're about to delete/overwrite
- * contain what we expect. This can fail if the index has become
- * corrupt for some reason. We want to throw any error before entering
- * the critical section --- otherwise it'd be a PANIC.
+ * contain what we expect. This can fail if the index has become corrupt
+ * for some reason. We want to throw any error before entering the
+ * critical section --- otherwise it'd be a PANIC.
*
* The test on the target item is just an Assert because _bt_getstackbuf
* should have guaranteed it has the expected contents. The test on the
diff --git a/src/backend/access/nbtree/nbtree.c b/src/backend/access/nbtree/nbtree.c
index 7a0e1a9c25..6a7ddd7db4 100644
--- a/src/backend/access/nbtree/nbtree.c
+++ b/src/backend/access/nbtree/nbtree.c
@@ -220,7 +220,7 @@ btbuildempty(PG_FUNCTION_ARGS)
metapage = (Page) palloc(BLCKSZ);
_bt_initmetapage(metapage, P_NONE, 0);
- /* Write the page. If archiving/streaming, XLOG it. */
+ /* Write the page. If archiving/streaming, XLOG it. */
smgrwrite(index->rd_smgr, INIT_FORKNUM, BTREE_METAPAGE,
(char *) metapage, true);
if (XLogIsNeeded())
@@ -403,6 +403,7 @@ btrescan(PG_FUNCTION_ARGS)
{
IndexScanDesc scan = (IndexScanDesc) PG_GETARG_POINTER(0);
ScanKey scankey = (ScanKey) PG_GETARG_POINTER(1);
+
/* remaining arguments are ignored */
BTScanOpaque so = (BTScanOpaque) scan->opaque;
diff --git a/src/backend/access/nbtree/nbtsearch.c b/src/backend/access/nbtree/nbtsearch.c
index cb78a1bae1..91f8cadea5 100644
--- a/src/backend/access/nbtree/nbtsearch.c
+++ b/src/backend/access/nbtree/nbtsearch.c
@@ -65,7 +65,7 @@ _bt_search(Relation rel, int keysz, ScanKey scankey, bool nextkey,
/* If index is empty and access = BT_READ, no root page is created. */
if (!BufferIsValid(*bufP))
{
- PredicateLockRelation(rel); /* Nothing finer to lock exists. */
+ PredicateLockRelation(rel); /* Nothing finer to lock exists. */
return (BTStack) NULL;
}
@@ -1364,7 +1364,7 @@ _bt_get_endpoint(Relation rel, uint32 level, bool rightmost)
if (!BufferIsValid(buf))
{
/* empty index... */
- PredicateLockRelation(rel); /* Nothing finer to lock exists. */
+ PredicateLockRelation(rel); /* Nothing finer to lock exists. */
return InvalidBuffer;
}
@@ -1444,7 +1444,7 @@ _bt_endpoint(IndexScanDesc scan, ScanDirection dir)
if (!BufferIsValid(buf))
{
/* empty index... */
- PredicateLockRelation(rel); /* Nothing finer to lock exists. */
+ PredicateLockRelation(rel); /* Nothing finer to lock exists. */
so->currPos.buf = InvalidBuffer;
return false;
}
diff --git a/src/backend/access/nbtree/nbtsort.c b/src/backend/access/nbtree/nbtsort.c
index fd0e86a6aa..256a7f9f98 100644
--- a/src/backend/access/nbtree/nbtsort.c
+++ b/src/backend/access/nbtree/nbtsort.c
@@ -799,7 +799,7 @@ _bt_load(BTWriteState *wstate, BTSpool *btspool, BTSpool *btspool2)
/*
* If the index is WAL-logged, we must fsync it down to disk before it's
- * safe to commit the transaction. (For a non-WAL-logged index we don't
+ * safe to commit the transaction. (For a non-WAL-logged index we don't
* care since the index will be uninteresting after a crash anyway.)
*
* It's obvious that we must do this when not WAL-logging the build. It's
diff --git a/src/backend/access/nbtree/nbtutils.c b/src/backend/access/nbtree/nbtutils.c
index add932d942..d448ba6a50 100644
--- a/src/backend/access/nbtree/nbtutils.c
+++ b/src/backend/access/nbtree/nbtutils.c
@@ -70,8 +70,8 @@ _bt_mkscankey(Relation rel, IndexTuple itup)
/*
* We can use the cached (default) support procs since no cross-type
- * comparison can be needed. The cached support proc entries have
- * the right collation for the index, too.
+ * comparison can be needed. The cached support proc entries have the
+ * right collation for the index, too.
*/
procinfo = index_getprocinfo(rel, i + 1, BTORDER_PROC);
arg = index_getattr(itup, i + 1, itupdesc, &null);
@@ -120,8 +120,8 @@ _bt_mkscankey_nodata(Relation rel)
/*
* We can use the cached (default) support procs since no cross-type
- * comparison can be needed. The cached support proc entries have
- * the right collation for the index, too.
+ * comparison can be needed. The cached support proc entries have the
+ * right collation for the index, too.
*/
procinfo = index_getprocinfo(rel, i + 1, BTORDER_PROC);
flags = SK_ISNULL | (indoption[i] << SK_BT_INDOPTION_SHIFT);
diff --git a/src/backend/access/transam/twophase.c b/src/backend/access/transam/twophase.c
index 729c7b72e0..281268120e 100644
--- a/src/backend/access/transam/twophase.c
+++ b/src/backend/access/transam/twophase.c
@@ -120,7 +120,7 @@ typedef struct GlobalTransactionData
TransactionId locking_xid; /* top-level XID of backend working on xact */
bool valid; /* TRUE if fully prepared */
char gid[GIDSIZE]; /* The GID assigned to the prepared xact */
-} GlobalTransactionData;
+} GlobalTransactionData;
/*
* Two Phase Commit shared state. Access to this struct is protected
@@ -1029,8 +1029,8 @@ EndPrepare(GlobalTransaction gxact)
/* If we crash now, we have prepared: WAL replay will fix things */
/*
- * Wake up all walsenders to send WAL up to the PREPARE record
- * immediately if replication is enabled
+ * Wake up all walsenders to send WAL up to the PREPARE record immediately
+ * if replication is enabled
*/
if (max_wal_senders > 0)
WalSndWakeup();
@@ -2043,8 +2043,8 @@ RecordTransactionCommitPrepared(TransactionId xid,
/*
* Wait for synchronous replication, if required.
*
- * Note that at this stage we have marked clog, but still show as
- * running in the procarray and continue to hold locks.
+ * Note that at this stage we have marked clog, but still show as running
+ * in the procarray and continue to hold locks.
*/
SyncRepWaitForLSN(recptr);
}
@@ -2130,8 +2130,8 @@ RecordTransactionAbortPrepared(TransactionId xid,
/*
* Wait for synchronous replication, if required.
*
- * Note that at this stage we have marked clog, but still show as
- * running in the procarray and continue to hold locks.
+ * Note that at this stage we have marked clog, but still show as running
+ * in the procarray and continue to hold locks.
*/
SyncRepWaitForLSN(recptr);
}
diff --git a/src/backend/access/transam/varsup.c b/src/backend/access/transam/varsup.c
index a828b3de48..500335bd6f 100644
--- a/src/backend/access/transam/varsup.c
+++ b/src/backend/access/transam/varsup.c
@@ -355,9 +355,9 @@ SetTransactionIdLimit(TransactionId oldest_datfrozenxid, Oid oldest_datoid)
char *oldest_datname;
/*
- * We can be called when not inside a transaction, for example
- * during StartupXLOG(). In such a case we cannot do database
- * access, so we must just report the oldest DB's OID.
+ * We can be called when not inside a transaction, for example during
+ * StartupXLOG(). In such a case we cannot do database access, so we
+ * must just report the oldest DB's OID.
*
* Note: it's also possible that get_database_name fails and returns
* NULL, for example because the database just got dropped. We'll
diff --git a/src/backend/access/transam/xact.c b/src/backend/access/transam/xact.c
index 55aee87910..8a4c4eccd7 100644
--- a/src/backend/access/transam/xact.c
+++ b/src/backend/access/transam/xact.c
@@ -420,11 +420,11 @@ AssignTransactionId(TransactionState s)
*/
if (isSubXact && !TransactionIdIsValid(s->parent->transactionId))
{
- TransactionState p = s->parent;
- TransactionState *parents;
- size_t parentOffset = 0;
+ TransactionState p = s->parent;
+ TransactionState *parents;
+ size_t parentOffset = 0;
- parents = palloc(sizeof(TransactionState) * s->nestingLevel);
+ parents = palloc(sizeof(TransactionState) * s->nestingLevel);
while (p != NULL && !TransactionIdIsValid(p->transactionId))
{
parents[parentOffset++] = p;
@@ -432,8 +432,8 @@ AssignTransactionId(TransactionState s)
}
/*
- * This is technically a recursive call, but the recursion will
- * never be more than one layer deep.
+ * This is technically a recursive call, but the recursion will never
+ * be more than one layer deep.
*/
while (parentOffset != 0)
AssignTransactionId(parents[--parentOffset]);
@@ -1037,16 +1037,17 @@ RecordTransactionCommit(void)
/*
* Check if we want to commit asynchronously. We can allow the XLOG flush
* to happen asynchronously if synchronous_commit=off, or if the current
- * transaction has not performed any WAL-logged operation. The latter case
- * can arise if the current transaction wrote only to temporary and/or
- * unlogged tables. In case of a crash, the loss of such a transaction
- * will be irrelevant since temp tables will be lost anyway, and unlogged
- * tables will be truncated. (Given the foregoing, you might think that it
- * would be unnecessary to emit the XLOG record at all in this case, but we
- * don't currently try to do that. It would certainly cause problems at
- * least in Hot Standby mode, where the KnownAssignedXids machinery
- * requires tracking every XID assignment. It might be OK to skip it only
- * when wal_level < hot_standby, but for now we don't.)
+ * transaction has not performed any WAL-logged operation. The latter
+ * case can arise if the current transaction wrote only to temporary
+ * and/or unlogged tables. In case of a crash, the loss of such a
+ * transaction will be irrelevant since temp tables will be lost anyway,
+ * and unlogged tables will be truncated. (Given the foregoing, you might
+ * think that it would be unnecessary to emit the XLOG record at all in
+ * this case, but we don't currently try to do that. It would certainly
+ * cause problems at least in Hot Standby mode, where the
+ * KnownAssignedXids machinery requires tracking every XID assignment. It
+ * might be OK to skip it only when wal_level < hot_standby, but for now
+ * we don't.)
*
* However, if we're doing cleanup of any non-temp rels or committing any
* command that wanted to force sync commit, then we must flush XLOG
@@ -1130,8 +1131,8 @@ RecordTransactionCommit(void)
/*
* Wait for synchronous replication, if required.
*
- * Note that at this stage we have marked clog, but still show as
- * running in the procarray and continue to hold locks.
+ * Note that at this stage we have marked clog, but still show as running
+ * in the procarray and continue to hold locks.
*/
SyncRepWaitForLSN(XactLastRecEnd);
@@ -1785,10 +1786,10 @@ CommitTransaction(void)
}
/*
- * The remaining actions cannot call any user-defined code, so it's
- * safe to start shutting down within-transaction services. But note
- * that most of this stuff could still throw an error, which would
- * switch us into the transaction-abort path.
+ * The remaining actions cannot call any user-defined code, so it's safe
+ * to start shutting down within-transaction services. But note that most
+ * of this stuff could still throw an error, which would switch us into
+ * the transaction-abort path.
*/
/* Shut down the deferred-trigger manager */
@@ -1805,8 +1806,8 @@ CommitTransaction(void)
/*
* Mark serializable transaction as complete for predicate locking
- * purposes. This should be done as late as we can put it and still
- * allow errors to be raised for failure patterns found at commit.
+ * purposes. This should be done as late as we can put it and still allow
+ * errors to be raised for failure patterns found at commit.
*/
PreCommit_CheckForSerializationFailure();
@@ -1988,10 +1989,10 @@ PrepareTransaction(void)
}
/*
- * The remaining actions cannot call any user-defined code, so it's
- * safe to start shutting down within-transaction services. But note
- * that most of this stuff could still throw an error, which would
- * switch us into the transaction-abort path.
+ * The remaining actions cannot call any user-defined code, so it's safe
+ * to start shutting down within-transaction services. But note that most
+ * of this stuff could still throw an error, which would switch us into
+ * the transaction-abort path.
*/
/* Shut down the deferred-trigger manager */
@@ -2008,8 +2009,8 @@ PrepareTransaction(void)
/*
* Mark serializable transaction as complete for predicate locking
- * purposes. This should be done as late as we can put it and still
- * allow errors to be raised for failure patterns found at commit.
+ * purposes. This should be done as late as we can put it and still allow
+ * errors to be raised for failure patterns found at commit.
*/
PreCommit_CheckForSerializationFailure();
diff --git a/src/backend/access/transam/xlog.c b/src/backend/access/transam/xlog.c
index b31c79ebbd..9c45759661 100644
--- a/src/backend/access/transam/xlog.c
+++ b/src/backend/access/transam/xlog.c
@@ -64,7 +64,7 @@
/* File path names (all relative to $PGDATA) */
#define RECOVERY_COMMAND_FILE "recovery.conf"
#define RECOVERY_COMMAND_DONE "recovery.done"
-#define PROMOTE_SIGNAL_FILE "promote"
+#define PROMOTE_SIGNAL_FILE "promote"
/* User-settable parameters */
@@ -160,6 +160,7 @@ static XLogRecPtr LastRec;
* known, need to check the shared state".
*/
static bool LocalRecoveryInProgress = true;
+
/*
* Local copy of SharedHotStandbyActive variable. False actually means "not
* known, need to check the shared state".
@@ -355,10 +356,9 @@ typedef struct XLogCtlInsert
/*
* exclusiveBackup is true if a backup started with pg_start_backup() is
* in progress, and nonExclusiveBackups is a counter indicating the number
- * of streaming base backups currently in progress. forcePageWrites is
- * set to true when either of these is non-zero. lastBackupStart is the
- * latest checkpoint redo location used as a starting point for an online
- * backup.
+ * of streaming base backups currently in progress. forcePageWrites is set
+ * to true when either of these is non-zero. lastBackupStart is the latest
+ * checkpoint redo location used as a starting point for an online backup.
*/
bool exclusiveBackup;
int nonExclusiveBackups;
@@ -388,7 +388,7 @@ typedef struct XLogCtlData
XLogwrtResult LogwrtResult;
uint32 ckptXidEpoch; /* nextXID & epoch of latest checkpoint */
TransactionId ckptXid;
- XLogRecPtr asyncXactLSN; /* LSN of newest async commit/abort */
+ XLogRecPtr asyncXactLSN; /* LSN of newest async commit/abort */
uint32 lastRemovedLog; /* latest removed/recycled XLOG segment */
uint32 lastRemovedSeg;
@@ -425,9 +425,9 @@ typedef struct XLogCtlData
bool SharedHotStandbyActive;
/*
- * recoveryWakeupLatch is used to wake up the startup process to
- * continue WAL replay, if it is waiting for WAL to arrive or failover
- * trigger file to appear.
+ * recoveryWakeupLatch is used to wake up the startup process to continue
+ * WAL replay, if it is waiting for WAL to arrive or failover trigger file
+ * to appear.
*/
Latch recoveryWakeupLatch;
@@ -576,7 +576,7 @@ typedef struct xl_parameter_change
/* logs restore point */
typedef struct xl_restore_point
{
- TimestampTz rp_time;
+ TimestampTz rp_time;
char rp_name[MAXFNAMELEN];
} xl_restore_point;
@@ -4272,27 +4272,29 @@ existsTimeLineHistory(TimeLineID probeTLI)
static bool
rescanLatestTimeLine(void)
{
- TimeLineID newtarget;
+ TimeLineID newtarget;
+
newtarget = findNewestTimeLine(recoveryTargetTLI);
if (newtarget != recoveryTargetTLI)
{
/*
* Determine the list of expected TLIs for the new TLI
*/
- List *newExpectedTLIs;
+ List *newExpectedTLIs;
+
newExpectedTLIs = readTimeLineHistory(newtarget);
/*
- * If the current timeline is not part of the history of the
- * new timeline, we cannot proceed to it.
+ * If the current timeline is not part of the history of the new
+ * timeline, we cannot proceed to it.
*
* XXX This isn't foolproof: The new timeline might have forked from
* the current one, but before the current recovery location. In that
* case we will still switch to the new timeline and proceed replaying
* from it even though the history doesn't match what we already
* replayed. That's not good. We will likely notice at the next online
- * checkpoint, as the TLI won't match what we expected, but it's
- * not guaranteed. The admin needs to make sure that doesn't happen.
+ * checkpoint, as the TLI won't match what we expected, but it's not
+ * guaranteed. The admin needs to make sure that doesn't happen.
*/
if (!list_member_int(newExpectedTLIs,
(int) recoveryTargetTLI))
@@ -4480,7 +4482,7 @@ writeTimeLineHistory(TimeLineID newTLI, TimeLineID parentTLI,
timestamptz_to_str(recoveryStopTime));
else if (recoveryTarget == RECOVERY_TARGET_NAME)
snprintf(buffer, sizeof(buffer),
- "%s%u\t%s\tat restore point \"%s\"\n",
+ "%s%u\t%s\tat restore point \"%s\"\n",
(srcfd < 0) ? "" : "\n",
parentTLI,
xlogfname,
@@ -4921,7 +4923,7 @@ check_wal_buffers(int *newval, void **extra, GucSource source)
{
/*
* If we haven't yet changed the boot_val default of -1, just let it
- * be. We'll fix it when XLOGShmemSize is called.
+ * be. We'll fix it when XLOGShmemSize is called.
*/
if (XLOGbuffers == -1)
return true;
@@ -4954,8 +4956,8 @@ XLOGShmemSize(void)
/*
* If the value of wal_buffers is -1, use the preferred auto-tune value.
* This isn't an amazingly clean place to do this, but we must wait till
- * NBuffers has received its final value, and must do it before using
- * the value of XLOGbuffers to do anything important.
+ * NBuffers has received its final value, and must do it before using the
+ * value of XLOGbuffers to do anything important.
*/
if (XLOGbuffers == -1)
{
@@ -5086,9 +5088,9 @@ BootStrapXLOG(void)
/*
* Set up information for the initial checkpoint record
*
- * The initial checkpoint record is written to the beginning of the
- * WAL segment with logid=0 logseg=1. The very first WAL segment, 0/0, is
- * not used, so that we can use 0/0 to mean "before any valid WAL segment".
+ * The initial checkpoint record is written to the beginning of the WAL
+ * segment with logid=0 logseg=1. The very first WAL segment, 0/0, is not
+ * used, so that we can use 0/0 to mean "before any valid WAL segment".
*/
checkPoint.redo.xlogid = 0;
checkPoint.redo.xrecoff = XLogSegSize + SizeOfXLogLongPHD;
@@ -5219,8 +5221,8 @@ readRecoveryCommandFile(void)
TimeLineID rtli = 0;
bool rtliGiven = false;
ConfigVariable *item,
- *head = NULL,
- *tail = NULL;
+ *head = NULL,
+ *tail = NULL;
fd = AllocateFile(RECOVERY_COMMAND_FILE, "r");
if (fd == NULL)
@@ -5236,7 +5238,7 @@ readRecoveryCommandFile(void)
/*
* Since we're asking ParseConfigFp() to error out at FATAL, there's no
* need to check the return value.
- */
+ */
ParseConfigFp(fd, RECOVERY_COMMAND_FILE, 0, FATAL, &head, &tail);
for (item = head; item; item = item->next)
@@ -5312,7 +5314,7 @@ readRecoveryCommandFile(void)
* this overrides recovery_target_time
*/
if (recoveryTarget == RECOVERY_TARGET_XID ||
- recoveryTarget == RECOVERY_TARGET_NAME)
+ recoveryTarget == RECOVERY_TARGET_NAME)
continue;
recoveryTarget = RECOVERY_TARGET_TIME;
@@ -5321,7 +5323,7 @@ readRecoveryCommandFile(void)
*/
recoveryTargetTime =
DatumGetTimestampTz(DirectFunctionCall3(timestamptz_in,
- CStringGetDatum(item->value),
+ CStringGetDatum(item->value),
ObjectIdGetDatum(InvalidOid),
Int32GetDatum(-1)));
ereport(DEBUG2,
@@ -5610,8 +5612,8 @@ recoveryStopsHere(XLogRecord *record, bool *includeThis)
if (recoveryTarget == RECOVERY_TARGET_UNSET)
{
/*
- * Save timestamp of latest transaction commit/abort if this is
- * a transaction record
+ * Save timestamp of latest transaction commit/abort if this is a
+ * transaction record
*/
if (record->xl_rmid == RM_XACT_ID)
SetLatestXTime(recordXtime);
@@ -5636,8 +5638,8 @@ recoveryStopsHere(XLogRecord *record, bool *includeThis)
else if (recoveryTarget == RECOVERY_TARGET_NAME)
{
/*
- * There can be many restore points that share the same name, so we stop
- * at the first one
+ * There can be many restore points that share the same name, so we
+ * stop at the first one
*/
stopsHere = (strcmp(recordRPName, recoveryTargetName) == 0);
@@ -5699,14 +5701,14 @@ recoveryStopsHere(XLogRecord *record, bool *includeThis)
strncpy(recoveryStopName, recordRPName, MAXFNAMELEN);
ereport(LOG,
- (errmsg("recovery stopping at restore point \"%s\", time %s",
- recoveryStopName,
- timestamptz_to_str(recoveryStopTime))));
+ (errmsg("recovery stopping at restore point \"%s\", time %s",
+ recoveryStopName,
+ timestamptz_to_str(recoveryStopTime))));
}
/*
- * Note that if we use a RECOVERY_TARGET_TIME then we can stop
- * at a restore point since they are timestamped, though the latest
+ * Note that if we use a RECOVERY_TARGET_TIME then we can stop at a
+ * restore point since they are timestamped, though the latest
* transaction time is not updated.
*/
if (record->xl_rmid == RM_XACT_ID && recoveryStopAfter)
@@ -5732,7 +5734,7 @@ recoveryPausesHere(void)
while (RecoveryIsPaused())
{
- pg_usleep(1000000L); /* 1000 ms */
+ pg_usleep(1000000L); /* 1000 ms */
HandleStartupProcInterrupts();
}
}
@@ -5742,7 +5744,7 @@ RecoveryIsPaused(void)
{
/* use volatile pointer to prevent code rearrangement */
volatile XLogCtlData *xlogctl = XLogCtl;
- bool recoveryPause;
+ bool recoveryPause;
SpinLockAcquire(&xlogctl->info_lck);
recoveryPause = xlogctl->recoveryPause;
@@ -5771,7 +5773,7 @@ pg_xlog_replay_pause(PG_FUNCTION_ARGS)
if (!superuser())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- (errmsg("must be superuser to control recovery"))));
+ (errmsg("must be superuser to control recovery"))));
if (!RecoveryInProgress())
ereport(ERROR,
@@ -5793,7 +5795,7 @@ pg_xlog_replay_resume(PG_FUNCTION_ARGS)
if (!superuser())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- (errmsg("must be superuser to control recovery"))));
+ (errmsg("must be superuser to control recovery"))));
if (!RecoveryInProgress())
ereport(ERROR,
@@ -5815,7 +5817,7 @@ pg_is_xlog_replay_paused(PG_FUNCTION_ARGS)
if (!superuser())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- (errmsg("must be superuser to control recovery"))));
+ (errmsg("must be superuser to control recovery"))));
if (!RecoveryInProgress())
ereport(ERROR,
@@ -5870,7 +5872,7 @@ GetLatestXTime(void)
Datum
pg_last_xact_replay_timestamp(PG_FUNCTION_ARGS)
{
- TimestampTz xtime;
+ TimestampTz xtime;
xtime = GetLatestXTime();
if (xtime == 0)
@@ -6132,10 +6134,10 @@ StartupXLOG(void)
InRecovery = true; /* force recovery even if SHUTDOWNED */
/*
- * Make sure that REDO location exists. This may not be
- * the case if there was a crash during an online backup,
- * which left a backup_label around that references a WAL
- * segment that's already been archived.
+ * Make sure that REDO location exists. This may not be the case
+ * if there was a crash during an online backup, which left a
+ * backup_label around that references a WAL segment that's
+ * already been archived.
*/
if (XLByteLT(checkPoint.redo, checkPointLoc))
{
@@ -6150,7 +6152,7 @@ StartupXLOG(void)
ereport(FATAL,
(errmsg("could not locate required checkpoint record"),
errhint("If you are not restoring from a backup, try removing the file \"%s/backup_label\".", DataDir)));
- wasShutdown = false; /* keep compiler quiet */
+ wasShutdown = false; /* keep compiler quiet */
}
/* set flag to delete it later */
haveBackupLabel = true;
@@ -6330,9 +6332,9 @@ StartupXLOG(void)
/*
* We're in recovery, so unlogged relations relations may be trashed
- * and must be reset. This should be done BEFORE allowing Hot
- * Standby connections, so that read-only backends don't try to
- * read whatever garbage is left over from before.
+ * and must be reset. This should be done BEFORE allowing Hot Standby
+ * connections, so that read-only backends don't try to read whatever
+ * garbage is left over from before.
*/
ResetUnloggedRelations(UNLOGGED_RELATION_CLEANUP);
@@ -6517,7 +6519,8 @@ StartupXLOG(void)
if (recoveryStopsHere(record, &recoveryApply))
{
/*
- * Pause only if users can connect to send a resume message
+ * Pause only if users can connect to send a resume
+ * message
*/
if (recoveryPauseAtTarget && standbyState == STANDBY_SNAPSHOT_READY)
{
@@ -7003,8 +7006,8 @@ HotStandbyActive(void)
{
/*
* We check shared state each time only until Hot Standby is active. We
- * can't de-activate Hot Standby, so there's no need to keep checking after
- * the shared variable has once been seen true.
+ * can't de-activate Hot Standby, so there's no need to keep checking
+ * after the shared variable has once been seen true.
*/
if (LocalHotStandbyActive)
return true;
@@ -7429,14 +7432,14 @@ LogCheckpointEnd(bool restartpoint)
*/
longest_secs = (long) (CheckpointStats.ckpt_longest_sync / 1000000);
longest_usecs = CheckpointStats.ckpt_longest_sync -
- (uint64) longest_secs * 1000000;
+ (uint64) longest_secs *1000000;
average_sync_time = 0;
- if (CheckpointStats.ckpt_sync_rels > 0)
+ if (CheckpointStats.ckpt_sync_rels > 0)
average_sync_time = CheckpointStats.ckpt_agg_sync_time /
CheckpointStats.ckpt_sync_rels;
average_secs = (long) (average_sync_time / 1000000);
- average_usecs = average_sync_time - (uint64) average_secs * 1000000;
+ average_usecs = average_sync_time - (uint64) average_secs *1000000;
if (restartpoint)
elog(LOG, "restartpoint complete: wrote %d buffers (%.1f%%); "
@@ -8241,9 +8244,9 @@ RequestXLogSwitch(void)
XLogRecPtr
XLogRestorePoint(const char *rpName)
{
- XLogRecPtr RecPtr;
- XLogRecData rdata;
- xl_restore_point xlrec;
+ XLogRecPtr RecPtr;
+ XLogRecData rdata;
+ xl_restore_point xlrec;
xlrec.rp_time = GetCurrentTimestamp();
strncpy(xlrec.rp_name, rpName, MAXFNAMELEN);
@@ -8257,7 +8260,7 @@ XLogRestorePoint(const char *rpName)
ereport(LOG,
(errmsg("restore point \"%s\" created at %X/%X",
- rpName, RecPtr.xlogid, RecPtr.xrecoff)));
+ rpName, RecPtr.xlogid, RecPtr.xrecoff)));
return RecPtr;
}
@@ -8643,7 +8646,7 @@ get_sync_bit(int method)
/*
* Optimize writes by bypassing kernel cache with O_DIRECT when using
- * O_SYNC/O_FSYNC and O_DSYNC. But only if archiving and streaming are
+ * O_SYNC/O_FSYNC and O_DSYNC. But only if archiving and streaming are
* disabled, otherwise the archive command or walsender process will read
* the WAL soon after writing it, which is guaranteed to cause a physical
* read if we bypassed the kernel cache. We also skip the
@@ -8775,7 +8778,7 @@ pg_start_backup(PG_FUNCTION_ARGS)
text *backupid = PG_GETARG_TEXT_P(0);
bool fast = PG_GETARG_BOOL(1);
char *backupidstr;
- XLogRecPtr startpoint;
+ XLogRecPtr startpoint;
char startxlogstr[MAXFNAMELEN];
backupidstr = text_to_cstring(backupid);
@@ -8791,7 +8794,7 @@ pg_start_backup(PG_FUNCTION_ARGS)
* do_pg_start_backup is the workhorse of the user-visible pg_start_backup()
* function. It creates the necessary starting checkpoint and constructs the
* backup label file.
- *
+ *
* There are two kind of backups: exclusive and non-exclusive. An exclusive
* backup is started with pg_start_backup(), and there can be only one active
* at a time. The backup label file of an exclusive backup is written to
@@ -8826,7 +8829,7 @@ do_pg_start_backup(const char *backupidstr, bool fast, char **labelfile)
if (!superuser() && !is_authenticated_user_replication_role())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- errmsg("must be superuser or replication role to run a backup")));
+ errmsg("must be superuser or replication role to run a backup")));
if (RecoveryInProgress())
ereport(ERROR,
@@ -8897,25 +8900,27 @@ do_pg_start_backup(const char *backupidstr, bool fast, char **labelfile)
/* Ensure we release forcePageWrites if fail below */
PG_ENSURE_ERROR_CLEANUP(pg_start_backup_callback, (Datum) BoolGetDatum(exclusive));
{
- bool gotUniqueStartpoint = false;
+ bool gotUniqueStartpoint = false;
+
do
{
/*
* Force a CHECKPOINT. Aside from being necessary to prevent torn
- * page problems, this guarantees that two successive backup runs will
- * have different checkpoint positions and hence different history
- * file names, even if nothing happened in between.
+ * page problems, this guarantees that two successive backup runs
+ * will have different checkpoint positions and hence different
+ * history file names, even if nothing happened in between.
*
- * We use CHECKPOINT_IMMEDIATE only if requested by user (via passing
- * fast = true). Otherwise this can take awhile.
+ * We use CHECKPOINT_IMMEDIATE only if requested by user (via
+ * passing fast = true). Otherwise this can take awhile.
*/
RequestCheckpoint(CHECKPOINT_FORCE | CHECKPOINT_WAIT |
(fast ? CHECKPOINT_IMMEDIATE : 0));
/*
- * Now we need to fetch the checkpoint record location, and also its
- * REDO pointer. The oldest point in WAL that would be needed to
- * restore starting from the checkpoint is precisely the REDO pointer.
+ * Now we need to fetch the checkpoint record location, and also
+ * its REDO pointer. The oldest point in WAL that would be needed
+ * to restore starting from the checkpoint is precisely the REDO
+ * pointer.
*/
LWLockAcquire(ControlFileLock, LW_SHARED);
checkpointloc = ControlFile->checkPoint;
@@ -8923,16 +8928,15 @@ do_pg_start_backup(const char *backupidstr, bool fast, char **labelfile)
LWLockRelease(ControlFileLock);
/*
- * If two base backups are started at the same time (in WAL
- * sender processes), we need to make sure that they use
- * different checkpoints as starting locations, because we use
- * the starting WAL location as a unique identifier for the base
- * backup in the end-of-backup WAL record and when we write the
- * backup history file. Perhaps it would be better generate a
- * separate unique ID for each backup instead of forcing another
- * checkpoint, but taking a checkpoint right after another is
- * not that expensive either because only few buffers have been
- * dirtied yet.
+ * If two base backups are started at the same time (in WAL sender
+ * processes), we need to make sure that they use different
+ * checkpoints as starting locations, because we use the starting
+ * WAL location as a unique identifier for the base backup in the
+ * end-of-backup WAL record and when we write the backup history
+ * file. Perhaps it would be better generate a separate unique ID
+ * for each backup instead of forcing another checkpoint, but
+ * taking a checkpoint right after another is not that expensive
+ * either because only few buffers have been dirtied yet.
*/
LWLockAcquire(WALInsertLock, LW_SHARED);
if (XLByteLT(XLogCtl->Insert.lastBackupStart, startpoint))
@@ -8941,13 +8945,13 @@ do_pg_start_backup(const char *backupidstr, bool fast, char **labelfile)
gotUniqueStartpoint = true;
}
LWLockRelease(WALInsertLock);
- } while(!gotUniqueStartpoint);
+ } while (!gotUniqueStartpoint);
XLByteToSeg(startpoint, _logId, _logSeg);
XLogFileName(xlogfilename, ThisTimeLineID, _logId, _logSeg);
/*
- * Construct backup label file
+ * Construct backup label file
*/
initStringInfo(&labelfbuf);
@@ -8970,8 +8974,8 @@ do_pg_start_backup(const char *backupidstr, bool fast, char **labelfile)
{
/*
* Check for existing backup label --- implies a backup is already
- * running. (XXX given that we checked exclusiveBackup above, maybe
- * it would be OK to just unlink any such label file?)
+ * running. (XXX given that we checked exclusiveBackup above,
+ * maybe it would be OK to just unlink any such label file?)
*/
if (stat(BACKUP_LABEL_FILE, &stat_buf) != 0)
{
@@ -9018,7 +9022,7 @@ do_pg_start_backup(const char *backupidstr, bool fast, char **labelfile)
static void
pg_start_backup_callback(int code, Datum arg)
{
- bool exclusive = DatumGetBool(arg);
+ bool exclusive = DatumGetBool(arg);
/* Update backup counters and forcePageWrites on failure */
LWLockAcquire(WALInsertLock, LW_EXCLUSIVE);
@@ -9101,7 +9105,7 @@ do_pg_stop_backup(char *labelfile, bool waitforarchive)
if (!superuser() && !is_authenticated_user_replication_role())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- (errmsg("must be superuser or replication role to run a backup"))));
+ (errmsg("must be superuser or replication role to run a backup"))));
if (RecoveryInProgress())
ereport(ERROR,
@@ -9145,8 +9149,8 @@ do_pg_stop_backup(char *labelfile, bool waitforarchive)
/*
* Read the existing label file into memory.
*/
- struct stat statbuf;
- int r;
+ struct stat statbuf;
+ int r;
if (stat(BACKUP_LABEL_FILE, &statbuf))
{
@@ -9197,7 +9201,7 @@ do_pg_stop_backup(char *labelfile, bool waitforarchive)
ereport(ERROR,
(errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
errmsg("invalid data in file \"%s\"", BACKUP_LABEL_FILE)));
- remaining = strchr(labelfile, '\n') + 1; /* %n is not portable enough */
+ remaining = strchr(labelfile, '\n') + 1; /* %n is not portable enough */
/*
* Write the backup-end xlog record
@@ -9388,8 +9392,8 @@ pg_switch_xlog(PG_FUNCTION_ARGS)
Datum
pg_create_restore_point(PG_FUNCTION_ARGS)
{
- text *restore_name = PG_GETARG_TEXT_P(0);
- char *restore_name_str;
+ text *restore_name = PG_GETARG_TEXT_P(0);
+ char *restore_name_str;
XLogRecPtr restorepoint;
char location[MAXFNAMELEN];
@@ -9407,7 +9411,7 @@ pg_create_restore_point(PG_FUNCTION_ARGS)
if (!XLogIsNeeded())
ereport(ERROR,
(errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
- errmsg("WAL level not sufficient for creating a restore point"),
+ errmsg("WAL level not sufficient for creating a restore point"),
errhint("wal_level must be set to \"archive\" or \"hot_standby\" at server start.")));
restore_name_str = text_to_cstring(restore_name);
@@ -9423,7 +9427,7 @@ pg_create_restore_point(PG_FUNCTION_ARGS)
* As a convenience, return the WAL location of the restore point record
*/
snprintf(location, sizeof(location), "%X/%X",
- restorepoint.xlogid, restorepoint.xrecoff);
+ restorepoint.xlogid, restorepoint.xrecoff);
PG_RETURN_TEXT_P(cstring_to_text(location));
}
@@ -10177,8 +10181,8 @@ retry:
}
/*
- * If it hasn't been long since last attempt, sleep
- * to avoid busy-waiting.
+ * If it hasn't been long since last attempt, sleep to
+ * avoid busy-waiting.
*/
now = (pg_time_t) time(NULL);
if ((now - last_fail_time) < 5)
@@ -10404,7 +10408,7 @@ static bool
CheckForStandbyTrigger(void)
{
struct stat stat_buf;
- static bool triggered = false;
+ static bool triggered = false;
if (triggered)
return true;
@@ -10446,8 +10450,8 @@ CheckPromoteSignal(void)
if (stat(PROMOTE_SIGNAL_FILE, &stat_buf) == 0)
{
/*
- * Since we are in a signal handler, it's not safe
- * to elog. We silently ignore any error from unlink.
+ * Since we are in a signal handler, it's not safe to elog. We
+ * silently ignore any error from unlink.
*/
unlink(PROMOTE_SIGNAL_FILE);
return true;
diff --git a/src/backend/catalog/aclchk.c b/src/backend/catalog/aclchk.c
index aa3d59d4c9..693b634398 100644
--- a/src/backend/catalog/aclchk.c
+++ b/src/backend/catalog/aclchk.c
@@ -1011,8 +1011,8 @@ SetDefaultACLsInSchemas(InternalDefaultACL *iacls, List *nspnames)
/*
* Note that we must do the permissions check against the target
- * role not the calling user. We require CREATE privileges,
- * since without CREATE you won't be able to do anything using the
+ * role not the calling user. We require CREATE privileges, since
+ * without CREATE you won't be able to do anything using the
* default privs anyway.
*/
iacls->nspid = get_namespace_oid(nspname, false);
@@ -1707,7 +1707,7 @@ ExecGrant_Relation(InternalGrant *istmt)
pg_class_tuple->relkind != RELKIND_FOREIGN_TABLE)
ereport(ERROR,
(errcode(ERRCODE_WRONG_OBJECT_TYPE),
- errmsg("\"%s\" is not a foreign table",
+ errmsg("\"%s\" is not a foreign table",
NameStr(pg_class_tuple->relname))));
/* Adjust the default permissions based on object type */
@@ -1964,13 +1964,13 @@ ExecGrant_Relation(InternalGrant *istmt)
this_privileges &= (AclMode) ACL_SELECT;
}
else if (pg_class_tuple->relkind == RELKIND_FOREIGN_TABLE &&
- this_privileges & ~((AclMode) ACL_SELECT))
+ this_privileges & ~((AclMode) ACL_SELECT))
{
/* Foreign tables have the same restriction as sequences. */
ereport(WARNING,
- (errcode(ERRCODE_INVALID_GRANT_OPERATION),
- errmsg("foreign table \"%s\" only supports SELECT column privileges",
- NameStr(pg_class_tuple->relname))));
+ (errcode(ERRCODE_INVALID_GRANT_OPERATION),
+ errmsg("foreign table \"%s\" only supports SELECT column privileges",
+ NameStr(pg_class_tuple->relname))));
this_privileges &= (AclMode) ACL_SELECT;
}
@@ -4768,7 +4768,7 @@ pg_extension_ownercheck(Oid ext_oid, Oid roleid)
* Note: roles do not have owners per se; instead we use this test in
* places where an ownership-like permissions test is needed for a role.
* Be sure to apply it to the role trying to do the operation, not the
- * role being operated on! Also note that this generally should not be
+ * role being operated on! Also note that this generally should not be
* considered enough privilege if the target role is a superuser.
* (We don't handle that consideration here because we want to give a
* separate error message for such cases, so the caller has to deal with it.)
diff --git a/src/backend/catalog/catalog.c b/src/backend/catalog/catalog.c
index 12935754bc..cbce0072de 100644
--- a/src/backend/catalog/catalog.c
+++ b/src/backend/catalog/catalog.c
@@ -80,11 +80,11 @@ forkname_to_number(char *forkName)
/*
* forkname_chars
- * We use this to figure out whether a filename could be a relation
- * fork (as opposed to an oddly named stray file that somehow ended
- * up in the database directory). If the passed string begins with
- * a fork name (other than the main fork name), we return its length,
- * and set *fork (if not NULL) to the fork number. If not, we return 0.
+ * We use this to figure out whether a filename could be a relation
+ * fork (as opposed to an oddly named stray file that somehow ended
+ * up in the database directory). If the passed string begins with
+ * a fork name (other than the main fork name), we return its length,
+ * and set *fork (if not NULL) to the fork number. If not, we return 0.
*
* Note that the present coding assumes that there are no fork names which
* are prefixes of other fork names.
@@ -96,7 +96,8 @@ forkname_chars(const char *str, ForkNumber *fork)
for (forkNum = 1; forkNum <= MAX_FORKNUM; forkNum++)
{
- int len = strlen(forkNames[forkNum]);
+ int len = strlen(forkNames[forkNum]);
+
if (strncmp(forkNames[forkNum], str, len) == 0)
{
if (fork)
@@ -150,7 +151,7 @@ relpathbackend(RelFileNode rnode, BackendId backend, ForkNumber forknum)
{
/* OIDCHARS will suffice for an integer, too */
pathlen = 5 + OIDCHARS + 2 + OIDCHARS + 1 + OIDCHARS + 1
- + FORKNAMECHARS + 1;
+ + FORKNAMECHARS + 1;
path = (char *) palloc(pathlen);
if (forknum != MAIN_FORKNUM)
snprintf(path, pathlen, "base/%u/t%d_%u_%s",
@@ -167,8 +168,8 @@ relpathbackend(RelFileNode rnode, BackendId backend, ForkNumber forknum)
if (backend == InvalidBackendId)
{
pathlen = 9 + 1 + OIDCHARS + 1
- + strlen(TABLESPACE_VERSION_DIRECTORY) + 1 + OIDCHARS + 1
- + OIDCHARS + 1 + FORKNAMECHARS + 1;
+ + strlen(TABLESPACE_VERSION_DIRECTORY) + 1 + OIDCHARS + 1
+ + OIDCHARS + 1 + FORKNAMECHARS + 1;
path = (char *) palloc(pathlen);
if (forknum != MAIN_FORKNUM)
snprintf(path, pathlen, "pg_tblspc/%u/%s/%u/%u_%s",
@@ -184,8 +185,8 @@ relpathbackend(RelFileNode rnode, BackendId backend, ForkNumber forknum)
{
/* OIDCHARS will suffice for an integer, too */
pathlen = 9 + 1 + OIDCHARS + 1
- + strlen(TABLESPACE_VERSION_DIRECTORY) + 1 + OIDCHARS + 2
- + OIDCHARS + 1 + OIDCHARS + 1 + FORKNAMECHARS + 1;
+ + strlen(TABLESPACE_VERSION_DIRECTORY) + 1 + OIDCHARS + 2
+ + OIDCHARS + 1 + OIDCHARS + 1 + FORKNAMECHARS + 1;
path = (char *) palloc(pathlen);
if (forknum != MAIN_FORKNUM)
snprintf(path, pathlen, "pg_tblspc/%u/%s/%u/t%d_%u_%s",
diff --git a/src/backend/catalog/dependency.c b/src/backend/catalog/dependency.c
index de24ef7a09..ec9bb48c63 100644
--- a/src/backend/catalog/dependency.c
+++ b/src/backend/catalog/dependency.c
@@ -160,7 +160,7 @@ static const Oid object_classes[MAX_OCLASS] = {
ForeignServerRelationId, /* OCLASS_FOREIGN_SERVER */
UserMappingRelationId, /* OCLASS_USER_MAPPING */
DefaultAclRelationId, /* OCLASS_DEFACL */
- ExtensionRelationId /* OCLASS_EXTENSION */
+ ExtensionRelationId /* OCLASS_EXTENSION */
};
@@ -1021,8 +1021,8 @@ deleteOneObject(const ObjectAddress *object, Relation depRel)
/*
* Delete any comments or security labels associated with this object.
- * (This is a convenient place to do these things, rather than having every
- * object type know to do it.)
+ * (This is a convenient place to do these things, rather than having
+ * every object type know to do it.)
*/
DeleteComments(object->objectId, object->classId, object->objectSubId);
DeleteSecurityLabel(object);
@@ -1263,7 +1263,7 @@ recordDependencyOnExpr(const ObjectAddress *depender,
* whereas 'behavior' is used for everything else.
*
* NOTE: the caller should ensure that a whole-table dependency on the
- * specified relation is created separately, if one is needed. In particular,
+ * specified relation is created separately, if one is needed. In particular,
* a whole-row Var "relation.*" will not cause this routine to emit any
* dependency item. This is appropriate behavior for subexpressions of an
* ordinary query, so other cases need to cope as necessary.
@@ -1383,7 +1383,7 @@ find_expr_references_walker(Node *node,
/*
* A whole-row Var references no specific columns, so adds no new
- * dependency. (We assume that there is a whole-table dependency
+ * dependency. (We assume that there is a whole-table dependency
* arising from each underlying rangetable entry. While we could
* record such a dependency when finding a whole-row Var that
* references a relation directly, it's quite unclear how to extend
@@ -1431,8 +1431,8 @@ find_expr_references_walker(Node *node,
/*
* We must also depend on the constant's collation: it could be
- * different from the datatype's, if a CollateExpr was const-folded
- * to a simple constant. However we can save work in the most common
+ * different from the datatype's, if a CollateExpr was const-folded to
+ * a simple constant. However we can save work in the most common
* case where the collation is "default", since we know that's pinned.
*/
if (OidIsValid(con->constcollid) &&
@@ -1695,7 +1695,7 @@ find_expr_references_walker(Node *node,
}
foreach(ct, rte->funccolcollations)
{
- Oid collid = lfirst_oid(ct);
+ Oid collid = lfirst_oid(ct);
if (OidIsValid(collid) &&
collid != DEFAULT_COLLATION_OID)
@@ -2224,12 +2224,12 @@ getObjectDescription(const ObjectAddress *object)
HeapTuple collTup;
collTup = SearchSysCache1(COLLOID,
- ObjectIdGetDatum(object->objectId));
+ ObjectIdGetDatum(object->objectId));
if (!HeapTupleIsValid(collTup))
elog(ERROR, "cache lookup failed for collation %u",
object->objectId);
appendStringInfo(&buffer, _("collation %s"),
- NameStr(((Form_pg_collation) GETSTRUCT(collTup))->collname));
+ NameStr(((Form_pg_collation) GETSTRUCT(collTup))->collname));
ReleaseSysCache(collTup);
break;
}
@@ -2796,7 +2796,7 @@ getObjectDescription(const ObjectAddress *object)
char *
getObjectDescriptionOids(Oid classid, Oid objid)
{
- ObjectAddress address;
+ ObjectAddress address;
address.classId = classid;
address.objectId = objid;
diff --git a/src/backend/catalog/heap.c b/src/backend/catalog/heap.c
index 5d25ce9ec8..09b26a5c72 100644
--- a/src/backend/catalog/heap.c
+++ b/src/backend/catalog/heap.c
@@ -431,7 +431,7 @@ CheckAttributeNamesTypes(TupleDesc tupdesc, char relkind,
CheckAttributeType(NameStr(tupdesc->attrs[i]->attname),
tupdesc->attrs[i]->atttypid,
tupdesc->attrs[i]->attcollation,
- NIL, /* assume we're creating a new rowtype */
+ NIL, /* assume we're creating a new rowtype */
allow_system_table_mods);
}
}
@@ -497,7 +497,7 @@ CheckAttributeType(const char *attname,
int i;
/*
- * Check for self-containment. Eventually we might be able to allow
+ * Check for self-containment. Eventually we might be able to allow
* this (just return without complaint, if so) but it's not clear how
* many other places would require anti-recursion defenses before it
* would be safe to allow tables to contain their own rowtype.
@@ -505,8 +505,8 @@ CheckAttributeType(const char *attname,
if (list_member_oid(containing_rowtypes, atttypid))
ereport(ERROR,
(errcode(ERRCODE_INVALID_TABLE_DEFINITION),
- errmsg("composite type %s cannot be made a member of itself",
- format_type_be(atttypid))));
+ errmsg("composite type %s cannot be made a member of itself",
+ format_type_be(atttypid))));
containing_rowtypes = lcons_oid(atttypid, containing_rowtypes);
@@ -541,15 +541,15 @@ CheckAttributeType(const char *attname,
}
/*
- * This might not be strictly invalid per SQL standard, but it is
- * pretty useless, and it cannot be dumped, so we must disallow it.
+ * This might not be strictly invalid per SQL standard, but it is pretty
+ * useless, and it cannot be dumped, so we must disallow it.
*/
if (!OidIsValid(attcollation) && type_is_collatable(atttypid))
- ereport(ERROR,
- (errcode(ERRCODE_INVALID_TABLE_DEFINITION),
- errmsg("no collation was derived for column \"%s\" with collatable type %s",
- attname, format_type_be(atttypid)),
- errhint("Use the COLLATE clause to set the collation explicitly.")));
+ ereport(ERROR,
+ (errcode(ERRCODE_INVALID_TABLE_DEFINITION),
+ errmsg("no collation was derived for column \"%s\" with collatable type %s",
+ attname, format_type_be(atttypid)),
+ errhint("Use the COLLATE clause to set the collation explicitly.")));
}
/*
@@ -921,7 +921,7 @@ AddNewRelationType(const char *typeName,
-1, /* typmod */
0, /* array dimensions for typBaseType */
false, /* Type NOT NULL */
- InvalidOid); /* typcollation */
+ InvalidOid); /* typcollation */
}
/* --------------------------------
@@ -992,9 +992,9 @@ heap_create_with_catalog(const char *relname,
CheckAttributeNamesTypes(tupdesc, relkind, allow_system_table_mods);
/*
- * If the relation already exists, it's an error, unless the user specifies
- * "IF NOT EXISTS". In that case, we just print a notice and do nothing
- * further.
+ * If the relation already exists, it's an error, unless the user
+ * specifies "IF NOT EXISTS". In that case, we just print a notice and do
+ * nothing further.
*/
existing_relid = get_relname_relid(relname, relnamespace);
if (existing_relid != InvalidOid)
@@ -1004,7 +1004,7 @@ heap_create_with_catalog(const char *relname,
ereport(NOTICE,
(errcode(ERRCODE_DUPLICATE_TABLE),
errmsg("relation \"%s\" already exists, skipping",
- relname)));
+ relname)));
heap_close(pg_class_desc, RowExclusiveLock);
return InvalidOid;
}
@@ -1048,8 +1048,8 @@ heap_create_with_catalog(const char *relname,
if (!OidIsValid(relid))
{
/*
- * Use binary-upgrade override for pg_class.oid/relfilenode,
- * if supplied.
+ * Use binary-upgrade override for pg_class.oid/relfilenode, if
+ * supplied.
*/
if (OidIsValid(binary_upgrade_next_heap_pg_class_oid) &&
(relkind == RELKIND_RELATION || relkind == RELKIND_SEQUENCE ||
@@ -1183,7 +1183,7 @@ heap_create_with_catalog(const char *relname,
-1, /* typmod */
0, /* array dimensions for typBaseType */
false, /* Type NOT NULL */
- InvalidOid); /* typcollation */
+ InvalidOid); /* typcollation */
pfree(relarrayname);
}
@@ -1285,12 +1285,12 @@ heap_create_with_catalog(const char *relname,
register_on_commit_action(relid, oncommit);
/*
- * If this is an unlogged relation, it needs an init fork so that it
- * can be correctly reinitialized on restart. Since we're going to
- * do an immediate sync, we ony need to xlog this if archiving or
- * streaming is enabled. And the immediate sync is required, because
- * otherwise there's no guarantee that this will hit the disk before
- * the next checkpoint moves the redo pointer.
+ * If this is an unlogged relation, it needs an init fork so that it can
+ * be correctly reinitialized on restart. Since we're going to do an
+ * immediate sync, we ony need to xlog this if archiving or streaming is
+ * enabled. And the immediate sync is required, because otherwise there's
+ * no guarantee that this will hit the disk before the next checkpoint
+ * moves the redo pointer.
*/
if (relpersistence == RELPERSISTENCE_UNLOGGED)
{
@@ -1654,8 +1654,8 @@ heap_drop_with_catalog(Oid relid)
/*
* There can no longer be anyone *else* touching the relation, but we
- * might still have open queries or cursors, or pending trigger events,
- * in our own session.
+ * might still have open queries or cursors, or pending trigger events, in
+ * our own session.
*/
CheckTableNotInUse(rel, "DROP TABLE");
@@ -1664,8 +1664,8 @@ heap_drop_with_catalog(Oid relid)
*/
if (rel->rd_rel->relkind == RELKIND_FOREIGN_TABLE)
{
- Relation rel;
- HeapTuple tuple;
+ Relation rel;
+ HeapTuple tuple;
rel = heap_open(ForeignTableRelationId, RowExclusiveLock);
@@ -1899,7 +1899,7 @@ StoreRelCheck(Relation rel, char *ccname, Node *expr,
CONSTRAINT_CHECK, /* Constraint Type */
false, /* Is Deferrable */
false, /* Is Deferred */
- true, /* Is Validated */
+ true, /* Is Validated */
RelationGetRelid(rel), /* relation */
attNos, /* attrs in the constraint */
keycount, /* # attrs in the constraint */
diff --git a/src/backend/catalog/index.c b/src/backend/catalog/index.c
index 679255a199..1bf74b3d4f 100644
--- a/src/backend/catalog/index.c
+++ b/src/backend/catalog/index.c
@@ -187,18 +187,18 @@ index_check_primary_key(Relation heapRel,
int i;
/*
- * If ALTER TABLE, check that there isn't already a PRIMARY KEY. In
- * CREATE TABLE, we have faith that the parser rejected multiple pkey
- * clauses; and CREATE INDEX doesn't have a way to say PRIMARY KEY, so
- * it's no problem either.
+ * If ALTER TABLE, check that there isn't already a PRIMARY KEY. In CREATE
+ * TABLE, we have faith that the parser rejected multiple pkey clauses;
+ * and CREATE INDEX doesn't have a way to say PRIMARY KEY, so it's no
+ * problem either.
*/
if (is_alter_table &&
relationHasPrimaryKey(heapRel))
{
ereport(ERROR,
(errcode(ERRCODE_INVALID_TABLE_DEFINITION),
- errmsg("multiple primary keys for table \"%s\" are not allowed",
- RelationGetRelationName(heapRel))));
+ errmsg("multiple primary keys for table \"%s\" are not allowed",
+ RelationGetRelationName(heapRel))));
}
/*
@@ -222,7 +222,7 @@ index_check_primary_key(Relation heapRel,
continue;
atttuple = SearchSysCache2(ATTNUM,
- ObjectIdGetDatum(RelationGetRelid(heapRel)),
+ ObjectIdGetDatum(RelationGetRelid(heapRel)),
Int16GetDatum(attnum));
if (!HeapTupleIsValid(atttuple))
elog(ERROR, "cache lookup failed for attribute %d of relation %u",
@@ -243,15 +243,14 @@ index_check_primary_key(Relation heapRel,
}
/*
- * XXX: Shouldn't the ALTER TABLE .. SET NOT NULL cascade to child
- * tables? Currently, since the PRIMARY KEY itself doesn't cascade,
- * we don't cascade the notnull constraint(s) either; but this is
- * pretty debatable.
+ * XXX: Shouldn't the ALTER TABLE .. SET NOT NULL cascade to child tables?
+ * Currently, since the PRIMARY KEY itself doesn't cascade, we don't
+ * cascade the notnull constraint(s) either; but this is pretty debatable.
*
- * XXX: possible future improvement: when being called from ALTER
- * TABLE, it would be more efficient to merge this with the outer
- * ALTER TABLE, so as to avoid two scans. But that seems to
- * complicate DefineIndex's API unduly.
+ * XXX: possible future improvement: when being called from ALTER TABLE,
+ * it would be more efficient to merge this with the outer ALTER TABLE, so
+ * as to avoid two scans. But that seems to complicate DefineIndex's API
+ * unduly.
*/
if (cmds)
AlterTableInternal(RelationGetRelid(heapRel), cmds, false);
@@ -788,8 +787,8 @@ index_create(Relation heapRelation,
if (!OidIsValid(indexRelationId))
{
/*
- * Use binary-upgrade override for pg_class.oid/relfilenode,
- * if supplied.
+ * Use binary-upgrade override for pg_class.oid/relfilenode, if
+ * supplied.
*/
if (OidIsValid(binary_upgrade_next_index_pg_class_oid))
{
@@ -872,7 +871,7 @@ index_create(Relation heapRelation,
* ----------------
*/
UpdateIndexRelation(indexRelationId, heapRelationId, indexInfo,
- collationObjectId, classObjectId, coloptions, isprimary, is_exclusion,
+ collationObjectId, classObjectId, coloptions, isprimary, is_exclusion,
!deferrable,
!concurrent);
@@ -947,7 +946,7 @@ index_create(Relation heapRelation,
/*
* If there are no simply-referenced columns, give the index an
- * auto dependency on the whole table. In most cases, this will
+ * auto dependency on the whole table. In most cases, this will
* be redundant, but it might not be if the index expressions and
* predicate contain no Vars or only whole-row Vars.
*/
@@ -1067,7 +1066,7 @@ index_create(Relation heapRelation,
/*
* Close the index; but we keep the lock that we acquired above until end
- * of transaction. Closing the heap is caller's responsibility.
+ * of transaction. Closing the heap is caller's responsibility.
*/
index_close(indexRelation, NoLock);
@@ -1176,8 +1175,8 @@ index_constraint_create(Relation heapRelation,
/*
* If the constraint is deferrable, create the deferred uniqueness
- * checking trigger. (The trigger will be given an internal
- * dependency on the constraint by CreateTrigger.)
+ * checking trigger. (The trigger will be given an internal dependency on
+ * the constraint by CreateTrigger.)
*/
if (deferrable)
{
@@ -1213,7 +1212,7 @@ index_constraint_create(Relation heapRelation,
* have been so marked already, so no need to clear the flag in the other
* case.
*
- * Note: this might better be done by callers. We do it here to avoid
+ * Note: this might better be done by callers. We do it here to avoid
* exposing index_update_stats() globally, but that wouldn't be necessary
* if relhaspkey went away.
*/
@@ -1235,10 +1234,10 @@ index_constraint_create(Relation heapRelation,
*/
if (update_pgindex && (mark_as_primary || deferrable))
{
- Relation pg_index;
- HeapTuple indexTuple;
- Form_pg_index indexForm;
- bool dirty = false;
+ Relation pg_index;
+ HeapTuple indexTuple;
+ Form_pg_index indexForm;
+ bool dirty = false;
pg_index = heap_open(IndexRelationId, RowExclusiveLock);
@@ -1303,8 +1302,8 @@ index_drop(Oid indexId)
userIndexRelation = index_open(indexId, AccessExclusiveLock);
/*
- * There can no longer be anyone *else* touching the index, but we
- * might still have open queries using it in our own session.
+ * There can no longer be anyone *else* touching the index, but we might
+ * still have open queries using it in our own session.
*/
CheckTableNotInUse(userIndexRelation, "DROP INDEX");
@@ -1739,7 +1738,8 @@ index_build(Relation heapRelation,
*/
if (heapRelation->rd_rel->relpersistence == RELPERSISTENCE_UNLOGGED)
{
- RegProcedure ambuildempty = indexRelation->rd_am->ambuildempty;
+ RegProcedure ambuildempty = indexRelation->rd_am->ambuildempty;
+
RelationOpenSmgr(indexRelation);
smgrcreate(indexRelation->rd_smgr, INIT_FORKNUM, false);
OidFunctionCall1(ambuildempty, PointerGetDatum(indexRelation));
@@ -2410,7 +2410,7 @@ validate_index(Oid heapId, Oid indexId, Snapshot snapshot)
ivinfo.strategy = NULL;
state.tuplesort = tuplesort_begin_datum(TIDOID,
- TIDLessOperator, InvalidOid, false,
+ TIDLessOperator, InvalidOid, false,
maintenance_work_mem,
false);
state.htups = state.itups = state.tups_inserted = 0;
@@ -2834,7 +2834,7 @@ reindex_index(Oid indexId, bool skip_constraint_checks)
* use catalog indexes while collecting the list.)
*
* To avoid deadlocks, VACUUM FULL or CLUSTER on a system catalog must omit the
- * REINDEX_CHECK_CONSTRAINTS flag. REINDEX should be used to rebuild an index
+ * REINDEX_CHECK_CONSTRAINTS flag. REINDEX should be used to rebuild an index
* if constraint inconsistency is suspected. For optimal performance, other
* callers should include the flag only after transforming the data in a manner
* that risks a change in constraint validity.
diff --git a/src/backend/catalog/namespace.c b/src/backend/catalog/namespace.c
index 734581e485..f8fd827693 100644
--- a/src/backend/catalog/namespace.c
+++ b/src/backend/catalog/namespace.c
@@ -2446,10 +2446,10 @@ CheckSetNamespace(Oid oldNspOid, Oid nspOid, Oid classid, Oid objid)
if (oldNspOid == nspOid)
ereport(ERROR,
(classid == RelationRelationId ?
- errcode(ERRCODE_DUPLICATE_TABLE) :
+ errcode(ERRCODE_DUPLICATE_TABLE) :
classid == ProcedureRelationId ?
- errcode(ERRCODE_DUPLICATE_FUNCTION) :
- errcode(ERRCODE_DUPLICATE_OBJECT),
+ errcode(ERRCODE_DUPLICATE_FUNCTION) :
+ errcode(ERRCODE_DUPLICATE_OBJECT),
errmsg("%s is already in schema \"%s\"",
getObjectDescriptionOids(classid, objid),
get_namespace_name(nspOid))));
@@ -2458,7 +2458,7 @@ CheckSetNamespace(Oid oldNspOid, Oid nspOid, Oid classid, Oid objid)
if (isAnyTempNamespace(nspOid) || isAnyTempNamespace(oldNspOid))
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("cannot move objects into or out of temporary schemas")));
+ errmsg("cannot move objects into or out of temporary schemas")));
/* same for TOAST schema */
if (nspOid == PG_TOAST_NAMESPACE || oldNspOid == PG_TOAST_NAMESPACE)
@@ -2525,7 +2525,7 @@ QualifiedNameGetCreationNamespace(List *names, char **objname_p)
/*
* get_namespace_oid - given a namespace name, look up the OID
*
- * If missing_ok is false, throw an error if namespace name not found. If
+ * If missing_ok is false, throw an error if namespace name not found. If
* true, just return InvalidOid.
*/
Oid
@@ -2535,9 +2535,9 @@ get_namespace_oid(const char *nspname, bool missing_ok)
oid = GetSysCacheOid1(NAMESPACENAME, CStringGetDatum(nspname));
if (!OidIsValid(oid) && !missing_ok)
- ereport(ERROR,
- (errcode(ERRCODE_UNDEFINED_SCHEMA),
- errmsg("schema \"%s\" does not exist", nspname)));
+ ereport(ERROR,
+ (errcode(ERRCODE_UNDEFINED_SCHEMA),
+ errmsg("schema \"%s\" does not exist", nspname)));
return oid;
}
@@ -2727,7 +2727,7 @@ GetTempNamespaceBackendId(Oid namespaceId)
/* See if the namespace name starts with "pg_temp_" or "pg_toast_temp_" */
nspname = get_namespace_name(namespaceId);
if (!nspname)
- return InvalidBackendId; /* no such namespace? */
+ return InvalidBackendId; /* no such namespace? */
if (strncmp(nspname, "pg_temp_", 8) == 0)
result = atoi(nspname + 8);
else if (strncmp(nspname, "pg_toast_temp_", 14) == 0)
@@ -2798,8 +2798,8 @@ GetOverrideSearchPath(MemoryContext context)
*
* It's possible that newpath->useTemp is set but there is no longer any
* active temp namespace, if the path was saved during a transaction that
- * created a temp namespace and was later rolled back. In that case we just
- * ignore useTemp. A plausible alternative would be to create a new temp
+ * created a temp namespace and was later rolled back. In that case we just
+ * ignore useTemp. A plausible alternative would be to create a new temp
* namespace, but for existing callers that's not necessary because an empty
* temp namespace wouldn't affect their results anyway.
*
@@ -3522,7 +3522,7 @@ check_search_path(char **newval, void **extra, GucSource source)
if (source == PGC_S_TEST)
ereport(NOTICE,
(errcode(ERRCODE_UNDEFINED_SCHEMA),
- errmsg("schema \"%s\" does not exist", curname)));
+ errmsg("schema \"%s\" does not exist", curname)));
else
{
GUC_check_errdetail("schema \"%s\" does not exist", curname);
diff --git a/src/backend/catalog/objectaddress.c b/src/backend/catalog/objectaddress.c
index 0d21d310a6..bf25091582 100644
--- a/src/backend/catalog/objectaddress.c
+++ b/src/backend/catalog/objectaddress.c
@@ -78,7 +78,7 @@ static Relation get_relation_by_qualified_name(ObjectType objtype,
static ObjectAddress get_object_address_relobject(ObjectType objtype,
List *objname, Relation *relp);
static ObjectAddress get_object_address_attribute(ObjectType objtype,
- List *objname, Relation *relp, LOCKMODE lockmode);
+ List *objname, Relation *relp, LOCKMODE lockmode);
static ObjectAddress get_object_address_opcf(ObjectType objtype, List *objname,
List *objargs);
static bool object_exists(ObjectAddress address);
@@ -108,8 +108,8 @@ ObjectAddress
get_object_address(ObjectType objtype, List *objname, List *objargs,
Relation *relp, LOCKMODE lockmode)
{
- ObjectAddress address;
- Relation relation = NULL;
+ ObjectAddress address;
+ Relation relation = NULL;
/* Some kind of lock must be taken. */
Assert(lockmode != NoLock);
@@ -130,7 +130,7 @@ get_object_address(ObjectType objtype, List *objname, List *objargs,
case OBJECT_COLUMN:
address =
get_object_address_attribute(objtype, objname, &relation,
- lockmode);
+ lockmode);
break;
case OBJECT_RULE:
case OBJECT_TRIGGER:
@@ -201,10 +201,10 @@ get_object_address(ObjectType objtype, List *objname, List *objargs,
break;
case OBJECT_CAST:
{
- TypeName *sourcetype = (TypeName *) linitial(objname);
- TypeName *targettype = (TypeName *) linitial(objargs);
- Oid sourcetypeid = typenameTypeId(NULL, sourcetype);
- Oid targettypeid = typenameTypeId(NULL, targettype);
+ TypeName *sourcetype = (TypeName *) linitial(objname);
+ TypeName *targettype = (TypeName *) linitial(objargs);
+ Oid sourcetypeid = typenameTypeId(NULL, sourcetype);
+ Oid targettypeid = typenameTypeId(NULL, targettype);
address.classId = CastRelationId;
address.objectId =
@@ -242,8 +242,8 @@ get_object_address(ObjectType objtype, List *objname, List *objargs,
/*
* If we're dealing with a relation or attribute, then the relation is
- * already locked. If we're dealing with any other type of object, we need
- * to lock it and then verify that it still exists.
+ * already locked. If we're dealing with any other type of object, we
+ * need to lock it and then verify that it still exists.
*/
if (address.classId != RelationRelationId)
{
@@ -308,7 +308,7 @@ get_object_address_unqualified(ObjectType objtype, List *qualname)
break;
default:
elog(ERROR, "unrecognized objtype: %d", (int) objtype);
- msg = NULL; /* placate compiler */
+ msg = NULL; /* placate compiler */
}
ereport(ERROR,
(errcode(ERRCODE_SYNTAX_ERROR),
@@ -379,7 +379,7 @@ static Relation
get_relation_by_qualified_name(ObjectType objtype, List *objname,
LOCKMODE lockmode)
{
- Relation relation;
+ Relation relation;
relation = relation_openrv(makeRangeVarFromNameList(objname), lockmode);
switch (objtype)
@@ -449,7 +449,7 @@ get_object_address_relobject(ObjectType objtype, List *objname, Relation *relp)
nnames = list_length(objname);
if (nnames < 2)
{
- Oid reloid;
+ Oid reloid;
/*
* For compatibility with very old releases, we sometimes allow users
@@ -514,7 +514,7 @@ static ObjectAddress
get_object_address_attribute(ObjectType objtype, List *objname,
Relation *relp, LOCKMODE lockmode)
{
- ObjectAddress address;
+ ObjectAddress address;
List *relname;
Oid reloid;
Relation relation;
@@ -534,7 +534,7 @@ get_object_address_attribute(ObjectType objtype, List *objname,
ereport(ERROR,
(errcode(ERRCODE_UNDEFINED_COLUMN),
errmsg("column \"%s\" of relation \"%s\" does not exist",
- attname, RelationGetRelationName(relation))));
+ attname, RelationGetRelationName(relation))));
*relp = relation;
return address;
@@ -584,8 +584,8 @@ object_exists(ObjectAddress address)
int cache = -1;
Oid indexoid = InvalidOid;
Relation rel;
- ScanKeyData skey[1];
- SysScanDesc sd;
+ ScanKeyData skey[1];
+ SysScanDesc sd;
bool found;
/* Sub-objects require special treatment. */
@@ -609,9 +609,9 @@ object_exists(ObjectAddress address)
/*
* For object types that have a relevant syscache, we use it; for
- * everything else, we'll have to do an index-scan. This switch
- * sets either the cache to be used for the syscache lookup, or the
- * index to be used for the index scan.
+ * everything else, we'll have to do an index-scan. This switch sets
+ * either the cache to be used for the syscache lookup, or the index to be
+ * used for the index scan.
*/
switch (address.classId)
{
@@ -664,6 +664,7 @@ object_exists(ObjectAddress address)
cache = OPFAMILYOID;
break;
case LargeObjectRelationId:
+
/*
* Weird backward compatibility hack: ObjectAddress notation uses
* LargeObjectRelationId for large objects, but since PostgreSQL
@@ -816,15 +817,15 @@ check_object_ownership(Oid roleid, ObjectType objtype, ObjectAddress address,
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
errmsg("must be owner of large object %u",
- address.objectId)));
+ address.objectId)));
break;
case OBJECT_CAST:
{
/* We can only check permissions on the source/target types */
- TypeName *sourcetype = (TypeName *) linitial(objname);
- TypeName *targettype = (TypeName *) linitial(objargs);
- Oid sourcetypeid = typenameTypeId(NULL, sourcetype);
- Oid targettypeid = typenameTypeId(NULL, targettype);
+ TypeName *sourcetype = (TypeName *) linitial(objname);
+ TypeName *targettype = (TypeName *) linitial(objargs);
+ Oid sourcetypeid = typenameTypeId(NULL, sourcetype);
+ Oid targettypeid = typenameTypeId(NULL, targettype);
if (!pg_type_ownercheck(sourcetypeid, roleid)
&& !pg_type_ownercheck(targettypeid, roleid))
@@ -851,6 +852,7 @@ check_object_ownership(Oid roleid, ObjectType objtype, ObjectAddress address,
NameListToString(objname));
break;
case OBJECT_ROLE:
+
/*
* We treat roles as being "owned" by those with CREATEROLE priv,
* except that superusers are only owned by superusers.
diff --git a/src/backend/catalog/pg_collation.c b/src/backend/catalog/pg_collation.c
index 708078463b..5b92a4c0c2 100644
--- a/src/backend/catalog/pg_collation.c
+++ b/src/backend/catalog/pg_collation.c
@@ -46,7 +46,9 @@ CollationCreate(const char *collname, Oid collnamespace,
HeapTuple tup;
Datum values[Natts_pg_collation];
bool nulls[Natts_pg_collation];
- NameData name_name, name_collate, name_ctype;
+ NameData name_name,
+ name_collate,
+ name_ctype;
Oid oid;
ObjectAddress myself,
referenced;
@@ -60,9 +62,9 @@ CollationCreate(const char *collname, Oid collnamespace,
/*
* Make sure there is no existing collation of same name & encoding.
*
- * This would be caught by the unique index anyway; we're just giving
- * a friendlier error message. The unique index provides a backstop
- * against race conditions.
+ * This would be caught by the unique index anyway; we're just giving a
+ * friendlier error message. The unique index provides a backstop against
+ * race conditions.
*/
if (SearchSysCacheExists3(COLLNAMEENCNSP,
PointerGetDatum(collname),
@@ -74,9 +76,9 @@ CollationCreate(const char *collname, Oid collnamespace,
collname, pg_encoding_to_char(collencoding))));
/*
- * Also forbid matching an any-encoding entry. This test of course is
- * not backed up by the unique index, but it's not a problem since we
- * don't support adding any-encoding entries after initdb.
+ * Also forbid matching an any-encoding entry. This test of course is not
+ * backed up by the unique index, but it's not a problem since we don't
+ * support adding any-encoding entries after initdb.
*/
if (SearchSysCacheExists3(COLLNAMEENCNSP,
PointerGetDatum(collname),
diff --git a/src/backend/catalog/pg_constraint.c b/src/backend/catalog/pg_constraint.c
index 6619eed431..69979942af 100644
--- a/src/backend/catalog/pg_constraint.c
+++ b/src/backend/catalog/pg_constraint.c
@@ -799,10 +799,10 @@ get_constraint_oid(Oid relid, const char *conname, bool missing_ok)
* the rel of interest are Vars with the indicated varno/varlevelsup.
*
* Currently we only check to see if the rel has a primary key that is a
- * subset of the grouping_columns. We could also use plain unique constraints
+ * subset of the grouping_columns. We could also use plain unique constraints
* if all their columns are known not null, but there's a problem: we need
* to be able to represent the not-null-ness as part of the constraints added
- * to *constraintDeps. FIXME whenever not-null constraints get represented
+ * to *constraintDeps. FIXME whenever not-null constraints get represented
* in pg_constraint.
*/
bool
@@ -852,7 +852,7 @@ check_functional_grouping(Oid relid,
if (isNull)
elog(ERROR, "null conkey for constraint %u",
HeapTupleGetOid(tuple));
- arr = DatumGetArrayTypeP(adatum); /* ensure not toasted */
+ arr = DatumGetArrayTypeP(adatum); /* ensure not toasted */
numkeys = ARR_DIMS(arr)[0];
if (ARR_NDIM(arr) != 1 ||
numkeys < 0 ||
diff --git a/src/backend/catalog/pg_depend.c b/src/backend/catalog/pg_depend.c
index 2bb7bb3d5f..67aad86d4e 100644
--- a/src/backend/catalog/pg_depend.c
+++ b/src/backend/catalog/pg_depend.c
@@ -126,7 +126,7 @@ recordMultipleDependencies(const ObjectAddress *depender,
/*
* If we are executing a CREATE EXTENSION operation, mark the given object
- * as being a member of the extension. Otherwise, do nothing.
+ * as being a member of the extension. Otherwise, do nothing.
*
* This must be called during creation of any user-definable object type
* that could be a member of an extension.
@@ -136,7 +136,7 @@ recordDependencyOnCurrentExtension(const ObjectAddress *object)
{
if (creating_extension)
{
- ObjectAddress extension;
+ ObjectAddress extension;
extension.classId = ExtensionRelationId;
extension.objectId = CurrentExtensionObject;
@@ -155,7 +155,7 @@ recordDependencyOnCurrentExtension(const ObjectAddress *object)
* (possibly with some differences from before).
*
* If skipExtensionDeps is true, we do not delete any dependencies that
- * show that the given object is a member of an extension. This avoids
+ * show that the given object is a member of an extension. This avoids
* needing a lot of extra logic to fetch and recreate that dependency.
*/
long
@@ -185,7 +185,7 @@ deleteDependencyRecordsFor(Oid classId, Oid objectId,
while (HeapTupleIsValid(tup = systable_getnext(scan)))
{
if (skipExtensionDeps &&
- ((Form_pg_depend) GETSTRUCT(tup))->deptype == DEPENDENCY_EXTENSION)
+ ((Form_pg_depend) GETSTRUCT(tup))->deptype == DEPENDENCY_EXTENSION)
continue;
simple_heap_delete(depRel, &tup->t_self);
diff --git a/src/backend/catalog/pg_enum.c b/src/backend/catalog/pg_enum.c
index e87a9311bd..08d8aa13f3 100644
--- a/src/backend/catalog/pg_enum.c
+++ b/src/backend/catalog/pg_enum.c
@@ -29,7 +29,7 @@
/* Potentially set by contrib/pg_upgrade_support functions */
-Oid binary_upgrade_next_pg_enum_oid = InvalidOid;
+Oid binary_upgrade_next_pg_enum_oid = InvalidOid;
static void RenumberEnumType(Relation pg_enum, HeapTuple *existing, int nelems);
static int oid_cmp(const void *p1, const void *p2);
@@ -58,9 +58,9 @@ EnumValuesCreate(Oid enumTypeOid, List *vals)
num_elems = list_length(vals);
/*
- * We do not bother to check the list of values for duplicates --- if
- * you have any, you'll get a less-than-friendly unique-index violation.
- * It is probably not worth trying harder.
+ * We do not bother to check the list of values for duplicates --- if you
+ * have any, you'll get a less-than-friendly unique-index violation. It is
+ * probably not worth trying harder.
*/
pg_enum = heap_open(EnumRelationId, RowExclusiveLock);
@@ -69,10 +69,9 @@ EnumValuesCreate(Oid enumTypeOid, List *vals)
* Allocate OIDs for the enum's members.
*
* While this method does not absolutely guarantee that we generate no
- * duplicate OIDs (since we haven't entered each oid into the table
- * before allocating the next), trouble could only occur if the OID
- * counter wraps all the way around before we finish. Which seems
- * unlikely.
+ * duplicate OIDs (since we haven't entered each oid into the table before
+ * allocating the next), trouble could only occur if the OID counter wraps
+ * all the way around before we finish. Which seems unlikely.
*/
oids = (Oid *) palloc(num_elems * sizeof(Oid));
@@ -83,9 +82,10 @@ EnumValuesCreate(Oid enumTypeOid, List *vals)
* tells the comparison functions the OIDs are in the correct sort
* order and can be compared directly.
*/
- Oid new_oid;
+ Oid new_oid;
- do {
+ do
+ {
new_oid = GetNewOid(pg_enum);
} while (new_oid & 1);
oids[elemno] = new_oid;
@@ -202,9 +202,9 @@ AddEnumLabel(Oid enumTypeOid,
/*
* Acquire a lock on the enum type, which we won't release until commit.
* This ensures that two backends aren't concurrently modifying the same
- * enum type. Without that, we couldn't be sure to get a consistent
- * view of the enum members via the syscache. Note that this does not
- * block other backends from inspecting the type; see comments for
+ * enum type. Without that, we couldn't be sure to get a consistent view
+ * of the enum members via the syscache. Note that this does not block
+ * other backends from inspecting the type; see comments for
* RenumberEnumType.
*/
LockDatabaseObject(TypeRelationId, enumTypeOid, 0, ExclusiveLock);
@@ -217,7 +217,7 @@ restart:
/* Get the list of existing members of the enum */
list = SearchSysCacheList1(ENUMTYPOIDNAME,
ObjectIdGetDatum(enumTypeOid));
- nelems = list->n_members;
+ nelems = list->n_members;
/* Sort the existing members by enumsortorder */
existing = (HeapTuple *) palloc(nelems * sizeof(HeapTuple));
@@ -229,8 +229,8 @@ restart:
if (neighbor == NULL)
{
/*
- * Put the new label at the end of the list.
- * No change to existing tuples is required.
+ * Put the new label at the end of the list. No change to existing
+ * tuples is required.
*/
if (nelems > 0)
{
@@ -244,10 +244,10 @@ restart:
else
{
/* BEFORE or AFTER was specified */
- int nbr_index;
- int other_nbr_index;
- Form_pg_enum nbr_en;
- Form_pg_enum other_nbr_en;
+ int nbr_index;
+ int other_nbr_index;
+ Form_pg_enum nbr_en;
+ Form_pg_enum other_nbr_en;
/* Locate the neighbor element */
for (nbr_index = 0; nbr_index < nelems; nbr_index++)
@@ -265,14 +265,14 @@ restart:
nbr_en = (Form_pg_enum) GETSTRUCT(existing[nbr_index]);
/*
- * Attempt to assign an appropriate enumsortorder value: one less
- * than the smallest member, one more than the largest member,
- * or halfway between two existing members.
+ * Attempt to assign an appropriate enumsortorder value: one less than
+ * the smallest member, one more than the largest member, or halfway
+ * between two existing members.
*
* In the "halfway" case, because of the finite precision of float4,
- * we might compute a value that's actually equal to one or the
- * other of its neighbors. In that case we renumber the existing
- * members and try again.
+ * we might compute a value that's actually equal to one or the other
+ * of its neighbors. In that case we renumber the existing members
+ * and try again.
*/
if (newValIsAfter)
other_nbr_index = nbr_index + 1;
@@ -291,10 +291,10 @@ restart:
/*
* On some machines, newelemorder may be in a register that's
- * wider than float4. We need to force it to be rounded to
- * float4 precision before making the following comparisons,
- * or we'll get wrong results. (Such behavior violates the C
- * standard, but fixing the compilers is out of our reach.)
+ * wider than float4. We need to force it to be rounded to float4
+ * precision before making the following comparisons, or we'll get
+ * wrong results. (Such behavior violates the C standard, but
+ * fixing the compilers is out of our reach.)
*/
newelemorder = DatumGetFloat4(Float4GetDatum(newelemorder));
@@ -314,9 +314,9 @@ restart:
if (OidIsValid(binary_upgrade_next_pg_enum_oid))
{
/*
- * Use binary-upgrade override for pg_enum.oid, if supplied.
- * During binary upgrade, all pg_enum.oid's are set this way
- * so they are guaranteed to be consistent.
+ * Use binary-upgrade override for pg_enum.oid, if supplied. During
+ * binary upgrade, all pg_enum.oid's are set this way so they are
+ * guaranteed to be consistent.
*/
if (neighbor != NULL)
ereport(ERROR,
@@ -337,7 +337,7 @@ restart:
*/
for (;;)
{
- bool sorts_ok;
+ bool sorts_ok;
/* Get a new OID (different from all existing pg_enum tuples) */
newOid = GetNewOid(pg_enum);
@@ -345,8 +345,8 @@ restart:
/*
* Detect whether it sorts correctly relative to existing
* even-numbered labels of the enum. We can ignore existing
- * labels with odd Oids, since a comparison involving one of
- * those will not take the fast path anyway.
+ * labels with odd Oids, since a comparison involving one of those
+ * will not take the fast path anyway.
*/
sorts_ok = true;
for (i = 0; i < nelems; i++)
@@ -385,9 +385,9 @@ restart:
break;
/*
- * If it's odd, and sorts OK, loop back to get another OID
- * and try again. Probably, the next available even OID
- * will sort correctly too, so it's worth trying.
+ * If it's odd, and sorts OK, loop back to get another OID and
+ * try again. Probably, the next available even OID will sort
+ * correctly too, so it's worth trying.
*/
}
else
@@ -435,7 +435,7 @@ restart:
* We avoid doing this unless absolutely necessary; in most installations
* it will never happen. The reason is that updating existing pg_enum
* entries creates hazards for other backends that are concurrently reading
- * pg_enum with SnapshotNow semantics. A concurrent SnapshotNow scan could
+ * pg_enum with SnapshotNow semantics. A concurrent SnapshotNow scan could
* see both old and new versions of an updated row as valid, or neither of
* them, if the commit happens between scanning the two versions. It's
* also quite likely for a concurrent scan to see an inconsistent set of
@@ -510,10 +510,10 @@ oid_cmp(const void *p1, const void *p2)
static int
sort_order_cmp(const void *p1, const void *p2)
{
- HeapTuple v1 = *((const HeapTuple *) p1);
- HeapTuple v2 = *((const HeapTuple *) p2);
- Form_pg_enum en1 = (Form_pg_enum) GETSTRUCT(v1);
- Form_pg_enum en2 = (Form_pg_enum) GETSTRUCT(v2);
+ HeapTuple v1 = *((const HeapTuple *) p1);
+ HeapTuple v2 = *((const HeapTuple *) p2);
+ Form_pg_enum en1 = (Form_pg_enum) GETSTRUCT(v1);
+ Form_pg_enum en2 = (Form_pg_enum) GETSTRUCT(v2);
if (en1->enumsortorder < en2->enumsortorder)
return -1;
diff --git a/src/backend/catalog/pg_proc.c b/src/backend/catalog/pg_proc.c
index 6138165cc3..47a8ff4d98 100644
--- a/src/backend/catalog/pg_proc.c
+++ b/src/backend/catalog/pg_proc.c
@@ -842,8 +842,8 @@ fmgr_sql_validator(PG_FUNCTION_ARGS)
if (!haspolyarg)
{
/*
- * OK to do full precheck: analyze and rewrite the queries,
- * then verify the result type.
+ * OK to do full precheck: analyze and rewrite the queries, then
+ * verify the result type.
*/
SQLFunctionParseInfoPtr pinfo;
@@ -858,7 +858,7 @@ fmgr_sql_validator(PG_FUNCTION_ARGS)
querytree_sublist = pg_analyze_and_rewrite_params(parsetree,
prosrc,
- (ParserSetupHook) sql_fn_parser_setup,
+ (ParserSetupHook) sql_fn_parser_setup,
pinfo);
querytree_list = list_concat(querytree_list,
querytree_sublist);
diff --git a/src/backend/catalog/pg_type.c b/src/backend/catalog/pg_type.c
index 06301c075b..9e35e73f9c 100644
--- a/src/backend/catalog/pg_type.c
+++ b/src/backend/catalog/pg_type.c
@@ -115,7 +115,7 @@ TypeShellMake(const char *typeName, Oid typeNamespace, Oid ownerId)
values[i++] = ObjectIdGetDatum(InvalidOid); /* typbasetype */
values[i++] = Int32GetDatum(-1); /* typtypmod */
values[i++] = Int32GetDatum(0); /* typndims */
- values[i++] = ObjectIdGetDatum(InvalidOid); /* typcollation */
+ values[i++] = ObjectIdGetDatum(InvalidOid); /* typcollation */
nulls[i++] = true; /* typdefaultbin */
nulls[i++] = true; /* typdefault */
@@ -352,7 +352,7 @@ TypeCreate(Oid newTypeOid,
values[i++] = ObjectIdGetDatum(baseType); /* typbasetype */
values[i++] = Int32GetDatum(typeMod); /* typtypmod */
values[i++] = Int32GetDatum(typNDims); /* typndims */
- values[i++] = ObjectIdGetDatum(typeCollation); /* typcollation */
+ values[i++] = ObjectIdGetDatum(typeCollation); /* typcollation */
/*
* initialize the default binary value for this type. Check for nulls of
diff --git a/src/backend/catalog/storage.c b/src/backend/catalog/storage.c
index 221f9f5c12..57987be2c0 100644
--- a/src/backend/catalog/storage.c
+++ b/src/backend/catalog/storage.c
@@ -119,7 +119,7 @@ RelationCreateStorage(RelFileNode rnode, char relpersistence)
break;
default:
elog(ERROR, "invalid relpersistence: %c", relpersistence);
- return; /* placate compiler */
+ return; /* placate compiler */
}
srel = smgropen(rnode, backend);
@@ -379,7 +379,7 @@ smgrDoPendingDeletes(bool isCommit)
* *ptr is set to point to a freshly-palloc'd array of RelFileNodes.
* If there are no relations to be deleted, *ptr is set to NULL.
*
- * Only non-temporary relations are included in the returned list. This is OK
+ * Only non-temporary relations are included in the returned list. This is OK
* because the list is used only in contexts where temporary relations don't
* matter: we're either writing to the two-phase state file (and transactions
* that have touched temp tables can't be prepared) or we're writing to xlog
diff --git a/src/backend/catalog/toasting.c b/src/backend/catalog/toasting.c
index 5d5496df98..452ca9bef0 100644
--- a/src/backend/catalog/toasting.c
+++ b/src/backend/catalog/toasting.c
@@ -279,7 +279,7 @@ create_toast_table(Relation rel, Oid toastOid, Oid toastIndexOid, Datum reloptio
list_make2("chunk_id", "chunk_seq"),
BTREE_AM_OID,
rel->rd_rel->reltablespace,
- collationObjectId, classObjectId, coloptions, (Datum) 0,
+ collationObjectId, classObjectId, coloptions, (Datum) 0,
true, false, false, false,
true, false, false);
diff --git a/src/backend/commands/alter.c b/src/backend/commands/alter.c
index 99fdd7dba3..215e21cae0 100644
--- a/src/backend/commands/alter.c
+++ b/src/backend/commands/alter.c
@@ -282,26 +282,26 @@ AlterObjectNamespace_oid(Oid classId, Oid objid, Oid nspOid)
switch (getObjectClass(&dep))
{
case OCLASS_CLASS:
- {
- Relation rel;
- Relation classRel;
+ {
+ Relation rel;
+ Relation classRel;
- rel = relation_open(objid, AccessExclusiveLock);
- oldNspOid = RelationGetNamespace(rel);
+ rel = relation_open(objid, AccessExclusiveLock);
+ oldNspOid = RelationGetNamespace(rel);
- classRel = heap_open(RelationRelationId, RowExclusiveLock);
+ classRel = heap_open(RelationRelationId, RowExclusiveLock);
- AlterRelationNamespaceInternal(classRel,
- objid,
- oldNspOid,
- nspOid,
- true);
+ AlterRelationNamespaceInternal(classRel,
+ objid,
+ oldNspOid,
+ nspOid,
+ true);
- heap_close(classRel, RowExclusiveLock);
+ heap_close(classRel, RowExclusiveLock);
- relation_close(rel, NoLock);
- break;
- }
+ relation_close(rel, NoLock);
+ break;
+ }
case OCLASS_PROC:
oldNspOid = AlterFunctionNamespace_oid(objid, nspOid);
@@ -386,9 +386,11 @@ AlterObjectNamespace(Relation rel, int oidCacheId, int nameCacheId,
{
Oid classId = RelationGetRelid(rel);
Oid oldNspOid;
- Datum name, namespace;
- bool isnull;
- HeapTuple tup, newtup;
+ Datum name,
+ namespace;
+ bool isnull;
+ HeapTuple tup,
+ newtup;
Datum *values;
bool *nulls;
bool *replaces;
@@ -410,7 +412,7 @@ AlterObjectNamespace(Relation rel, int oidCacheId, int nameCacheId,
/* Permission checks ... superusers can always do it */
if (!superuser())
{
- Datum owner;
+ Datum owner;
Oid ownerId;
AclResult aclresult;
diff --git a/src/backend/commands/analyze.c b/src/backend/commands/analyze.c
index 774bb04471..dde301b89a 100644
--- a/src/backend/commands/analyze.c
+++ b/src/backend/commands/analyze.c
@@ -95,7 +95,7 @@ static void compute_index_stats(Relation onerel, double totalrows,
HeapTuple *rows, int numrows,
MemoryContext col_context);
static VacAttrStats *examine_attribute(Relation onerel, int attnum,
- Node *index_expr);
+ Node *index_expr);
static int acquire_sample_rows(Relation onerel, HeapTuple *rows,
int targrows, double *totalrows, double *totaldeadrows);
static double random_fract(void);
@@ -160,8 +160,8 @@ analyze_rel(Oid relid, VacuumStmt *vacstmt,
if (IsAutoVacuumWorkerProcess() && Log_autovacuum_min_duration >= 0)
ereport(LOG,
(errcode(ERRCODE_LOCK_NOT_AVAILABLE),
- errmsg("skipping analyze of \"%s\" --- lock not available",
- vacstmt->relation->relname)));
+ errmsg("skipping analyze of \"%s\" --- lock not available",
+ vacstmt->relation->relname)));
}
if (!onerel)
return;
@@ -853,10 +853,10 @@ examine_attribute(Relation onerel, int attnum, Node *index_expr)
/*
* When analyzing an expression index, believe the expression tree's type
* not the column datatype --- the latter might be the opckeytype storage
- * type of the opclass, which is not interesting for our purposes. (Note:
+ * type of the opclass, which is not interesting for our purposes. (Note:
* if we did anything with non-expression index columns, we'd need to
* figure out where to get the correct type info from, but for now that's
- * not a problem.) It's not clear whether anyone will care about the
+ * not a problem.) It's not clear whether anyone will care about the
* typmod, but we store that too just in case.
*/
if (index_expr)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index 4c4f356e79..2cc2aaa8f6 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -718,7 +718,7 @@ copy_heap_data(Oid OIDNewHeap, Oid OIDOldHeap, Oid OIDOldIndex,
TransactionId OldestXmin;
TransactionId FreezeXid;
RewriteState rwstate;
- bool use_sort;
+ bool use_sort;
Tuplesortstate *tuplesort;
double num_tuples = 0,
tups_vacuumed = 0,
@@ -813,11 +813,11 @@ copy_heap_data(Oid OIDNewHeap, Oid OIDOldHeap, Oid OIDOldIndex,
rwstate = begin_heap_rewrite(NewHeap, OldestXmin, FreezeXid, use_wal);
/*
- * Decide whether to use an indexscan or seqscan-and-optional-sort to
- * scan the OldHeap. We know how to use a sort to duplicate the ordering
- * of a btree index, and will use seqscan-and-sort for that case if the
- * planner tells us it's cheaper. Otherwise, always indexscan if an
- * index is provided, else plain seqscan.
+ * Decide whether to use an indexscan or seqscan-and-optional-sort to scan
+ * the OldHeap. We know how to use a sort to duplicate the ordering of a
+ * btree index, and will use seqscan-and-sort for that case if the planner
+ * tells us it's cheaper. Otherwise, always indexscan if an index is
+ * provided, else plain seqscan.
*/
if (OldIndex != NULL && OldIndex->rd_rel->relam == BTREE_AM_OID)
use_sort = plan_cluster_use_sort(OIDOldHeap, OIDOldIndex);
@@ -869,8 +869,8 @@ copy_heap_data(Oid OIDNewHeap, Oid OIDOldHeap, Oid OIDOldIndex,
/*
* Scan through the OldHeap, either in OldIndex order or sequentially;
* copy each tuple into the NewHeap, or transiently to the tuplesort
- * module. Note that we don't bother sorting dead tuples (they won't
- * get to the new table anyway).
+ * module. Note that we don't bother sorting dead tuples (they won't get
+ * to the new table anyway).
*/
for (;;)
{
@@ -984,8 +984,8 @@ copy_heap_data(Oid OIDNewHeap, Oid OIDOldHeap, Oid OIDOldIndex,
heap_endscan(heapScan);
/*
- * In scan-and-sort mode, complete the sort, then read out all live
- * tuples from the tuplestore and write them to the new relation.
+ * In scan-and-sort mode, complete the sort, then read out all live tuples
+ * from the tuplestore and write them to the new relation.
*/
if (tuplesort != NULL)
{
@@ -1554,7 +1554,7 @@ reform_and_rewrite_tuple(HeapTuple tuple,
bool newRelHasOids, RewriteState rwstate)
{
HeapTuple copiedTuple;
- int i;
+ int i;
heap_deform_tuple(tuple, oldTupDesc, values, isnull);
diff --git a/src/backend/commands/collationcmds.c b/src/backend/commands/collationcmds.c
index 2a6938fd04..7f8a108374 100644
--- a/src/backend/commands/collationcmds.c
+++ b/src/backend/commands/collationcmds.c
@@ -34,7 +34,7 @@
#include "utils/syscache.h"
static void AlterCollationOwner_internal(Relation rel, Oid collationOid,
- Oid newOwnerId);
+ Oid newOwnerId);
/*
* CREATE COLLATION
@@ -46,10 +46,10 @@ DefineCollation(List *names, List *parameters)
Oid collNamespace;
AclResult aclresult;
ListCell *pl;
- DefElem *fromEl = NULL;
- DefElem *localeEl = NULL;
- DefElem *lccollateEl = NULL;
- DefElem *lcctypeEl = NULL;
+ DefElem *fromEl = NULL;
+ DefElem *localeEl = NULL;
+ DefElem *lccollateEl = NULL;
+ DefElem *lcctypeEl = NULL;
char *collcollate = NULL;
char *collctype = NULL;
Oid newoid;
@@ -63,7 +63,7 @@ DefineCollation(List *names, List *parameters)
foreach(pl, parameters)
{
- DefElem *defel = (DefElem *) lfirst(pl);
+ DefElem *defel = (DefElem *) lfirst(pl);
DefElem **defelp;
if (pg_strcasecmp(defel->defname, "from") == 0)
@@ -97,7 +97,7 @@ DefineCollation(List *names, List *parameters)
Oid collid;
HeapTuple tp;
- collid = get_collation_oid(defGetQualifiedName(fromEl), false);
+ collid = get_collation_oid(defGetQualifiedName(fromEl), false);
tp = SearchSysCache1(COLLOID, ObjectIdGetDatum(collid));
if (!HeapTupleIsValid(tp))
elog(ERROR, "cache lookup failed for collation %u", collid);
@@ -123,7 +123,7 @@ DefineCollation(List *names, List *parameters)
if (!collcollate)
ereport(ERROR,
(errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
- errmsg("parameter \"lc_collate\" parameter must be specified")));
+ errmsg("parameter \"lc_collate\" parameter must be specified")));
if (!collctype)
ereport(ERROR,
@@ -391,7 +391,7 @@ AlterCollationNamespace(List *name, const char *newschema)
Oid
AlterCollationNamespace_oid(Oid collOid, Oid newNspOid)
{
- Oid oldNspOid;
+ Oid oldNspOid;
Relation rel;
char *collation_name;
diff --git a/src/backend/commands/comment.c b/src/backend/commands/comment.c
index 3fbeefa018..d09bef0682 100644
--- a/src/backend/commands/comment.c
+++ b/src/backend/commands/comment.c
@@ -37,8 +37,8 @@
void
CommentObject(CommentStmt *stmt)
{
- ObjectAddress address;
- Relation relation;
+ ObjectAddress address;
+ Relation relation;
/*
* When loading a dump, we may see a COMMENT ON DATABASE for the old name
@@ -46,12 +46,13 @@ CommentObject(CommentStmt *stmt)
* (which is really pg_restore's fault, but for now we will work around
* the problem here). Consensus is that the best fix is to treat wrong
* database name as a WARNING not an ERROR; hence, the following special
- * case. (If the length of stmt->objname is not 1, get_object_address will
- * throw an error below; that's OK.)
+ * case. (If the length of stmt->objname is not 1, get_object_address
+ * will throw an error below; that's OK.)
*/
if (stmt->objtype == OBJECT_DATABASE && list_length(stmt->objname) == 1)
{
- char *database = strVal(linitial(stmt->objname));
+ char *database = strVal(linitial(stmt->objname));
+
if (!OidIsValid(get_database_oid(database, true)))
{
ereport(WARNING,
@@ -62,10 +63,10 @@ CommentObject(CommentStmt *stmt)
}
/*
- * Translate the parser representation that identifies this object into
- * an ObjectAddress. get_object_address() will throw an error if the
- * object does not exist, and will also acquire a lock on the target
- * to guard against concurrent DROP operations.
+ * Translate the parser representation that identifies this object into an
+ * ObjectAddress. get_object_address() will throw an error if the object
+ * does not exist, and will also acquire a lock on the target to guard
+ * against concurrent DROP operations.
*/
address = get_object_address(stmt->objtype, stmt->objname, stmt->objargs,
&relation, ShareUpdateExclusiveLock);
@@ -78,6 +79,7 @@ CommentObject(CommentStmt *stmt)
switch (stmt->objtype)
{
case OBJECT_COLUMN:
+
/*
* Allow comments only on columns of tables, views, composite
* types, and foreign tables (which are the only relkinds for
diff --git a/src/backend/commands/conversioncmds.c b/src/backend/commands/conversioncmds.c
index b5e4420ca8..2c1c6da900 100644
--- a/src/backend/commands/conversioncmds.c
+++ b/src/backend/commands/conversioncmds.c
@@ -335,7 +335,8 @@ AlterConversionOwner_internal(Relation rel, Oid conversionOid, Oid newOwnerId)
void
AlterConversionNamespace(List *name, const char *newschema)
{
- Oid convOid, nspOid;
+ Oid convOid,
+ nspOid;
Relation rel;
rel = heap_open(ConversionRelationId, RowExclusiveLock);
@@ -361,7 +362,7 @@ AlterConversionNamespace(List *name, const char *newschema)
Oid
AlterConversionNamespace_oid(Oid convOid, Oid newNspOid)
{
- Oid oldNspOid;
+ Oid oldNspOid;
Relation rel;
rel = heap_open(ConversionRelationId, RowExclusiveLock);
diff --git a/src/backend/commands/copy.c b/src/backend/commands/copy.c
index 3af0b09719..57429035e8 100644
--- a/src/backend/commands/copy.c
+++ b/src/backend/commands/copy.c
@@ -115,7 +115,7 @@ typedef struct CopyStateData
char *quote; /* CSV quote char (must be 1 byte) */
char *escape; /* CSV escape char (must be 1 byte) */
List *force_quote; /* list of column names */
- bool force_quote_all; /* FORCE QUOTE *? */
+ bool force_quote_all; /* FORCE QUOTE *? */
bool *force_quote_flags; /* per-column CSV FQ flags */
List *force_notnull; /* list of column names */
bool *force_notnull_flags; /* per-column CSV FNN flags */
@@ -161,8 +161,8 @@ typedef struct CopyStateData
/* field raw data pointers found by COPY FROM */
- int max_fields;
- char ** raw_fields;
+ int max_fields;
+ char **raw_fields;
/*
* Similarly, line_buf holds the whole input line being processed. The
@@ -266,10 +266,10 @@ static const char BinarySignature[11] = "PGCOPY\n\377\r\n\0";
/* non-export function prototypes */
static CopyState BeginCopy(bool is_from, Relation rel, Node *raw_query,
- const char *queryString, List *attnamelist, List *options);
+ const char *queryString, List *attnamelist, List *options);
static void EndCopy(CopyState cstate);
static CopyState BeginCopyTo(Relation rel, Node *query, const char *queryString,
- const char *filename, List *attnamelist, List *options);
+ const char *filename, List *attnamelist, List *options);
static void EndCopyTo(CopyState cstate);
static uint64 DoCopyTo(CopyState cstate);
static uint64 CopyTo(CopyState cstate);
@@ -278,8 +278,8 @@ static void CopyOneRowTo(CopyState cstate, Oid tupleOid,
static uint64 CopyFrom(CopyState cstate);
static bool CopyReadLine(CopyState cstate);
static bool CopyReadLineText(CopyState cstate);
-static int CopyReadAttributesText(CopyState cstate);
-static int CopyReadAttributesCSV(CopyState cstate);
+static int CopyReadAttributesText(CopyState cstate);
+static int CopyReadAttributesCSV(CopyState cstate);
static Datum CopyReadBinaryAttribute(CopyState cstate,
int column_no, FmgrInfo *flinfo,
Oid typioparam, int32 typmod,
@@ -748,17 +748,17 @@ DoCopy(const CopyStmt *stmt, const char *queryString)
if (stmt->relation)
{
- TupleDesc tupDesc;
- AclMode required_access = (is_from ? ACL_INSERT : ACL_SELECT);
- RangeTblEntry *rte;
- List *attnums;
- ListCell *cur;
+ TupleDesc tupDesc;
+ AclMode required_access = (is_from ? ACL_INSERT : ACL_SELECT);
+ RangeTblEntry *rte;
+ List *attnums;
+ ListCell *cur;
Assert(!stmt->query);
/* Open and lock the relation, using the appropriate lock type. */
rel = heap_openrv(stmt->relation,
- (is_from ? RowExclusiveLock : AccessShareLock));
+ (is_from ? RowExclusiveLock : AccessShareLock));
rte = makeNode(RangeTblEntry);
rte->rtekind = RTE_RELATION;
@@ -770,8 +770,8 @@ DoCopy(const CopyStmt *stmt, const char *queryString)
attnums = CopyGetAttnums(tupDesc, rel, stmt->attlist);
foreach(cur, attnums)
{
- int attno = lfirst_int(cur) -
- FirstLowInvalidHeapAttributeNumber;
+ int attno = lfirst_int(cur) -
+ FirstLowInvalidHeapAttributeNumber;
if (is_from)
rte->modifiedCols = bms_add_member(rte->modifiedCols, attno);
@@ -1136,8 +1136,8 @@ BeginCopy(bool is_from,
cstate = (CopyStateData *) palloc0(sizeof(CopyStateData));
/*
- * We allocate everything used by a cstate in a new memory context.
- * This avoids memory leaks during repeated use of COPY in a query.
+ * We allocate everything used by a cstate in a new memory context. This
+ * avoids memory leaks during repeated use of COPY in a query.
*/
cstate->copycontext = AllocSetContextCreate(CurrentMemoryContext,
"COPY",
@@ -1300,9 +1300,9 @@ BeginCopy(bool is_from,
cstate->file_encoding = pg_get_client_encoding();
/*
- * Set up encoding conversion info. Even if the file and server
- * encodings are the same, we must apply pg_any_to_server() to validate
- * data in multibyte encodings.
+ * Set up encoding conversion info. Even if the file and server encodings
+ * are the same, we must apply pg_any_to_server() to validate data in
+ * multibyte encodings.
*/
cstate->need_transcoding =
(cstate->file_encoding != GetDatabaseEncoding() ||
@@ -1552,8 +1552,8 @@ CopyTo(CopyState cstate)
*/
if (cstate->need_transcoding)
cstate->null_print_client = pg_server_to_any(cstate->null_print,
- cstate->null_print_len,
- cstate->file_encoding);
+ cstate->null_print_len,
+ cstate->file_encoding);
/* if a header has been requested send the line */
if (cstate->header_line)
@@ -2001,9 +2001,9 @@ CopyFrom(CopyState cstate)
{
slot = ExecBRInsertTriggers(estate, resultRelInfo, slot);
- if (slot == NULL) /* "do nothing" */
+ if (slot == NULL) /* "do nothing" */
skip_tuple = true;
- else /* trigger might have changed tuple */
+ else /* trigger might have changed tuple */
tuple = ExecMaterializeSlot(slot);
}
@@ -2159,7 +2159,7 @@ BeginCopyFrom(Relation rel,
{
/* Initialize expressions in copycontext. */
defexprs[num_defaults] = ExecInitExpr(
- expression_planner((Expr *) defexpr), NULL);
+ expression_planner((Expr *) defexpr), NULL);
defmap[num_defaults] = attnum - 1;
num_defaults++;
}
@@ -2255,7 +2255,7 @@ BeginCopyFrom(Relation rel,
if (!cstate->binary)
{
AttrNumber attr_count = list_length(cstate->attnumlist);
- int nfields = cstate->file_has_oids ? (attr_count + 1) : attr_count;
+ int nfields = cstate->file_has_oids ? (attr_count + 1) : attr_count;
cstate->max_fields = nfields;
cstate->raw_fields = (char **) palloc(nfields * sizeof(char *));
@@ -2291,7 +2291,7 @@ NextCopyFromRawFields(CopyState cstate, char ***fields, int *nfields)
{
cstate->cur_lineno++;
if (CopyReadLine(cstate))
- return false; /* done */
+ return false; /* done */
}
cstate->cur_lineno++;
@@ -2300,9 +2300,9 @@ NextCopyFromRawFields(CopyState cstate, char ***fields, int *nfields)
done = CopyReadLine(cstate);
/*
- * EOF at start of line means we're done. If we see EOF after
- * some characters, we act as though it was newline followed by
- * EOF, ie, process the line and then exit loop on next iteration.
+ * EOF at start of line means we're done. If we see EOF after some
+ * characters, we act as though it was newline followed by EOF, ie,
+ * process the line and then exit loop on next iteration.
*/
if (done && cstate->line_buf.len == 0)
return false;
@@ -2341,7 +2341,7 @@ NextCopyFrom(CopyState cstate, ExprContext *econtext,
FmgrInfo *in_functions = cstate->in_functions;
Oid *typioparams = cstate->typioparams;
int i;
- int nfields;
+ int nfields;
bool isnull;
bool file_has_oids = cstate->file_has_oids;
int *defmap = cstate->defmap;
@@ -2456,18 +2456,18 @@ NextCopyFrom(CopyState cstate, ExprContext *econtext,
if (fld_count == -1)
{
/*
- * Received EOF marker. In a V3-protocol copy, wait for
- * the protocol-level EOF, and complain if it doesn't come
- * immediately. This ensures that we correctly handle
- * CopyFail, if client chooses to send that now.
+ * Received EOF marker. In a V3-protocol copy, wait for the
+ * protocol-level EOF, and complain if it doesn't come
+ * immediately. This ensures that we correctly handle CopyFail,
+ * if client chooses to send that now.
*
- * Note that we MUST NOT try to read more data in an
- * old-protocol copy, since there is no protocol-level EOF
- * marker then. We could go either way for copy from file,
- * but choose to throw error if there's data after the EOF
- * marker, for consistency with the new-protocol case.
+ * Note that we MUST NOT try to read more data in an old-protocol
+ * copy, since there is no protocol-level EOF marker then. We
+ * could go either way for copy from file, but choose to throw
+ * error if there's data after the EOF marker, for consistency
+ * with the new-protocol case.
*/
- char dummy;
+ char dummy;
if (cstate->copy_dest != COPY_OLD_FE &&
CopyGetData(cstate, &dummy, 1, 1) > 0)
@@ -2485,14 +2485,14 @@ NextCopyFrom(CopyState cstate, ExprContext *econtext,
if (file_has_oids)
{
- Oid loaded_oid;
+ Oid loaded_oid;
cstate->cur_attname = "oid";
loaded_oid =
DatumGetObjectId(CopyReadBinaryAttribute(cstate,
0,
- &cstate->oid_in_function,
- cstate->oid_typioparam,
+ &cstate->oid_in_function,
+ cstate->oid_typioparam,
-1,
&isnull));
if (isnull || loaded_oid == InvalidOid)
@@ -2524,8 +2524,8 @@ NextCopyFrom(CopyState cstate, ExprContext *econtext,
/*
* Now compute and insert any defaults available for the columns not
- * provided by the input data. Anything not processed here or above
- * will remain NULL.
+ * provided by the input data. Anything not processed here or above will
+ * remain NULL.
*/
for (i = 0; i < num_defaults; i++)
{
@@ -3023,12 +3023,12 @@ GetDecimalFromHex(char hex)
* performing de-escaping as needed.
*
* The input is in line_buf. We use attribute_buf to hold the result
- * strings. cstate->raw_fields[k] is set to point to the k'th attribute
- * string, or NULL when the input matches the null marker string.
+ * strings. cstate->raw_fields[k] is set to point to the k'th attribute
+ * string, or NULL when the input matches the null marker string.
* This array is expanded as necessary.
*
- * (Note that the caller cannot check for nulls since the returned
- * string would be the post-de-escaping equivalent, which may look
+ * (Note that the caller cannot check for nulls since the returned
+ * string would be the post-de-escaping equivalent, which may look
* the same as some valid data string.)
*
* delim is the column delimiter string (must be just one byte for now).
@@ -3090,8 +3090,8 @@ CopyReadAttributesText(CopyState cstate)
if (fieldno >= cstate->max_fields)
{
cstate->max_fields *= 2;
- cstate->raw_fields =
- repalloc(cstate->raw_fields, cstate->max_fields*sizeof(char *));
+ cstate->raw_fields =
+ repalloc(cstate->raw_fields, cstate->max_fields * sizeof(char *));
}
/* Remember start of field on both input and output sides */
@@ -3307,8 +3307,8 @@ CopyReadAttributesCSV(CopyState cstate)
if (fieldno >= cstate->max_fields)
{
cstate->max_fields *= 2;
- cstate->raw_fields =
- repalloc(cstate->raw_fields, cstate->max_fields*sizeof(char *));
+ cstate->raw_fields =
+ repalloc(cstate->raw_fields, cstate->max_fields * sizeof(char *));
}
/* Remember start of field on both input and output sides */
diff --git a/src/backend/commands/dbcommands.c b/src/backend/commands/dbcommands.c
index 87d9e545b4..f319eb539c 100644
--- a/src/backend/commands/dbcommands.c
+++ b/src/backend/commands/dbcommands.c
@@ -680,8 +680,8 @@ createdb(const CreatedbStmt *stmt)
void
check_encoding_locale_matches(int encoding, const char *collate, const char *ctype)
{
- int ctype_encoding = pg_get_encoding_from_locale(ctype, true);
- int collate_encoding = pg_get_encoding_from_locale(collate, true);
+ int ctype_encoding = pg_get_encoding_from_locale(ctype, true);
+ int collate_encoding = pg_get_encoding_from_locale(collate, true);
if (!(ctype_encoding == encoding ||
ctype_encoding == PG_SQL_ASCII ||
@@ -1849,10 +1849,10 @@ get_database_oid(const char *dbname, bool missing_ok)
heap_close(pg_database, AccessShareLock);
if (!OidIsValid(oid) && !missing_ok)
- ereport(ERROR,
- (errcode(ERRCODE_UNDEFINED_DATABASE),
- errmsg("database \"%s\" does not exist",
- dbname)));
+ ereport(ERROR,
+ (errcode(ERRCODE_UNDEFINED_DATABASE),
+ errmsg("database \"%s\" does not exist",
+ dbname)));
return oid;
}
diff --git a/src/backend/commands/explain.c b/src/backend/commands/explain.c
index 1d9586f07d..7a361585bd 100644
--- a/src/backend/commands/explain.c
+++ b/src/backend/commands/explain.c
@@ -59,26 +59,26 @@ static void ExplainNode(PlanState *planstate, List *ancestors,
const char *relationship, const char *plan_name,
ExplainState *es);
static void show_plan_tlist(PlanState *planstate, List *ancestors,
- ExplainState *es);
+ ExplainState *es);
static void show_expression(Node *node, const char *qlabel,
PlanState *planstate, List *ancestors,
bool useprefix, ExplainState *es);
static void show_qual(List *qual, const char *qlabel,
- PlanState *planstate, List *ancestors,
- bool useprefix, ExplainState *es);
+ PlanState *planstate, List *ancestors,
+ bool useprefix, ExplainState *es);
static void show_scan_qual(List *qual, const char *qlabel,
- PlanState *planstate, List *ancestors,
- ExplainState *es);
+ PlanState *planstate, List *ancestors,
+ ExplainState *es);
static void show_upper_qual(List *qual, const char *qlabel,
- PlanState *planstate, List *ancestors,
- ExplainState *es);
+ PlanState *planstate, List *ancestors,
+ ExplainState *es);
static void show_sort_keys(SortState *sortstate, List *ancestors,
- ExplainState *es);
+ ExplainState *es);
static void show_merge_append_keys(MergeAppendState *mstate, List *ancestors,
- ExplainState *es);
+ ExplainState *es);
static void show_sort_keys_common(PlanState *planstate,
- int nkeys, AttrNumber *keycols,
- List *ancestors, ExplainState *es);
+ int nkeys, AttrNumber *keycols,
+ List *ancestors, ExplainState *es);
static void show_sort_info(SortState *sortstate, ExplainState *es);
static void show_hash_info(HashState *hashstate, ExplainState *es);
static void show_foreignscan_info(ForeignScanState *fsstate, ExplainState *es);
@@ -89,7 +89,7 @@ static void ExplainTargetRel(Plan *plan, Index rti, ExplainState *es);
static void ExplainMemberNodes(List *plans, PlanState **planstates,
List *ancestors, ExplainState *es);
static void ExplainSubPlans(List *plans, List *ancestors,
- const char *relationship, ExplainState *es);
+ const char *relationship, ExplainState *es);
static void ExplainProperty(const char *qlabel, const char *value,
bool numeric, ExplainState *es);
static void ExplainOpenGroup(const char *objtype, const char *labelname,
@@ -1358,7 +1358,7 @@ show_scan_qual(List *qual, const char *qlabel,
{
bool useprefix;
- useprefix = (IsA(planstate->plan, SubqueryScan) || es->verbose);
+ useprefix = (IsA(planstate->plan, SubqueryScan) ||es->verbose);
show_qual(qual, qlabel, planstate, ancestors, useprefix, es);
}
diff --git a/src/backend/commands/extension.c b/src/backend/commands/extension.c
index 7c3e8107de..d848926ae5 100644
--- a/src/backend/commands/extension.c
+++ b/src/backend/commands/extension.c
@@ -56,8 +56,8 @@
/* Globally visible state variables */
-bool creating_extension = false;
-Oid CurrentExtensionObject = InvalidOid;
+bool creating_extension = false;
+Oid CurrentExtensionObject = InvalidOid;
/*
* Internal data structure to hold the results of parsing a control file
@@ -66,8 +66,8 @@ typedef struct ExtensionControlFile
{
char *name; /* name of the extension */
char *directory; /* directory for script files */
- char *default_version; /* default install target version, if any */
- char *module_pathname; /* string to substitute for MODULE_PATHNAME */
+ char *default_version; /* default install target version, if any */
+ char *module_pathname; /* string to substitute for MODULE_PATHNAME */
char *comment; /* comment, if any */
char *schema; /* target schema (allowed if !relocatable) */
bool relocatable; /* is ALTER EXTENSION SET SCHEMA supported? */
@@ -85,9 +85,9 @@ typedef struct ExtensionVersionInfo
List *reachable; /* List of ExtensionVersionInfo's */
bool installable; /* does this version have an install script? */
/* working state for Dijkstra's algorithm: */
- bool distance_known; /* is distance from start known yet? */
+ bool distance_known; /* is distance from start known yet? */
int distance; /* current worst-case distance estimate */
- struct ExtensionVersionInfo *previous; /* current best predecessor */
+ struct ExtensionVersionInfo *previous; /* current best predecessor */
} ExtensionVersionInfo;
/* Local functions */
@@ -107,7 +107,7 @@ static void ApplyExtensionUpdates(Oid extensionOid,
/*
* get_extension_oid - given an extension name, look up the OID
*
- * If missing_ok is false, throw an error if extension name not found. If
+ * If missing_ok is false, throw an error if extension name not found. If
* true, just return InvalidOid.
*/
Oid
@@ -142,10 +142,10 @@ get_extension_oid(const char *extname, bool missing_ok)
heap_close(rel, AccessShareLock);
if (!OidIsValid(result) && !missing_ok)
- ereport(ERROR,
- (errcode(ERRCODE_UNDEFINED_OBJECT),
- errmsg("extension \"%s\" does not exist",
- extname)));
+ ereport(ERROR,
+ (errcode(ERRCODE_UNDEFINED_OBJECT),
+ errmsg("extension \"%s\" does not exist",
+ extname)));
return result;
}
@@ -237,8 +237,8 @@ check_valid_extension_name(const char *extensionname)
int namelen = strlen(extensionname);
/*
- * Disallow empty names (the parser rejects empty identifiers anyway,
- * but let's check).
+ * Disallow empty names (the parser rejects empty identifiers anyway, but
+ * let's check).
*/
if (namelen == 0)
ereport(ERROR,
@@ -256,16 +256,16 @@ check_valid_extension_name(const char *extensionname)
errdetail("Extension names must not contain \"--\".")));
/*
- * No leading or trailing dash either. (We could probably allow this,
- * but it would require much care in filename parsing and would make
- * filenames visually if not formally ambiguous. Since there's no
- * real-world use case, let's just forbid it.)
+ * No leading or trailing dash either. (We could probably allow this, but
+ * it would require much care in filename parsing and would make filenames
+ * visually if not formally ambiguous. Since there's no real-world use
+ * case, let's just forbid it.)
*/
if (extensionname[0] == '-' || extensionname[namelen - 1] == '-')
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
errmsg("invalid extension name: \"%s\"", extensionname),
- errdetail("Extension names must not begin or end with \"-\".")));
+ errdetail("Extension names must not begin or end with \"-\".")));
/*
* No directory separators either (this is sufficient to prevent ".."
@@ -290,7 +290,7 @@ check_valid_version_name(const char *versionname)
if (namelen == 0)
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
- errmsg("invalid extension version name: \"%s\"", versionname),
+ errmsg("invalid extension version name: \"%s\"", versionname),
errdetail("Version names must not be empty.")));
/*
@@ -299,7 +299,7 @@ check_valid_version_name(const char *versionname)
if (strstr(versionname, "--"))
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
- errmsg("invalid extension version name: \"%s\"", versionname),
+ errmsg("invalid extension version name: \"%s\"", versionname),
errdetail("Version names must not contain \"--\".")));
/*
@@ -308,8 +308,8 @@ check_valid_version_name(const char *versionname)
if (versionname[0] == '-' || versionname[namelen - 1] == '-')
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
- errmsg("invalid extension version name: \"%s\"", versionname),
- errdetail("Version names must not begin or end with \"-\".")));
+ errmsg("invalid extension version name: \"%s\"", versionname),
+ errdetail("Version names must not begin or end with \"-\".")));
/*
* No directory separators either (this is sufficient to prevent ".."
@@ -318,7 +318,7 @@ check_valid_version_name(const char *versionname)
if (first_dir_separator(versionname) != NULL)
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
- errmsg("invalid extension version name: \"%s\"", versionname),
+ errmsg("invalid extension version name: \"%s\"", versionname),
errdetail("Version names must not contain directory separator characters.")));
}
@@ -386,7 +386,7 @@ get_extension_script_directory(ExtensionControlFile *control)
get_share_path(my_exec_path, sharepath);
result = (char *) palloc(MAXPGPATH);
- snprintf(result, MAXPGPATH, "%s/%s", sharepath, control->directory);
+ snprintf(result, MAXPGPATH, "%s/%s", sharepath, control->directory);
return result;
}
@@ -434,7 +434,7 @@ get_extension_script_filename(ExtensionControlFile *control,
/*
* Parse contents of primary or auxiliary control file, and fill in
- * fields of *control. We parse primary file if version == NULL,
+ * fields of *control. We parse primary file if version == NULL,
* else the optional auxiliary file for that version.
*
* Control files are supposed to be very short, half a dozen lines,
@@ -448,8 +448,8 @@ parse_extension_control_file(ExtensionControlFile *control,
char *filename;
FILE *file;
ConfigVariable *item,
- *head = NULL,
- *tail = NULL;
+ *head = NULL,
+ *tail = NULL;
/*
* Locate the file to read. Auxiliary files are optional.
@@ -553,8 +553,8 @@ parse_extension_control_file(ExtensionControlFile *control,
/* syntax error in name list */
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
- errmsg("parameter \"%s\" must be a list of extension names",
- item->name)));
+ errmsg("parameter \"%s\" must be a list of extension names",
+ item->name)));
}
}
else
@@ -632,12 +632,12 @@ static char *
read_extension_script_file(const ExtensionControlFile *control,
const char *filename)
{
- int src_encoding;
- int dest_encoding = GetDatabaseEncoding();
- bytea *content;
+ int src_encoding;
+ int dest_encoding = GetDatabaseEncoding();
+ bytea *content;
char *src_str;
- char *dest_str;
- int len;
+ char *dest_str;
+ int len;
content = read_binary_file(filename, 0, -1);
@@ -675,7 +675,7 @@ read_extension_script_file(const ExtensionControlFile *control,
* filename is used only to report errors.
*
* Note: it's tempting to just use SPI to execute the string, but that does
- * not work very well. The really serious problem is that SPI will parse,
+ * not work very well. The really serious problem is that SPI will parse,
* analyze, and plan the whole string before executing any of it; of course
* this fails if there are any plannable statements referring to objects
* created earlier in the script. A lesser annoyance is that SPI insists
@@ -774,7 +774,7 @@ execute_extension_script(Oid extensionOid, ExtensionControlFile *control,
List *requiredSchemas,
const char *schemaName, Oid schemaOid)
{
- char *filename;
+ char *filename;
char *save_client_min_messages,
*save_log_min_messages,
*save_search_path;
@@ -809,8 +809,8 @@ execute_extension_script(Oid extensionOid, ExtensionControlFile *control,
* so that we won't spam the user with useless NOTICE messages from common
* script actions like creating shell types.
*
- * We use the equivalent of SET LOCAL to ensure the setting is undone
- * upon error.
+ * We use the equivalent of SET LOCAL to ensure the setting is undone upon
+ * error.
*/
save_client_min_messages =
pstrdup(GetConfigOption("client_min_messages", false));
@@ -832,8 +832,8 @@ execute_extension_script(Oid extensionOid, ExtensionControlFile *control,
* makes the target schema be the default creation target namespace.
*
* Note: it might look tempting to use PushOverrideSearchPath for this,
- * but we cannot do that. We have to actually set the search_path GUC
- * in case the extension script examines or changes it.
+ * but we cannot do that. We have to actually set the search_path GUC in
+ * case the extension script examines or changes it.
*/
save_search_path = pstrdup(GetConfigOption("search_path", false));
@@ -855,32 +855,32 @@ execute_extension_script(Oid extensionOid, ExtensionControlFile *control,
/*
* Set creating_extension and related variables so that
* recordDependencyOnCurrentExtension and other functions do the right
- * things. On failure, ensure we reset these variables.
+ * things. On failure, ensure we reset these variables.
*/
creating_extension = true;
CurrentExtensionObject = extensionOid;
PG_TRY();
{
- char *sql = read_extension_script_file(control, filename);
+ char *sql = read_extension_script_file(control, filename);
/*
* If it's not relocatable, substitute the target schema name for
* occcurrences of @extschema@.
*
- * For a relocatable extension, we just run the script as-is.
- * There cannot be any need for @extschema@, else it wouldn't
- * be relocatable.
+ * For a relocatable extension, we just run the script as-is. There
+ * cannot be any need for @extschema@, else it wouldn't be
+ * relocatable.
*/
if (!control->relocatable)
{
- const char *qSchemaName = quote_identifier(schemaName);
+ const char *qSchemaName = quote_identifier(schemaName);
sql = text_to_cstring(
- DatumGetTextPP(
- DirectFunctionCall3(replace_text,
- CStringGetTextDatum(sql),
- CStringGetTextDatum("@extschema@"),
- CStringGetTextDatum(qSchemaName))));
+ DatumGetTextPP(
+ DirectFunctionCall3(replace_text,
+ CStringGetTextDatum(sql),
+ CStringGetTextDatum("@extschema@"),
+ CStringGetTextDatum(qSchemaName))));
}
/*
@@ -890,11 +890,11 @@ execute_extension_script(Oid extensionOid, ExtensionControlFile *control,
if (control->module_pathname)
{
sql = text_to_cstring(
- DatumGetTextPP(
- DirectFunctionCall3(replace_text,
- CStringGetTextDatum(sql),
- CStringGetTextDatum("MODULE_PATHNAME"),
- CStringGetTextDatum(control->module_pathname))));
+ DatumGetTextPP(
+ DirectFunctionCall3(replace_text,
+ CStringGetTextDatum(sql),
+ CStringGetTextDatum("MODULE_PATHNAME"),
+ CStringGetTextDatum(control->module_pathname))));
}
execute_sql_string(sql, filename);
@@ -1004,7 +1004,7 @@ get_ext_ver_list(ExtensionControlFile *control)
struct dirent *de;
location = get_extension_script_directory(control);
- dir = AllocateDir(location);
+ dir = AllocateDir(location);
while ((de = ReadDir(dir, location)) != NULL)
{
char *vername;
@@ -1094,7 +1094,7 @@ identify_update_path(ExtensionControlFile *control,
* is still good.
*
* Result is a List of names of versions to transition through (the initial
- * version is *not* included). Returns NIL if no such path.
+ * version is *not* included). Returns NIL if no such path.
*/
static List *
find_update_path(List *evi_list,
@@ -1132,7 +1132,7 @@ find_update_path(List *evi_list,
foreach(lc, evi->reachable)
{
ExtensionVersionInfo *evi2 = (ExtensionVersionInfo *) lfirst(lc);
- int newdist;
+ int newdist;
newdist = evi->distance + 1;
if (newdist < evi2->distance)
@@ -1178,10 +1178,10 @@ CreateExtension(CreateExtensionStmt *stmt)
DefElem *d_schema = NULL;
DefElem *d_new_version = NULL;
DefElem *d_old_version = NULL;
- char *schemaName;
+ char *schemaName;
Oid schemaOid;
- char *versionName;
- char *oldVersionName;
+ char *versionName;
+ char *oldVersionName;
Oid extowner = GetUserId();
ExtensionControlFile *pcontrol;
ExtensionControlFile *control;
@@ -1195,10 +1195,10 @@ CreateExtension(CreateExtensionStmt *stmt)
check_valid_extension_name(stmt->extname);
/*
- * Check for duplicate extension name. The unique index on
+ * Check for duplicate extension name. The unique index on
* pg_extension.extname would catch this anyway, and serves as a backstop
- * in case of race conditions; but this is a friendlier error message,
- * and besides we need a check to support IF NOT EXISTS.
+ * in case of race conditions; but this is a friendlier error message, and
+ * besides we need a check to support IF NOT EXISTS.
*/
if (get_extension_oid(stmt->extname, true) != InvalidOid)
{
@@ -1218,8 +1218,8 @@ CreateExtension(CreateExtensionStmt *stmt)
}
/*
- * We use global variables to track the extension being created, so we
- * can create only one extension at the same time.
+ * We use global variables to track the extension being created, so we can
+ * create only one extension at the same time.
*/
if (creating_extension)
ereport(ERROR,
@@ -1306,8 +1306,8 @@ CreateExtension(CreateExtensionStmt *stmt)
if (list_length(updateVersions) == 1)
{
/*
- * Simple case where there's just one update script to run.
- * We will not need any follow-on update steps.
+ * Simple case where there's just one update script to run. We
+ * will not need any follow-on update steps.
*/
Assert(strcmp((char *) linitial(updateVersions), versionName) == 0);
updateVersions = NIL;
@@ -1351,9 +1351,9 @@ CreateExtension(CreateExtensionStmt *stmt)
strcmp(control->schema, schemaName) != 0)
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("extension \"%s\" must be installed in schema \"%s\"",
- control->name,
- control->schema)));
+ errmsg("extension \"%s\" must be installed in schema \"%s\"",
+ control->name,
+ control->schema)));
/* If the user is giving us the schema name, it must exist already */
schemaOid = get_namespace_oid(schemaName, false);
@@ -1362,7 +1362,7 @@ CreateExtension(CreateExtensionStmt *stmt)
{
/*
* The extension is not relocatable and the author gave us a schema
- * for it. We create the schema here if it does not already exist.
+ * for it. We create the schema here if it does not already exist.
*/
schemaName = control->schema;
schemaOid = get_namespace_oid(schemaName, true);
@@ -1380,13 +1380,13 @@ CreateExtension(CreateExtensionStmt *stmt)
* Else, use the current default creation namespace, which is the
* first explicit entry in the search_path.
*/
- List *search_path = fetch_search_path(false);
+ List *search_path = fetch_search_path(false);
- if (search_path == NIL) /* probably can't happen */
+ if (search_path == NIL) /* probably can't happen */
elog(ERROR, "there is no default creation target");
schemaOid = linitial_oid(search_path);
schemaName = get_namespace_name(schemaOid);
- if (schemaName == NULL) /* recently-deleted namespace? */
+ if (schemaName == NULL) /* recently-deleted namespace? */
elog(ERROR, "there is no default creation target");
list_free(search_path);
@@ -1397,13 +1397,13 @@ CreateExtension(CreateExtensionStmt *stmt)
* extension script actually creates any objects there, it will fail if
* the user doesn't have such permissions. But there are cases such as
* procedural languages where it's convenient to set schema = pg_catalog
- * yet we don't want to restrict the command to users with ACL_CREATE
- * for pg_catalog.
+ * yet we don't want to restrict the command to users with ACL_CREATE for
+ * pg_catalog.
*/
/*
- * Look up the prerequisite extensions, and build lists of their OIDs
- * and the OIDs of their target schemas.
+ * Look up the prerequisite extensions, and build lists of their OIDs and
+ * the OIDs of their target schemas.
*/
requiredExtensions = NIL;
requiredSchemas = NIL;
@@ -1453,8 +1453,8 @@ CreateExtension(CreateExtensionStmt *stmt)
schemaName, schemaOid);
/*
- * If additional update scripts have to be executed, apply the updates
- * as though a series of ALTER EXTENSION UPDATE commands were given
+ * If additional update scripts have to be executed, apply the updates as
+ * though a series of ALTER EXTENSION UPDATE commands were given
*/
ApplyExtensionUpdates(extensionOid, pcontrol,
versionName, updateVersions);
@@ -1653,7 +1653,7 @@ RemoveExtensionById(Oid extId)
/*
* This function lists the available extensions (one row per primary control
- * file in the control directory). We parse each control file and report the
+ * file in the control directory). We parse each control file and report the
* interesting fields.
*
* The system view pg_available_extensions provides a user interface to this
@@ -1663,14 +1663,14 @@ RemoveExtensionById(Oid extId)
Datum
pg_available_extensions(PG_FUNCTION_ARGS)
{
- ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo;
- TupleDesc tupdesc;
- Tuplestorestate *tupstore;
- MemoryContext per_query_ctx;
- MemoryContext oldcontext;
- char *location;
- DIR *dir;
- struct dirent *de;
+ ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo;
+ TupleDesc tupdesc;
+ Tuplestorestate *tupstore;
+ MemoryContext per_query_ctx;
+ MemoryContext oldcontext;
+ char *location;
+ DIR *dir;
+ struct dirent *de;
/* check to see if caller supports us returning a tuplestore */
if (rsinfo == NULL || !IsA(rsinfo, ReturnSetInfo))
@@ -1699,11 +1699,11 @@ pg_available_extensions(PG_FUNCTION_ARGS)
MemoryContextSwitchTo(oldcontext);
location = get_extension_control_directory();
- dir = AllocateDir(location);
+ dir = AllocateDir(location);
/*
- * If the control directory doesn't exist, we want to silently return
- * an empty set. Any other error will be reported by ReadDir.
+ * If the control directory doesn't exist, we want to silently return an
+ * empty set. Any other error will be reported by ReadDir.
*/
if (dir == NULL && errno == ENOENT)
{
@@ -1762,7 +1762,7 @@ pg_available_extensions(PG_FUNCTION_ARGS)
/*
* This function lists the available extension versions (one row per
- * extension installation script). For each version, we parse the related
+ * extension installation script). For each version, we parse the related
* control file(s) and report the interesting fields.
*
* The system view pg_available_extension_versions provides a user interface
@@ -1772,14 +1772,14 @@ pg_available_extensions(PG_FUNCTION_ARGS)
Datum
pg_available_extension_versions(PG_FUNCTION_ARGS)
{
- ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo;
- TupleDesc tupdesc;
- Tuplestorestate *tupstore;
- MemoryContext per_query_ctx;
- MemoryContext oldcontext;
- char *location;
- DIR *dir;
- struct dirent *de;
+ ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo;
+ TupleDesc tupdesc;
+ Tuplestorestate *tupstore;
+ MemoryContext per_query_ctx;
+ MemoryContext oldcontext;
+ char *location;
+ DIR *dir;
+ struct dirent *de;
/* check to see if caller supports us returning a tuplestore */
if (rsinfo == NULL || !IsA(rsinfo, ReturnSetInfo))
@@ -1808,11 +1808,11 @@ pg_available_extension_versions(PG_FUNCTION_ARGS)
MemoryContextSwitchTo(oldcontext);
location = get_extension_control_directory();
- dir = AllocateDir(location);
+ dir = AllocateDir(location);
/*
- * If the control directory doesn't exist, we want to silently return
- * an empty set. Any other error will be reported by ReadDir.
+ * If the control directory doesn't exist, we want to silently return an
+ * empty set. Any other error will be reported by ReadDir.
*/
if (dir == NULL && errno == ENOENT)
{
@@ -1867,7 +1867,7 @@ get_available_versions_for_extension(ExtensionControlFile *pcontrol,
struct dirent *de;
location = get_extension_script_directory(pcontrol);
- dir = AllocateDir(location);
+ dir = AllocateDir(location);
/* Note this will fail if script directory doesn't exist */
while ((de = ReadDir(dir, location)) != NULL)
{
@@ -1962,11 +1962,11 @@ Datum
pg_extension_update_paths(PG_FUNCTION_ARGS)
{
Name extname = PG_GETARG_NAME(0);
- ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo;
- TupleDesc tupdesc;
- Tuplestorestate *tupstore;
- MemoryContext per_query_ctx;
- MemoryContext oldcontext;
+ ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo;
+ TupleDesc tupdesc;
+ Tuplestorestate *tupstore;
+ MemoryContext per_query_ctx;
+ MemoryContext oldcontext;
List *evi_list;
ExtensionControlFile *control;
ListCell *lc1;
@@ -2079,8 +2079,8 @@ pg_extension_config_dump(PG_FUNCTION_ARGS)
text *wherecond = PG_GETARG_TEXT_P(1);
char *tablename;
Relation extRel;
- ScanKeyData key[1];
- SysScanDesc extScan;
+ ScanKeyData key[1];
+ SysScanDesc extScan;
HeapTuple extTup;
Datum arrayDatum;
Datum elementDatum;
@@ -2092,8 +2092,8 @@ pg_extension_config_dump(PG_FUNCTION_ARGS)
ArrayType *a;
/*
- * We only allow this to be called from an extension's SQL script.
- * We shouldn't need any permissions check beyond that.
+ * We only allow this to be called from an extension's SQL script. We
+ * shouldn't need any permissions check beyond that.
*/
if (!creating_extension)
ereport(ERROR,
@@ -2103,8 +2103,8 @@ pg_extension_config_dump(PG_FUNCTION_ARGS)
/*
* Check that the table exists and is a member of the extension being
- * created. This ensures that we don't need to register a dependency
- * to protect the extconfig entry.
+ * created. This ensures that we don't need to register a dependency to
+ * protect the extconfig entry.
*/
tablename = get_rel_name(tableoid);
if (tablename == NULL)
@@ -2115,12 +2115,12 @@ pg_extension_config_dump(PG_FUNCTION_ARGS)
CurrentExtensionObject)
ereport(ERROR,
(errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
- errmsg("table \"%s\" is not a member of the extension being created",
- tablename)));
+ errmsg("table \"%s\" is not a member of the extension being created",
+ tablename)));
/*
- * Add the table OID and WHERE condition to the extension's extconfig
- * and extcondition arrays.
+ * Add the table OID and WHERE condition to the extension's extconfig and
+ * extcondition arrays.
*/
/* Find the pg_extension tuple */
@@ -2136,7 +2136,7 @@ pg_extension_config_dump(PG_FUNCTION_ARGS)
extTup = systable_getnext(extScan);
- if (!HeapTupleIsValid(extTup)) /* should not happen */
+ if (!HeapTupleIsValid(extTup)) /* should not happen */
elog(ERROR, "extension with oid %u does not exist",
CurrentExtensionObject);
@@ -2162,7 +2162,7 @@ pg_extension_config_dump(PG_FUNCTION_ARGS)
Assert(ARR_NDIM(a) == 1);
Assert(ARR_LBOUND(a)[0] == 1);
- arrayIndex = ARR_DIMS(a)[0] + 1; /* add after end */
+ arrayIndex = ARR_DIMS(a)[0] + 1; /* add after end */
a = array_set(a, 1, &arrayIndex,
elementDatum,
@@ -2193,7 +2193,7 @@ pg_extension_config_dump(PG_FUNCTION_ARGS)
Assert(ARR_NDIM(a) == 1);
Assert(ARR_LBOUND(a)[0] == 1);
- arrayIndex = ARR_DIMS(a)[0] + 1; /* add after end */
+ arrayIndex = ARR_DIMS(a)[0] + 1; /* add after end */
a = array_set(a, 1, &arrayIndex,
elementDatum,
@@ -2231,12 +2231,12 @@ AlterExtensionNamespace(List *names, const char *newschema)
Oid oldNspOid = InvalidOid;
AclResult aclresult;
Relation extRel;
- ScanKeyData key[2];
- SysScanDesc extScan;
+ ScanKeyData key[2];
+ SysScanDesc extScan;
HeapTuple extTup;
Form_pg_extension extForm;
Relation depRel;
- SysScanDesc depScan;
+ SysScanDesc depScan;
HeapTuple depTup;
if (list_length(names) != 1)
@@ -2275,7 +2275,7 @@ AlterExtensionNamespace(List *names, const char *newschema)
extTup = systable_getnext(extScan);
- if (!HeapTupleIsValid(extTup)) /* should not happen */
+ if (!HeapTupleIsValid(extTup)) /* should not happen */
elog(ERROR, "extension with oid %u does not exist", extensionOid);
/* Copy tuple so we can modify it below */
@@ -2285,8 +2285,8 @@ AlterExtensionNamespace(List *names, const char *newschema)
systable_endscan(extScan);
/*
- * If the extension is already in the target schema, just silently
- * do nothing.
+ * If the extension is already in the target schema, just silently do
+ * nothing.
*/
if (extForm->extnamespace == nspOid)
{
@@ -2323,10 +2323,10 @@ AlterExtensionNamespace(List *names, const char *newschema)
{
Form_pg_depend pg_depend = (Form_pg_depend) GETSTRUCT(depTup);
ObjectAddress dep;
- Oid dep_oldNspOid;
+ Oid dep_oldNspOid;
/*
- * Ignore non-membership dependencies. (Currently, the only other
+ * Ignore non-membership dependencies. (Currently, the only other
* case we could see here is a normal dependency from another
* extension.)
*/
@@ -2388,13 +2388,13 @@ void
ExecAlterExtensionStmt(AlterExtensionStmt *stmt)
{
DefElem *d_new_version = NULL;
- char *versionName;
- char *oldVersionName;
+ char *versionName;
+ char *oldVersionName;
ExtensionControlFile *control;
Oid extensionOid;
Relation extRel;
- ScanKeyData key[1];
- SysScanDesc extScan;
+ ScanKeyData key[1];
+ SysScanDesc extScan;
HeapTuple extTup;
List *updateVersions;
Datum datum;
@@ -2402,8 +2402,8 @@ ExecAlterExtensionStmt(AlterExtensionStmt *stmt)
ListCell *lc;
/*
- * We use global variables to track the extension being created, so we
- * can create/update only one extension at the same time.
+ * We use global variables to track the extension being created, so we can
+ * create/update only one extension at the same time.
*/
if (creating_extension)
ereport(ERROR,
@@ -2426,10 +2426,10 @@ ExecAlterExtensionStmt(AlterExtensionStmt *stmt)
extTup = systable_getnext(extScan);
if (!HeapTupleIsValid(extTup))
- ereport(ERROR,
- (errcode(ERRCODE_UNDEFINED_OBJECT),
- errmsg("extension \"%s\" does not exist",
- stmt->extname)));
+ ereport(ERROR,
+ (errcode(ERRCODE_UNDEFINED_OBJECT),
+ errmsg("extension \"%s\" does not exist",
+ stmt->extname)));
extensionOid = HeapTupleGetOid(extTup);
@@ -2499,8 +2499,8 @@ ExecAlterExtensionStmt(AlterExtensionStmt *stmt)
if (strcmp(oldVersionName, versionName) == 0)
{
ereport(NOTICE,
- (errmsg("version \"%s\" of extension \"%s\" is already installed",
- versionName, stmt->extname)));
+ (errmsg("version \"%s\" of extension \"%s\" is already installed",
+ versionName, stmt->extname)));
return;
}
@@ -2545,8 +2545,8 @@ ApplyExtensionUpdates(Oid extensionOid,
List *requiredExtensions;
List *requiredSchemas;
Relation extRel;
- ScanKeyData key[1];
- SysScanDesc extScan;
+ ScanKeyData key[1];
+ SysScanDesc extScan;
HeapTuple extTup;
Form_pg_extension extForm;
Datum values[Natts_pg_extension];
@@ -2573,7 +2573,7 @@ ApplyExtensionUpdates(Oid extensionOid,
extTup = systable_getnext(extScan);
- if (!HeapTupleIsValid(extTup)) /* should not happen */
+ if (!HeapTupleIsValid(extTup)) /* should not happen */
elog(ERROR, "extension with oid %u does not exist",
extensionOid);
@@ -2668,9 +2668,9 @@ ApplyExtensionUpdates(Oid extensionOid,
schemaName, schemaOid);
/*
- * Update prior-version name and loop around. Since execute_sql_string
- * did a final CommandCounterIncrement, we can update the pg_extension
- * row again.
+ * Update prior-version name and loop around. Since
+ * execute_sql_string did a final CommandCounterIncrement, we can
+ * update the pg_extension row again.
*/
oldVersionName = versionName;
}
@@ -2682,10 +2682,10 @@ ApplyExtensionUpdates(Oid extensionOid,
void
ExecAlterExtensionContentsStmt(AlterExtensionContentsStmt *stmt)
{
- ObjectAddress extension;
- ObjectAddress object;
- Relation relation;
- Oid oldExtension;
+ ObjectAddress extension;
+ ObjectAddress object;
+ Relation relation;
+ Oid oldExtension;
extension.classId = ExtensionRelationId;
extension.objectId = get_extension_oid(stmt->extname, false);
@@ -2697,10 +2697,10 @@ ExecAlterExtensionContentsStmt(AlterExtensionContentsStmt *stmt)
stmt->extname);
/*
- * Translate the parser representation that identifies the object into
- * an ObjectAddress. get_object_address() will throw an error if the
- * object does not exist, and will also acquire a lock on the object to
- * guard against concurrent DROP and ALTER EXTENSION ADD/DROP operations.
+ * Translate the parser representation that identifies the object into an
+ * ObjectAddress. get_object_address() will throw an error if the object
+ * does not exist, and will also acquire a lock on the object to guard
+ * against concurrent DROP and ALTER EXTENSION ADD/DROP operations.
*/
object = get_object_address(stmt->objtype, stmt->objname, stmt->objargs,
&relation, ShareUpdateExclusiveLock);
diff --git a/src/backend/commands/foreigncmds.c b/src/backend/commands/foreigncmds.c
index 13d6d882f8..21d52e06ba 100644
--- a/src/backend/commands/foreigncmds.c
+++ b/src/backend/commands/foreigncmds.c
@@ -586,8 +586,8 @@ AlterForeignDataWrapper(AlterFdwStmt *stmt)
*/
if (OidIsValid(fdwvalidator))
ereport(WARNING,
- (errmsg("changing the foreign-data wrapper validator can cause "
- "the options for dependent objects to become invalid")));
+ (errmsg("changing the foreign-data wrapper validator can cause "
+ "the options for dependent objects to become invalid")));
}
else
{
@@ -643,8 +643,8 @@ AlterForeignDataWrapper(AlterFdwStmt *stmt)
ObjectAddress referenced;
/*
- * Flush all existing dependency records of this FDW on functions;
- * we assume there can be none other than the ones we are fixing.
+ * Flush all existing dependency records of this FDW on functions; we
+ * assume there can be none other than the ones we are fixing.
*/
deleteDependencyRecordsForClass(ForeignDataWrapperRelationId,
fdwId,
diff --git a/src/backend/commands/functioncmds.c b/src/backend/commands/functioncmds.c
index c8cbe035f0..03da168ff2 100644
--- a/src/backend/commands/functioncmds.c
+++ b/src/backend/commands/functioncmds.c
@@ -1665,7 +1665,7 @@ CreateCast(CreateCastStmt *stmt)
* We also disallow creating binary-compatibility casts involving
* domains. Casting from a domain to its base type is already
* allowed, and casting the other way ought to go through domain
- * coercion to permit constraint checking. Again, if you're intent on
+ * coercion to permit constraint checking. Again, if you're intent on
* having your own semantics for that, create a no-op cast function.
*
* NOTE: if we were to relax this, the above checks for composites
@@ -1830,7 +1830,7 @@ DropCast(DropCastStmt *stmt)
Oid
get_cast_oid(Oid sourcetypeid, Oid targettypeid, bool missing_ok)
{
- Oid oid;
+ Oid oid;
oid = GetSysCacheOid2(CASTSOURCETARGET,
ObjectIdGetDatum(sourcetypeid),
diff --git a/src/backend/commands/indexcmds.c b/src/backend/commands/indexcmds.c
index cfcce55967..05e8234a0f 100644
--- a/src/backend/commands/indexcmds.c
+++ b/src/backend/commands/indexcmds.c
@@ -395,7 +395,7 @@ DefineIndex(RangeVar *heapRelation,
indexRelationId =
index_create(rel, indexRelationName, indexRelationId,
indexInfo, indexColNames,
- accessMethodId, tablespaceId, collationObjectId, classObjectId,
+ accessMethodId, tablespaceId, collationObjectId, classObjectId,
coloptions, reloptions, primary,
isconstraint, deferrable, initdeferred,
allowSystemTableMods,
@@ -840,14 +840,14 @@ ComputeIndexAttrs(IndexInfo *indexInfo,
else
{
/* Index expression */
- Node *expr = attribute->expr;
+ Node *expr = attribute->expr;
Assert(expr != NULL);
atttype = exprType(expr);
attcollation = exprCollation(expr);
/*
- * Strip any top-level COLLATE clause. This ensures that we treat
+ * Strip any top-level COLLATE clause. This ensures that we treat
* "x COLLATE y" and "(x COLLATE y)" alike.
*/
while (IsA(expr, CollateExpr))
@@ -864,7 +864,7 @@ ComputeIndexAttrs(IndexInfo *indexInfo,
}
else
{
- indexInfo->ii_KeyAttrNumbers[attn] = 0; /* marks expression */
+ indexInfo->ii_KeyAttrNumbers[attn] = 0; /* marks expression */
indexInfo->ii_Expressions = lappend(indexInfo->ii_Expressions,
expr);
@@ -876,7 +876,7 @@ ComputeIndexAttrs(IndexInfo *indexInfo,
if (contain_subplans(expr))
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("cannot use subquery in index expression")));
+ errmsg("cannot use subquery in index expression")));
if (contain_agg_clause(expr))
ereport(ERROR,
(errcode(ERRCODE_GROUPING_ERROR),
@@ -904,8 +904,8 @@ ComputeIndexAttrs(IndexInfo *indexInfo,
/*
* Check we have a collation iff it's a collatable type. The only
* expected failures here are (1) COLLATE applied to a noncollatable
- * type, or (2) index expression had an unresolved collation. But
- * we might as well code this to be a complete consistency check.
+ * type, or (2) index expression had an unresolved collation. But we
+ * might as well code this to be a complete consistency check.
*/
if (type_is_collatable(atttype))
{
diff --git a/src/backend/commands/opclasscmds.c b/src/backend/commands/opclasscmds.c
index 68072dd421..aff5ac6ec4 100644
--- a/src/backend/commands/opclasscmds.c
+++ b/src/backend/commands/opclasscmds.c
@@ -126,7 +126,7 @@ OpFamilyCacheLookup(Oid amID, List *opfamilyname, bool missing_ok)
if (!HeapTupleIsValid(htup) && !missing_ok)
{
- HeapTuple amtup;
+ HeapTuple amtup;
amtup = SearchSysCache1(AMOID, ObjectIdGetDatum(amID));
if (!HeapTupleIsValid(amtup))
@@ -134,8 +134,8 @@ OpFamilyCacheLookup(Oid amID, List *opfamilyname, bool missing_ok)
ereport(ERROR,
(errcode(ERRCODE_UNDEFINED_OBJECT),
errmsg("operator family \"%s\" does not exist for access method \"%s\"",
- NameListToString(opfamilyname),
- NameStr(((Form_pg_am) GETSTRUCT(amtup))->amname))));
+ NameListToString(opfamilyname),
+ NameStr(((Form_pg_am) GETSTRUCT(amtup))->amname))));
}
return htup;
@@ -143,7 +143,7 @@ OpFamilyCacheLookup(Oid amID, List *opfamilyname, bool missing_ok)
/*
* get_opfamily_oid
- * find an opfamily OID by possibly qualified name
+ * find an opfamily OID by possibly qualified name
*
* If not found, returns InvalidOid if missing_ok, else throws error.
*/
@@ -202,7 +202,7 @@ OpClassCacheLookup(Oid amID, List *opclassname, bool missing_ok)
if (!HeapTupleIsValid(htup) && !missing_ok)
{
- HeapTuple amtup;
+ HeapTuple amtup;
amtup = SearchSysCache1(AMOID, ObjectIdGetDatum(amID));
if (!HeapTupleIsValid(amtup))
@@ -219,7 +219,7 @@ OpClassCacheLookup(Oid amID, List *opclassname, bool missing_ok)
/*
* get_opclass_oid
- * find an opclass OID by possibly qualified name
+ * find an opclass OID by possibly qualified name
*
* If not found, returns InvalidOid if missing_ok, else throws error.
*/
@@ -1088,11 +1088,11 @@ assignOperTypes(OpFamilyMember *member, Oid amoid, Oid typeoid)
if (OidIsValid(member->sortfamily))
{
/*
- * Ordering op, check index supports that. (We could perhaps also
+ * Ordering op, check index supports that. (We could perhaps also
* check that the operator returns a type supported by the sortfamily,
* but that seems more trouble than it's worth here. If it does not,
- * the operator will never be matchable to any ORDER BY clause, but
- * no worse consequences can ensue. Also, trying to check that would
+ * the operator will never be matchable to any ORDER BY clause, but no
+ * worse consequences can ensue. Also, trying to check that would
* create an ordering hazard during dump/reload: it's possible that
* the family has been created but not yet populated with the required
* operators.)
@@ -1108,8 +1108,8 @@ assignOperTypes(OpFamilyMember *member, Oid amoid, Oid typeoid)
if (!pg_am->amcanorderbyop)
ereport(ERROR,
(errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
- errmsg("access method \"%s\" does not support ordering operators",
- NameStr(pg_am->amname))));
+ errmsg("access method \"%s\" does not support ordering operators",
+ NameStr(pg_am->amname))));
ReleaseSysCache(amtup);
}
@@ -1276,7 +1276,7 @@ storeOperators(List *opfamilyname, Oid amoid,
foreach(l, operators)
{
OpFamilyMember *op = (OpFamilyMember *) lfirst(l);
- char oppurpose;
+ char oppurpose;
/*
* If adding to an existing family, check for conflict with an
@@ -1566,7 +1566,7 @@ RemoveOpClass(RemoveOpClassStmt *stmt)
{
ereport(NOTICE,
(errmsg("operator class \"%s\" does not exist for access method \"%s\"",
- NameListToString(stmt->opclassname), stmt->amname)));
+ NameListToString(stmt->opclassname), stmt->amname)));
return;
}
@@ -1617,7 +1617,7 @@ RemoveOpFamily(RemoveOpFamilyStmt *stmt)
ereport(ERROR,
(errcode(ERRCODE_UNDEFINED_OBJECT),
errmsg("operator family \"%s\" does not exist for access method \"%s\"",
- NameListToString(stmt->opfamilyname), stmt->amname)));
+ NameListToString(stmt->opfamilyname), stmt->amname)));
return;
}
@@ -2029,7 +2029,7 @@ AlterOpClassNamespace(List *name, char *access_method, const char *newschema)
Oid
AlterOpClassNamespace_oid(Oid opclassOid, Oid newNspOid)
{
- Oid oldNspOid;
+ Oid oldNspOid;
Relation rel;
rel = heap_open(OperatorClassRelationId, RowExclusiveLock);
@@ -2238,7 +2238,7 @@ AlterOpFamilyNamespace(List *name, char *access_method, const char *newschema)
Oid
AlterOpFamilyNamespace_oid(Oid opfamilyOid, Oid newNspOid)
{
- Oid oldNspOid;
+ Oid oldNspOid;
Relation rel;
rel = heap_open(OperatorFamilyRelationId, RowExclusiveLock);
diff --git a/src/backend/commands/operatorcmds.c b/src/backend/commands/operatorcmds.c
index b4374a62f4..c99de4b240 100644
--- a/src/backend/commands/operatorcmds.c
+++ b/src/backend/commands/operatorcmds.c
@@ -464,7 +464,8 @@ AlterOperatorNamespace(List *names, List *argtypes, const char *newschema)
List *operatorName = names;
TypeName *typeName1 = (TypeName *) linitial(argtypes);
TypeName *typeName2 = (TypeName *) lsecond(argtypes);
- Oid operOid, nspOid;
+ Oid operOid,
+ nspOid;
Relation rel;
rel = heap_open(OperatorRelationId, RowExclusiveLock);
@@ -490,7 +491,7 @@ AlterOperatorNamespace(List *names, List *argtypes, const char *newschema)
Oid
AlterOperatorNamespace_oid(Oid operOid, Oid newNspOid)
{
- Oid oldNspOid;
+ Oid oldNspOid;
Relation rel;
rel = heap_open(OperatorRelationId, RowExclusiveLock);
diff --git a/src/backend/commands/portalcmds.c b/src/backend/commands/portalcmds.c
index 60aca3ce8e..89086aa371 100644
--- a/src/backend/commands/portalcmds.c
+++ b/src/backend/commands/portalcmds.c
@@ -255,10 +255,10 @@ PortalCleanup(Portal portal)
if (queryDesc)
{
/*
- * Reset the queryDesc before anything else. This prevents us
- * from trying to shut down the executor twice, in case of an
- * error below. The transaction abort mechanisms will take care
- * of resource cleanup in such a case.
+ * Reset the queryDesc before anything else. This prevents us from
+ * trying to shut down the executor twice, in case of an error below.
+ * The transaction abort mechanisms will take care of resource cleanup
+ * in such a case.
*/
portal->queryDesc = NULL;
diff --git a/src/backend/commands/prepare.c b/src/backend/commands/prepare.c
index adbf5872f3..dfa2ab0026 100644
--- a/src/backend/commands/prepare.c
+++ b/src/backend/commands/prepare.c
@@ -382,7 +382,7 @@ EvaluateParams(PreparedStatement *pstmt, List *params,
/* sizeof(ParamListInfoData) includes the first array element */
paramLI = (ParamListInfo)
palloc(sizeof(ParamListInfoData) +
- (num_params - 1) *sizeof(ParamExternData));
+ (num_params - 1) * sizeof(ParamExternData));
/* we have static list of params, so no hooks needed */
paramLI->paramFetch = NULL;
paramLI->paramFetchArg = NULL;
diff --git a/src/backend/commands/seclabel.c b/src/backend/commands/seclabel.c
index 1c96b005d7..7afb7139a6 100644
--- a/src/backend/commands/seclabel.c
+++ b/src/backend/commands/seclabel.c
@@ -1,7 +1,7 @@
/* -------------------------------------------------------------------------
*
* seclabel.c
- * routines to support security label feature.
+ * routines to support security label feature.
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
@@ -28,7 +28,7 @@
typedef struct
{
const char *provider_name;
- check_object_relabel_type hook;
+ check_object_relabel_type hook;
} LabelProvider;
static List *label_provider_list = NIL;
@@ -42,9 +42,9 @@ void
ExecSecLabelStmt(SecLabelStmt *stmt)
{
LabelProvider *provider = NULL;
- ObjectAddress address;
- Relation relation;
- ListCell *lc;
+ ObjectAddress address;
+ Relation relation;
+ ListCell *lc;
/*
* Find the named label provider, or if none specified, check whether
@@ -55,16 +55,16 @@ ExecSecLabelStmt(SecLabelStmt *stmt)
if (label_provider_list == NIL)
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
- errmsg("no security label providers have been loaded")));
+ errmsg("no security label providers have been loaded")));
if (lnext(list_head(label_provider_list)) != NULL)
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
- errmsg("must specify provider when multiple security label providers have been loaded")));
+ errmsg("must specify provider when multiple security label providers have been loaded")));
provider = (LabelProvider *) linitial(label_provider_list);
}
else
{
- foreach (lc, label_provider_list)
+ foreach(lc, label_provider_list)
{
LabelProvider *lp = lfirst(lc);
@@ -82,10 +82,10 @@ ExecSecLabelStmt(SecLabelStmt *stmt)
}
/*
- * Translate the parser representation which identifies this object
- * into an ObjectAddress. get_object_address() will throw an error if
- * the object does not exist, and will also acquire a lock on the
- * target to guard against concurrent modifications.
+ * Translate the parser representation which identifies this object into
+ * an ObjectAddress. get_object_address() will throw an error if the
+ * object does not exist, and will also acquire a lock on the target to
+ * guard against concurrent modifications.
*/
address = get_object_address(stmt->objtype, stmt->objname, stmt->objargs,
&relation, ShareUpdateExclusiveLock);
@@ -98,6 +98,7 @@ ExecSecLabelStmt(SecLabelStmt *stmt)
switch (stmt->objtype)
{
case OBJECT_COLUMN:
+
/*
* Allow security labels only on columns of tables, views,
* composite types, and foreign tables (which are the only
@@ -117,7 +118,7 @@ ExecSecLabelStmt(SecLabelStmt *stmt)
}
/* Provider gets control here, may throw ERROR to veto new label. */
- (*provider->hook)(&address, stmt->label);
+ (*provider->hook) (&address, stmt->label);
/* Apply new label. */
SetSecurityLabel(&address, provider->provider_name, stmt->label);
@@ -140,8 +141,8 @@ char *
GetSecurityLabel(const ObjectAddress *object, const char *provider)
{
Relation pg_seclabel;
- ScanKeyData keys[4];
- SysScanDesc scan;
+ ScanKeyData keys[4];
+ SysScanDesc scan;
HeapTuple tuple;
Datum datum;
bool isnull;
@@ -196,8 +197,8 @@ SetSecurityLabel(const ObjectAddress *object,
const char *provider, const char *label)
{
Relation pg_seclabel;
- ScanKeyData keys[4];
- SysScanDesc scan;
+ ScanKeyData keys[4];
+ SysScanDesc scan;
HeapTuple oldtup;
HeapTuple newtup = NULL;
Datum values[Natts_pg_seclabel];
@@ -281,8 +282,8 @@ void
DeleteSecurityLabel(const ObjectAddress *object)
{
Relation pg_seclabel;
- ScanKeyData skey[3];
- SysScanDesc scan;
+ ScanKeyData skey[3];
+ SysScanDesc scan;
HeapTuple oldtup;
int nkeys;
@@ -323,8 +324,8 @@ DeleteSecurityLabel(const ObjectAddress *object)
void
register_label_provider(const char *provider_name, check_object_relabel_type hook)
{
- LabelProvider *provider;
- MemoryContext oldcxt;
+ LabelProvider *provider;
+ MemoryContext oldcxt;
oldcxt = MemoryContextSwitchTo(TopMemoryContext);
provider = palloc(sizeof(LabelProvider));
diff --git a/src/backend/commands/sequence.c b/src/backend/commands/sequence.c
index bfa94a0c11..6a91a102dc 100644
--- a/src/backend/commands/sequence.c
+++ b/src/backend/commands/sequence.c
@@ -287,7 +287,7 @@ ResetSequence(Oid seq_relid)
seq->log_cnt = 1;
/*
- * Create a new storage file for the sequence. We want to keep the
+ * Create a new storage file for the sequence. We want to keep the
* sequence's relfrozenxid at 0, since it won't contain any unfrozen XIDs.
*/
RelationSetNewRelfilenode(seq_rel, InvalidTransactionId);
@@ -1037,7 +1037,7 @@ init_sequence(Oid relid, SeqTable *p_elm, Relation *p_rel)
/*
* If the sequence has been transactionally replaced since we last saw it,
- * discard any cached-but-unissued values. We do not touch the currval()
+ * discard any cached-but-unissued values. We do not touch the currval()
* state, however.
*/
if (seqrel->rd_rel->relfilenode != elm->filenode)
diff --git a/src/backend/commands/tablecmds.c b/src/backend/commands/tablecmds.c
index 886b656b43..790bc2a521 100644
--- a/src/backend/commands/tablecmds.c
+++ b/src/backend/commands/tablecmds.c
@@ -286,9 +286,9 @@ static void ATWrongRelkindError(Relation rel, int allowed_targets);
static void ATSimpleRecursion(List **wqueue, Relation rel,
AlterTableCmd *cmd, bool recurse, LOCKMODE lockmode);
static void ATTypedTableRecursion(List **wqueue, Relation rel, AlterTableCmd *cmd,
- LOCKMODE lockmode);
+ LOCKMODE lockmode);
static List *find_typed_table_dependencies(Oid typeOid, const char *typeName,
- DropBehavior behavior);
+ DropBehavior behavior);
static void ATPrepAddColumn(List **wqueue, Relation rel, bool recurse, bool recursing,
AlterTableCmd *cmd, LOCKMODE lockmode);
static void ATExecAddColumn(List **wqueue, AlteredTableInfo *tab, Relation rel,
@@ -311,7 +311,7 @@ static void ATExecSetOptions(Relation rel, const char *colName,
static void ATExecSetStorage(Relation rel, const char *colName,
Node *newValue, LOCKMODE lockmode);
static void ATPrepDropColumn(List **wqueue, Relation rel, bool recurse, bool recursing,
- AlterTableCmd *cmd, LOCKMODE lockmode);
+ AlterTableCmd *cmd, LOCKMODE lockmode);
static void ATExecDropColumn(List **wqueue, Relation rel, const char *colName,
DropBehavior behavior,
bool recurse, bool recursing,
@@ -320,9 +320,9 @@ static void ATExecAddIndex(AlteredTableInfo *tab, Relation rel,
IndexStmt *stmt, bool is_rebuild, LOCKMODE lockmode);
static void ATExecAddConstraint(List **wqueue,
AlteredTableInfo *tab, Relation rel,
- Constraint *newConstraint, bool recurse, LOCKMODE lockmode);
+ Constraint *newConstraint, bool recurse, LOCKMODE lockmode);
static void ATExecAddIndexConstraint(AlteredTableInfo *tab, Relation rel,
- IndexStmt *stmt, LOCKMODE lockmode);
+ IndexStmt *stmt, LOCKMODE lockmode);
static void ATAddCheckConstraint(List **wqueue,
AlteredTableInfo *tab, Relation rel,
Constraint *constr,
@@ -339,7 +339,7 @@ static void ATPrepAlterColumnType(List **wqueue,
AlterTableCmd *cmd, LOCKMODE lockmode);
static bool ATColumnChangeRequiresRewrite(Node *expr, AttrNumber varattno);
static void ATExecAlterColumnType(AlteredTableInfo *tab, Relation rel,
- AlterTableCmd *cmd, LOCKMODE lockmode);
+ AlterTableCmd *cmd, LOCKMODE lockmode);
static void ATPostAlterTypeCleanup(List **wqueue, AlteredTableInfo *tab, LOCKMODE lockmode);
static void ATPostAlterTypeParse(char *cmd, List **wqueue, LOCKMODE lockmode);
static void change_owner_recurse_to_sequences(Oid relationOid,
@@ -351,7 +351,7 @@ static void ATPrepSetTableSpace(AlteredTableInfo *tab, Relation rel,
static void ATExecSetTableSpace(Oid tableOid, Oid newTableSpace, LOCKMODE lockmode);
static void ATExecSetRelOptions(Relation rel, List *defList, bool isReset, LOCKMODE lockmode);
static void ATExecEnableDisableTrigger(Relation rel, char *trigname,
- char fires_when, bool skip_system, LOCKMODE lockmode);
+ char fires_when, bool skip_system, LOCKMODE lockmode);
static void ATExecEnableDisableRule(Relation rel, char *rulename,
char fires_when, LOCKMODE lockmode);
static void ATPrepAddInherit(Relation child_rel);
@@ -412,7 +412,7 @@ DefineRelation(CreateStmt *stmt, char relkind, Oid ownerId)
/*
* Check consistency of arguments
*/
- if (stmt->oncommit != ONCOMMIT_NOOP
+ if (stmt->oncommit != ONCOMMIT_NOOP
&& stmt->relation->relpersistence != RELPERSISTENCE_TEMP)
ereport(ERROR,
(errcode(ERRCODE_INVALID_TABLE_DEFINITION),
@@ -547,7 +547,7 @@ DefineRelation(CreateStmt *stmt, char relkind, Oid ownerId)
if (relkind == RELKIND_FOREIGN_TABLE)
ereport(ERROR,
(errcode(ERRCODE_WRONG_OBJECT_TYPE),
- errmsg("default values on foreign tables are not supported")));
+ errmsg("default values on foreign tables are not supported")));
Assert(colDef->cooked_default == NULL);
@@ -706,7 +706,7 @@ DropErrorMsgWrongType(const char *relname, char wrongkind, char rightkind)
/*
* RemoveRelations
* Implements DROP TABLE, DROP INDEX, DROP SEQUENCE, DROP VIEW,
- * DROP FOREIGN TABLE
+ * DROP FOREIGN TABLE
*/
void
RemoveRelations(DropStmt *drop)
@@ -1454,11 +1454,11 @@ MergeAttributes(List *schema, List *supers, char relpersistence,
if (defCollId != attribute->attcollation)
ereport(ERROR,
(errcode(ERRCODE_COLLATION_MISMATCH),
- errmsg("inherited column \"%s\" has a collation conflict",
- attributeName),
+ errmsg("inherited column \"%s\" has a collation conflict",
+ attributeName),
errdetail("\"%s\" versus \"%s\"",
get_collation_name(defCollId),
- get_collation_name(attribute->attcollation))));
+ get_collation_name(attribute->attcollation))));
/* Copy storage parameter */
if (def->storage == 0)
@@ -2061,8 +2061,8 @@ renameatt_internal(Oid myrelid,
relkind != RELKIND_FOREIGN_TABLE)
ereport(ERROR,
(errcode(ERRCODE_WRONG_OBJECT_TYPE),
- errmsg("\"%s\" is not a table, view, composite type, index or foreign table",
- RelationGetRelationName(targetrelation))));
+ errmsg("\"%s\" is not a table, view, composite type, index or foreign table",
+ RelationGetRelationName(targetrelation))));
/*
* permissions checking. only the owner of a class can change its schema.
@@ -2138,7 +2138,7 @@ renameatt_internal(Oid myrelid,
ListCell *lo;
child_oids = find_typed_table_dependencies(targetrelation->rd_rel->reltype,
- RelationGetRelationName(targetrelation),
+ RelationGetRelationName(targetrelation),
behavior);
foreach(lo, child_oids)
@@ -2211,11 +2211,11 @@ void
renameatt(Oid myrelid, RenameStmt *stmt)
{
renameatt_internal(myrelid,
- stmt->subname, /* old att name */
- stmt->newname, /* new att name */
- interpretInhOption(stmt->relation->inhOpt), /* recursive? */
- false, /* recursing? */
- 0, /* expected inhcount */
+ stmt->subname, /* old att name */
+ stmt->newname, /* new att name */
+ interpretInhOption(stmt->relation->inhOpt), /* recursive? */
+ false, /* recursing? */
+ 0, /* expected inhcount */
stmt->behavior);
}
@@ -2460,7 +2460,7 @@ void
AlterTable(AlterTableStmt *stmt)
{
Relation rel;
- LOCKMODE lockmode = AlterTableGetLockLevel(stmt->cmds);
+ LOCKMODE lockmode = AlterTableGetLockLevel(stmt->cmds);
/*
* Acquire same level of lock as already acquired during parsing.
@@ -2531,7 +2531,7 @@ AlterTable(AlterTableStmt *stmt)
}
ATController(rel, stmt->cmds, interpretInhOption(stmt->relation->inhOpt),
- lockmode);
+ lockmode);
}
/*
@@ -2549,7 +2549,7 @@ void
AlterTableInternal(Oid relid, List *cmds, bool recurse)
{
Relation rel;
- LOCKMODE lockmode = AlterTableGetLockLevel(cmds);
+ LOCKMODE lockmode = AlterTableGetLockLevel(cmds);
rel = relation_open(relid, lockmode);
@@ -2581,31 +2581,33 @@ LOCKMODE
AlterTableGetLockLevel(List *cmds)
{
ListCell *lcmd;
- LOCKMODE lockmode = ShareUpdateExclusiveLock;
+ LOCKMODE lockmode = ShareUpdateExclusiveLock;
foreach(lcmd, cmds)
{
AlterTableCmd *cmd = (AlterTableCmd *) lfirst(lcmd);
- LOCKMODE cmd_lockmode = AccessExclusiveLock; /* default for compiler */
+ LOCKMODE cmd_lockmode = AccessExclusiveLock; /* default for compiler */
switch (cmd->subtype)
{
- /*
- * Need AccessExclusiveLock for these subcommands because they
- * affect or potentially affect both read and write operations.
- *
- * New subcommand types should be added here by default.
- */
- case AT_AddColumn: /* may rewrite heap, in some cases and visible to SELECT */
- case AT_DropColumn: /* change visible to SELECT */
+ /*
+ * Need AccessExclusiveLock for these subcommands because they
+ * affect or potentially affect both read and write
+ * operations.
+ *
+ * New subcommand types should be added here by default.
+ */
+ case AT_AddColumn: /* may rewrite heap, in some cases and visible
+ * to SELECT */
+ case AT_DropColumn: /* change visible to SELECT */
case AT_AddColumnToView: /* CREATE VIEW */
case AT_AlterColumnType: /* must rewrite heap */
case AT_DropConstraint: /* as DROP INDEX */
- case AT_AddOids: /* must rewrite heap */
- case AT_DropOids: /* calls AT_DropColumn */
+ case AT_AddOids: /* must rewrite heap */
+ case AT_DropOids: /* calls AT_DropColumn */
case AT_EnableAlwaysRule: /* may change SELECT rules */
case AT_EnableReplicaRule: /* may change SELECT rules */
- case AT_EnableRule: /* may change SELECT rules */
+ case AT_EnableRule: /* may change SELECT rules */
case AT_DisableRule: /* may change SELECT rules */
case AT_ChangeOwner: /* change visible to SELECT */
case AT_SetTableSpace: /* must rewrite heap */
@@ -2615,12 +2617,12 @@ AlterTableGetLockLevel(List *cmds)
cmd_lockmode = AccessExclusiveLock;
break;
- /*
- * These subcommands affect write operations only.
- */
+ /*
+ * These subcommands affect write operations only.
+ */
case AT_ColumnDefault:
- case AT_ProcessedConstraint: /* becomes AT_AddConstraint */
- case AT_AddConstraintRecurse: /* becomes AT_AddConstraint */
+ case AT_ProcessedConstraint: /* becomes AT_AddConstraint */
+ case AT_AddConstraintRecurse: /* becomes AT_AddConstraint */
case AT_EnableTrig:
case AT_EnableAlwaysTrig:
case AT_EnableReplicaTrig:
@@ -2629,7 +2631,7 @@ AlterTableGetLockLevel(List *cmds)
case AT_DisableTrig:
case AT_DisableTrigAll:
case AT_DisableTrigUser:
- case AT_AddIndex: /* from ADD CONSTRAINT */
+ case AT_AddIndex: /* from ADD CONSTRAINT */
case AT_AddIndexConstraint:
cmd_lockmode = ShareRowExclusiveLock;
break;
@@ -2644,14 +2646,17 @@ AlterTableGetLockLevel(List *cmds)
case CONSTR_EXCLUSION:
case CONSTR_PRIMARY:
case CONSTR_UNIQUE:
+
/*
* Cases essentially the same as CREATE INDEX. We
- * could reduce the lock strength to ShareLock if we
- * can work out how to allow concurrent catalog updates.
+ * could reduce the lock strength to ShareLock if
+ * we can work out how to allow concurrent catalog
+ * updates.
*/
cmd_lockmode = ShareRowExclusiveLock;
break;
case CONSTR_FOREIGN:
+
/*
* We add triggers to both tables when we add a
* Foreign Key, so the lock level must be at least
@@ -2666,26 +2671,29 @@ AlterTableGetLockLevel(List *cmds)
}
break;
- /*
- * These subcommands affect inheritance behaviour. Queries started before us
- * will continue to see the old inheritance behaviour, while queries started
- * after we commit will see new behaviour. No need to prevent reads or writes
- * to the subtable while we hook it up though. In both cases the parent table
- * is locked with AccessShareLock.
- */
+ /*
+ * These subcommands affect inheritance behaviour. Queries
+ * started before us will continue to see the old inheritance
+ * behaviour, while queries started after we commit will see
+ * new behaviour. No need to prevent reads or writes to the
+ * subtable while we hook it up though. In both cases the
+ * parent table is locked with AccessShareLock.
+ */
case AT_AddInherit:
case AT_DropInherit:
cmd_lockmode = ShareUpdateExclusiveLock;
break;
- /*
- * These subcommands affect general strategies for performance and maintenance,
- * though don't change the semantic results from normal data reads and writes.
- * Delaying an ALTER TABLE behind currently active writes only delays the point
- * where the new strategy begins to take effect, so there is no benefit in waiting.
- * In this case the minimum restriction applies: we don't currently allow
- * concurrent catalog updates.
- */
+ /*
+ * These subcommands affect general strategies for performance
+ * and maintenance, though don't change the semantic results
+ * from normal data reads and writes. Delaying an ALTER TABLE
+ * behind currently active writes only delays the point where
+ * the new strategy begins to take effect, so there is no
+ * benefit in waiting. In this case the minimum restriction
+ * applies: we don't currently allow concurrent catalog
+ * updates.
+ */
case AT_SetStatistics:
case AT_ClusterOn:
case AT_DropCluster:
@@ -2698,7 +2706,7 @@ AlterTableGetLockLevel(List *cmds)
cmd_lockmode = ShareUpdateExclusiveLock;
break;
- default: /* oops */
+ default: /* oops */
elog(ERROR, "unrecognized alter table type: %d",
(int) cmd->subtype);
break;
@@ -2773,7 +2781,7 @@ ATPrepCmd(List **wqueue, Relation rel, AlterTableCmd *cmd,
{
case AT_AddColumn: /* ADD COLUMN */
ATSimplePermissions(rel,
- ATT_TABLE|ATT_COMPOSITE_TYPE|ATT_FOREIGN_TABLE);
+ ATT_TABLE | ATT_COMPOSITE_TYPE | ATT_FOREIGN_TABLE);
ATPrepAddColumn(wqueue, rel, recurse, recursing, cmd, lockmode);
/* Recursion occurs during execution phase */
pass = AT_PASS_ADD_COL;
@@ -2793,19 +2801,19 @@ ATPrepCmd(List **wqueue, Relation rel, AlterTableCmd *cmd,
* substitutes default values into INSERTs before it expands
* rules.
*/
- ATSimplePermissions(rel, ATT_TABLE|ATT_VIEW);
+ ATSimplePermissions(rel, ATT_TABLE | ATT_VIEW);
ATSimpleRecursion(wqueue, rel, cmd, recurse, lockmode);
/* No command-specific prep needed */
pass = cmd->def ? AT_PASS_ADD_CONSTR : AT_PASS_DROP;
break;
case AT_DropNotNull: /* ALTER COLUMN DROP NOT NULL */
- ATSimplePermissions(rel, ATT_TABLE|ATT_FOREIGN_TABLE);
+ ATSimplePermissions(rel, ATT_TABLE | ATT_FOREIGN_TABLE);
ATSimpleRecursion(wqueue, rel, cmd, recurse, lockmode);
/* No command-specific prep needed */
pass = AT_PASS_DROP;
break;
case AT_SetNotNull: /* ALTER COLUMN SET NOT NULL */
- ATSimplePermissions(rel, ATT_TABLE|ATT_FOREIGN_TABLE);
+ ATSimplePermissions(rel, ATT_TABLE | ATT_FOREIGN_TABLE);
ATSimpleRecursion(wqueue, rel, cmd, recurse, lockmode);
/* No command-specific prep needed */
pass = AT_PASS_ADD_CONSTR;
@@ -2818,7 +2826,7 @@ ATPrepCmd(List **wqueue, Relation rel, AlterTableCmd *cmd,
break;
case AT_SetOptions: /* ALTER COLUMN SET ( options ) */
case AT_ResetOptions: /* ALTER COLUMN RESET ( options ) */
- ATSimplePermissions(rel, ATT_TABLE|ATT_INDEX);
+ ATSimplePermissions(rel, ATT_TABLE | ATT_INDEX);
/* This command never recurses */
pass = AT_PASS_MISC;
break;
@@ -2830,7 +2838,7 @@ ATPrepCmd(List **wqueue, Relation rel, AlterTableCmd *cmd,
break;
case AT_DropColumn: /* DROP COLUMN */
ATSimplePermissions(rel,
- ATT_TABLE|ATT_COMPOSITE_TYPE|ATT_FOREIGN_TABLE);
+ ATT_TABLE | ATT_COMPOSITE_TYPE | ATT_FOREIGN_TABLE);
ATPrepDropColumn(wqueue, rel, recurse, recursing, cmd, lockmode);
/* Recursion occurs during execution phase */
pass = AT_PASS_DROP;
@@ -2849,7 +2857,7 @@ ATPrepCmd(List **wqueue, Relation rel, AlterTableCmd *cmd,
cmd->subtype = AT_AddConstraintRecurse;
pass = AT_PASS_ADD_CONSTR;
break;
- case AT_AddIndexConstraint: /* ADD CONSTRAINT USING INDEX */
+ case AT_AddIndexConstraint: /* ADD CONSTRAINT USING INDEX */
ATSimplePermissions(rel, ATT_TABLE);
/* This command never recurses */
/* No command-specific prep needed */
@@ -2865,7 +2873,7 @@ ATPrepCmd(List **wqueue, Relation rel, AlterTableCmd *cmd,
break;
case AT_AlterColumnType: /* ALTER COLUMN TYPE */
ATSimplePermissions(rel,
- ATT_TABLE|ATT_COMPOSITE_TYPE|ATT_FOREIGN_TABLE);
+ ATT_TABLE | ATT_COMPOSITE_TYPE | ATT_FOREIGN_TABLE);
/* Performs own recursion */
ATPrepAlterColumnType(wqueue, tab, rel, recurse, recursing, cmd, lockmode);
pass = AT_PASS_ALTER_TYPE;
@@ -2904,14 +2912,14 @@ ATPrepCmd(List **wqueue, Relation rel, AlterTableCmd *cmd,
pass = AT_PASS_DROP;
break;
case AT_SetTableSpace: /* SET TABLESPACE */
- ATSimplePermissions(rel, ATT_TABLE|ATT_INDEX);
+ ATSimplePermissions(rel, ATT_TABLE | ATT_INDEX);
/* This command never recurses */
ATPrepSetTableSpace(tab, rel, cmd->name, lockmode);
pass = AT_PASS_MISC; /* doesn't actually matter */
break;
case AT_SetRelOptions: /* SET (...) */
case AT_ResetRelOptions: /* RESET (...) */
- ATSimplePermissions(rel, ATT_TABLE|ATT_INDEX);
+ ATSimplePermissions(rel, ATT_TABLE | ATT_INDEX);
/* This command never recurses */
/* No command-specific prep needed */
pass = AT_PASS_MISC;
@@ -3072,11 +3080,11 @@ ATExecCmd(List **wqueue, AlteredTableInfo *tab, Relation rel,
break;
case AT_DropColumn: /* DROP COLUMN */
ATExecDropColumn(wqueue, rel, cmd->name,
- cmd->behavior, false, false, cmd->missing_ok, lockmode);
+ cmd->behavior, false, false, cmd->missing_ok, lockmode);
break;
case AT_DropColumnRecurse: /* DROP COLUMN with recursion */
ATExecDropColumn(wqueue, rel, cmd->name,
- cmd->behavior, true, false, cmd->missing_ok, lockmode);
+ cmd->behavior, true, false, cmd->missing_ok, lockmode);
break;
case AT_AddIndex: /* ADD INDEX */
ATExecAddIndex(tab, rel, (IndexStmt *) cmd->def, false, lockmode);
@@ -3092,7 +3100,7 @@ ATExecCmd(List **wqueue, AlteredTableInfo *tab, Relation rel,
ATExecAddConstraint(wqueue, tab, rel, (Constraint *) cmd->def,
true, lockmode);
break;
- case AT_AddIndexConstraint: /* ADD CONSTRAINT USING INDEX */
+ case AT_AddIndexConstraint: /* ADD CONSTRAINT USING INDEX */
ATExecAddIndexConstraint(tab, rel, (IndexStmt *) cmd->def, lockmode);
break;
case AT_ValidateConstraint:
@@ -3156,7 +3164,7 @@ ATExecCmd(List **wqueue, AlteredTableInfo *tab, Relation rel,
case AT_EnableTrig: /* ENABLE TRIGGER name */
ATExecEnableDisableTrigger(rel, cmd->name,
- TRIGGER_FIRES_ON_ORIGIN, false, lockmode);
+ TRIGGER_FIRES_ON_ORIGIN, false, lockmode);
break;
case AT_EnableAlwaysTrig: /* ENABLE ALWAYS TRIGGER name */
ATExecEnableDisableTrigger(rel, cmd->name,
@@ -3164,7 +3172,7 @@ ATExecCmd(List **wqueue, AlteredTableInfo *tab, Relation rel,
break;
case AT_EnableReplicaTrig: /* ENABLE REPLICA TRIGGER name */
ATExecEnableDisableTrigger(rel, cmd->name,
- TRIGGER_FIRES_ON_REPLICA, false, lockmode);
+ TRIGGER_FIRES_ON_REPLICA, false, lockmode);
break;
case AT_DisableTrig: /* DISABLE TRIGGER name */
ATExecEnableDisableTrigger(rel, cmd->name,
@@ -3172,7 +3180,7 @@ ATExecCmd(List **wqueue, AlteredTableInfo *tab, Relation rel,
break;
case AT_EnableTrigAll: /* ENABLE TRIGGER ALL */
ATExecEnableDisableTrigger(rel, NULL,
- TRIGGER_FIRES_ON_ORIGIN, false, lockmode);
+ TRIGGER_FIRES_ON_ORIGIN, false, lockmode);
break;
case AT_DisableTrigAll: /* DISABLE TRIGGER ALL */
ATExecEnableDisableTrigger(rel, NULL,
@@ -3180,7 +3188,7 @@ ATExecCmd(List **wqueue, AlteredTableInfo *tab, Relation rel,
break;
case AT_EnableTrigUser: /* ENABLE TRIGGER USER */
ATExecEnableDisableTrigger(rel, NULL,
- TRIGGER_FIRES_ON_ORIGIN, true, lockmode);
+ TRIGGER_FIRES_ON_ORIGIN, true, lockmode);
break;
case AT_DisableTrigUser: /* DISABLE TRIGGER USER */
ATExecEnableDisableTrigger(rel, NULL,
@@ -3254,8 +3262,8 @@ ATRewriteTables(List **wqueue, LOCKMODE lockmode)
* (Eventually we'll probably need to check for composite type
* dependencies even when we're just scanning the table without a
* rewrite, but at the moment a composite type does not enforce any
- * constraints, so it's not necessary/appropriate to enforce them
- * just during ALTER.)
+ * constraints, so it's not necessary/appropriate to enforce them just
+ * during ALTER.)
*/
if (tab->newvals != NIL || tab->rewrite)
{
@@ -3386,8 +3394,8 @@ ATRewriteTables(List **wqueue, LOCKMODE lockmode)
con->conid);
/*
- * No need to mark the constraint row as validated,
- * we did that when we inserted the row earlier.
+ * No need to mark the constraint row as validated, we did
+ * that when we inserted the row earlier.
*/
heap_close(refrel, NoLock);
@@ -3723,7 +3731,7 @@ ATGetQueueEntry(List **wqueue, Relation rel)
static void
ATSimplePermissions(Relation rel, int allowed_targets)
{
- int actual_target;
+ int actual_target;
switch (rel->rd_rel->relkind)
{
@@ -3779,16 +3787,16 @@ ATWrongRelkindError(Relation rel, int allowed_targets)
case ATT_TABLE:
msg = _("\"%s\" is not a table");
break;
- case ATT_TABLE|ATT_INDEX:
+ case ATT_TABLE | ATT_INDEX:
msg = _("\"%s\" is not a table or index");
break;
- case ATT_TABLE|ATT_VIEW:
+ case ATT_TABLE | ATT_VIEW:
msg = _("\"%s\" is not a table or view");
break;
- case ATT_TABLE|ATT_FOREIGN_TABLE:
+ case ATT_TABLE | ATT_FOREIGN_TABLE:
msg = _("\"%s\" is not a table or foreign table");
break;
- case ATT_TABLE|ATT_COMPOSITE_TYPE|ATT_FOREIGN_TABLE:
+ case ATT_TABLE | ATT_COMPOSITE_TYPE | ATT_FOREIGN_TABLE:
msg = _("\"%s\" is not a table, composite type, or foreign table");
break;
case ATT_VIEW:
@@ -4032,7 +4040,7 @@ find_typed_table_dependencies(Oid typeOid, const char *typeName, DropBehavior be
(errcode(ERRCODE_DEPENDENT_OBJECTS_STILL_EXIST),
errmsg("cannot alter type \"%s\" because it is the type of a typed table",
typeName),
- errhint("Use ALTER ... CASCADE to alter the typed tables too.")));
+ errhint("Use ALTER ... CASCADE to alter the typed tables too.")));
else
result = lappend_oid(result, HeapTupleGetOid(tuple));
}
@@ -4103,9 +4111,9 @@ ATExecAddColumn(List **wqueue, AlteredTableInfo *tab, Relation rel,
/*
* Are we adding the column to a recursion child? If so, check whether to
- * merge with an existing definition for the column. If we do merge,
- * we must not recurse. Children will already have the column, and
- * recursing into them would mess up attinhcount.
+ * merge with an existing definition for the column. If we do merge, we
+ * must not recurse. Children will already have the column, and recursing
+ * into them would mess up attinhcount.
*/
if (colDef->inhcount > 0)
{
@@ -4133,10 +4141,10 @@ ATExecAddColumn(List **wqueue, AlteredTableInfo *tab, Relation rel,
ereport(ERROR,
(errcode(ERRCODE_COLLATION_MISMATCH),
errmsg("child table \"%s\" has different collation for column \"%s\"",
- RelationGetRelationName(rel), colDef->colname),
+ RelationGetRelationName(rel), colDef->colname),
errdetail("\"%s\" versus \"%s\"",
get_collation_name(ccollid),
- get_collation_name(childatt->attcollation))));
+ get_collation_name(childatt->attcollation))));
/* If it's OID, child column must actually be OID */
if (isOid && childatt->attnum != ObjectIdAttributeNumber)
@@ -4265,7 +4273,7 @@ ATExecAddColumn(List **wqueue, AlteredTableInfo *tab, Relation rel,
if (relkind == RELKIND_FOREIGN_TABLE)
ereport(ERROR,
(errcode(ERRCODE_WRONG_OBJECT_TYPE),
- errmsg("default values on foreign tables are not supported")));
+ errmsg("default values on foreign tables are not supported")));
rawEnt = (RawColumnDefault *) palloc(sizeof(RawColumnDefault));
rawEnt->attnum = attribute.attnum;
@@ -5170,10 +5178,11 @@ ATExecAddIndexConstraint(AlteredTableInfo *tab, Relation rel,
elog(ERROR, "index \"%s\" is not unique", indexName);
/*
- * Determine name to assign to constraint. We require a constraint to
+ * Determine name to assign to constraint. We require a constraint to
* have the same name as the underlying index; therefore, use the index's
- * existing name as the default constraint name, and if the user explicitly
- * gives some other name for the constraint, rename the index to match.
+ * existing name as the default constraint name, and if the user
+ * explicitly gives some other name for the constraint, rename the index
+ * to match.
*/
constraintName = stmt->idxname;
if (constraintName == NULL)
@@ -5216,7 +5225,7 @@ ATExecAddIndexConstraint(AlteredTableInfo *tab, Relation rel,
*/
static void
ATExecAddConstraint(List **wqueue, AlteredTableInfo *tab, Relation rel,
- Constraint *newConstraint, bool recurse, LOCKMODE lockmode)
+ Constraint *newConstraint, bool recurse, LOCKMODE lockmode)
{
Assert(IsA(newConstraint, Constraint));
@@ -5337,9 +5346,9 @@ ATAddCheckConstraint(List **wqueue, AlteredTableInfo *tab, Relation rel,
/*
* If the constraint got merged with an existing constraint, we're done.
- * We mustn't recurse to child tables in this case, because they've already
- * got the constraint, and visiting them again would lead to an incorrect
- * value for coninhcount.
+ * We mustn't recurse to child tables in this case, because they've
+ * already got the constraint, and visiting them again would lead to an
+ * incorrect value for coninhcount.
*/
if (newcons == NIL)
return;
@@ -5655,8 +5664,8 @@ ATAddForeignKeyConstraint(AlteredTableInfo *tab, Relation rel,
/*
* Tell Phase 3 to check that the constraint is satisfied by existing rows
- * We can skip this during table creation or if requested explicitly
- * by specifying NOT VALID on an alter table statement.
+ * We can skip this during table creation or if requested explicitly by
+ * specifying NOT VALID on an alter table statement.
*/
if (!fkconstraint->skip_validation)
{
@@ -5718,8 +5727,8 @@ ATExecValidateConstraint(Relation rel, const char *constrName)
if (!found)
ereport(ERROR,
(errcode(ERRCODE_UNDEFINED_OBJECT),
- errmsg("foreign key constraint \"%s\" of relation \"%s\" does not exist",
- constrName, RelationGetRelationName(rel))));
+ errmsg("foreign key constraint \"%s\" of relation \"%s\" does not exist",
+ constrName, RelationGetRelationName(rel))));
if (!con->convalidated)
{
@@ -5729,17 +5738,16 @@ ATExecValidateConstraint(Relation rel, const char *constrName)
Relation refrel;
/*
- * Triggers are already in place on both tables, so a
- * concurrent write that alters the result here is not
- * possible. Normally we can run a query here to do the
- * validation, which would only require AccessShareLock.
- * In some cases, it is possible that we might need to
- * fire triggers to perform the check, so we take a lock
- * at RowShareLock level just in case.
+ * Triggers are already in place on both tables, so a concurrent write
+ * that alters the result here is not possible. Normally we can run a
+ * query here to do the validation, which would only require
+ * AccessShareLock. In some cases, it is possible that we might need
+ * to fire triggers to perform the check, so we take a lock at
+ * RowShareLock level just in case.
*/
refrel = heap_open(con->confrelid, RowShareLock);
- validateForeignKeyConstraint((char *)constrName, rel, refrel,
+ validateForeignKeyConstraint((char *) constrName, rel, refrel,
con->conindid,
conid);
@@ -6571,12 +6579,12 @@ ATPrepAlterColumnType(List **wqueue,
if (tab->relkind == RELKIND_RELATION)
{
/*
- * Set up an expression to transform the old data value to the new type.
- * If a USING option was given, transform and use that expression, else
- * just take the old value and try to coerce it. We do this first so that
- * type incompatibility can be detected before we waste effort, and
- * because we need the expression to be parsed against the original table
- * rowtype.
+ * Set up an expression to transform the old data value to the new
+ * type. If a USING option was given, transform and use that
+ * expression, else just take the old value and try to coerce it. We
+ * do this first so that type incompatibility can be detected before
+ * we waste effort, and because we need the expression to be parsed
+ * against the original table rowtype.
*/
if (transform)
{
@@ -6596,13 +6604,13 @@ ATPrepAlterColumnType(List **wqueue,
if (expression_returns_set(transform))
ereport(ERROR,
(errcode(ERRCODE_DATATYPE_MISMATCH),
- errmsg("transform expression must not return a set")));
+ errmsg("transform expression must not return a set")));
/* No subplans or aggregates, either... */
if (pstate->p_hasSubLinks)
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("cannot use subquery in transform expression")));
+ errmsg("cannot use subquery in transform expression")));
if (pstate->p_hasAggs)
ereport(ERROR,
(errcode(ERRCODE_GROUPING_ERROR),
@@ -6615,7 +6623,7 @@ ATPrepAlterColumnType(List **wqueue,
else
{
transform = (Node *) makeVar(1, attnum,
- attTup->atttypid, attTup->atttypmod, attTup->attcollation,
+ attTup->atttypid, attTup->atttypmod, attTup->attcollation,
0);
}
@@ -6649,14 +6657,14 @@ ATPrepAlterColumnType(List **wqueue,
else if (transform)
ereport(ERROR,
(errcode(ERRCODE_WRONG_OBJECT_TYPE),
- errmsg("ALTER TYPE USING is only supported on plain tables")));
+ errmsg("ALTER TYPE USING is only supported on plain tables")));
if (tab->relkind == RELKIND_COMPOSITE_TYPE ||
tab->relkind == RELKIND_FOREIGN_TABLE)
{
/*
- * For composite types, do this check now. Tables will check
- * it later when the table is being rewritten.
+ * For composite types, do this check now. Tables will check it later
+ * when the table is being rewritten.
*/
find_composite_type_dependencies(rel->rd_rel->reltype, rel, NULL);
}
@@ -6699,7 +6707,7 @@ ATColumnChangeRequiresRewrite(Node *expr, AttrNumber varattno)
for (;;)
{
/* only one varno, so no need to check that */
- if (IsA(expr, Var) && ((Var *) expr)->varattno == varattno)
+ if (IsA(expr, Var) &&((Var *) expr)->varattno == varattno)
return false;
else if (IsA(expr, RelabelType))
expr = (Node *) ((RelabelType *) expr)->arg;
@@ -6924,13 +6932,14 @@ ATExecAlterColumnType(AlteredTableInfo *tab, Relation rel,
break;
case OCLASS_TRIGGER:
+
/*
* A trigger can depend on a column because the column is
* specified as an update target, or because the column is
* used in the trigger's WHEN condition. The first case would
* not require any extra work, but the second case would
* require updating the WHEN expression, which will take a
- * significant amount of new code. Since we can't easily tell
+ * significant amount of new code. Since we can't easily tell
* which case applies, we punt for both. FIXME someday.
*/
ereport(ERROR,
@@ -7940,7 +7949,7 @@ copy_relation_data(SMgrRelation src, SMgrRelation dst,
*/
static void
ATExecEnableDisableTrigger(Relation rel, char *trigname,
- char fires_when, bool skip_system, LOCKMODE lockmode)
+ char fires_when, bool skip_system, LOCKMODE lockmode)
{
EnableDisableTrigger(rel, trigname, fires_when, skip_system);
}
@@ -8558,18 +8567,18 @@ ATExecDropInherit(Relation rel, RangeVar *parent, LOCKMODE lockmode)
static void
ATExecGenericOptions(Relation rel, List *options)
{
- Relation ftrel;
- ForeignServer *server;
+ Relation ftrel;
+ ForeignServer *server;
ForeignDataWrapper *fdw;
- HeapTuple tuple;
- bool isnull;
- Datum repl_val[Natts_pg_foreign_table];
- bool repl_null[Natts_pg_foreign_table];
- bool repl_repl[Natts_pg_foreign_table];
- Datum datum;
- Form_pg_foreign_table tableform;
-
- if (options == NIL)
+ HeapTuple tuple;
+ bool isnull;
+ Datum repl_val[Natts_pg_foreign_table];
+ bool repl_null[Natts_pg_foreign_table];
+ bool repl_repl[Natts_pg_foreign_table];
+ Datum datum;
+ Form_pg_foreign_table tableform;
+
+ if (options == NIL)
return;
ftrel = heap_open(ForeignTableRelationId, RowExclusiveLock);
@@ -8579,7 +8588,7 @@ ATExecGenericOptions(Relation rel, List *options)
ereport(ERROR,
(errcode(ERRCODE_UNDEFINED_OBJECT),
errmsg("foreign table \"%s\" does not exist",
- RelationGetRelationName(rel))));
+ RelationGetRelationName(rel))));
tableform = (Form_pg_foreign_table) GETSTRUCT(tuple);
server = GetForeignServer(tableform->ftserver);
fdw = GetForeignDataWrapper(server->fdwid);
@@ -8718,8 +8727,8 @@ AlterTableNamespace(RangeVar *relation, const char *newschema,
default:
ereport(ERROR,
(errcode(ERRCODE_WRONG_OBJECT_TYPE),
- errmsg("\"%s\" is not a table, view, sequence, or foreign table",
- RelationGetRelationName(rel))));
+ errmsg("\"%s\" is not a table, view, sequence, or foreign table",
+ RelationGetRelationName(rel))));
}
/* get schema OID and check its permissions */
@@ -8836,7 +8845,7 @@ AlterIndexNamespaces(Relation classRel, Relation rel,
*/
static void
AlterSeqNamespaces(Relation classRel, Relation rel,
- Oid oldNspOid, Oid newNspOid, const char *newNspName, LOCKMODE lockmode)
+ Oid oldNspOid, Oid newNspOid, const char *newNspName, LOCKMODE lockmode)
{
Relation depRel;
SysScanDesc scan;
diff --git a/src/backend/commands/tablespace.c b/src/backend/commands/tablespace.c
index 42a704beb1..3024dc4b64 100644
--- a/src/backend/commands/tablespace.c
+++ b/src/backend/commands/tablespace.c
@@ -559,7 +559,7 @@ create_tablespace_directories(const char *location, const Oid tablespaceoid)
(errcode(ERRCODE_UNDEFINED_FILE),
errmsg("directory \"%s\" does not exist", location),
InRecovery ? errhint("Create this directory for the tablespace before "
- "restarting the server."): 0));
+ "restarting the server.") : 0));
else
ereport(ERROR,
(errcode_for_file_access(),
@@ -573,8 +573,8 @@ create_tablespace_directories(const char *location, const Oid tablespaceoid)
/*
* Our theory for replaying a CREATE is to forcibly drop the target
- * subdirectory if present, and then recreate it. This may be
- * more work than needed, but it is simple to implement.
+ * subdirectory if present, and then recreate it. This may be more
+ * work than needed, but it is simple to implement.
*/
if (stat(location_with_version_dir, &st) == 0 && S_ISDIR(st.st_mode))
{
@@ -1353,10 +1353,10 @@ get_tablespace_oid(const char *tablespacename, bool missing_ok)
heap_close(rel, AccessShareLock);
if (!OidIsValid(result) && !missing_ok)
- ereport(ERROR,
- (errcode(ERRCODE_UNDEFINED_OBJECT),
- errmsg("tablespace \"%s\" does not exist",
- tablespacename)));
+ ereport(ERROR,
+ (errcode(ERRCODE_UNDEFINED_OBJECT),
+ errmsg("tablespace \"%s\" does not exist",
+ tablespacename)));
return result;
}
diff --git a/src/backend/commands/trigger.c b/src/backend/commands/trigger.c
index 329d4d95f1..6b1ade8990 100644
--- a/src/backend/commands/trigger.c
+++ b/src/backend/commands/trigger.c
@@ -144,11 +144,11 @@ CreateTrigger(CreateTrigStmt *stmt, const char *queryString,
referenced;
/*
- * ShareRowExclusiveLock is sufficient to prevent concurrent write activity
- * to the relation, and thus to lock out any operations that might want to
- * fire triggers on the relation. If we had ON SELECT triggers we would
- * need to take an AccessExclusiveLock to add one of those, just as we do
- * with ON SELECT rules.
+ * ShareRowExclusiveLock is sufficient to prevent concurrent write
+ * activity to the relation, and thus to lock out any operations that
+ * might want to fire triggers on the relation. If we had ON SELECT
+ * triggers we would need to take an AccessExclusiveLock to add one of
+ * those, just as we do with ON SELECT rules.
*/
rel = heap_openrv(stmt->relation, ShareRowExclusiveLock);
@@ -244,7 +244,7 @@ CreateTrigger(CreateTrigStmt *stmt, const char *queryString,
if (stmt->whenClause)
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("INSTEAD OF triggers cannot have WHEN conditions")));
+ errmsg("INSTEAD OF triggers cannot have WHEN conditions")));
if (stmt->columns != NIL)
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
@@ -480,8 +480,8 @@ CreateTrigger(CreateTrigStmt *stmt, const char *queryString,
* can skip this for internally generated triggers, since the name
* modification above should be sufficient.
*
- * NOTE that this is cool only because we have ShareRowExclusiveLock on the
- * relation, so the trigger set won't be changing underneath us.
+ * NOTE that this is cool only because we have ShareRowExclusiveLock on
+ * the relation, so the trigger set won't be changing underneath us.
*/
if (!isInternal)
{
@@ -1036,8 +1036,8 @@ DropTrigger(Oid relid, const char *trigname, DropBehavior behavior,
if (!OidIsValid(object.objectId))
{
ereport(NOTICE,
- (errmsg("trigger \"%s\" for table \"%s\" does not exist, skipping",
- trigname, get_rel_name(relid))));
+ (errmsg("trigger \"%s\" for table \"%s\" does not exist, skipping",
+ trigname, get_rel_name(relid))));
return;
}
@@ -1083,9 +1083,9 @@ RemoveTriggerById(Oid trigOid)
/*
* Open and lock the relation the trigger belongs to. As in
- * CreateTrigger, this is sufficient to lock out all operations that
- * could fire or add triggers; but it would need to be revisited if
- * we had ON SELECT triggers.
+ * CreateTrigger, this is sufficient to lock out all operations that could
+ * fire or add triggers; but it would need to be revisited if we had ON
+ * SELECT triggers.
*/
relid = ((Form_pg_trigger) GETSTRUCT(tup))->tgrelid;
@@ -1960,7 +1960,7 @@ ExecBRInsertTriggers(EState *estate, ResultRelInfo *relinfo,
if (newtuple != slottuple)
{
/*
- * Return the modified tuple using the es_trig_tuple_slot. We assume
+ * Return the modified tuple using the es_trig_tuple_slot. We assume
* the tuple was allocated in per-tuple memory context, and therefore
* will go away by itself. The tuple table slot should not try to
* clear it.
@@ -2035,7 +2035,7 @@ ExecIRInsertTriggers(EState *estate, ResultRelInfo *relinfo,
if (newtuple != slottuple)
{
/*
- * Return the modified tuple using the es_trig_tuple_slot. We assume
+ * Return the modified tuple using the es_trig_tuple_slot. We assume
* the tuple was allocated in per-tuple memory context, and therefore
* will go away by itself. The tuple table slot should not try to
* clear it.
@@ -2378,7 +2378,7 @@ ExecBRUpdateTriggers(EState *estate, EPQState *epqstate,
if (newtuple != slottuple)
{
/*
- * Return the modified tuple using the es_trig_tuple_slot. We assume
+ * Return the modified tuple using the es_trig_tuple_slot. We assume
* the tuple was allocated in per-tuple memory context, and therefore
* will go away by itself. The tuple table slot should not try to
* clear it.
@@ -2461,7 +2461,7 @@ ExecIRUpdateTriggers(EState *estate, ResultRelInfo *relinfo,
if (newtuple != slottuple)
{
/*
- * Return the modified tuple using the es_trig_tuple_slot. We assume
+ * Return the modified tuple using the es_trig_tuple_slot. We assume
* the tuple was allocated in per-tuple memory context, and therefore
* will go away by itself. The tuple table slot should not try to
* clear it.
@@ -2891,7 +2891,7 @@ typedef struct AfterTriggerEventDataOneCtid
{
TriggerFlags ate_flags; /* status bits and offset to shared data */
ItemPointerData ate_ctid1; /* inserted, deleted, or old updated tuple */
-} AfterTriggerEventDataOneCtid;
+} AfterTriggerEventDataOneCtid;
#define SizeofTriggerEvent(evt) \
(((evt)->ate_flags & AFTER_TRIGGER_2CTIDS) ? \
diff --git a/src/backend/commands/tsearchcmds.c b/src/backend/commands/tsearchcmds.c
index 81f129dff6..80a30e180d 100644
--- a/src/backend/commands/tsearchcmds.c
+++ b/src/backend/commands/tsearchcmds.c
@@ -407,7 +407,8 @@ RenameTSParser(List *oldname, const char *newname)
void
AlterTSParserNamespace(List *name, const char *newschema)
{
- Oid prsId, nspOid;
+ Oid prsId,
+ nspOid;
Relation rel;
rel = heap_open(TSParserRelationId, RowExclusiveLock);
@@ -429,7 +430,7 @@ AlterTSParserNamespace(List *name, const char *newschema)
Oid
AlterTSParserNamespace_oid(Oid prsId, Oid newNspOid)
{
- Oid oldNspOid;
+ Oid oldNspOid;
Relation rel;
rel = heap_open(TSParserRelationId, RowExclusiveLock);
@@ -685,7 +686,8 @@ RenameTSDictionary(List *oldname, const char *newname)
void
AlterTSDictionaryNamespace(List *name, const char *newschema)
{
- Oid dictId, nspOid;
+ Oid dictId,
+ nspOid;
Relation rel;
rel = heap_open(TSDictionaryRelationId, RowExclusiveLock);
@@ -708,7 +710,7 @@ AlterTSDictionaryNamespace(List *name, const char *newschema)
Oid
AlterTSDictionaryNamespace_oid(Oid dictId, Oid newNspOid)
{
- Oid oldNspOid;
+ Oid oldNspOid;
Relation rel;
rel = heap_open(TSDictionaryRelationId, RowExclusiveLock);
@@ -1218,7 +1220,8 @@ RenameTSTemplate(List *oldname, const char *newname)
void
AlterTSTemplateNamespace(List *name, const char *newschema)
{
- Oid tmplId, nspOid;
+ Oid tmplId,
+ nspOid;
Relation rel;
rel = heap_open(TSTemplateRelationId, RowExclusiveLock);
@@ -1240,7 +1243,7 @@ AlterTSTemplateNamespace(List *name, const char *newschema)
Oid
AlterTSTemplateNamespace_oid(Oid tmplId, Oid newNspOid)
{
- Oid oldNspOid;
+ Oid oldNspOid;
Relation rel;
rel = heap_open(TSTemplateRelationId, RowExclusiveLock);
@@ -1668,7 +1671,8 @@ RenameTSConfiguration(List *oldname, const char *newname)
void
AlterTSConfigurationNamespace(List *name, const char *newschema)
{
- Oid cfgId, nspOid;
+ Oid cfgId,
+ nspOid;
Relation rel;
rel = heap_open(TSConfigRelationId, RowExclusiveLock);
@@ -1691,7 +1695,7 @@ AlterTSConfigurationNamespace(List *name, const char *newschema)
Oid
AlterTSConfigurationNamespace_oid(Oid cfgId, Oid newNspOid)
{
- Oid oldNspOid;
+ Oid oldNspOid;
Relation rel;
rel = heap_open(TSConfigRelationId, RowExclusiveLock);
diff --git a/src/backend/commands/typecmds.c b/src/backend/commands/typecmds.c
index 4c06d898a8..1a20b0d91b 100644
--- a/src/backend/commands/typecmds.c
+++ b/src/backend/commands/typecmds.c
@@ -138,7 +138,7 @@ DefineType(List *names, List *parameters)
DefElem *byValueEl = NULL;
DefElem *alignmentEl = NULL;
DefElem *storageEl = NULL;
- DefElem *collatableEl = NULL;
+ DefElem *collatableEl = NULL;
Oid inputOid;
Oid outputOid;
Oid receiveOid = InvalidOid;
@@ -537,7 +537,7 @@ DefineType(List *names, List *parameters)
* now have TypeCreate do all the real work.
*
* Note: the pg_type.oid is stored in user tables as array elements (base
- * types) in ArrayType and in composite types in DatumTupleFields. This
+ * types) in ArrayType and in composite types in DatumTupleFields. This
* oid must be preserved by binary upgrades.
*/
typoid =
@@ -1179,7 +1179,7 @@ DefineEnum(CreateEnumStmt *stmt)
-1, /* typMod (Domains only) */
0, /* Array dimensions of typbasetype */
false, /* Type NOT NULL */
- InvalidOid); /* typcollation */
+ InvalidOid); /* typcollation */
/* Enter the enum's values into pg_enum */
EnumValuesCreate(enumTypeOid, stmt->vals);
@@ -2416,7 +2416,7 @@ domainAddConstraint(Oid domainOid, Oid domainNamespace, Oid baseTypeOid,
CONSTRAINT_CHECK, /* Constraint Type */
false, /* Is Deferrable */
false, /* Is Deferred */
- true, /* Is Validated */
+ true, /* Is Validated */
InvalidOid, /* not a relation constraint */
NULL,
0,
diff --git a/src/backend/commands/user.c b/src/backend/commands/user.c
index f13eb2891e..9c9164d3bc 100644
--- a/src/backend/commands/user.c
+++ b/src/backend/commands/user.c
@@ -84,7 +84,7 @@ CreateRole(CreateRoleStmt *stmt)
bool createrole = false; /* Can this user create roles? */
bool createdb = false; /* Can the user create databases? */
bool canlogin = false; /* Can this user login? */
- bool isreplication = false; /* Is this a replication role? */
+ bool isreplication = false; /* Is this a replication role? */
int connlimit = -1; /* maximum connections allowed */
List *addroleto = NIL; /* roles to make this a member of */
List *rolemembers = NIL; /* roles to be members of this role */
@@ -98,7 +98,7 @@ CreateRole(CreateRoleStmt *stmt)
DefElem *dcreaterole = NULL;
DefElem *dcreatedb = NULL;
DefElem *dcanlogin = NULL;
- DefElem *disreplication = NULL;
+ DefElem *disreplication = NULL;
DefElem *dconnlimit = NULL;
DefElem *daddroleto = NULL;
DefElem *drolemembers = NULL;
@@ -240,9 +240,10 @@ CreateRole(CreateRoleStmt *stmt)
if (dissuper)
{
issuper = intVal(dissuper->arg) != 0;
+
/*
- * Superusers get replication by default, but only if
- * NOREPLICATION wasn't explicitly mentioned
+ * Superusers get replication by default, but only if NOREPLICATION
+ * wasn't explicitly mentioned
*/
if (!(disreplication && intVal(disreplication->arg) == 0))
isreplication = 1;
@@ -287,7 +288,7 @@ CreateRole(CreateRoleStmt *stmt)
if (!superuser())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- errmsg("must be superuser to create replication users")));
+ errmsg("must be superuser to create replication users")));
}
else
{
@@ -384,8 +385,8 @@ CreateRole(CreateRoleStmt *stmt)
tuple = heap_form_tuple(pg_authid_dsc, new_record, new_record_nulls);
/*
- * pg_largeobject_metadata contains pg_authid.oid's, so we
- * use the binary-upgrade override, if specified.
+ * pg_largeobject_metadata contains pg_authid.oid's, so we use the
+ * binary-upgrade override, if specified.
*/
if (OidIsValid(binary_upgrade_next_pg_authid_oid))
{
@@ -467,7 +468,7 @@ AlterRole(AlterRoleStmt *stmt)
int createrole = -1; /* Can this user create roles? */
int createdb = -1; /* Can the user create databases? */
int canlogin = -1; /* Can this user login? */
- int isreplication = -1; /* Is this a replication role? */
+ int isreplication = -1; /* Is this a replication role? */
int connlimit = -1; /* maximum connections allowed */
List *rolemembers = NIL; /* roles to be added/removed */
char *validUntil = NULL; /* time the login is valid until */
@@ -479,7 +480,7 @@ AlterRole(AlterRoleStmt *stmt)
DefElem *dcreaterole = NULL;
DefElem *dcreatedb = NULL;
DefElem *dcanlogin = NULL;
- DefElem *disreplication = NULL;
+ DefElem *disreplication = NULL;
DefElem *dconnlimit = NULL;
DefElem *drolemembers = NULL;
DefElem *dvalidUntil = NULL;
diff --git a/src/backend/commands/vacuum.c b/src/backend/commands/vacuum.c
index 1651aa94dc..90c413a988 100644
--- a/src/backend/commands/vacuum.c
+++ b/src/backend/commands/vacuum.c
@@ -527,7 +527,7 @@ vac_update_relstats(Relation relation,
/*
* If we have discovered that there are no indexes, then there's no
- * primary key either. This could be done more thoroughly...
+ * primary key either. This could be done more thoroughly...
*/
if (pgcform->relhaspkey && !hasindex)
{
@@ -839,8 +839,8 @@ vacuum_rel(Oid relid, VacuumStmt *vacstmt, bool do_toast, bool for_wraparound,
* There's a race condition here: the rel may have gone away since the
* last time we saw it. If so, we don't need to vacuum it.
*
- * If we've been asked not to wait for the relation lock, acquire it
- * first in non-blocking mode, before calling try_relation_open().
+ * If we've been asked not to wait for the relation lock, acquire it first
+ * in non-blocking mode, before calling try_relation_open().
*/
if (!(vacstmt->options & VACOPT_NOWAIT))
onerel = try_relation_open(relid, lmode);
@@ -852,8 +852,8 @@ vacuum_rel(Oid relid, VacuumStmt *vacstmt, bool do_toast, bool for_wraparound,
if (IsAutoVacuumWorkerProcess() && Log_autovacuum_min_duration >= 0)
ereport(LOG,
(errcode(ERRCODE_LOCK_NOT_AVAILABLE),
- errmsg("skipping vacuum of \"%s\" --- lock not available",
- vacstmt->relation->relname)));
+ errmsg("skipping vacuum of \"%s\" --- lock not available",
+ vacstmt->relation->relname)));
}
if (!onerel)
diff --git a/src/backend/commands/vacuumlazy.c b/src/backend/commands/vacuumlazy.c
index a5c024cc19..9393fa0727 100644
--- a/src/backend/commands/vacuumlazy.c
+++ b/src/backend/commands/vacuumlazy.c
@@ -705,15 +705,16 @@ lazy_scan_heap(Relation onerel, LVRelStats *vacrelstats,
PageSetAllVisible(page);
SetBufferCommitInfoNeedsSave(buf);
}
+
/*
* It's possible for the value returned by GetOldestXmin() to move
* backwards, so it's not wrong for us to see tuples that appear to
* not be visible to everyone yet, while PD_ALL_VISIBLE is already
* set. The real safe xmin value never moves backwards, but
* GetOldestXmin() is conservative and sometimes returns a value
- * that's unnecessarily small, so if we see that contradiction it
- * just means that the tuples that we think are not visible to
- * everyone yet actually are, and the PD_ALL_VISIBLE flag is correct.
+ * that's unnecessarily small, so if we see that contradiction it just
+ * means that the tuples that we think are not visible to everyone yet
+ * actually are, and the PD_ALL_VISIBLE flag is correct.
*
* There should never be dead tuples on a page with PD_ALL_VISIBLE
* set, however.
diff --git a/src/backend/commands/variable.c b/src/backend/commands/variable.c
index 2cec713089..5d0fbdfb40 100644
--- a/src/backend/commands/variable.c
+++ b/src/backend/commands/variable.c
@@ -132,8 +132,8 @@ check_datestyle(char **newval, void **extra, GucSource source)
* We can't simply "return check_datestyle(...)" because we need
* to handle constructs like "DEFAULT, ISO".
*/
- char *subval;
- void *subextra = NULL;
+ char *subval;
+ void *subextra = NULL;
subval = strdup(GetConfigOptionResetString("datestyle"));
if (!subval)
@@ -262,9 +262,9 @@ check_timezone(char **newval, void **extra, GucSource source)
{
/*
* The boot_val given for TimeZone in guc.c is NULL. When we see this
- * we just do nothing. If this isn't overridden from the config file
+ * we just do nothing. If this isn't overridden from the config file
* then pg_timezone_initialize() will eventually select a default
- * value from the environment. This hack has two purposes: to avoid
+ * value from the environment. This hack has two purposes: to avoid
* wasting cycles loading values that might soon be overridden from
* the config file, and to avoid trying to read the timezone files
* during InitializeGUCOptions(). The latter doesn't work in an
@@ -289,7 +289,7 @@ check_timezone(char **newval, void **extra, GucSource source)
if (pg_strncasecmp(*newval, "interval", 8) == 0)
{
/*
- * Support INTERVAL 'foo'. This is for SQL spec compliance, not
+ * Support INTERVAL 'foo'. This is for SQL spec compliance, not
* because it has any actual real-world usefulness.
*/
const char *valueptr = *newval;
@@ -391,13 +391,13 @@ check_timezone(char **newval, void **extra, GucSource source)
*
* Note: the result string should be something that we'd accept as input.
* We use the numeric format for interval cases, because it's simpler to
- * reload. In the named-timezone case, *newval is already OK and need not
+ * reload. In the named-timezone case, *newval is already OK and need not
* be changed; it might not have the canonical casing, but that's taken
* care of by show_timezone.
*/
if (myextra.HasCTZSet)
{
- char *result = (char *) malloc(64);
+ char *result = (char *) malloc(64);
if (!result)
return false;
@@ -567,7 +567,7 @@ show_log_timezone(void)
* We allow idempotent changes (r/w -> r/w and r/o -> r/o) at any time, and
* we also always allow changes from read-write to read-only. However,
* read-only may be changed to read-write only when in a top-level transaction
- * that has not yet taken an initial snapshot. Can't do it in a hot standby
+ * that has not yet taken an initial snapshot. Can't do it in a hot standby
* slave, either.
*/
bool
@@ -719,7 +719,7 @@ check_transaction_deferrable(bool *newval, void **extra, GucSource source)
*
* We can't roll back the random sequence on error, and we don't want
* config file reloads to affect it, so we only want interactive SET SEED
- * commands to set it. We use the "extra" storage to ensure that rollbacks
+ * commands to set it. We use the "extra" storage to ensure that rollbacks
* don't try to do the operation again.
*/
@@ -851,8 +851,8 @@ check_session_authorization(char **newval, void **extra, GucSource source)
{
/*
* Can't do catalog lookups, so fail. The result of this is that
- * session_authorization cannot be set in postgresql.conf, which
- * seems like a good thing anyway, so we don't work hard to avoid it.
+ * session_authorization cannot be set in postgresql.conf, which seems
+ * like a good thing anyway, so we don't work hard to avoid it.
*/
return false;
}
@@ -977,7 +977,7 @@ const char *
show_role(void)
{
/*
- * Check whether SET ROLE is active; if not return "none". This is a
+ * Check whether SET ROLE is active; if not return "none". This is a
* kluge to deal with the fact that SET SESSION AUTHORIZATION logically
* resets SET ROLE to NONE, but we cannot set the GUC role variable from
* assign_session_authorization (because we haven't got enough info to
diff --git a/src/backend/commands/view.c b/src/backend/commands/view.c
index 508fb23c9a..be681e3fd4 100644
--- a/src/backend/commands/view.c
+++ b/src/backend/commands/view.c
@@ -120,7 +120,7 @@ DefineVirtualRelation(const RangeVar *relation, List *tlist, bool replace)
def->colname = pstrdup(tle->resname);
def->typeName = makeTypeNameFromOid(exprType((Node *) tle->expr),
- exprTypmod((Node *) tle->expr));
+ exprTypmod((Node *) tle->expr));
def->inhcount = 0;
def->is_local = true;
def->is_not_null = false;
@@ -130,6 +130,7 @@ DefineVirtualRelation(const RangeVar *relation, List *tlist, bool replace)
def->cooked_default = NULL;
def->collClause = NULL;
def->collOid = exprCollation((Node *) tle->expr);
+
/*
* It's possible that the column is of a collatable type but the
* collation could not be resolved, so double-check.
@@ -240,7 +241,7 @@ DefineVirtualRelation(const RangeVar *relation, List *tlist, bool replace)
}
else
{
- Oid relid;
+ Oid relid;
/*
* now set the parameters for keys/inheritance etc. All of these are
@@ -437,8 +438,8 @@ DefineView(ViewStmt *stmt, const char *queryString)
/*
* Check for unsupported cases. These tests are redundant with ones in
- * DefineQueryRewrite(), but that function will complain about a bogus
- * ON SELECT rule, and we'd rather the message complain about a view.
+ * DefineQueryRewrite(), but that function will complain about a bogus ON
+ * SELECT rule, and we'd rather the message complain about a view.
*/
if (viewParse->intoClause != NULL)
ereport(ERROR,
@@ -447,7 +448,7 @@ DefineView(ViewStmt *stmt, const char *queryString)
if (viewParse->hasModifyingCTE)
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("views must not contain data-modifying statements in WITH")));
+ errmsg("views must not contain data-modifying statements in WITH")));
/*
* If a list of column names was given, run through and insert these into
@@ -500,7 +501,7 @@ DefineView(ViewStmt *stmt, const char *queryString)
if (view->relpersistence == RELPERSISTENCE_UNLOGGED)
ereport(ERROR,
(errcode(ERRCODE_SYNTAX_ERROR),
- errmsg("views cannot be unlogged because they do not have storage")));
+ errmsg("views cannot be unlogged because they do not have storage")));
/*
* Create the view relation
diff --git a/src/backend/executor/execMain.c b/src/backend/executor/execMain.c
index caa9faea87..86ec987019 100644
--- a/src/backend/executor/execMain.c
+++ b/src/backend/executor/execMain.c
@@ -19,7 +19,7 @@
* ExecutorRun accepts direction and count arguments that specify whether
* the plan is to be executed forwards, backwards, and for how many tuples.
* In some cases ExecutorRun may be called multiple times to process all
- * the tuples for a plan. It is also acceptable to stop short of executing
+ * the tuples for a plan. It is also acceptable to stop short of executing
* the whole plan (but only if it is a SELECT).
*
* ExecutorFinish must be called after the final ExecutorRun call and
@@ -168,6 +168,7 @@ standard_ExecutorStart(QueryDesc *queryDesc, int eflags)
switch (queryDesc->operation)
{
case CMD_SELECT:
+
/*
* SELECT INTO, SELECT FOR UPDATE/SHARE and modifying CTEs need to
* mark tuples
@@ -332,12 +333,12 @@ standard_ExecutorRun(QueryDesc *queryDesc,
* ExecutorFinish
*
* This routine must be called after the last ExecutorRun call.
- * It performs cleanup such as firing AFTER triggers. It is
+ * It performs cleanup such as firing AFTER triggers. It is
* separate from ExecutorEnd because EXPLAIN ANALYZE needs to
* include these actions in the total runtime.
*
* We provide a function hook variable that lets loadable plugins
- * get control when ExecutorFinish is called. Such a plugin would
+ * get control when ExecutorFinish is called. Such a plugin would
* normally call standard_ExecutorFinish().
*
* ----------------------------------------------------------------
@@ -425,9 +426,9 @@ standard_ExecutorEnd(QueryDesc *queryDesc)
Assert(estate != NULL);
/*
- * Check that ExecutorFinish was called, unless in EXPLAIN-only mode.
- * This Assert is needed because ExecutorFinish is new as of 9.1, and
- * callers might forget to call it.
+ * Check that ExecutorFinish was called, unless in EXPLAIN-only mode. This
+ * Assert is needed because ExecutorFinish is new as of 9.1, and callers
+ * might forget to call it.
*/
Assert(estate->es_finished ||
(estate->es_top_eflags & EXEC_FLAG_EXPLAIN_ONLY));
@@ -519,7 +520,7 @@ ExecCheckRTPerms(List *rangeTable, bool ereport_on_violation)
foreach(l, rangeTable)
{
- RangeTblEntry *rte = (RangeTblEntry *) lfirst(l);
+ RangeTblEntry *rte = (RangeTblEntry *) lfirst(l);
result = ExecCheckRTEPerms(rte);
if (!result)
@@ -533,8 +534,8 @@ ExecCheckRTPerms(List *rangeTable, bool ereport_on_violation)
}
if (ExecutorCheckPerms_hook)
- result = (*ExecutorCheckPerms_hook)(rangeTable,
- ereport_on_violation);
+ result = (*ExecutorCheckPerms_hook) (rangeTable,
+ ereport_on_violation);
return result;
}
@@ -980,7 +981,7 @@ InitPlan(QueryDesc *queryDesc, int eflags)
void
CheckValidResultRel(Relation resultRel, CmdType operation)
{
- TriggerDesc *trigDesc = resultRel->trigdesc;
+ TriggerDesc *trigDesc = resultRel->trigdesc;
switch (resultRel->rd_rel->relkind)
{
@@ -1005,26 +1006,26 @@ CheckValidResultRel(Relation resultRel, CmdType operation)
case CMD_INSERT:
if (!trigDesc || !trigDesc->trig_insert_instead_row)
ereport(ERROR,
- (errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
- errmsg("cannot insert into view \"%s\"",
- RelationGetRelationName(resultRel)),
- errhint("You need an unconditional ON INSERT DO INSTEAD rule or an INSTEAD OF INSERT trigger.")));
+ (errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
+ errmsg("cannot insert into view \"%s\"",
+ RelationGetRelationName(resultRel)),
+ errhint("You need an unconditional ON INSERT DO INSTEAD rule or an INSTEAD OF INSERT trigger.")));
break;
case CMD_UPDATE:
if (!trigDesc || !trigDesc->trig_update_instead_row)
ereport(ERROR,
- (errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
- errmsg("cannot update view \"%s\"",
- RelationGetRelationName(resultRel)),
- errhint("You need an unconditional ON UPDATE DO INSTEAD rule or an INSTEAD OF UPDATE trigger.")));
+ (errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
+ errmsg("cannot update view \"%s\"",
+ RelationGetRelationName(resultRel)),
+ errhint("You need an unconditional ON UPDATE DO INSTEAD rule or an INSTEAD OF UPDATE trigger.")));
break;
case CMD_DELETE:
if (!trigDesc || !trigDesc->trig_delete_instead_row)
ereport(ERROR,
- (errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
- errmsg("cannot delete from view \"%s\"",
- RelationGetRelationName(resultRel)),
- errhint("You need an unconditional ON DELETE DO INSTEAD rule or an INSTEAD OF DELETE trigger.")));
+ (errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
+ errmsg("cannot delete from view \"%s\"",
+ RelationGetRelationName(resultRel)),
+ errhint("You need an unconditional ON DELETE DO INSTEAD rule or an INSTEAD OF DELETE trigger.")));
break;
default:
elog(ERROR, "unrecognized CmdType: %d", (int) operation);
@@ -1137,8 +1138,8 @@ ExecGetTriggerResultRel(EState *estate, Oid relid)
/*
* Open the target relation's relcache entry. We assume that an
* appropriate lock is still held by the backend from whenever the trigger
- * event got queued, so we need take no new lock here. Also, we need
- * not recheck the relkind, so no need for CheckValidResultRel.
+ * event got queued, so we need take no new lock here. Also, we need not
+ * recheck the relkind, so no need for CheckValidResultRel.
*/
rel = heap_open(relid, NoLock);
@@ -1238,12 +1239,12 @@ ExecPostprocessPlan(EState *estate)
/*
* Run any secondary ModifyTable nodes to completion, in case the main
- * query did not fetch all rows from them. (We do this to ensure that
+ * query did not fetch all rows from them. (We do this to ensure that
* such nodes have predictable results.)
*/
foreach(lc, estate->es_auxmodifytables)
{
- PlanState *ps = (PlanState *) lfirst(lc);
+ PlanState *ps = (PlanState *) lfirst(lc);
for (;;)
{
@@ -2220,9 +2221,9 @@ EvalPlanQualStart(EPQState *epqstate, EState *parentestate, Plan *planTree)
* ExecInitSubPlan expects to be able to find these entries. Some of the
* SubPlans might not be used in the part of the plan tree we intend to
* run, but since it's not easy to tell which, we just initialize them
- * all. (However, if the subplan is headed by a ModifyTable node, then
- * it must be a data-modifying CTE, which we will certainly not need to
- * re-run, so we can skip initializing it. This is just an efficiency
+ * all. (However, if the subplan is headed by a ModifyTable node, then it
+ * must be a data-modifying CTE, which we will certainly not need to
+ * re-run, so we can skip initializing it. This is just an efficiency
* hack; it won't skip data-modifying CTEs for which the ModifyTable node
* is not at the top.)
*/
diff --git a/src/backend/executor/execQual.c b/src/backend/executor/execQual.c
index c153ca00db..5f0b58f43b 100644
--- a/src/backend/executor/execQual.c
+++ b/src/backend/executor/execQual.c
@@ -79,9 +79,9 @@ static Datum ExecEvalWholeRowSlow(ExprState *exprstate, ExprContext *econtext,
static Datum ExecEvalConst(ExprState *exprstate, ExprContext *econtext,
bool *isNull, ExprDoneCond *isDone);
static Datum ExecEvalParamExec(ExprState *exprstate, ExprContext *econtext,
- bool *isNull, ExprDoneCond *isDone);
+ bool *isNull, ExprDoneCond *isDone);
static Datum ExecEvalParamExtern(ExprState *exprstate, ExprContext *econtext,
- bool *isNull, ExprDoneCond *isDone);
+ bool *isNull, ExprDoneCond *isDone);
static void init_fcache(Oid foid, Oid input_collation, FuncExprState *fcache,
MemoryContext fcacheCxt, bool needDescForSets);
static void ShutdownFuncExpr(Datum arg);
@@ -1043,7 +1043,7 @@ ExecEvalParamExtern(ExprState *exprstate, ExprContext *econtext,
ereport(ERROR,
(errcode(ERRCODE_UNDEFINED_OBJECT),
errmsg("no value found for parameter %d", thisParamId)));
- return (Datum) 0; /* keep compiler quiet */
+ return (Datum) 0; /* keep compiler quiet */
}
diff --git a/src/backend/executor/execUtils.c b/src/backend/executor/execUtils.c
index 7e84ccdd9c..0cbbe04d3b 100644
--- a/src/backend/executor/execUtils.c
+++ b/src/backend/executor/execUtils.c
@@ -1319,9 +1319,9 @@ retry:
/*
* Ordinarily, at this point the search should have found the originally
* inserted tuple, unless we exited the loop early because of conflict.
- * However, it is possible to define exclusion constraints for which
- * that wouldn't be true --- for instance, if the operator is <>.
- * So we no longer complain if found_self is still false.
+ * However, it is possible to define exclusion constraints for which that
+ * wouldn't be true --- for instance, if the operator is <>. So we no
+ * longer complain if found_self is still false.
*/
econtext->ecxt_scantuple = save_scantuple;
diff --git a/src/backend/executor/functions.c b/src/backend/executor/functions.c
index 70d126c521..9c867bbae2 100644
--- a/src/backend/executor/functions.c
+++ b/src/backend/executor/functions.c
@@ -81,7 +81,7 @@ typedef struct
char *fname; /* function name (for error msgs) */
char *src; /* function body text (for error msgs) */
- SQLFunctionParseInfoPtr pinfo; /* data for parser callback hooks */
+ SQLFunctionParseInfoPtr pinfo; /* data for parser callback hooks */
Oid rettype; /* actual return type */
int16 typlen; /* length of the return type */
@@ -119,7 +119,7 @@ typedef struct SQLFunctionParseInfo
Oid *argtypes; /* resolved types of input arguments */
int nargs; /* number of input arguments */
Oid collation; /* function's input collation, if known */
-} SQLFunctionParseInfo;
+} SQLFunctionParseInfo;
/* non-export function prototypes */
@@ -255,7 +255,7 @@ sql_fn_param_ref(ParseState *pstate, ParamRef *pref)
* Set up the per-query execution_state records for a SQL function.
*
* The input is a List of Lists of parsed and rewritten, but not planned,
- * querytrees. The sublist structure denotes the original query boundaries.
+ * querytrees. The sublist structure denotes the original query boundaries.
*/
static List *
init_execution_state(List *queryTree_list,
@@ -299,8 +299,8 @@ init_execution_state(List *queryTree_list,
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
/* translator: %s is a SQL statement name */
- errmsg("%s is not allowed in a non-volatile function",
- CreateCommandTag(stmt))));
+ errmsg("%s is not allowed in a non-volatile function",
+ CreateCommandTag(stmt))));
/* OK, build the execution_state for this query */
newes = (execution_state *) palloc(sizeof(execution_state));
@@ -311,8 +311,8 @@ init_execution_state(List *queryTree_list,
newes->next = NULL;
newes->status = F_EXEC_START;
- newes->setsResult = false; /* might change below */
- newes->lazyEval = false; /* might change below */
+ newes->setsResult = false; /* might change below */
+ newes->lazyEval = false; /* might change below */
newes->stmt = stmt;
newes->qd = NULL;
@@ -442,7 +442,7 @@ init_sql_fcache(FmgrInfo *finfo, bool lazyEvalOK)
fcache->src = TextDatumGetCString(tmp);
/*
- * Parse and rewrite the queries in the function text. Use sublists to
+ * Parse and rewrite the queries in the function text. Use sublists to
* keep track of the original query boundaries. But we also build a
* "flat" list of the rewritten queries to pass to check_sql_fn_retval.
* This is because the last canSetTag query determines the result type
@@ -462,7 +462,7 @@ init_sql_fcache(FmgrInfo *finfo, bool lazyEvalOK)
queryTree_sublist = pg_analyze_and_rewrite_params(parsetree,
fcache->src,
- (ParserSetupHook) sql_fn_parser_setup,
+ (ParserSetupHook) sql_fn_parser_setup,
fcache->pinfo);
queryTree_list = lappend(queryTree_list, queryTree_sublist);
flat_query_list = list_concat(flat_query_list,
@@ -657,7 +657,7 @@ postquel_sub_params(SQLFunctionCachePtr fcache,
{
/* sizeof(ParamListInfoData) includes the first array element */
paramLI = (ParamListInfo) palloc(sizeof(ParamListInfoData) +
- (nargs - 1) *sizeof(ParamExternData));
+ (nargs - 1) * sizeof(ParamExternData));
/* we have static list of params, so no hooks needed */
paramLI->paramFetch = NULL;
paramLI->paramFetchArg = NULL;
@@ -748,8 +748,8 @@ fmgr_sql(PG_FUNCTION_ARGS)
execution_state *es;
TupleTableSlot *slot;
Datum result;
- List *eslist;
- ListCell *eslc;
+ List *eslist;
+ ListCell *eslc;
/*
* Switch to context in which the fcache lives. This ensures that
@@ -847,10 +847,10 @@ fmgr_sql(PG_FUNCTION_ARGS)
*
* In a non-read-only function, we rely on the fact that we'll never
* suspend execution between queries of the function: the only reason to
- * suspend execution before completion is if we are returning a row from
- * a lazily-evaluated SELECT. So, when first entering this loop, we'll
+ * suspend execution before completion is if we are returning a row from a
+ * lazily-evaluated SELECT. So, when first entering this loop, we'll
* either start a new query (and push a fresh snapshot) or re-establish
- * the active snapshot from the existing query descriptor. If we need to
+ * the active snapshot from the existing query descriptor. If we need to
* start a new query in a subsequent execution of the loop, either we need
* a fresh snapshot (and pushed_snapshot is false) or the existing
* snapshot is on the active stack and we can just bump its command ID.
@@ -927,10 +927,10 @@ fmgr_sql(PG_FUNCTION_ARGS)
es = (execution_state *) lfirst(eslc);
/*
- * Flush the current snapshot so that we will take a new one
- * for the new query list. This ensures that new snaps are
- * taken at original-query boundaries, matching the behavior
- * of interactive execution.
+ * Flush the current snapshot so that we will take a new one for
+ * the new query list. This ensures that new snaps are taken at
+ * original-query boundaries, matching the behavior of interactive
+ * execution.
*/
if (pushed_snapshot)
{
@@ -1183,7 +1183,7 @@ ShutdownSQLFunction(Datum arg)
{
SQLFunctionCachePtr fcache = (SQLFunctionCachePtr) DatumGetPointer(arg);
execution_state *es;
- ListCell *lc;
+ ListCell *lc;
foreach(lc, fcache->func_state)
{
@@ -1415,7 +1415,7 @@ check_sql_fn_retval(Oid func_id, Oid rettype, List *queryTreeList,
* the function that's calling it.
*
* XXX Note that if rettype is RECORD, the IsBinaryCoercible check
- * will succeed for any composite restype. For the moment we rely on
+ * will succeed for any composite restype. For the moment we rely on
* runtime type checking to catch any discrepancy, but it'd be nice to
* do better at parse time.
*/
@@ -1432,7 +1432,7 @@ check_sql_fn_retval(Oid func_id, Oid rettype, List *queryTreeList,
tle->expr = (Expr *) makeRelabelType(tle->expr,
rettype,
-1,
- get_typcollation(rettype),
+ get_typcollation(rettype),
COERCE_DONTCARE);
/* Relabel is dangerous if sort/group or setop column */
if (tle->ressortgroupref != 0 || parse->setOperations)
@@ -1536,7 +1536,7 @@ check_sql_fn_retval(Oid func_id, Oid rettype, List *queryTreeList,
tle->expr = (Expr *) makeRelabelType(tle->expr,
atttype,
-1,
- get_typcollation(atttype),
+ get_typcollation(atttype),
COERCE_DONTCARE);
/* Relabel is dangerous if sort/group or setop column */
if (tle->ressortgroupref != 0 || parse->setOperations)
diff --git a/src/backend/executor/nodeAgg.c b/src/backend/executor/nodeAgg.c
index 51b1228c26..47555bab55 100644
--- a/src/backend/executor/nodeAgg.c
+++ b/src/backend/executor/nodeAgg.c
@@ -199,7 +199,7 @@ typedef struct AggStatePerAggData
*/
Tuplesortstate *sortstate; /* sort object, if DISTINCT or ORDER BY */
-} AggStatePerAggData;
+} AggStatePerAggData;
/*
* AggStatePerGroupData - per-aggregate-per-group working state
@@ -246,7 +246,7 @@ typedef struct AggHashEntryData
TupleHashEntryData shared; /* common header for hash table entries */
/* per-aggregate transition status array - must be last! */
AggStatePerGroupData pergroup[1]; /* VARIABLE LENGTH ARRAY */
-} AggHashEntryData; /* VARIABLE LENGTH STRUCT */
+} AggHashEntryData; /* VARIABLE LENGTH STRUCT */
static void initialize_aggregates(AggState *aggstate,
@@ -827,7 +827,7 @@ build_hash_table(AggState *aggstate)
Assert(node->numGroups > 0);
entrysize = sizeof(AggHashEntryData) +
- (aggstate->numaggs - 1) *sizeof(AggStatePerGroupData);
+ (aggstate->numaggs - 1) * sizeof(AggStatePerGroupData);
aggstate->hashtable = BuildTupleHashTable(node->numCols,
node->grpColIdx,
@@ -899,7 +899,7 @@ hash_agg_entry_size(int numAggs)
/* This must match build_hash_table */
entrysize = sizeof(AggHashEntryData) +
- (numAggs - 1) *sizeof(AggStatePerGroupData);
+ (numAggs - 1) * sizeof(AggStatePerGroupData);
entrysize = MAXALIGN(entrysize);
/* Account for hashtable overhead (assuming fill factor = 1) */
entrysize += 3 * sizeof(void *);
diff --git a/src/backend/executor/nodeBitmapIndexscan.c b/src/backend/executor/nodeBitmapIndexscan.c
index 90ff0403ab..4de54ea55f 100644
--- a/src/backend/executor/nodeBitmapIndexscan.c
+++ b/src/backend/executor/nodeBitmapIndexscan.c
@@ -307,8 +307,8 @@ ExecInitBitmapIndexScan(BitmapIndexScan *node, EState *estate, int eflags)
indexstate->biss_NumScanKeys);
/*
- * If no run-time keys to calculate, go ahead and pass the scankeys to
- * the index AM.
+ * If no run-time keys to calculate, go ahead and pass the scankeys to the
+ * index AM.
*/
if (indexstate->biss_NumRuntimeKeys == 0 &&
indexstate->biss_NumArrayKeys == 0)
diff --git a/src/backend/executor/nodeForeignscan.c b/src/backend/executor/nodeForeignscan.c
index c4309a981e..d50489c7f4 100644
--- a/src/backend/executor/nodeForeignscan.c
+++ b/src/backend/executor/nodeForeignscan.c
@@ -40,7 +40,7 @@ static TupleTableSlot *
ForeignNext(ForeignScanState *node)
{
TupleTableSlot *slot;
- ForeignScan *plan = (ForeignScan *) node->ss.ps.plan;
+ ForeignScan *plan = (ForeignScan *) node->ss.ps.plan;
ExprContext *econtext = node->ss.ps.ps_ExprContext;
MemoryContext oldcontext;
diff --git a/src/backend/executor/nodeHash.c b/src/backend/executor/nodeHash.c
index 295563011f..1af98c81a6 100644
--- a/src/backend/executor/nodeHash.c
+++ b/src/backend/executor/nodeHash.c
@@ -960,13 +960,11 @@ void
ExecPrepHashTableForUnmatched(HashJoinState *hjstate)
{
/*
- *----------
- * During this scan we use the HashJoinState fields as follows:
+ * ---------- During this scan we use the HashJoinState fields as follows:
*
- * hj_CurBucketNo: next regular bucket to scan
- * hj_CurSkewBucketNo: next skew bucket (an index into skewBucketNums)
- * hj_CurTuple: last tuple returned, or NULL to start next bucket
- *----------
+ * hj_CurBucketNo: next regular bucket to scan hj_CurSkewBucketNo: next
+ * skew bucket (an index into skewBucketNums) hj_CurTuple: last tuple
+ * returned, or NULL to start next bucket ----------
*/
hjstate->hj_CurBucketNo = 0;
hjstate->hj_CurSkewBucketNo = 0;
@@ -1003,7 +1001,7 @@ ExecScanHashTableForUnmatched(HashJoinState *hjstate, ExprContext *econtext)
}
else if (hjstate->hj_CurSkewBucketNo < hashtable->nSkewBuckets)
{
- int j = hashtable->skewBucketNums[hjstate->hj_CurSkewBucketNo];
+ int j = hashtable->skewBucketNums[hjstate->hj_CurSkewBucketNo];
hashTuple = hashtable->skewBucket[j]->tuples;
hjstate->hj_CurSkewBucketNo++;
@@ -1020,7 +1018,7 @@ ExecScanHashTableForUnmatched(HashJoinState *hjstate, ExprContext *econtext)
/* insert hashtable's tuple into exec slot */
inntuple = ExecStoreMinimalTuple(HJTUPLE_MINTUPLE(hashTuple),
hjstate->hj_HashTupleSlot,
- false); /* do not pfree */
+ false); /* do not pfree */
econtext->ecxt_innertuple = inntuple;
/*
@@ -1091,7 +1089,7 @@ ExecHashTableResetMatchFlags(HashJoinTable hashtable)
/* ... and the same for the skew buckets, if any */
for (i = 0; i < hashtable->nSkewBuckets; i++)
{
- int j = hashtable->skewBucketNums[i];
+ int j = hashtable->skewBucketNums[i];
HashSkewBucket *skewBucket = hashtable->skewBucket[j];
for (tuple = skewBucket->tuples; tuple != NULL; tuple = tuple->next)
diff --git a/src/backend/executor/nodeHashjoin.c b/src/backend/executor/nodeHashjoin.c
index a6847c956f..7c02db94ad 100644
--- a/src/backend/executor/nodeHashjoin.c
+++ b/src/backend/executor/nodeHashjoin.c
@@ -113,6 +113,7 @@ ExecHashJoin(HashJoinState *node)
switch (node->hj_JoinState)
{
case HJ_BUILD_HASHTABLE:
+
/*
* First time through: build hash table for inner relation.
*/
@@ -123,12 +124,12 @@ ExecHashJoin(HashJoinState *node)
* right/full join, we can quit without building the hash
* table. However, for an inner join it is only a win to
* check this when the outer relation's startup cost is less
- * than the projected cost of building the hash
- * table. Otherwise it's best to build the hash table first
- * and see if the inner relation is empty. (When it's a left
- * join, we should always make this check, since we aren't
- * going to be able to skip the join on the strength of an
- * empty inner relation anyway.)
+ * than the projected cost of building the hash table.
+ * Otherwise it's best to build the hash table first and see
+ * if the inner relation is empty. (When it's a left join, we
+ * should always make this check, since we aren't going to be
+ * able to skip the join on the strength of an empty inner
+ * relation anyway.)
*
* If we are rescanning the join, we make use of information
* gained on the previous scan: don't bother to try the
@@ -185,8 +186,8 @@ ExecHashJoin(HashJoinState *node)
return NULL;
/*
- * need to remember whether nbatch has increased since we began
- * scanning the outer relation
+ * need to remember whether nbatch has increased since we
+ * began scanning the outer relation
*/
hashtable->nbatch_outstart = hashtable->nbatch;
@@ -202,6 +203,7 @@ ExecHashJoin(HashJoinState *node)
/* FALL THRU */
case HJ_NEED_NEW_OUTER:
+
/*
* We don't have an outer tuple, try to get the next one
*/
@@ -250,7 +252,7 @@ ExecHashJoin(HashJoinState *node)
Assert(batchno > hashtable->curbatch);
ExecHashJoinSaveTuple(ExecFetchSlotMinimalTuple(outerTupleSlot),
hashvalue,
- &hashtable->outerBatchFile[batchno]);
+ &hashtable->outerBatchFile[batchno]);
/* Loop around, staying in HJ_NEED_NEW_OUTER state */
continue;
}
@@ -261,6 +263,7 @@ ExecHashJoin(HashJoinState *node)
/* FALL THRU */
case HJ_SCAN_BUCKET:
+
/*
* Scan the selected hash bucket for matches to current outer
*/
@@ -296,8 +299,8 @@ ExecHashJoin(HashJoinState *node)
}
/*
- * In a semijoin, we'll consider returning the first match,
- * but after that we're done with this outer tuple.
+ * In a semijoin, we'll consider returning the first
+ * match, but after that we're done with this outer tuple.
*/
if (node->js.jointype == JOIN_SEMI)
node->hj_JoinState = HJ_NEED_NEW_OUTER;
@@ -320,10 +323,11 @@ ExecHashJoin(HashJoinState *node)
break;
case HJ_FILL_OUTER_TUPLE:
+
/*
* The current outer tuple has run out of matches, so check
- * whether to emit a dummy outer-join tuple. Whether we
- * emit one or not, the next state is NEED_NEW_OUTER.
+ * whether to emit a dummy outer-join tuple. Whether we emit
+ * one or not, the next state is NEED_NEW_OUTER.
*/
node->hj_JoinState = HJ_NEED_NEW_OUTER;
@@ -354,6 +358,7 @@ ExecHashJoin(HashJoinState *node)
break;
case HJ_FILL_INNER_TUPLES:
+
/*
* We have finished a batch, but we are doing right/full join,
* so any unmatched inner tuples in the hashtable have to be
@@ -389,11 +394,12 @@ ExecHashJoin(HashJoinState *node)
break;
case HJ_NEED_NEW_BATCH:
+
/*
* Try to advance to next batch. Done if there are no more.
*/
if (!ExecHashJoinNewBatch(node))
- return NULL; /* end of join */
+ return NULL; /* end of join */
node->hj_JoinState = HJ_NEED_NEW_OUTER;
break;
@@ -783,7 +789,7 @@ ExecHashJoinNewBatch(HashJoinState *hjstate)
}
if (curbatch >= nbatch)
- return false; /* no more batches */
+ return false; /* no more batches */
hashtable->curbatch = curbatch;
@@ -829,7 +835,7 @@ ExecHashJoinNewBatch(HashJoinState *hjstate)
if (BufFileSeek(hashtable->outerBatchFile[curbatch], 0, 0L, SEEK_SET))
ereport(ERROR,
(errcode_for_file_access(),
- errmsg("could not rewind hash-join temporary file: %m")));
+ errmsg("could not rewind hash-join temporary file: %m")));
}
return true;
@@ -944,14 +950,13 @@ ExecReScanHashJoin(HashJoinState *node)
ExecHashTableResetMatchFlags(node->hj_HashTable);
/*
- * Also, we need to reset our state about the emptiness of
- * the outer relation, so that the new scan of the outer will
- * update it correctly if it turns out to be empty this time.
- * (There's no harm in clearing it now because ExecHashJoin won't
- * need the info. In the other cases, where the hash table
- * doesn't exist or we are destroying it, we leave this state
- * alone because ExecHashJoin will need it the first time
- * through.)
+ * Also, we need to reset our state about the emptiness of the
+ * outer relation, so that the new scan of the outer will update
+ * it correctly if it turns out to be empty this time. (There's no
+ * harm in clearing it now because ExecHashJoin won't need the
+ * info. In the other cases, where the hash table doesn't exist
+ * or we are destroying it, we leave this state alone because
+ * ExecHashJoin will need it the first time through.)
*/
node->hj_OuterNotEmpty = false;
diff --git a/src/backend/executor/nodeIndexscan.c b/src/backend/executor/nodeIndexscan.c
index 3b8741fc21..d8e59ca39e 100644
--- a/src/backend/executor/nodeIndexscan.c
+++ b/src/backend/executor/nodeIndexscan.c
@@ -212,7 +212,7 @@ ExecIndexEvalRuntimeKeys(ExprContext *econtext,
/*
* For each run-time key, extract the run-time expression and evaluate
- * it with respect to the current context. We then stick the result
+ * it with respect to the current context. We then stick the result
* into the proper scan key.
*
* Note: the result of the eval could be a pass-by-ref value that's
@@ -605,16 +605,16 @@ ExecInitIndexScan(IndexScan *node, EState *estate, int eflags)
indexstate->iss_RelationDesc,
estate->es_snapshot,
indexstate->iss_NumScanKeys,
- indexstate->iss_NumOrderByKeys);
+ indexstate->iss_NumOrderByKeys);
/*
- * If no run-time keys to calculate, go ahead and pass the scankeys to
- * the index AM.
+ * If no run-time keys to calculate, go ahead and pass the scankeys to the
+ * index AM.
*/
if (indexstate->iss_NumRuntimeKeys == 0)
index_rescan(indexstate->iss_ScanDesc,
indexstate->iss_ScanKeys, indexstate->iss_NumScanKeys,
- indexstate->iss_OrderByKeys, indexstate->iss_NumOrderByKeys);
+ indexstate->iss_OrderByKeys, indexstate->iss_NumOrderByKeys);
/*
* all done.
@@ -703,11 +703,11 @@ ExecIndexBuildScanKeys(PlanState *planstate, Relation index, Index scanrelid,
scan_keys = (ScanKey) palloc(n_scan_keys * sizeof(ScanKeyData));
/*
- * runtime_keys array is dynamically resized as needed. We handle it
- * this way so that the same runtime keys array can be shared between
- * indexquals and indexorderbys, which will be processed in separate
- * calls of this function. Caller must be sure to pass in NULL/0 for
- * first call.
+ * runtime_keys array is dynamically resized as needed. We handle it this
+ * way so that the same runtime keys array can be shared between
+ * indexquals and indexorderbys, which will be processed in separate calls
+ * of this function. Caller must be sure to pass in NULL/0 for first
+ * call.
*/
runtime_keys = *runtimeKeys;
n_runtime_keys = max_runtime_keys = *numRuntimeKeys;
diff --git a/src/backend/executor/nodeLimit.c b/src/backend/executor/nodeLimit.c
index edbe0558b7..85d1a6e27f 100644
--- a/src/backend/executor/nodeLimit.c
+++ b/src/backend/executor/nodeLimit.c
@@ -346,14 +346,14 @@ pass_down_bound(LimitState *node, PlanState *child_node)
else if (IsA(child_node, ResultState))
{
/*
- * An extra consideration here is that if the Result is projecting
- * a targetlist that contains any SRFs, we can't assume that every
- * input tuple generates an output tuple, so a Sort underneath
- * might need to return more than N tuples to satisfy LIMIT N.
- * So we cannot use bounded sort.
+ * An extra consideration here is that if the Result is projecting a
+ * targetlist that contains any SRFs, we can't assume that every input
+ * tuple generates an output tuple, so a Sort underneath might need to
+ * return more than N tuples to satisfy LIMIT N. So we cannot use
+ * bounded sort.
*
- * If Result supported qual checking, we'd have to punt on seeing
- * a qual, too. Note that having a resconstantqual is not a
+ * If Result supported qual checking, we'd have to punt on seeing a
+ * qual, too. Note that having a resconstantqual is not a
* showstopper: if that fails we're not getting any rows at all.
*/
if (outerPlanState(child_node) &&
diff --git a/src/backend/executor/nodeLockRows.c b/src/backend/executor/nodeLockRows.c
index 2e08008807..d71278ebd7 100644
--- a/src/backend/executor/nodeLockRows.c
+++ b/src/backend/executor/nodeLockRows.c
@@ -291,7 +291,7 @@ ExecInitLockRows(LockRows *node, EState *estate, int eflags)
/*
* Locate the ExecRowMark(s) that this node is responsible for, and
- * construct ExecAuxRowMarks for them. (InitPlan should already have
+ * construct ExecAuxRowMarks for them. (InitPlan should already have
* built the global list of ExecRowMarks.)
*/
lrstate->lr_arowMarks = NIL;
diff --git a/src/backend/executor/nodeMergeAppend.c b/src/backend/executor/nodeMergeAppend.c
index 73920f21c8..4ebe0cbe03 100644
--- a/src/backend/executor/nodeMergeAppend.c
+++ b/src/backend/executor/nodeMergeAppend.c
@@ -48,8 +48,8 @@
* contains integers which index into the slots array. These typedefs try to
* clear it up, but they're only documentation.
*/
-typedef int SlotNumber;
-typedef int HeapPosition;
+typedef int SlotNumber;
+typedef int HeapPosition;
static void heap_insert_slot(MergeAppendState *node, SlotNumber new_slot);
static void heap_siftup_slot(MergeAppendState *node);
@@ -128,13 +128,13 @@ ExecInitMergeAppend(MergeAppend *node, EState *estate, int eflags)
* initialize sort-key information
*/
mergestate->ms_nkeys = node->numCols;
- mergestate->ms_scankeys = palloc0(sizeof(ScanKeyData) * node->numCols);
+ mergestate->ms_scankeys = palloc0(sizeof(ScanKeyData) * node->numCols);
for (i = 0; i < node->numCols; i++)
{
- Oid sortFunction;
- bool reverse;
- int flags;
+ Oid sortFunction;
+ bool reverse;
+ int flags;
if (!get_compare_function_for_ordering_op(node->sortOperators[i],
&sortFunction, &reverse))
@@ -187,8 +187,8 @@ ExecMergeAppend(MergeAppendState *node)
if (!node->ms_initialized)
{
/*
- * First time through: pull the first tuple from each subplan,
- * and set up the heap.
+ * First time through: pull the first tuple from each subplan, and set
+ * up the heap.
*/
for (i = 0; i < node->ms_nplans; i++)
{
@@ -243,7 +243,7 @@ heap_insert_slot(MergeAppendState *node, SlotNumber new_slot)
j = node->ms_heap_size++; /* j is where the "hole" is */
while (j > 0)
{
- int i = (j-1)/2;
+ int i = (j - 1) / 2;
if (heap_compare_slots(node, new_slot, node->ms_heap[i]) >= 0)
break;
@@ -269,11 +269,11 @@ heap_siftup_slot(MergeAppendState *node)
i = 0; /* i is where the "hole" is */
for (;;)
{
- int j = 2 * i + 1;
+ int j = 2 * i + 1;
if (j >= n)
break;
- if (j+1 < n && heap_compare_slots(node, heap[j], heap[j+1]) > 0)
+ if (j + 1 < n && heap_compare_slots(node, heap[j], heap[j + 1]) > 0)
j++;
if (heap_compare_slots(node, heap[n], heap[j]) <= 0)
break;
@@ -298,13 +298,13 @@ heap_compare_slots(MergeAppendState *node, SlotNumber slot1, SlotNumber slot2)
for (nkey = 0; nkey < node->ms_nkeys; nkey++)
{
- ScanKey scankey = node->ms_scankeys + nkey;
- AttrNumber attno = scankey->sk_attno;
- Datum datum1,
- datum2;
- bool isNull1,
- isNull2;
- int32 compare;
+ ScanKey scankey = node->ms_scankeys + nkey;
+ AttrNumber attno = scankey->sk_attno;
+ Datum datum1,
+ datum2;
+ bool isNull1,
+ isNull2;
+ int32 compare;
datum1 = slot_getattr(s1, attno, &isNull1);
datum2 = slot_getattr(s2, attno, &isNull2);
diff --git a/src/backend/executor/nodeMergejoin.c b/src/backend/executor/nodeMergejoin.c
index 75c3a64535..ce5462e961 100644
--- a/src/backend/executor/nodeMergejoin.c
+++ b/src/backend/executor/nodeMergejoin.c
@@ -143,7 +143,7 @@ typedef struct MergeJoinClauseData
bool reverse; /* if true, negate the cmpfn's output */
bool nulls_first; /* if true, nulls sort low */
FmgrInfo cmpfinfo;
-} MergeJoinClauseData;
+} MergeJoinClauseData;
/* Result type for MJEvalOuterValues and MJEvalInnerValues */
typedef enum
diff --git a/src/backend/executor/nodeModifyTable.c b/src/backend/executor/nodeModifyTable.c
index f10f70a17d..c0eab4bf0d 100644
--- a/src/backend/executor/nodeModifyTable.c
+++ b/src/backend/executor/nodeModifyTable.c
@@ -544,7 +544,7 @@ ExecUpdate(ItemPointer tupleid,
*
* If we generate a new candidate tuple after EvalPlanQual testing, we
* must loop back here and recheck constraints. (We don't need to
- * redo triggers, however. If there are any BEFORE triggers then
+ * redo triggers, however. If there are any BEFORE triggers then
* trigger.c will have done heap_lock_tuple to lock the correct tuple,
* so there's no need to do them again.)
*/
@@ -608,11 +608,10 @@ lreplace:;
/*
* Note: instead of having to update the old index tuples associated
- * with the heap tuple, all we do is form and insert new index
- * tuples. This is because UPDATEs are actually DELETEs and INSERTs,
- * and index tuple deletion is done later by VACUUM (see notes in
- * ExecDelete). All we do here is insert new index tuples. -cim
- * 9/27/89
+ * with the heap tuple, all we do is form and insert new index tuples.
+ * This is because UPDATEs are actually DELETEs and INSERTs, and index
+ * tuple deletion is done later by VACUUM (see notes in ExecDelete).
+ * All we do here is insert new index tuples. -cim 9/27/89
*/
/*
@@ -713,7 +712,7 @@ ExecModifyTable(ModifyTableState *node)
TupleTableSlot *planSlot;
ItemPointer tupleid = NULL;
ItemPointerData tuple_ctid;
- HeapTupleHeader oldtuple = NULL;
+ HeapTupleHeader oldtuple = NULL;
/*
* If we've already completed processing, don't try to do more. We need
@@ -740,7 +739,7 @@ ExecModifyTable(ModifyTableState *node)
/*
* es_result_relation_info must point to the currently active result
- * relation while we are within this ModifyTable node. Even though
+ * relation while we are within this ModifyTable node. Even though
* ModifyTable nodes can't be nested statically, they can be nested
* dynamically (since our subplan could include a reference to a modifying
* CTE). So we have to save and restore the caller's value.
@@ -756,7 +755,7 @@ ExecModifyTable(ModifyTableState *node)
for (;;)
{
/*
- * Reset the per-output-tuple exprcontext. This is needed because
+ * Reset the per-output-tuple exprcontext. This is needed because
* triggers expect to use that context as workspace. It's a bit ugly
* to do this below the top level of the plan, however. We might need
* to rethink this later.
@@ -806,7 +805,8 @@ ExecModifyTable(ModifyTableState *node)
elog(ERROR, "ctid is NULL");
tupleid = (ItemPointer) DatumGetPointer(datum);
- tuple_ctid = *tupleid; /* be sure we don't free ctid!! */
+ tuple_ctid = *tupleid; /* be sure we don't free
+ * ctid!! */
tupleid = &tuple_ctid;
}
else
@@ -836,11 +836,11 @@ ExecModifyTable(ModifyTableState *node)
break;
case CMD_UPDATE:
slot = ExecUpdate(tupleid, oldtuple, slot, planSlot,
- &node->mt_epqstate, estate, node->canSetTag);
+ &node->mt_epqstate, estate, node->canSetTag);
break;
case CMD_DELETE:
slot = ExecDelete(tupleid, oldtuple, planSlot,
- &node->mt_epqstate, estate, node->canSetTag);
+ &node->mt_epqstate, estate, node->canSetTag);
break;
default:
elog(ERROR, "unknown operation");
@@ -922,9 +922,9 @@ ExecInitModifyTable(ModifyTable *node, EState *estate, int eflags)
/*
* call ExecInitNode on each of the plans to be executed and save the
- * results into the array "mt_plans". This is also a convenient place
- * to verify that the proposed target relations are valid and open their
- * indexes for insertion of new index entries. Note we *must* set
+ * results into the array "mt_plans". This is also a convenient place to
+ * verify that the proposed target relations are valid and open their
+ * indexes for insertion of new index entries. Note we *must* set
* estate->es_result_relation_info correctly while we initialize each
* sub-plan; ExecContextForcesOids depends on that!
*/
@@ -944,7 +944,7 @@ ExecInitModifyTable(ModifyTable *node, EState *estate, int eflags)
/*
* If there are indices on the result relation, open them and save
* descriptors in the result relation info, so that we can add new
- * index entries for the tuples we add/update. We need not do this
+ * index entries for the tuples we add/update. We need not do this
* for a DELETE, however, since deletion doesn't affect indexes.
*/
if (resultRelInfo->ri_RelationDesc->rd_rel->relhasindex &&
@@ -1147,10 +1147,10 @@ ExecInitModifyTable(ModifyTable *node, EState *estate, int eflags)
* Lastly, if this is not the primary (canSetTag) ModifyTable node, add it
* to estate->es_auxmodifytables so that it will be run to completion by
* ExecPostprocessPlan. (It'd actually work fine to add the primary
- * ModifyTable node too, but there's no need.) Note the use of lcons
- * not lappend: we need later-initialized ModifyTable nodes to be shut
- * down before earlier ones. This ensures that we don't throw away
- * RETURNING rows that need to be seen by a later CTE subplan.
+ * ModifyTable node too, but there's no need.) Note the use of lcons not
+ * lappend: we need later-initialized ModifyTable nodes to be shut down
+ * before earlier ones. This ensures that we don't throw away RETURNING
+ * rows that need to be seen by a later CTE subplan.
*/
if (!mtstate->canSetTag)
estate->es_auxmodifytables = lcons(mtstate,
diff --git a/src/backend/executor/nodeNestloop.c b/src/backend/executor/nodeNestloop.c
index 4893a6ea6d..e98bc0f5a3 100644
--- a/src/backend/executor/nodeNestloop.c
+++ b/src/backend/executor/nodeNestloop.c
@@ -137,9 +137,8 @@ ExecNestLoop(NestLoopState *node)
node->nl_MatchedOuter = false;
/*
- * fetch the values of any outer Vars that must be passed to
- * the inner scan, and store them in the appropriate PARAM_EXEC
- * slots.
+ * fetch the values of any outer Vars that must be passed to the
+ * inner scan, and store them in the appropriate PARAM_EXEC slots.
*/
foreach(lc, nl->nestParams)
{
@@ -330,9 +329,9 @@ ExecInitNestLoop(NestLoop *node, EState *estate, int eflags)
*
* If we have no parameters to pass into the inner rel from the outer,
* tell the inner child that cheap rescans would be good. If we do have
- * such parameters, then there is no point in REWIND support at all in
- * the inner child, because it will always be rescanned with fresh
- * parameter values.
+ * such parameters, then there is no point in REWIND support at all in the
+ * inner child, because it will always be rescanned with fresh parameter
+ * values.
*/
outerPlanState(nlstate) = ExecInitNode(outerPlan(node), estate, eflags);
if (node->nestParams == NIL)
diff --git a/src/backend/executor/nodeRecursiveunion.c b/src/backend/executor/nodeRecursiveunion.c
index 84c051854b..12e1b9a585 100644
--- a/src/backend/executor/nodeRecursiveunion.c
+++ b/src/backend/executor/nodeRecursiveunion.c
@@ -29,7 +29,7 @@ typedef struct RUHashEntryData *RUHashEntry;
typedef struct RUHashEntryData
{
TupleHashEntryData shared; /* common header for hash table entries */
-} RUHashEntryData;
+} RUHashEntryData;
/*
diff --git a/src/backend/executor/nodeSetOp.c b/src/backend/executor/nodeSetOp.c
index aa352d7822..9106f14873 100644
--- a/src/backend/executor/nodeSetOp.c
+++ b/src/backend/executor/nodeSetOp.c
@@ -76,7 +76,7 @@ typedef struct SetOpHashEntryData
{
TupleHashEntryData shared; /* common header for hash table entries */
SetOpStatePerGroupData pergroup;
-} SetOpHashEntryData;
+} SetOpHashEntryData;
static TupleTableSlot *setop_retrieve_direct(SetOpState *setopstate);
diff --git a/src/backend/executor/nodeWindowAgg.c b/src/backend/executor/nodeWindowAgg.c
index 5680efeb69..25d9298cef 100644
--- a/src/backend/executor/nodeWindowAgg.c
+++ b/src/backend/executor/nodeWindowAgg.c
@@ -92,7 +92,7 @@ typedef struct WindowStatePerFuncData
int aggno; /* if so, index of its PerAggData */
WindowObject winobj; /* object used in window function API */
-} WindowStatePerFuncData;
+} WindowStatePerFuncData;
/*
* For plain aggregate window functions, we also have one of these.
diff --git a/src/backend/executor/spi.c b/src/backend/executor/spi.c
index a717a0deea..6e723ca092 100644
--- a/src/backend/executor/spi.c
+++ b/src/backend/executor/spi.c
@@ -1787,8 +1787,8 @@ _SPI_execute_plan(SPIPlanPtr plan, ParamListInfo paramLI,
* snapshot != InvalidSnapshot, read_only = true: use exactly the given
* snapshot.
*
- * snapshot != InvalidSnapshot, read_only = false: use the given
- * snapshot, modified by advancing its command ID before each querytree.
+ * snapshot != InvalidSnapshot, read_only = false: use the given snapshot,
+ * modified by advancing its command ID before each querytree.
*
* snapshot == InvalidSnapshot, read_only = true: use the entry-time
* ActiveSnapshot, if any (if there isn't one, we run with no snapshot).
@@ -1797,8 +1797,8 @@ _SPI_execute_plan(SPIPlanPtr plan, ParamListInfo paramLI,
* snapshot for each user command, and advance its command ID before each
* querytree within the command.
*
- * In the first two cases, we can just push the snap onto the stack
- * once for the whole plan list.
+ * In the first two cases, we can just push the snap onto the stack once
+ * for the whole plan list.
*/
if (snapshot != InvalidSnapshot)
{
@@ -2028,7 +2028,7 @@ _SPI_convert_params(int nargs, Oid *argtypes,
/* sizeof(ParamListInfoData) includes the first array element */
paramLI = (ParamListInfo) palloc(sizeof(ParamListInfoData) +
- (nargs - 1) *sizeof(ParamExternData));
+ (nargs - 1) * sizeof(ParamExternData));
/* we have static list of params, so no hooks needed */
paramLI->paramFetch = NULL;
paramLI->paramFetchArg = NULL;
diff --git a/src/backend/libpq/auth.c b/src/backend/libpq/auth.c
index 151ec5613b..d003b1206a 100644
--- a/src/backend/libpq/auth.c
+++ b/src/backend/libpq/auth.c
@@ -61,6 +61,7 @@ static int recv_and_check_password_packet(Port *port);
#define IDENT_PORT 113
static int ident_inet(hbaPort *port);
+
#ifdef HAVE_UNIX_SOCKETS
static int auth_peer(hbaPort *port);
#endif
@@ -182,7 +183,7 @@ static int pg_GSS_recvauth(Port *port);
*----------------------------------------------------------------
*/
#ifdef ENABLE_SSPI
-typedef SECURITY_STATUS
+typedef SECURITY_STATUS
(WINAPI * QUERY_SECURITY_CONTEXT_TOKEN_FN) (
PCtxtHandle, void **);
static int pg_SSPI_recvauth(Port *port);
@@ -543,7 +544,7 @@ ClientAuthentication(Port *port)
}
#endif
status = auth_peer(port);
-#else /* HAVE_UNIX_SOCKETS */
+#else /* HAVE_UNIX_SOCKETS */
Assert(false);
#endif
break;
@@ -598,7 +599,7 @@ ClientAuthentication(Port *port)
}
if (ClientAuthentication_hook)
- (*ClientAuthentication_hook)(port, status);
+ (*ClientAuthentication_hook) (port, status);
if (status == STATUS_OK)
sendAuthRequest(port, AUTH_REQ_OK);
@@ -844,7 +845,7 @@ pg_krb5_recvauth(Port *port)
return ret;
retval = krb5_recvauth(pg_krb5_context, &auth_context,
- (krb5_pointer) & port->sock, pg_krb_srvnam,
+ (krb5_pointer) &port->sock, pg_krb_srvnam,
pg_krb5_server, 0, pg_krb5_keytab, &ticket);
if (retval)
{
@@ -1814,7 +1815,6 @@ auth_peer(hbaPort *port)
}
strlcpy(ident_user, pass->pw_name, IDENT_USERNAME_MAX + 1);
-
#elif defined(SO_PEERCRED)
/* Linux style: use getsockopt(SO_PEERCRED) */
struct ucred peercred;
@@ -1843,7 +1843,6 @@ auth_peer(hbaPort *port)
}
strlcpy(ident_user, pass->pw_name, IDENT_USERNAME_MAX + 1);
-
#elif defined(HAVE_GETPEERUCRED)
/* Solaris > 10 */
uid_t uid;
@@ -1879,7 +1878,6 @@ auth_peer(hbaPort *port)
}
strlcpy(ident_user, pass->pw_name, IDENT_USERNAME_MAX + 1);
-
#elif defined(HAVE_STRUCT_CMSGCRED) || defined(HAVE_STRUCT_FCRED) || (defined(HAVE_STRUCT_SOCKCRED) && defined(LOCAL_CREDS))
struct msghdr msg;
@@ -1947,7 +1945,6 @@ auth_peer(hbaPort *port)
}
strlcpy(ident_user, pw->pw_name, IDENT_USERNAME_MAX + 1);
-
#else
ereport(LOG,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
@@ -2768,10 +2765,10 @@ CheckRADIUSAuth(Port *port)
pg_freeaddrinfo_all(hint.ai_family, serveraddrs);
/*
- * Figure out at what time we should time out. We can't just use
- * a single call to select() with a timeout, since somebody can
- * be sending invalid packets to our port thus causing us to
- * retry in a loop and never time out.
+ * Figure out at what time we should time out. We can't just use a single
+ * call to select() with a timeout, since somebody can be sending invalid
+ * packets to our port thus causing us to retry in a loop and never time
+ * out.
*/
gettimeofday(&endtime, NULL);
endtime.tv_sec += RADIUS_TIMEOUT;
@@ -2780,7 +2777,7 @@ CheckRADIUSAuth(Port *port)
{
struct timeval timeout;
struct timeval now;
- int64 timeoutval;
+ int64 timeoutval;
gettimeofday(&now, NULL);
timeoutval = (endtime.tv_sec * 1000000 + endtime.tv_usec) - (now.tv_sec * 1000000 + now.tv_usec);
@@ -2820,12 +2817,12 @@ CheckRADIUSAuth(Port *port)
/*
* Attempt to read the response packet, and verify the contents.
*
- * Any packet that's not actually a RADIUS packet, or otherwise
- * does not validate as an explicit reject, is just ignored and
- * we retry for another packet (until we reach the timeout). This
- * is to avoid the possibility to denial-of-service the login by
- * flooding the server with invalid packets on the port that
- * we're expecting the RADIUS response on.
+ * Any packet that's not actually a RADIUS packet, or otherwise does
+ * not validate as an explicit reject, is just ignored and we retry
+ * for another packet (until we reach the timeout). This is to avoid
+ * the possibility to denial-of-service the login by flooding the
+ * server with invalid packets on the port that we're expecting the
+ * RADIUS response on.
*/
addrsize = sizeof(remoteaddr);
@@ -2846,12 +2843,12 @@ CheckRADIUSAuth(Port *port)
{
#ifdef HAVE_IPV6
ereport(LOG,
- (errmsg("RADIUS response was sent from incorrect port: %i",
- ntohs(remoteaddr.sin6_port))));
+ (errmsg("RADIUS response was sent from incorrect port: %i",
+ ntohs(remoteaddr.sin6_port))));
#else
ereport(LOG,
- (errmsg("RADIUS response was sent from incorrect port: %i",
- ntohs(remoteaddr.sin_port))));
+ (errmsg("RADIUS response was sent from incorrect port: %i",
+ ntohs(remoteaddr.sin_port))));
#endif
continue;
}
@@ -2885,12 +2882,12 @@ CheckRADIUSAuth(Port *port)
*/
cryptvector = palloc(packetlength + strlen(port->hba->radiussecret));
- memcpy(cryptvector, receivepacket, 4); /* code+id+length */
- memcpy(cryptvector + 4, packet->vector, RADIUS_VECTOR_LENGTH); /* request
- * authenticator, from
- * original packet */
- if (packetlength > RADIUS_HEADER_LENGTH) /* there may be no attributes
- * at all */
+ memcpy(cryptvector, receivepacket, 4); /* code+id+length */
+ memcpy(cryptvector + 4, packet->vector, RADIUS_VECTOR_LENGTH); /* request
+ * authenticator, from
+ * original packet */
+ if (packetlength > RADIUS_HEADER_LENGTH) /* there may be no
+ * attributes at all */
memcpy(cryptvector + RADIUS_HEADER_LENGTH, receive_buffer + RADIUS_HEADER_LENGTH, packetlength - RADIUS_HEADER_LENGTH);
memcpy(cryptvector + packetlength, port->hba->radiussecret, strlen(port->hba->radiussecret));
@@ -2899,7 +2896,7 @@ CheckRADIUSAuth(Port *port)
encryptedpassword))
{
ereport(LOG,
- (errmsg("could not perform MD5 encryption of received packet")));
+ (errmsg("could not perform MD5 encryption of received packet")));
pfree(cryptvector);
continue;
}
@@ -2925,9 +2922,9 @@ CheckRADIUSAuth(Port *port)
else
{
ereport(LOG,
- (errmsg("RADIUS response has invalid code (%i) for user \"%s\"",
- receivepacket->code, port->user_name)));
+ (errmsg("RADIUS response has invalid code (%i) for user \"%s\"",
+ receivepacket->code, port->user_name)));
continue;
}
- } /* while (true) */
+ } /* while (true) */
}
diff --git a/src/backend/libpq/hba.c b/src/backend/libpq/hba.c
index 2def6cea89..fdc29aaa72 100644
--- a/src/backend/libpq/hba.c
+++ b/src/backend/libpq/hba.c
@@ -543,7 +543,7 @@ check_db(const char *dbname, const char *role, Oid roleid, char *param_str)
}
static bool
-ipv4eq(struct sockaddr_in *a, struct sockaddr_in *b)
+ipv4eq(struct sockaddr_in * a, struct sockaddr_in * b)
{
return (a->sin_addr.s_addr == b->sin_addr.s_addr);
}
@@ -551,9 +551,9 @@ ipv4eq(struct sockaddr_in *a, struct sockaddr_in *b)
#ifdef HAVE_IPV6
static bool
-ipv6eq(struct sockaddr_in6 *a, struct sockaddr_in6 *b)
+ipv6eq(struct sockaddr_in6 * a, struct sockaddr_in6 * b)
{
- int i;
+ int i;
for (i = 0; i < 16; i++)
if (a->sin6_addr.s6_addr[i] != b->sin6_addr.s6_addr[i])
@@ -561,8 +561,7 @@ ipv6eq(struct sockaddr_in6 *a, struct sockaddr_in6 *b)
return true;
}
-
-#endif /* HAVE_IPV6 */
+#endif /* HAVE_IPV6 */
/*
* Check whether host name matches pattern.
@@ -572,8 +571,8 @@ hostname_match(const char *pattern, const char *actual_hostname)
{
if (pattern[0] == '.') /* suffix match */
{
- size_t plen = strlen(pattern);
- size_t hlen = strlen(actual_hostname);
+ size_t plen = strlen(pattern);
+ size_t hlen = strlen(actual_hostname);
if (hlen < plen)
return false;
@@ -590,7 +589,8 @@ hostname_match(const char *pattern, const char *actual_hostname)
static bool
check_hostname(hbaPort *port, const char *hostname)
{
- struct addrinfo *gai_result, *gai;
+ struct addrinfo *gai_result,
+ *gai;
int ret;
bool found;
@@ -632,7 +632,7 @@ check_hostname(hbaPort *port, const char *hostname)
if (gai->ai_addr->sa_family == AF_INET)
{
if (ipv4eq((struct sockaddr_in *) gai->ai_addr,
- (struct sockaddr_in *) &port->raddr.addr))
+ (struct sockaddr_in *) & port->raddr.addr))
{
found = true;
break;
@@ -642,7 +642,7 @@ check_hostname(hbaPort *port, const char *hostname)
else if (gai->ai_addr->sa_family == AF_INET6)
{
if (ipv6eq((struct sockaddr_in6 *) gai->ai_addr,
- (struct sockaddr_in6 *) &port->raddr.addr))
+ (struct sockaddr_in6 *) & port->raddr.addr))
{
found = true;
break;
@@ -974,8 +974,8 @@ parse_hba_line(List *line, int line_num, HbaLine *parsedline)
(errcode(ERRCODE_CONFIG_FILE_ERROR),
errmsg("specifying both host name and CIDR mask is invalid: \"%s\"",
token),
- errcontext("line %d of configuration file \"%s\"",
- line_num, HbaFileName)));
+ errcontext("line %d of configuration file \"%s\"",
+ line_num, HbaFileName)));
pfree(token);
return false;
}
diff --git a/src/backend/libpq/pqcomm.c b/src/backend/libpq/pqcomm.c
index 3232e64d4a..b83a2efb69 100644
--- a/src/backend/libpq/pqcomm.c
+++ b/src/backend/libpq/pqcomm.c
@@ -85,7 +85,7 @@
#ifdef HAVE_UTIME_H
#include
#endif
-#ifdef WIN32_ONLY_COMPILER /* mstcpip.h is missing on mingw */
+#ifdef WIN32_ONLY_COMPILER /* mstcpip.h is missing on mingw */
#include
#endif
@@ -745,7 +745,7 @@ TouchSocketFile(void)
*/
/* --------------------------------
- * pq_set_nonblocking - set socket blocking/non-blocking
+ * pq_set_nonblocking - set socket blocking/non-blocking
*
* Sets the socket non-blocking if nonblocking is TRUE, or sets it
* blocking otherwise.
@@ -760,16 +760,17 @@ pq_set_nonblocking(bool nonblocking)
#ifdef WIN32
pgwin32_noblock = nonblocking ? 1 : 0;
#else
+
/*
- * Use COMMERROR on failure, because ERROR would try to send the error
- * to the client, which might require changing the mode again, leading
- * to infinite recursion.
+ * Use COMMERROR on failure, because ERROR would try to send the error to
+ * the client, which might require changing the mode again, leading to
+ * infinite recursion.
*/
if (nonblocking)
{
if (!pg_set_noblock(MyProcPort->sock))
ereport(COMMERROR,
- (errmsg("could not set socket to non-blocking mode: %m")));
+ (errmsg("could not set socket to non-blocking mode: %m")));
}
else
{
@@ -903,18 +904,17 @@ pq_getbyte_if_available(unsigned char *c)
{
/*
* Ok if no data available without blocking or interrupted (though
- * EINTR really shouldn't happen with a non-blocking socket).
- * Report other errors.
+ * EINTR really shouldn't happen with a non-blocking socket). Report
+ * other errors.
*/
if (errno == EAGAIN || errno == EWOULDBLOCK || errno == EINTR)
r = 0;
else
{
/*
- * Careful: an ereport() that tries to write to the client
- * would cause recursion to here, leading to stack overflow
- * and core dump! This message must go *only* to the
- * postmaster log.
+ * Careful: an ereport() that tries to write to the client would
+ * cause recursion to here, leading to stack overflow and core
+ * dump! This message must go *only* to the postmaster log.
*/
ereport(COMMERROR,
(errcode_for_socket_access(),
@@ -1219,8 +1219,8 @@ internal_flush(void)
continue; /* Ok if we were interrupted */
/*
- * Ok if no data writable without blocking, and the socket
- * is in non-blocking mode.
+ * Ok if no data writable without blocking, and the socket is in
+ * non-blocking mode.
*/
if (errno == EAGAIN ||
errno == EWOULDBLOCK)
@@ -1369,8 +1369,8 @@ fail:
void
pq_putmessage_noblock(char msgtype, const char *s, size_t len)
{
- int res;
- int required;
+ int res;
+ int required;
/*
* Ensure we have enough space in the output buffer for the message header
@@ -1383,7 +1383,8 @@ pq_putmessage_noblock(char msgtype, const char *s, size_t len)
PqSendBufferSize = required;
}
res = pq_putmessage(msgtype, s, len);
- Assert(res == 0); /* should not fail when the message fits in buffer */
+ Assert(res == 0); /* should not fail when the message fits in
+ * buffer */
}
@@ -1434,13 +1435,13 @@ pq_endcopyout(bool errorAbort)
static int
pq_setkeepaliveswin32(Port *port, int idle, int interval)
{
- struct tcp_keepalive ka;
- DWORD retsize;
+ struct tcp_keepalive ka;
+ DWORD retsize;
if (idle <= 0)
- idle = 2 * 60 * 60; /* default = 2 hours */
+ idle = 2 * 60 * 60; /* default = 2 hours */
if (interval <= 0)
- interval = 1; /* default = 1 second */
+ interval = 1; /* default = 1 second */
ka.onoff = 1;
ka.keepalivetime = idle * 1000;
@@ -1500,11 +1501,11 @@ pq_getkeepalivesidle(Port *port)
elog(LOG, "getsockopt(TCP_KEEPALIVE) failed: %m");
port->default_keepalives_idle = -1; /* don't know */
}
-#endif /* TCP_KEEPIDLE */
-#else /* WIN32 */
+#endif /* TCP_KEEPIDLE */
+#else /* WIN32 */
/* We can't get the defaults on Windows, so return "don't know" */
port->default_keepalives_idle = -1;
-#endif /* WIN32 */
+#endif /* WIN32 */
}
return port->default_keepalives_idle;
@@ -1555,10 +1556,10 @@ pq_setkeepalivesidle(int idle, Port *port)
#endif
port->keepalives_idle = idle;
-#else /* WIN32 */
+#else /* WIN32 */
return pq_setkeepaliveswin32(port, idle, port->keepalives_interval);
#endif
-#else /* TCP_KEEPIDLE || SIO_KEEPALIVE_VALS */
+#else /* TCP_KEEPIDLE || SIO_KEEPALIVE_VALS */
if (idle != 0)
{
elog(LOG, "setting the keepalive idle time is not supported");
@@ -1593,7 +1594,7 @@ pq_getkeepalivesinterval(Port *port)
#else
/* We can't get the defaults on Windows, so return "don't know" */
port->default_keepalives_interval = -1;
-#endif /* WIN32 */
+#endif /* WIN32 */
}
return port->default_keepalives_interval;
@@ -1635,7 +1636,7 @@ pq_setkeepalivesinterval(int interval, Port *port)
}
port->keepalives_interval = interval;
-#else /* WIN32 */
+#else /* WIN32 */
return pq_setkeepaliveswin32(port, port->keepalives_idle, interval);
#endif
#else
diff --git a/src/backend/main/main.c b/src/backend/main/main.c
index 43d182b4db..c4ef56dc6c 100644
--- a/src/backend/main/main.c
+++ b/src/backend/main/main.c
@@ -204,7 +204,7 @@ main(int argc, char *argv[])
/*
* Place platform-specific startup hacks here. This is the right
* place to put code that must be executed early in the launch of any new
- * server process. Note that this code will NOT be executed when a backend
+ * server process. Note that this code will NOT be executed when a backend
* or sub-bootstrap process is forked, unless we are in a fork/exec
* environment (ie EXEC_BACKEND is defined).
*
@@ -218,8 +218,8 @@ startup_hacks(const char *progname)
/*
* On some platforms, unaligned memory accesses result in a kernel trap;
* the default kernel behavior is to emulate the memory access, but this
- * results in a significant performance penalty. We want PG never to
- * make such unaligned memory accesses, so this code disables the kernel
+ * results in a significant performance penalty. We want PG never to make
+ * such unaligned memory accesses, so this code disables the kernel
* emulation: unaligned accesses will result in SIGBUS instead.
*/
#ifdef NOFIXADE
@@ -230,7 +230,7 @@ startup_hacks(const char *progname)
#if defined(__alpha) /* no __alpha__ ? */
{
- int buffer[] = {SSIN_UACPROC, UAC_SIGBUS | UAC_NOPRINT};
+ int buffer[] = {SSIN_UACPROC, UAC_SIGBUS | UAC_NOPRINT};
if (setsysinfo(SSI_NVPAIRS, buffer, 1, (caddr_t) NULL,
(unsigned long) NULL) < 0)
@@ -238,7 +238,6 @@ startup_hacks(const char *progname)
progname, strerror(errno));
}
#endif /* __alpha */
-
#endif /* NOFIXADE */
/*
diff --git a/src/backend/nodes/copyfuncs.c b/src/backend/nodes/copyfuncs.c
index 0eac9826a4..c0d2294317 100644
--- a/src/backend/nodes/copyfuncs.c
+++ b/src/backend/nodes/copyfuncs.c
@@ -581,7 +581,7 @@ _copyForeignScan(ForeignScan *from)
static FdwPlan *
_copyFdwPlan(FdwPlan *from)
{
- FdwPlan *newnode = makeNode(FdwPlan);
+ FdwPlan *newnode = makeNode(FdwPlan);
COPY_SCALAR_FIELD(startup_cost);
COPY_SCALAR_FIELD(total_cost);
@@ -1468,7 +1468,7 @@ _copyConvertRowtypeExpr(ConvertRowtypeExpr *from)
static CollateExpr *
_copyCollateExpr(CollateExpr *from)
{
- CollateExpr *newnode = makeNode(CollateExpr);
+ CollateExpr *newnode = makeNode(CollateExpr);
COPY_NODE_FIELD(arg);
COPY_SCALAR_FIELD(collOid);
@@ -2269,7 +2269,7 @@ _copyTypeCast(TypeCast *from)
static CollateClause *
_copyCollateClause(CollateClause *from)
{
- CollateClause *newnode = makeNode(CollateClause);
+ CollateClause *newnode = makeNode(CollateClause);
COPY_NODE_FIELD(arg);
COPY_NODE_FIELD(collname);
diff --git a/src/backend/nodes/nodeFuncs.c b/src/backend/nodes/nodeFuncs.c
index af1ccb7efe..0e57f6c6d7 100644
--- a/src/backend/nodes/nodeFuncs.c
+++ b/src/backend/nodes/nodeFuncs.c
@@ -675,10 +675,10 @@ exprCollation(Node *expr)
coll = ((NullIfExpr *) expr)->opcollid;
break;
case T_ScalarArrayOpExpr:
- coll = InvalidOid; /* result is always boolean */
+ coll = InvalidOid; /* result is always boolean */
break;
case T_BoolExpr:
- coll = InvalidOid; /* result is always boolean */
+ coll = InvalidOid; /* result is always boolean */
break;
case T_SubLink:
{
@@ -736,7 +736,7 @@ exprCollation(Node *expr)
coll = ((FieldSelect *) expr)->resultcollid;
break;
case T_FieldStore:
- coll = InvalidOid; /* result is always composite */
+ coll = InvalidOid; /* result is always composite */
break;
case T_RelabelType:
coll = ((RelabelType *) expr)->resultcollid;
@@ -748,7 +748,7 @@ exprCollation(Node *expr)
coll = ((ArrayCoerceExpr *) expr)->resultcollid;
break;
case T_ConvertRowtypeExpr:
- coll = InvalidOid; /* result is always composite */
+ coll = InvalidOid; /* result is always composite */
break;
case T_CollateExpr:
coll = ((CollateExpr *) expr)->collOid;
@@ -763,10 +763,10 @@ exprCollation(Node *expr)
coll = ((ArrayExpr *) expr)->array_collid;
break;
case T_RowExpr:
- coll = InvalidOid; /* result is always composite */
+ coll = InvalidOid; /* result is always composite */
break;
case T_RowCompareExpr:
- coll = InvalidOid; /* result is always boolean */
+ coll = InvalidOid; /* result is always boolean */
break;
case T_CoalesceExpr:
coll = ((CoalesceExpr *) expr)->coalescecollid;
@@ -775,10 +775,11 @@ exprCollation(Node *expr)
coll = ((MinMaxExpr *) expr)->minmaxcollid;
break;
case T_XmlExpr:
+
/*
* XMLSERIALIZE returns text from non-collatable inputs, so its
- * collation is always default. The other cases return boolean
- * or XML, which are non-collatable.
+ * collation is always default. The other cases return boolean or
+ * XML, which are non-collatable.
*/
if (((XmlExpr *) expr)->op == IS_XMLSERIALIZE)
coll = DEFAULT_COLLATION_OID;
@@ -786,10 +787,10 @@ exprCollation(Node *expr)
coll = InvalidOid;
break;
case T_NullTest:
- coll = InvalidOid; /* result is always boolean */
+ coll = InvalidOid; /* result is always boolean */
break;
case T_BooleanTest:
- coll = InvalidOid; /* result is always boolean */
+ coll = InvalidOid; /* result is always boolean */
break;
case T_CoerceToDomain:
coll = ((CoerceToDomain *) expr)->resultcollid;
@@ -801,7 +802,7 @@ exprCollation(Node *expr)
coll = ((SetToDefault *) expr)->collation;
break;
case T_CurrentOfExpr:
- coll = InvalidOid; /* result is always boolean */
+ coll = InvalidOid; /* result is always boolean */
break;
case T_PlaceHolderVar:
coll = exprCollation((Node *) ((PlaceHolderVar *) expr)->phexpr);
@@ -907,10 +908,10 @@ exprSetCollation(Node *expr, Oid collation)
((NullIfExpr *) expr)->opcollid = collation;
break;
case T_ScalarArrayOpExpr:
- Assert(!OidIsValid(collation)); /* result is always boolean */
+ Assert(!OidIsValid(collation)); /* result is always boolean */
break;
case T_BoolExpr:
- Assert(!OidIsValid(collation)); /* result is always boolean */
+ Assert(!OidIsValid(collation)); /* result is always boolean */
break;
case T_SubLink:
#ifdef USE_ASSERT_CHECKING
@@ -937,13 +938,13 @@ exprSetCollation(Node *expr, Oid collation)
Assert(!OidIsValid(collation));
}
}
-#endif /* USE_ASSERT_CHECKING */
+#endif /* USE_ASSERT_CHECKING */
break;
case T_FieldSelect:
((FieldSelect *) expr)->resultcollid = collation;
break;
case T_FieldStore:
- Assert(!OidIsValid(collation)); /* result is always composite */
+ Assert(!OidIsValid(collation)); /* result is always composite */
break;
case T_RelabelType:
((RelabelType *) expr)->resultcollid = collation;
@@ -955,7 +956,7 @@ exprSetCollation(Node *expr, Oid collation)
((ArrayCoerceExpr *) expr)->resultcollid = collation;
break;
case T_ConvertRowtypeExpr:
- Assert(!OidIsValid(collation)); /* result is always composite */
+ Assert(!OidIsValid(collation)); /* result is always composite */
break;
case T_CaseExpr:
((CaseExpr *) expr)->casecollid = collation;
@@ -964,10 +965,10 @@ exprSetCollation(Node *expr, Oid collation)
((ArrayExpr *) expr)->array_collid = collation;
break;
case T_RowExpr:
- Assert(!OidIsValid(collation)); /* result is always composite */
+ Assert(!OidIsValid(collation)); /* result is always composite */
break;
case T_RowCompareExpr:
- Assert(!OidIsValid(collation)); /* result is always boolean */
+ Assert(!OidIsValid(collation)); /* result is always boolean */
break;
case T_CoalesceExpr:
((CoalesceExpr *) expr)->coalescecollid = collation;
@@ -981,10 +982,10 @@ exprSetCollation(Node *expr, Oid collation)
(collation == InvalidOid));
break;
case T_NullTest:
- Assert(!OidIsValid(collation)); /* result is always boolean */
+ Assert(!OidIsValid(collation)); /* result is always boolean */
break;
case T_BooleanTest:
- Assert(!OidIsValid(collation)); /* result is always boolean */
+ Assert(!OidIsValid(collation)); /* result is always boolean */
break;
case T_CoerceToDomain:
((CoerceToDomain *) expr)->resultcollid = collation;
@@ -996,7 +997,7 @@ exprSetCollation(Node *expr, Oid collation)
((SetToDefault *) expr)->collation = collation;
break;
case T_CurrentOfExpr:
- Assert(!OidIsValid(collation)); /* result is always boolean */
+ Assert(!OidIsValid(collation)); /* result is always boolean */
break;
default:
elog(ERROR, "unrecognized node type: %d", (int) nodeTag(expr));
diff --git a/src/backend/nodes/params.c b/src/backend/nodes/params.c
index d6e6e6a2bd..62d766a282 100644
--- a/src/backend/nodes/params.c
+++ b/src/backend/nodes/params.c
@@ -43,7 +43,7 @@ copyParamList(ParamListInfo from)
/* sizeof(ParamListInfoData) includes the first array element */
size = sizeof(ParamListInfoData) +
- (from->numParams - 1) *sizeof(ParamExternData);
+ (from->numParams - 1) * sizeof(ParamExternData);
retval = (ParamListInfo) palloc(size);
retval->paramFetch = NULL;
diff --git a/src/backend/optimizer/path/allpaths.c b/src/backend/optimizer/path/allpaths.c
index dc2a23bb27..47ab08e502 100644
--- a/src/backend/optimizer/path/allpaths.c
+++ b/src/backend/optimizer/path/allpaths.c
@@ -66,7 +66,7 @@ static void set_cte_pathlist(PlannerInfo *root, RelOptInfo *rel,
static void set_worktable_pathlist(PlannerInfo *root, RelOptInfo *rel,
RangeTblEntry *rte);
static void set_foreign_pathlist(PlannerInfo *root, RelOptInfo *rel,
- RangeTblEntry *rte);
+ RangeTblEntry *rte);
static RelOptInfo *make_rel_from_joinlist(PlannerInfo *root, List *joinlist);
static bool subquery_is_pushdown_safe(Query *subquery, Query *topquery,
bool *differentTypes);
@@ -413,11 +413,11 @@ set_append_rel_pathlist(PlannerInfo *root, RelOptInfo *rel,
/*
* We have to make child entries in the EquivalenceClass data
- * structures as well. This is needed either if the parent
- * participates in some eclass joins (because we will want to
- * consider inner-indexscan joins on the individual children)
- * or if the parent has useful pathkeys (because we should try
- * to build MergeAppend paths that produce those sort orderings).
+ * structures as well. This is needed either if the parent
+ * participates in some eclass joins (because we will want to consider
+ * inner-indexscan joins on the individual children) or if the parent
+ * has useful pathkeys (because we should try to build MergeAppend
+ * paths that produce those sort orderings).
*/
if (rel->has_eclass_joins || has_useful_pathkeys(root, rel))
add_child_rel_equivalences(root, appinfo, rel, childrel);
@@ -462,7 +462,7 @@ set_append_rel_pathlist(PlannerInfo *root, RelOptInfo *rel,
/* Have we already seen this ordering? */
foreach(lpk, all_child_pathkeys)
{
- List *existing_pathkeys = (List *) lfirst(lpk);
+ List *existing_pathkeys = (List *) lfirst(lpk);
if (compare_pathkeys(existing_pathkeys,
childkeys) == PATHKEYS_EQUAL)
@@ -540,18 +540,18 @@ set_append_rel_pathlist(PlannerInfo *root, RelOptInfo *rel,
/*
* Next, build MergeAppend paths based on the collected list of child
- * pathkeys. We consider both cheapest-startup and cheapest-total
- * cases, ie, for each interesting ordering, collect all the cheapest
- * startup subpaths and all the cheapest total paths, and build a
- * MergeAppend path for each list.
+ * pathkeys. We consider both cheapest-startup and cheapest-total cases,
+ * ie, for each interesting ordering, collect all the cheapest startup
+ * subpaths and all the cheapest total paths, and build a MergeAppend path
+ * for each list.
*/
foreach(l, all_child_pathkeys)
{
- List *pathkeys = (List *) lfirst(l);
- List *startup_subpaths = NIL;
- List *total_subpaths = NIL;
- bool startup_neq_total = false;
- ListCell *lcr;
+ List *pathkeys = (List *) lfirst(l);
+ List *startup_subpaths = NIL;
+ List *total_subpaths = NIL;
+ bool startup_neq_total = false;
+ ListCell *lcr;
/* Select the child paths for this ordering... */
foreach(lcr, live_childrels)
@@ -581,8 +581,8 @@ set_append_rel_pathlist(PlannerInfo *root, RelOptInfo *rel,
/*
* Notice whether we actually have different paths for the
- * "cheapest" and "total" cases; frequently there will be no
- * point in two create_merge_append_path() calls.
+ * "cheapest" and "total" cases; frequently there will be no point
+ * in two create_merge_append_path() calls.
*/
if (cheapest_startup != cheapest_total)
startup_neq_total = true;
@@ -623,7 +623,7 @@ accumulate_append_subpath(List *subpaths, Path *path)
{
if (IsA(path, AppendPath))
{
- AppendPath *apath = (AppendPath *) path;
+ AppendPath *apath = (AppendPath *) path;
/* list_copy is important here to avoid sharing list substructure */
return list_concat(subpaths, list_copy(apath->subpaths));
diff --git a/src/backend/optimizer/path/costsize.c b/src/backend/optimizer/path/costsize.c
index 8f763b4369..e200dcf472 100644
--- a/src/backend/optimizer/path/costsize.c
+++ b/src/backend/optimizer/path/costsize.c
@@ -1096,7 +1096,7 @@ cost_recursive_union(Plan *runion, Plan *nrterm, Plan *rterm)
* accesses (XXX can't we refine that guess?)
*
* By default, we charge two operator evals per tuple comparison, which should
- * be in the right ballpark in most cases. The caller can tweak this by
+ * be in the right ballpark in most cases. The caller can tweak this by
* specifying nonzero comparison_cost; typically that's used for any extra
* work that has to be done to prepare the inputs to the comparison operators.
*
@@ -1218,7 +1218,7 @@ cost_sort(Path *path, PlannerInfo *root,
* Determines and returns the cost of a MergeAppend node.
*
* MergeAppend merges several pre-sorted input streams, using a heap that
- * at any given instant holds the next tuple from each stream. If there
+ * at any given instant holds the next tuple from each stream. If there
* are N streams, we need about N*log2(N) tuple comparisons to construct
* the heap at startup, and then for each output tuple, about log2(N)
* comparisons to delete the top heap entry and another log2(N) comparisons
@@ -2909,7 +2909,7 @@ adjust_semi_join(PlannerInfo *root, JoinPath *path, SpecialJoinInfo *sjinfo,
List *nrclauses;
nrclauses = select_nonredundant_join_clauses(root,
- path->joinrestrictinfo,
+ path->joinrestrictinfo,
path->innerjoinpath);
*indexed_join_quals = (nrclauses == NIL);
}
@@ -3185,7 +3185,7 @@ set_subquery_size_estimates(PlannerInfo *root, RelOptInfo *rel,
/*
* Compute per-output-column width estimates by examining the subquery's
- * targetlist. For any output that is a plain Var, get the width estimate
+ * targetlist. For any output that is a plain Var, get the width estimate
* that was made while planning the subquery. Otherwise, fall back on a
* datatype-based estimate.
*/
@@ -3210,7 +3210,7 @@ set_subquery_size_estimates(PlannerInfo *root, RelOptInfo *rel,
if (IsA(texpr, Var) &&
subroot->parse->setOperations == NULL)
{
- Var *var = (Var *) texpr;
+ Var *var = (Var *) texpr;
RelOptInfo *subrel = find_base_rel(subroot, var->varno);
item_width = subrel->attr_widths[var->varattno - subrel->min_attr];
@@ -3332,7 +3332,7 @@ set_cte_size_estimates(PlannerInfo *root, RelOptInfo *rel, Plan *cteplan)
* of estimating baserestrictcost, so we set that, and we also set up width
* using what will be purely datatype-driven estimates from the targetlist.
* There is no way to do anything sane with the rows value, so we just put
- * a default estimate and hope that the wrapper can improve on it. The
+ * a default estimate and hope that the wrapper can improve on it. The
* wrapper's PlanForeignScan function will be called momentarily.
*
* The rel's targetlist and restrictinfo list must have been constructed
@@ -3396,8 +3396,8 @@ set_rel_width(PlannerInfo *root, RelOptInfo *rel)
ndx = var->varattno - rel->min_attr;
/*
- * If it's a whole-row Var, we'll deal with it below after we
- * have already cached as many attr widths as possible.
+ * If it's a whole-row Var, we'll deal with it below after we have
+ * already cached as many attr widths as possible.
*/
if (var->varattno == 0)
{
@@ -3406,8 +3406,8 @@ set_rel_width(PlannerInfo *root, RelOptInfo *rel)
}
/*
- * The width may have been cached already (especially if it's
- * a subquery), so don't duplicate effort.
+ * The width may have been cached already (especially if it's a
+ * subquery), so don't duplicate effort.
*/
if (rel->attr_widths[ndx] > 0)
{
@@ -3464,13 +3464,13 @@ set_rel_width(PlannerInfo *root, RelOptInfo *rel)
*/
if (have_wholerow_var)
{
- int32 wholerow_width = sizeof(HeapTupleHeaderData);
+ int32 wholerow_width = sizeof(HeapTupleHeaderData);
if (reloid != InvalidOid)
{
/* Real relation, so estimate true tuple width */
wholerow_width += get_relation_data_width(reloid,
- rel->attr_widths - rel->min_attr);
+ rel->attr_widths - rel->min_attr);
}
else
{
@@ -3484,8 +3484,8 @@ set_rel_width(PlannerInfo *root, RelOptInfo *rel)
rel->attr_widths[0 - rel->min_attr] = wholerow_width;
/*
- * Include the whole-row Var as part of the output tuple. Yes,
- * that really is what happens at runtime.
+ * Include the whole-row Var as part of the output tuple. Yes, that
+ * really is what happens at runtime.
*/
tuple_width += wholerow_width;
}
diff --git a/src/backend/optimizer/path/equivclass.c b/src/backend/optimizer/path/equivclass.c
index 9a32e16940..a365beecd8 100644
--- a/src/backend/optimizer/path/equivclass.c
+++ b/src/backend/optimizer/path/equivclass.c
@@ -385,7 +385,7 @@ process_equivalence(PlannerInfo *root, RestrictInfo *restrictinfo,
* Also, the expression's exposed collation must match the EC's collation.
* This is important because in comparisons like "foo < bar COLLATE baz",
* only one of the expressions has the correct exposed collation as we receive
- * it from the parser. Forcing both of them to have it ensures that all
+ * it from the parser. Forcing both of them to have it ensures that all
* variant spellings of such a construct behave the same. Again, we can
* stick on a RelabelType to force the right exposed collation. (It might
* work to not label the collation at all in EC members, but this is risky
@@ -414,13 +414,13 @@ canonicalize_ec_expression(Expr *expr, Oid req_type, Oid req_collation)
exprCollation((Node *) expr) != req_collation)
{
/*
- * Strip any existing RelabelType, then add a new one if needed.
- * This is to preserve the invariant of no redundant RelabelTypes.
+ * Strip any existing RelabelType, then add a new one if needed. This
+ * is to preserve the invariant of no redundant RelabelTypes.
*
* If we have to change the exposed type of the stripped expression,
* set typmod to -1 (since the new type may not have the same typmod
- * interpretation). If we only have to change collation, preserve
- * the exposed typmod.
+ * interpretation). If we only have to change collation, preserve the
+ * exposed typmod.
*/
while (expr && IsA(expr, RelabelType))
expr = (Expr *) ((RelabelType *) expr)->arg;
@@ -1784,8 +1784,8 @@ add_child_rel_equivalences(PlannerInfo *root,
ListCell *lc2;
/*
- * If this EC contains a constant, then it's not useful for sorting
- * or driving an inner index-scan, so we skip generating child EMs.
+ * If this EC contains a constant, then it's not useful for sorting or
+ * driving an inner index-scan, so we skip generating child EMs.
*
* If this EC contains a volatile expression, then generating child
* EMs would be downright dangerous. We rely on a volatile EC having
diff --git a/src/backend/optimizer/path/indxpath.c b/src/backend/optimizer/path/indxpath.c
index 76f842631f..ef65cf2224 100644
--- a/src/backend/optimizer/path/indxpath.c
+++ b/src/backend/optimizer/path/indxpath.c
@@ -119,7 +119,7 @@ static bool match_special_index_operator(Expr *clause,
static Expr *expand_boolean_index_clause(Node *clause, int indexcol,
IndexOptInfo *index);
static List *expand_indexqual_opclause(RestrictInfo *rinfo,
- Oid opfamily, Oid idxcollation);
+ Oid opfamily, Oid idxcollation);
static RestrictInfo *expand_indexqual_rowcompare(RestrictInfo *rinfo,
IndexOptInfo *index,
int indexcol);
@@ -1159,8 +1159,8 @@ group_clauses_by_indexkey(IndexOptInfo *index,
* (2) must contain an operator which is in the same family as the index
* operator for this column, or is a "special" operator as recognized
* by match_special_index_operator();
- * and
- * (3) must match the collation of the index, if collation is relevant.
+ * and
+ * (3) must match the collation of the index, if collation is relevant.
*
* Our definition of "const" is pretty liberal: we allow Vars belonging
* to the caller-specified outer_relids relations (which had better not
@@ -1312,7 +1312,7 @@ match_clause_to_indexcol(IndexOptInfo *index,
* is a "special" indexable operator.
*/
if (plain_op &&
- match_special_index_operator(clause, opfamily, idxcollation, true))
+ match_special_index_operator(clause, opfamily, idxcollation, true))
return true;
return false;
}
@@ -1438,7 +1438,7 @@ match_rowcompare_to_indexcol(IndexOptInfo *index,
/****************************************************************************
- * ---- ROUTINES TO CHECK ORDERING OPERATORS ----
+ * ---- ROUTINES TO CHECK ORDERING OPERATORS ----
****************************************************************************/
/*
@@ -1461,7 +1461,7 @@ match_index_to_pathkeys(IndexOptInfo *index, List *pathkeys)
foreach(lc1, pathkeys)
{
- PathKey *pathkey = (PathKey *) lfirst(lc1);
+ PathKey *pathkey = (PathKey *) lfirst(lc1);
bool found = false;
ListCell *lc2;
@@ -1483,7 +1483,7 @@ match_index_to_pathkeys(IndexOptInfo *index, List *pathkeys)
foreach(lc2, pathkey->pk_eclass->ec_members)
{
EquivalenceMember *member = (EquivalenceMember *) lfirst(lc2);
- int indexcol;
+ int indexcol;
/* No possibility of match if it references other relations */
if (!bms_equal(member->em_relids, index->rel->relids))
@@ -1491,7 +1491,7 @@ match_index_to_pathkeys(IndexOptInfo *index, List *pathkeys)
for (indexcol = 0; indexcol < index->ncolumns; indexcol++)
{
- Expr *expr;
+ Expr *expr;
expr = match_clause_to_ordering_op(index,
indexcol,
@@ -1535,7 +1535,7 @@ match_index_to_pathkeys(IndexOptInfo *index, List *pathkeys)
* Note that we currently do not consider the collation of the ordering
* operator's result. In practical cases the result type will be numeric
* and thus have no collation, and it's not very clear what to match to
- * if it did have a collation. The index's collation should match the
+ * if it did have a collation. The index's collation should match the
* ordering operator's input collation, not its result.
*
* If successful, return 'clause' as-is if the indexkey is on the left,
@@ -1598,8 +1598,8 @@ match_clause_to_ordering_op(IndexOptInfo *index,
return NULL;
/*
- * Is the (commuted) operator an ordering operator for the opfamily?
- * And if so, does it yield the right sorting semantics?
+ * Is the (commuted) operator an ordering operator for the opfamily? And
+ * if so, does it yield the right sorting semantics?
*/
sortfamily = get_op_opfamily_sortfamily(expr_op, opfamily);
if (sortfamily != pk_opfamily)
@@ -2198,9 +2198,9 @@ relation_has_unique_index_for(PlannerInfo *root, RelOptInfo *rel,
continue;
/*
- * XXX at some point we may need to check collations here
- * too. For the moment we assume all collations reduce to
- * the same notion of equality.
+ * XXX at some point we may need to check collations here too.
+ * For the moment we assume all collations reduce to the same
+ * notion of equality.
*/
/* OK, see if the condition operand matches the index key */
@@ -2544,10 +2544,10 @@ match_special_index_operator(Expr *clause, Oid opfamily, Oid idxcollation,
*
* The non-pattern opclasses will not sort the way we need in most non-C
* locales. We can use such an index anyway for an exact match (simple
- * equality), but not for prefix-match cases. Note that we are looking
- * at the index's collation, not the expression's collation -- this test
- * is not dependent on the LIKE/regex operator's collation (which would
- * only affect case folding behavior of ILIKE, anyway).
+ * equality), but not for prefix-match cases. Note that we are looking at
+ * the index's collation, not the expression's collation -- this test is
+ * not dependent on the LIKE/regex operator's collation (which would only
+ * affect case folding behavior of ILIKE, anyway).
*/
switch (expr_op)
{
@@ -2657,7 +2657,7 @@ expand_indexqual_conditions(IndexOptInfo *index, List *clausegroups)
resultquals = list_concat(resultquals,
expand_indexqual_opclause(rinfo,
curFamily,
- curCollation));
+ curCollation));
}
else if (IsA(clause, ScalarArrayOpExpr))
{
@@ -3254,7 +3254,7 @@ network_prefix_quals(Node *leftop, Oid expr_op, Oid opfamily, Datum rightop)
expr = make_opclause(opr1oid, BOOLOID, false,
(Expr *) leftop,
(Expr *) makeConst(datatype, -1,
- InvalidOid, /* not collatable */
+ InvalidOid, /* not collatable */
-1, opr1right,
false, false),
InvalidOid, InvalidOid);
@@ -3272,7 +3272,7 @@ network_prefix_quals(Node *leftop, Oid expr_op, Oid opfamily, Datum rightop)
expr = make_opclause(opr2oid, BOOLOID, false,
(Expr *) leftop,
(Expr *) makeConst(datatype, -1,
- InvalidOid, /* not collatable */
+ InvalidOid, /* not collatable */
-1, opr2right,
false, false),
InvalidOid, InvalidOid);
diff --git a/src/backend/optimizer/path/joinpath.c b/src/backend/optimizer/path/joinpath.c
index 740dc32dc7..7d3cf425da 100644
--- a/src/backend/optimizer/path/joinpath.c
+++ b/src/backend/optimizer/path/joinpath.c
@@ -97,11 +97,11 @@ add_paths_to_joinrel(PlannerInfo *root,
/*
* 1. Consider mergejoin paths where both relations must be explicitly
- * sorted. Skip this if we can't mergejoin.
+ * sorted. Skip this if we can't mergejoin.
*/
if (mergejoin_allowed)
sort_inner_and_outer(root, joinrel, outerrel, innerrel,
- restrictlist, mergeclause_list, jointype, sjinfo);
+ restrictlist, mergeclause_list, jointype, sjinfo);
/*
* 2. Consider paths where the outer relation need not be explicitly
@@ -112,7 +112,7 @@ add_paths_to_joinrel(PlannerInfo *root,
*/
if (mergejoin_allowed)
match_unsorted_outer(root, joinrel, outerrel, innerrel,
- restrictlist, mergeclause_list, jointype, sjinfo);
+ restrictlist, mergeclause_list, jointype, sjinfo);
#ifdef NOT_USED
@@ -129,7 +129,7 @@ add_paths_to_joinrel(PlannerInfo *root,
*/
if (mergejoin_allowed)
match_unsorted_inner(root, joinrel, outerrel, innerrel,
- restrictlist, mergeclause_list, jointype, sjinfo);
+ restrictlist, mergeclause_list, jointype, sjinfo);
#endif
/*
diff --git a/src/backend/optimizer/path/joinrels.c b/src/backend/optimizer/path/joinrels.c
index 42618649fb..bbb79c582d 100644
--- a/src/backend/optimizer/path/joinrels.c
+++ b/src/backend/optimizer/path/joinrels.c
@@ -30,7 +30,7 @@ static bool has_legal_joinclause(PlannerInfo *root, RelOptInfo *rel);
static bool is_dummy_rel(RelOptInfo *rel);
static void mark_dummy_rel(RelOptInfo *rel);
static bool restriction_is_constant_false(List *restrictlist,
- bool only_pushed_down);
+ bool only_pushed_down);
/*
@@ -604,10 +604,10 @@ make_join_rel(PlannerInfo *root, RelOptInfo *rel1, RelOptInfo *rel2)
*
* Also, a provably constant-false join restriction typically means that
* we can skip evaluating one or both sides of the join. We do this by
- * marking the appropriate rel as dummy. For outer joins, a constant-false
- * restriction that is pushed down still means the whole join is dummy,
- * while a non-pushed-down one means that no inner rows will join so we
- * can treat the inner rel as dummy.
+ * marking the appropriate rel as dummy. For outer joins, a
+ * constant-false restriction that is pushed down still means the whole
+ * join is dummy, while a non-pushed-down one means that no inner rows
+ * will join so we can treat the inner rel as dummy.
*
* We need only consider the jointypes that appear in join_info_list, plus
* JOIN_INNER.
diff --git a/src/backend/optimizer/path/pathkeys.c b/src/backend/optimizer/path/pathkeys.c
index 47597a5d35..e5228a81c6 100644
--- a/src/backend/optimizer/path/pathkeys.c
+++ b/src/backend/optimizer/path/pathkeys.c
@@ -253,7 +253,7 @@ make_pathkey_from_sortinfo(PlannerInfo *root,
/*
* EquivalenceClasses need to contain opfamily lists based on the family
* membership of mergejoinable equality operators, which could belong to
- * more than one opfamily. So we have to look up the opfamily's equality
+ * more than one opfamily. So we have to look up the opfamily's equality
* operator and get its membership.
*/
equality_op = get_opfamily_member(opfamily,
@@ -558,9 +558,9 @@ build_index_pathkeys(PlannerInfo *root,
true);
/*
- * If the sort key isn't already present in any EquivalenceClass,
- * then it's not an interesting sort order for this query. So
- * we can stop now --- lower-order sort keys aren't useful either.
+ * If the sort key isn't already present in any EquivalenceClass, then
+ * it's not an interesting sort order for this query. So we can stop
+ * now --- lower-order sort keys aren't useful either.
*/
if (!cpathkey)
break;
@@ -747,8 +747,8 @@ convert_subquery_pathkeys(PlannerInfo *root, RelOptInfo *rel,
continue;
/*
- * Build a representation of this targetlist entry as
- * an outer Var.
+ * Build a representation of this targetlist entry as an
+ * outer Var.
*/
outer_expr = (Expr *) makeVarFromTargetEntry(rel->relid,
tle);
@@ -923,7 +923,7 @@ make_pathkeys_for_sortclauses(PlannerInfo *root,
* right sides.
*
* Note this is called before EC merging is complete, so the links won't
- * necessarily point to canonical ECs. Before they are actually used for
+ * necessarily point to canonical ECs. Before they are actually used for
* anything, update_mergeclause_eclasses must be called to ensure that
* they've been updated to point to canonical ECs.
*/
diff --git a/src/backend/optimizer/plan/analyzejoins.c b/src/backend/optimizer/plan/analyzejoins.c
index 80d42f3be6..1784ac2fc5 100644
--- a/src/backend/optimizer/plan/analyzejoins.c
+++ b/src/backend/optimizer/plan/analyzejoins.c
@@ -31,7 +31,7 @@
/* local functions */
static bool join_is_removable(PlannerInfo *root, SpecialJoinInfo *sjinfo);
static void remove_rel_from_query(PlannerInfo *root, int relid,
- Relids joinrelids);
+ Relids joinrelids);
static List *remove_rel_from_joinlist(List *joinlist, int relid, int *nremoved);
@@ -238,10 +238,10 @@ join_is_removable(PlannerInfo *root, SpecialJoinInfo *sjinfo)
!bms_equal(restrictinfo->required_relids, joinrelids))
{
/*
- * If such a clause actually references the inner rel then
- * join removal has to be disallowed. We have to check this
- * despite the previous attr_needed checks because of the
- * possibility of pushed-down clauses referencing the rel.
+ * If such a clause actually references the inner rel then join
+ * removal has to be disallowed. We have to check this despite
+ * the previous attr_needed checks because of the possibility of
+ * pushed-down clauses referencing the rel.
*/
if (bms_is_member(innerrelid, restrictinfo->clause_relids))
return false;
@@ -365,8 +365,8 @@ remove_rel_from_query(PlannerInfo *root, int relid, Relids joinrelids)
* Likewise remove references from SpecialJoinInfo data structures.
*
* This is relevant in case the outer join we're deleting is nested inside
- * other outer joins: the upper joins' relid sets have to be adjusted.
- * The RHS of the target outer join will be made empty here, but that's OK
+ * other outer joins: the upper joins' relid sets have to be adjusted. The
+ * RHS of the target outer join will be made empty here, but that's OK
* since caller will delete that SpecialJoinInfo entirely.
*/
foreach(l, root->join_info_list)
@@ -426,6 +426,7 @@ remove_rel_from_query(PlannerInfo *root, int relid, Relids joinrelids)
{
/* Recheck that qual doesn't actually reference the target rel */
Assert(!bms_is_member(relid, rinfo->clause_relids));
+
/*
* The required_relids probably aren't shared with anything else,
* but let's copy them just to be sure.
diff --git a/src/backend/optimizer/plan/createplan.c b/src/backend/optimizer/plan/createplan.c
index f130881251..1a9540ce06 100644
--- a/src/backend/optimizer/plan/createplan.c
+++ b/src/backend/optimizer/plan/createplan.c
@@ -108,7 +108,7 @@ static TidScan *make_tidscan(List *qptlist, List *qpqual, Index scanrelid,
List *tidquals);
static FunctionScan *make_functionscan(List *qptlist, List *qpqual,
Index scanrelid, Node *funcexpr, List *funccolnames,
- List *funccoltypes, List *funccoltypmods, List *funccolcollations);
+ List *funccoltypes, List *funccoltypmods, List *funccolcollations);
static ValuesScan *make_valuesscan(List *qptlist, List *qpqual,
Index scanrelid, List *values_lists);
static CteScan *make_ctescan(List *qptlist, List *qpqual,
@@ -143,24 +143,25 @@ static MergeJoin *make_mergejoin(List *tlist,
bool *mergenullsfirst,
Plan *lefttree, Plan *righttree,
JoinType jointype);
-static Sort *make_sort(PlannerInfo *root, Plan *lefttree, int numCols,
- AttrNumber *sortColIdx, Oid *sortOperators, Oid *collations, bool *nullsFirst,
+static Sort *
+make_sort(PlannerInfo *root, Plan *lefttree, int numCols,
+AttrNumber *sortColIdx, Oid *sortOperators, Oid *collations, bool *nullsFirst,
double limit_tuples);
static Plan *prepare_sort_from_pathkeys(PlannerInfo *root,
- Plan *lefttree, List *pathkeys,
- bool adjust_tlist_in_place,
- int *p_numsortkeys,
- AttrNumber **p_sortColIdx,
- Oid **p_sortOperators,
- Oid **p_collations,
- bool **p_nullsFirst);
+ Plan *lefttree, List *pathkeys,
+ bool adjust_tlist_in_place,
+ int *p_numsortkeys,
+ AttrNumber **p_sortColIdx,
+ Oid **p_sortOperators,
+ Oid **p_collations,
+ bool **p_nullsFirst);
static Material *make_material(Plan *lefttree);
/*
* create_plan
* Creates the access plan for a query by recursively processing the
- * desired tree of pathnodes, starting at the node 'best_path'. For
+ * desired tree of pathnodes, starting at the node 'best_path'. For
* every pathnode found, we create a corresponding plan node containing
* appropriate id, target list, and qualification information.
*
@@ -737,7 +738,7 @@ create_merge_append_plan(PlannerInfo *root, MergeAppendPath *best_path)
/* Now, insert a Sort node if subplan isn't sufficiently ordered */
if (!pathkeys_contained_in(pathkeys, subpath->pathkeys))
subplan = (Plan *) make_sort(root, subplan, numsortkeys,
- sortColIdx, sortOperators, collations, nullsFirst,
+ sortColIdx, sortOperators, collations, nullsFirst,
best_path->limit_tuples);
subplans = lappend(subplans, subplan);
@@ -983,7 +984,7 @@ create_unique_plan(PlannerInfo *root, UniquePath *best_path)
sortcl->eqop = eqop;
sortcl->sortop = sortop;
sortcl->nulls_first = false;
- sortcl->hashable = false; /* no need to make this accurate */
+ sortcl->hashable = false; /* no need to make this accurate */
sortList = lappend(sortList, sortcl);
groupColPos++;
}
@@ -1153,8 +1154,8 @@ create_indexscan_plan(PlannerInfo *root,
qpqual = extract_actual_clauses(qpqual, false);
/*
- * We have to replace any outer-relation variables with nestloop params
- * in the indexqualorig, qpqual, and indexorderbyorig expressions. A bit
+ * We have to replace any outer-relation variables with nestloop params in
+ * the indexqualorig, qpqual, and indexorderbyorig expressions. A bit
* annoying to have to do this separately from the processing in
* fix_indexqual_references --- rethink this when generalizing the inner
* indexscan support. But note we can't really do this earlier because
@@ -1465,6 +1466,7 @@ create_bitmap_subplan(PlannerInfo *root, Path *bitmapqual,
*indexqual = lappend(*indexqual, pred);
}
}
+
/*
* Replace outer-relation variables with nestloop params, but only
* after doing the above comparisons to index predicates.
@@ -2330,10 +2332,10 @@ replace_nestloop_params_mutator(Node *node, PlannerInfo *root)
return NULL;
if (IsA(node, Var))
{
- Var *var = (Var *) node;
- Param *param;
+ Var *var = (Var *) node;
+ Param *param;
NestLoopParam *nlp;
- ListCell *lc;
+ ListCell *lc;
/* Upper-level Vars should be long gone at this point */
Assert(var->varlevelsup == 0);
@@ -2493,7 +2495,7 @@ fix_indexqual_references(PlannerInfo *root, IndexPath *index_path,
*
* This is a simplified version of fix_indexqual_references. The input does
* not have RestrictInfo nodes, and we assume that indxqual.c already
- * commuted the clauses to put the index keys on the left. Also, we don't
+ * commuted the clauses to put the index keys on the left. Also, we don't
* bother to support any cases except simple OpExprs, since nothing else
* is allowed for ordering operators.
*/
@@ -3082,8 +3084,8 @@ make_append(List *appendplans, List *tlist)
* If you change this, see also create_append_path(). Also, the size
* calculations should match set_append_rel_pathlist(). It'd be better
* not to duplicate all this logic, but some callers of this function
- * aren't working from an appendrel or AppendPath, so there's noplace
- * to copy the data from.
+ * aren't working from an appendrel or AppendPath, so there's noplace to
+ * copy the data from.
*/
plan->startup_cost = 0;
plan->total_cost = 0;
@@ -3320,7 +3322,7 @@ make_mergejoin(List *tlist,
*/
static Sort *
make_sort(PlannerInfo *root, Plan *lefttree, int numCols,
- AttrNumber *sortColIdx, Oid *sortOperators, Oid *collations, bool *nullsFirst,
+AttrNumber *sortColIdx, Oid *sortOperators, Oid *collations, bool *nullsFirst,
double limit_tuples)
{
Sort *node = makeNode(Sort);
@@ -3398,7 +3400,7 @@ add_sort_column(AttrNumber colIdx, Oid sortOp, Oid coll, bool nulls_first,
* prepare_sort_from_pathkeys
* Prepare to sort according to given pathkeys
*
- * This is used to set up for both Sort and MergeAppend nodes. It calculates
+ * This is used to set up for both Sort and MergeAppend nodes. It calculates
* the executor's representation of the sort key information, and adjusts the
* plan targetlist if needed to add resjunk sort columns.
*
@@ -3608,7 +3610,7 @@ prepare_sort_from_pathkeys(PlannerInfo *root, Plan *lefttree, List *pathkeys,
pathkey->pk_eclass->ec_collation,
pathkey->pk_nulls_first,
numsortkeys,
- sortColIdx, sortOperators, collations, nullsFirst);
+ sortColIdx, sortOperators, collations, nullsFirst);
}
Assert(numsortkeys > 0);
@@ -3653,7 +3655,7 @@ make_sort_from_pathkeys(PlannerInfo *root, Plan *lefttree, List *pathkeys,
/* Now build the Sort node */
return make_sort(root, lefttree, numsortkeys,
- sortColIdx, sortOperators, collations, nullsFirst, limit_tuples);
+ sortColIdx, sortOperators, collations, nullsFirst, limit_tuples);
}
/*
@@ -3699,7 +3701,7 @@ make_sort_from_sortclauses(PlannerInfo *root, List *sortcls, Plan *lefttree)
exprCollation((Node *) tle->expr),
sortcl->nulls_first,
numsortkeys,
- sortColIdx, sortOperators, collations, nullsFirst);
+ sortColIdx, sortOperators, collations, nullsFirst);
}
Assert(numsortkeys > 0);
@@ -3761,7 +3763,7 @@ make_sort_from_groupcols(PlannerInfo *root,
exprCollation((Node *) tle->expr),
grpcl->nulls_first,
numsortkeys,
- sortColIdx, sortOperators, collations, nullsFirst);
+ sortColIdx, sortOperators, collations, nullsFirst);
grpno++;
}
diff --git a/src/backend/optimizer/plan/initsplan.c b/src/backend/optimizer/plan/initsplan.c
index 0e00df6433..333ede218e 100644
--- a/src/backend/optimizer/plan/initsplan.c
+++ b/src/backend/optimizer/plan/initsplan.c
@@ -188,10 +188,11 @@ add_vars_to_targetlist(PlannerInfo *root, List *vars, Relids where_needed)
phinfo->ph_needed = bms_add_members(phinfo->ph_needed,
where_needed);
+
/*
- * Update ph_may_need too. This is currently only necessary
- * when being called from build_base_rel_tlists, but we may as
- * well do it always.
+ * Update ph_may_need too. This is currently only necessary when
+ * being called from build_base_rel_tlists, but we may as well do
+ * it always.
*/
phinfo->ph_may_need = bms_add_members(phinfo->ph_may_need,
where_needed);
@@ -704,8 +705,8 @@ make_outerjoininfo(PlannerInfo *root,
* this join's nullable side, and it may get used above this join, then
* ensure that min_righthand contains the full eval_at set of the PHV.
* This ensures that the PHV actually can be evaluated within the RHS.
- * Note that this works only because we should already have determined
- * the final eval_at level for any PHV syntactically within this join.
+ * Note that this works only because we should already have determined the
+ * final eval_at level for any PHV syntactically within this join.
*/
foreach(l, root->placeholder_list)
{
@@ -1070,7 +1071,7 @@ distribute_qual_to_rels(PlannerInfo *root, Node *clause,
*
* In all cases, it's important to initialize the left_ec and right_ec
* fields of a mergejoinable clause, so that all possibly mergejoinable
- * expressions have representations in EquivalenceClasses. If
+ * expressions have representations in EquivalenceClasses. If
* process_equivalence is successful, it will take care of that;
* otherwise, we have to call initialize_mergeclause_eclasses to do it.
*/
diff --git a/src/backend/optimizer/plan/planagg.c b/src/backend/optimizer/plan/planagg.c
index f2ddf2a844..7fce92c2f1 100644
--- a/src/backend/optimizer/plan/planagg.c
+++ b/src/backend/optimizer/plan/planagg.c
@@ -10,9 +10,9 @@
* ORDER BY col ASC/DESC
* LIMIT 1)
* Given a suitable index on tab.col, this can be much faster than the
- * generic scan-all-the-rows aggregation plan. We can handle multiple
+ * generic scan-all-the-rows aggregation plan. We can handle multiple
* MIN/MAX aggregates by generating multiple subqueries, and their
- * orderings can be different. However, if the query contains any
+ * orderings can be different. However, if the query contains any
* non-optimizable aggregates, there's no point since we'll have to
* scan all the rows anyway.
*
@@ -87,10 +87,10 @@ preprocess_minmax_aggregates(PlannerInfo *root, List *tlist)
*
* We don't handle GROUP BY or windowing, because our current
* implementations of grouping require looking at all the rows anyway, and
- * so there's not much point in optimizing MIN/MAX. (Note: relaxing
- * this would likely require some restructuring in grouping_planner(),
- * since it performs assorted processing related to these features between
- * calling preprocess_minmax_aggregates and optimize_minmax_aggregates.)
+ * so there's not much point in optimizing MIN/MAX. (Note: relaxing this
+ * would likely require some restructuring in grouping_planner(), since it
+ * performs assorted processing related to these features between calling
+ * preprocess_minmax_aggregates and optimize_minmax_aggregates.)
*/
if (parse->groupClause || parse->hasWindowFuncs)
return;
@@ -119,7 +119,7 @@ preprocess_minmax_aggregates(PlannerInfo *root, List *tlist)
/*
* Scan the tlist and HAVING qual to find all the aggregates and verify
- * all are MIN/MAX aggregates. Stop as soon as we find one that isn't.
+ * all are MIN/MAX aggregates. Stop as soon as we find one that isn't.
*/
aggs_list = NIL;
if (find_minmax_aggs_walker((Node *) tlist, &aggs_list))
@@ -146,7 +146,7 @@ preprocess_minmax_aggregates(PlannerInfo *root, List *tlist)
* ordering operator.
*/
eqop = get_equality_op_for_ordering_op(mminfo->aggsortop, &reverse);
- if (!OidIsValid(eqop)) /* shouldn't happen */
+ if (!OidIsValid(eqop)) /* shouldn't happen */
elog(ERROR, "could not find equality operator for ordering operator %u",
mminfo->aggsortop);
@@ -154,7 +154,7 @@ preprocess_minmax_aggregates(PlannerInfo *root, List *tlist)
* We can use either an ordering that gives NULLS FIRST or one that
* gives NULLS LAST; furthermore there's unlikely to be much
* performance difference between them, so it doesn't seem worth
- * costing out both ways if we get a hit on the first one. NULLS
+ * costing out both ways if we get a hit on the first one. NULLS
* FIRST is more likely to be available if the operator is a
* reverse-sort operator, so try that first if reverse.
*/
@@ -169,8 +169,8 @@ preprocess_minmax_aggregates(PlannerInfo *root, List *tlist)
/*
* We're done until path generation is complete. Save info for later.
- * (Setting root->minmax_aggs non-NIL signals we succeeded in making
- * index access paths for all the aggregates.)
+ * (Setting root->minmax_aggs non-NIL signals we succeeded in making index
+ * access paths for all the aggregates.)
*/
root->minmax_aggs = aggs_list;
}
@@ -333,7 +333,7 @@ find_minmax_aggs_walker(Node *node, List **context)
mminfo->aggfnoid = aggref->aggfnoid;
mminfo->aggsortop = aggsortop;
mminfo->target = curTarget->expr;
- mminfo->subroot = NULL; /* don't compute path yet */
+ mminfo->subroot = NULL; /* don't compute path yet */
mminfo->path = NULL;
mminfo->pathcost = 0;
mminfo->param = NULL;
@@ -424,7 +424,7 @@ build_minmax_path(PlannerInfo *root, MinMaxAggInfo *mminfo,
sortcl->eqop = eqop;
sortcl->sortop = sortop;
sortcl->nulls_first = nulls_first;
- sortcl->hashable = false; /* no need to make this accurate */
+ sortcl->hashable = false; /* no need to make this accurate */
parse->sortClause = list_make1(sortcl);
/* set up expressions for LIMIT 1 */
@@ -450,8 +450,8 @@ build_minmax_path(PlannerInfo *root, MinMaxAggInfo *mminfo,
subroot->query_pathkeys = subroot->sort_pathkeys;
/*
- * Generate the best paths for this query, telling query_planner that
- * we have LIMIT 1.
+ * Generate the best paths for this query, telling query_planner that we
+ * have LIMIT 1.
*/
query_planner(subroot, parse->targetList, 1.0, 1.0,
&cheapest_path, &sorted_path, &dNumGroups);
@@ -527,11 +527,11 @@ make_agg_subplan(PlannerInfo *root, MinMaxAggInfo *mminfo)
exprCollation((Node *) mminfo->target));
/*
- * Make sure the initplan gets into the outer PlannerInfo, along with
- * any other initplans generated by the sub-planning run. We had to
- * include the outer PlannerInfo's pre-existing initplans into the
- * inner one's init_plans list earlier, so make sure we don't put back
- * any duplicate entries.
+ * Make sure the initplan gets into the outer PlannerInfo, along with any
+ * other initplans generated by the sub-planning run. We had to include
+ * the outer PlannerInfo's pre-existing initplans into the inner one's
+ * init_plans list earlier, so make sure we don't put back any duplicate
+ * entries.
*/
root->init_plans = list_concat_unique_ptr(root->init_plans,
subroot->init_plans);
diff --git a/src/backend/optimizer/plan/planmain.c b/src/backend/optimizer/plan/planmain.c
index 3dc23662e7..ff39d5754d 100644
--- a/src/backend/optimizer/plan/planmain.c
+++ b/src/backend/optimizer/plan/planmain.c
@@ -179,12 +179,12 @@ query_planner(PlannerInfo *root, List *tlist,
/*
* Examine the targetlist and join tree, adding entries to baserel
* targetlists for all referenced Vars, and generating PlaceHolderInfo
- * entries for all referenced PlaceHolderVars. Restrict and join clauses
- * are added to appropriate lists belonging to the mentioned relations.
- * We also build EquivalenceClasses for provably equivalent expressions.
- * The SpecialJoinInfo list is also built to hold information about join
- * order restrictions. Finally, we form a target joinlist for
- * make_one_rel() to work from.
+ * entries for all referenced PlaceHolderVars. Restrict and join clauses
+ * are added to appropriate lists belonging to the mentioned relations. We
+ * also build EquivalenceClasses for provably equivalent expressions. The
+ * SpecialJoinInfo list is also built to hold information about join order
+ * restrictions. Finally, we form a target joinlist for make_one_rel() to
+ * work from.
*/
build_base_rel_tlists(root, tlist);
@@ -216,7 +216,7 @@ query_planner(PlannerInfo *root, List *tlist,
/*
* Examine any "placeholder" expressions generated during subquery pullup.
* Make sure that the Vars they need are marked as needed at the relevant
- * join level. This must be done before join removal because it might
+ * join level. This must be done before join removal because it might
* cause Vars or placeholders to be needed above a join when they weren't
* so marked before.
*/
diff --git a/src/backend/optimizer/plan/planner.c b/src/backend/optimizer/plan/planner.c
index 56d25abc6d..58a5bf8ece 100644
--- a/src/backend/optimizer/plan/planner.c
+++ b/src/backend/optimizer/plan/planner.c
@@ -345,16 +345,16 @@ subquery_planner(PlannerGlobal *glob, Query *parse,
inline_set_returning_functions(root);
/*
- * Check to see if any subqueries in the jointree can be merged into
- * this query.
+ * Check to see if any subqueries in the jointree can be merged into this
+ * query.
*/
parse->jointree = (FromExpr *)
pull_up_subqueries(root, (Node *) parse->jointree, NULL, NULL);
/*
- * If this is a simple UNION ALL query, flatten it into an appendrel.
- * We do this now because it requires applying pull_up_subqueries to the
- * leaf queries of the UNION ALL, which weren't touched above because they
+ * If this is a simple UNION ALL query, flatten it into an appendrel. We
+ * do this now because it requires applying pull_up_subqueries to the leaf
+ * queries of the UNION ALL, which weren't touched above because they
* weren't referenced by the jointree (they will be after we do this).
*/
if (parse->setOperations)
@@ -575,7 +575,7 @@ subquery_planner(PlannerGlobal *glob, Query *parse,
plan = (Plan *) make_modifytable(parse->commandType,
parse->canSetTag,
- list_make1_int(parse->resultRelation),
+ list_make1_int(parse->resultRelation),
list_make1(plan),
returningLists,
rowMarks,
@@ -3116,9 +3116,9 @@ plan_cluster_use_sort(Oid tableOid, Oid indexOid)
/*
* Determine eval cost of the index expressions, if any. We need to
- * charge twice that amount for each tuple comparison that happens
- * during the sort, since tuplesort.c will have to re-evaluate the
- * index expressions each time. (XXX that's pretty inefficient...)
+ * charge twice that amount for each tuple comparison that happens during
+ * the sort, since tuplesort.c will have to re-evaluate the index
+ * expressions each time. (XXX that's pretty inefficient...)
*/
cost_qual_eval(&indexExprCost, indexInfo->indexprs, root);
comparisonCost = 2.0 * (indexExprCost.startup + indexExprCost.per_tuple);
diff --git a/src/backend/optimizer/prep/prepjointree.c b/src/backend/optimizer/prep/prepjointree.c
index bd678ac7ed..a40f116bf9 100644
--- a/src/backend/optimizer/prep/prepjointree.c
+++ b/src/backend/optimizer/prep/prepjointree.c
@@ -1429,7 +1429,7 @@ pullup_replace_vars_callback(Var *var,
*
* If a query's setOperations tree consists entirely of simple UNION ALL
* operations, flatten it into an append relation, which we can process more
- * intelligently than the general setops case. Otherwise, do nothing.
+ * intelligently than the general setops case. Otherwise, do nothing.
*
* In most cases, this can succeed only for a top-level query, because for a
* subquery in FROM, the parent query's invocation of pull_up_subqueries would
@@ -1478,10 +1478,10 @@ flatten_simple_union_all(PlannerInfo *root)
/*
* Make a copy of the leftmost RTE and add it to the rtable. This copy
- * will represent the leftmost leaf query in its capacity as a member
- * of the appendrel. The original will represent the appendrel as a
- * whole. (We must do things this way because the upper query's Vars
- * have to be seen as referring to the whole appendrel.)
+ * will represent the leftmost leaf query in its capacity as a member of
+ * the appendrel. The original will represent the appendrel as a whole.
+ * (We must do things this way because the upper query's Vars have to be
+ * seen as referring to the whole appendrel.)
*/
childRTE = copyObject(leftmostRTE);
parse->rtable = lappend(parse->rtable, childRTE);
@@ -1503,8 +1503,8 @@ flatten_simple_union_all(PlannerInfo *root)
parse->jointree->fromlist = list_make1(rtr);
/*
- * Now pretend the query has no setops. We must do this before trying
- * to do subquery pullup, because of Assert in pull_up_simple_subquery.
+ * Now pretend the query has no setops. We must do this before trying to
+ * do subquery pullup, because of Assert in pull_up_simple_subquery.
*/
parse->setOperations = NULL;
@@ -1842,9 +1842,9 @@ reduce_outer_joins_pass2(Node *jtnode,
* never both, to the children of an outer join.
*
* Note that a SEMI join works like an inner join here: it's okay
- * to pass down both local and upper constraints. (There can't
- * be any upper constraints affecting its inner side, but it's
- * not worth having a separate code path to avoid passing them.)
+ * to pass down both local and upper constraints. (There can't be
+ * any upper constraints affecting its inner side, but it's not
+ * worth having a separate code path to avoid passing them.)
*
* At a FULL join we just punt and pass nothing down --- is it
* possible to be smarter?
@@ -1882,7 +1882,7 @@ reduce_outer_joins_pass2(Node *jtnode,
pass_nonnullable_vars = local_nonnullable_vars;
pass_forced_null_vars = local_forced_null_vars;
}
- else if (jointype != JOIN_FULL) /* ie, LEFT or ANTI */
+ else if (jointype != JOIN_FULL) /* ie, LEFT or ANTI */
{
/* can't pass local constraints to non-nullable side */
pass_nonnullable_rels = nonnullable_rels;
diff --git a/src/backend/optimizer/prep/prepqual.c b/src/backend/optimizer/prep/prepqual.c
index 10e00d90dd..f6f00c4ee9 100644
--- a/src/backend/optimizer/prep/prepqual.c
+++ b/src/backend/optimizer/prep/prepqual.c
@@ -54,12 +54,12 @@ static Expr *process_duplicate_ors(List *orlist);
* Although this can be invoked on its own, it's mainly intended as a helper
* for eval_const_expressions(), and that context drives several design
* decisions. In particular, if the input is already AND/OR flat, we must
- * preserve that property. We also don't bother to recurse in situations
+ * preserve that property. We also don't bother to recurse in situations
* where we can assume that lower-level executions of eval_const_expressions
* would already have simplified sub-clauses of the input.
*
* The difference between this and a simple make_notclause() is that this
- * tries to get rid of the NOT node by logical simplification. It's clearly
+ * tries to get rid of the NOT node by logical simplification. It's clearly
* always a win if the NOT node can be eliminated altogether. However, our
* use of DeMorgan's laws could result in having more NOT nodes rather than
* fewer. We do that unconditionally anyway, because in WHERE clauses it's
@@ -141,21 +141,21 @@ negate_clause(Node *node)
switch (expr->boolop)
{
- /*--------------------
- * Apply DeMorgan's Laws:
- * (NOT (AND A B)) => (OR (NOT A) (NOT B))
- * (NOT (OR A B)) => (AND (NOT A) (NOT B))
- * i.e., swap AND for OR and negate each subclause.
- *
- * If the input is already AND/OR flat and has no NOT
- * directly above AND or OR, this transformation preserves
- * those properties. For example, if no direct child of
- * the given AND clause is an AND or a NOT-above-OR, then
- * the recursive calls of negate_clause() can't return any
- * OR clauses. So we needn't call pull_ors() before
- * building a new OR clause. Similarly for the OR case.
- *--------------------
- */
+ /*--------------------
+ * Apply DeMorgan's Laws:
+ * (NOT (AND A B)) => (OR (NOT A) (NOT B))
+ * (NOT (OR A B)) => (AND (NOT A) (NOT B))
+ * i.e., swap AND for OR and negate each subclause.
+ *
+ * If the input is already AND/OR flat and has no NOT
+ * directly above AND or OR, this transformation preserves
+ * those properties. For example, if no direct child of
+ * the given AND clause is an AND or a NOT-above-OR, then
+ * the recursive calls of negate_clause() can't return any
+ * OR clauses. So we needn't call pull_ors() before
+ * building a new OR clause. Similarly for the OR case.
+ *--------------------
+ */
case AND_EXPR:
{
List *nargs = NIL;
@@ -183,6 +183,7 @@ negate_clause(Node *node)
}
break;
case NOT_EXPR:
+
/*
* NOT underneath NOT: they cancel. We assume the
* input is already simplified, so no need to recurse.
@@ -218,8 +219,8 @@ negate_clause(Node *node)
break;
case T_BooleanTest:
{
- BooleanTest *expr = (BooleanTest *) node;
- BooleanTest *newexpr = makeNode(BooleanTest);
+ BooleanTest *expr = (BooleanTest *) node;
+ BooleanTest *newexpr = makeNode(BooleanTest);
newexpr->arg = expr->arg;
switch (expr->booltesttype)
diff --git a/src/backend/optimizer/prep/preptlist.c b/src/backend/optimizer/prep/preptlist.c
index 4ba8921528..c97150c6f7 100644
--- a/src/backend/optimizer/prep/preptlist.c
+++ b/src/backend/optimizer/prep/preptlist.c
@@ -4,7 +4,7 @@
* Routines to preprocess the parse tree target list
*
* For INSERT and UPDATE queries, the targetlist must contain an entry for
- * each attribute of the target relation in the correct order. For all query
+ * each attribute of the target relation in the correct order. For all query
* types, we may need to add junk tlist entries for Vars used in the RETURNING
* list and row ID information needed for EvalPlanQual checking.
*
@@ -80,7 +80,7 @@ preprocess_targetlist(PlannerInfo *root, List *tlist)
/*
* Add necessary junk columns for rowmarked rels. These values are needed
* for locking of rels selected FOR UPDATE/SHARE, and to do EvalPlanQual
- * rechecking. See comments for PlanRowMark in plannodes.h.
+ * rechecking. See comments for PlanRowMark in plannodes.h.
*/
foreach(lc, root->rowMarks)
{
diff --git a/src/backend/optimizer/prep/prepunion.c b/src/backend/optimizer/prep/prepunion.c
index e15a862042..0ed9535d94 100644
--- a/src/backend/optimizer/prep/prepunion.c
+++ b/src/backend/optimizer/prep/prepunion.c
@@ -938,7 +938,7 @@ generate_setop_tlist(List *colTypes, int flag,
* The Vars are always generated with varno 0.
*/
static List *
-generate_append_tlist(List *colTypes, List*colCollations, bool flag,
+generate_append_tlist(List *colTypes, List *colCollations, bool flag,
List *input_plans,
List *refnames_tlist)
{
diff --git a/src/backend/optimizer/util/clauses.c b/src/backend/optimizer/util/clauses.c
index b1069259f9..b3c2aec97b 100644
--- a/src/backend/optimizer/util/clauses.c
+++ b/src/backend/optimizer/util/clauses.c
@@ -2042,7 +2042,7 @@ rowtype_field_matches(Oid rowtypeid, int fieldnum,
*
* Whenever a function is eliminated from the expression by means of
* constant-expression evaluation or inlining, we add the function to
- * root->glob->invalItems. This ensures the plan is known to depend on
+ * root->glob->invalItems. This ensures the plan is known to depend on
* such functions, even though they aren't referenced anymore.
*
* We assume that the tree has already been type-checked and contains
@@ -2437,8 +2437,8 @@ eval_const_expressions_mutator(Node *node,
context);
/*
- * Use negate_clause() to see if we can simplify away
- * the NOT.
+ * Use negate_clause() to see if we can simplify away the
+ * NOT.
*/
return negate_clause(arg);
}
@@ -2548,9 +2548,9 @@ eval_const_expressions_mutator(Node *node,
makeConst(OIDOID, -1, InvalidOid, sizeof(Oid),
ObjectIdGetDatum(intypioparam),
false, true),
- makeConst(INT4OID, -1, InvalidOid, sizeof(int32),
- Int32GetDatum(-1),
- false, true));
+ makeConst(INT4OID, -1, InvalidOid, sizeof(int32),
+ Int32GetDatum(-1),
+ false, true));
simple = simplify_function(infunc,
expr->resulttype, -1,
@@ -2618,9 +2618,9 @@ eval_const_expressions_mutator(Node *node,
/*
* If we can simplify the input to a constant, then we don't need the
* CollateExpr node at all: just change the constcollid field of the
- * Const node. Otherwise, replace the CollateExpr with a RelabelType.
- * (We do that so as to improve uniformity of expression representation
- * and thus simplify comparison of expressions.)
+ * Const node. Otherwise, replace the CollateExpr with a RelabelType.
+ * (We do that so as to improve uniformity of expression
+ * representation and thus simplify comparison of expressions.)
*/
CollateExpr *collate = (CollateExpr *) node;
Node *arg;
@@ -2675,7 +2675,7 @@ eval_const_expressions_mutator(Node *node,
* placeholder nodes, so that we have the opportunity to reduce
* constant test conditions. For example this allows
* CASE 0 WHEN 0 THEN 1 ELSE 1/0 END
- * to reduce to 1 rather than drawing a divide-by-0 error. Note
+ * to reduce to 1 rather than drawing a divide-by-0 error. Note
* that when the test expression is constant, we don't have to
* include it in the resulting CASE; for example
* CASE 0 WHEN x THEN y ELSE z END
@@ -2855,9 +2855,9 @@ eval_const_expressions_mutator(Node *node,
/*
* We can remove null constants from the list. For a non-null
* constant, if it has not been preceded by any other
- * non-null-constant expressions then it is the result. Otherwise,
- * it's the next argument, but we can drop following arguments
- * since they will never be reached.
+ * non-null-constant expressions then it is the result.
+ * Otherwise, it's the next argument, but we can drop following
+ * arguments since they will never be reached.
*/
if (IsA(e, Const))
{
@@ -3353,12 +3353,12 @@ simplify_boolean_equality(Oid opno, List *args)
if (DatumGetBool(((Const *) leftop)->constvalue))
return rightop; /* true = foo */
else
- return negate_clause(rightop); /* false = foo */
+ return negate_clause(rightop); /* false = foo */
}
else
{
if (DatumGetBool(((Const *) leftop)->constvalue))
- return negate_clause(rightop); /* true <> foo */
+ return negate_clause(rightop); /* true <> foo */
else
return rightop; /* false <> foo */
}
@@ -3902,7 +3902,7 @@ inline_function(Oid funcid, Oid result_type, Oid result_collid,
fexpr->funcresulttype = result_type;
fexpr->funcretset = false;
fexpr->funcformat = COERCE_DONTCARE; /* doesn't matter */
- fexpr->funccollid = result_collid; /* doesn't matter */
+ fexpr->funccollid = result_collid; /* doesn't matter */
fexpr->inputcollid = input_collid;
fexpr->args = args;
fexpr->location = -1;
@@ -4060,18 +4060,18 @@ inline_function(Oid funcid, Oid result_type, Oid result_collid,
MemoryContextDelete(mycxt);
/*
- * If the result is of a collatable type, force the result to expose
- * the correct collation. In most cases this does not matter, but
- * it's possible that the function result is used directly as a sort key
- * or in other places where we expect exprCollation() to tell the truth.
+ * If the result is of a collatable type, force the result to expose the
+ * correct collation. In most cases this does not matter, but it's
+ * possible that the function result is used directly as a sort key or in
+ * other places where we expect exprCollation() to tell the truth.
*/
if (OidIsValid(result_collid))
{
- Oid exprcoll = exprCollation(newexpr);
+ Oid exprcoll = exprCollation(newexpr);
if (OidIsValid(exprcoll) && exprcoll != result_collid)
{
- CollateExpr *newnode = makeNode(CollateExpr);
+ CollateExpr *newnode = makeNode(CollateExpr);
newnode->arg = (Expr *) newexpr;
newnode->collOid = result_collid;
@@ -4370,11 +4370,11 @@ inline_set_returning_function(PlannerInfo *root, RangeTblEntry *rte)
oldcxt = MemoryContextSwitchTo(mycxt);
/*
- * When we call eval_const_expressions below, it might try to add items
- * to root->glob->invalItems. Since it is running in the temp context,
- * those items will be in that context, and will need to be copied out
- * if we're successful. Temporarily reset the list so that we can keep
- * those items separate from the pre-existing list contents.
+ * When we call eval_const_expressions below, it might try to add items to
+ * root->glob->invalItems. Since it is running in the temp context, those
+ * items will be in that context, and will need to be copied out if we're
+ * successful. Temporarily reset the list so that we can keep those items
+ * separate from the pre-existing list contents.
*/
saveInvalItems = root->glob->invalItems;
root->glob->invalItems = NIL;
@@ -4419,8 +4419,8 @@ inline_set_returning_function(PlannerInfo *root, RangeTblEntry *rte)
goto fail;
/*
- * Set up to handle parameters while parsing the function body. We
- * can use the FuncExpr just created as the input for
+ * Set up to handle parameters while parsing the function body. We can
+ * use the FuncExpr just created as the input for
* prepare_sql_fn_parse_info.
*/
pinfo = prepare_sql_fn_parse_info(func_tuple,
@@ -4438,7 +4438,7 @@ inline_set_returning_function(PlannerInfo *root, RangeTblEntry *rte)
querytree_list = pg_analyze_and_rewrite_params(linitial(raw_parsetree_list),
src,
- (ParserSetupHook) sql_fn_parser_setup,
+ (ParserSetupHook) sql_fn_parser_setup,
pinfo);
if (list_length(querytree_list) != 1)
goto fail;
@@ -4513,8 +4513,8 @@ inline_set_returning_function(PlannerInfo *root, RangeTblEntry *rte)
ReleaseSysCache(func_tuple);
/*
- * We don't have to fix collations here because the upper query is
- * already parsed, ie, the collations in the RTE are what count.
+ * We don't have to fix collations here because the upper query is already
+ * parsed, ie, the collations in the RTE are what count.
*/
/*
diff --git a/src/backend/optimizer/util/pathnode.c b/src/backend/optimizer/util/pathnode.c
index b60c88d925..55218b5869 100644
--- a/src/backend/optimizer/util/pathnode.c
+++ b/src/backend/optimizer/util/pathnode.c
@@ -745,7 +745,7 @@ create_merge_append_path(PlannerInfo *root,
else
{
/* We'll need to insert a Sort node, so include cost for that */
- Path sort_path; /* dummy for result of cost_sort */
+ Path sort_path; /* dummy for result of cost_sort */
cost_sort(&sort_path,
root,
@@ -1432,11 +1432,11 @@ create_foreignscan_path(PlannerInfo *root, RelOptInfo *rel)
ForeignPath *pathnode = makeNode(ForeignPath);
RangeTblEntry *rte;
FdwRoutine *fdwroutine;
- FdwPlan *fdwplan;
+ FdwPlan *fdwplan;
pathnode->path.pathtype = T_ForeignScan;
pathnode->path.parent = rel;
- pathnode->path.pathkeys = NIL; /* result is always unordered */
+ pathnode->path.pathkeys = NIL; /* result is always unordered */
/* Get FDW's callback info */
rte = planner_rt_fetch(rel->relid, root);
diff --git a/src/backend/optimizer/util/placeholder.c b/src/backend/optimizer/util/placeholder.c
index 61edd4991c..9796fbf9b6 100644
--- a/src/backend/optimizer/util/placeholder.c
+++ b/src/backend/optimizer/util/placeholder.c
@@ -25,7 +25,7 @@
/* Local functions */
static Relids find_placeholders_recurse(PlannerInfo *root, Node *jtnode);
static void find_placeholders_in_qual(PlannerInfo *root, Node *qual,
- Relids relids);
+ Relids relids);
/*
@@ -179,7 +179,7 @@ find_placeholders_recurse(PlannerInfo *root, Node *jtnode)
{
elog(ERROR, "unrecognized node type: %d",
(int) nodeTag(jtnode));
- jtrelids = NULL; /* keep compiler quiet */
+ jtrelids = NULL; /* keep compiler quiet */
}
return jtrelids;
}
diff --git a/src/backend/optimizer/util/predtest.c b/src/backend/optimizer/util/predtest.c
index 72fd3e4ca7..a7e83729b1 100644
--- a/src/backend/optimizer/util/predtest.c
+++ b/src/backend/optimizer/util/predtest.c
@@ -1696,7 +1696,7 @@ get_btree_test_op(Oid pred_op, Oid clause_op, bool refute_it)
else if (OidIsValid(clause_op_negator))
{
clause_tuple = SearchSysCache3(AMOPOPID,
- ObjectIdGetDatum(clause_op_negator),
+ ObjectIdGetDatum(clause_op_negator),
CharGetDatum(AMOP_SEARCH),
ObjectIdGetDatum(opfamily_id));
if (HeapTupleIsValid(clause_tuple))
diff --git a/src/backend/optimizer/util/var.c b/src/backend/optimizer/util/var.c
index 944db23800..edf507c405 100644
--- a/src/backend/optimizer/util/var.c
+++ b/src/backend/optimizer/util/var.c
@@ -694,7 +694,7 @@ pull_var_clause_walker(Node *node, pull_var_clause_context *context)
* entries might now be arbitrary expressions, not just Vars. This affects
* this function in one important way: we might find ourselves inserting
* SubLink expressions into subqueries, and we must make sure that their
- * Query.hasSubLinks fields get set to TRUE if so. If there are any
+ * Query.hasSubLinks fields get set to TRUE if so. If there are any
* SubLinks in the join alias lists, the outer Query should already have
* hasSubLinks = TRUE, so this is only relevant to un-flattened subqueries.
*
diff --git a/src/backend/parser/analyze.c b/src/backend/parser/analyze.c
index 315f067b17..e4e83a6716 100644
--- a/src/backend/parser/analyze.c
+++ b/src/backend/parser/analyze.c
@@ -759,8 +759,8 @@ transformInsertRow(ParseState *pstate, List *exprlist,
* columns. Add a suitable hint if that seems to be the problem,
* because the main error message is quite misleading for this case.
* (If there's no stmtcols, you'll get something about data type
- * mismatch, which is less misleading so we don't worry about giving
- * a hint in that case.)
+ * mismatch, which is less misleading so we don't worry about giving a
+ * hint in that case.)
*/
ereport(ERROR,
(errcode(ERRCODE_SYNTAX_ERROR),
@@ -809,7 +809,7 @@ transformInsertRow(ParseState *pstate, List *exprlist,
* return -1 if expression isn't a RowExpr or a Var referencing one.
*
* This is currently used only for hint purposes, so we aren't terribly
- * tense about recognizing all possible cases. The Var case is interesting
+ * tense about recognizing all possible cases. The Var case is interesting
* because that's what we'll get in the INSERT ... SELECT (...) case.
*/
static int
@@ -1100,8 +1100,8 @@ transformValuesClause(ParseState *pstate, SelectStmt *stmt)
/*
* We must assign collations now because assign_query_collations
* doesn't process rangetable entries. We just assign all the
- * collations independently in each row, and don't worry about
- * whether they are consistent vertically either.
+ * collations independently in each row, and don't worry about whether
+ * they are consistent vertically either.
*/
assign_list_collations(pstate, newsublist);
@@ -1452,7 +1452,7 @@ transformSetOperationStmt(ParseState *pstate, SelectStmt *stmt)
* Recursively transform leaves and internal nodes of a set-op tree
*
* In addition to returning the transformed node, if targetlist isn't NULL
- * then we return a list of its non-resjunk TargetEntry nodes. For a leaf
+ * then we return a list of its non-resjunk TargetEntry nodes. For a leaf
* set-op node these are the actual targetlist entries; otherwise they are
* dummy entries created to carry the type, typmod, collation, and location
* (for error messages) of each output column of the set-op node. This info
@@ -1672,7 +1672,7 @@ transformSetOperationTree(ParseState *pstate, SelectStmt *stmt,
* child query's semantics.
*
* If a child expression is an UNKNOWN-type Const or Param, we
- * want to replace it with the coerced expression. This can only
+ * want to replace it with the coerced expression. This can only
* happen when the child is a leaf set-op node. It's safe to
* replace the expression because if the child query's semantics
* depended on the type of this output column, it'd have already
@@ -1721,8 +1721,8 @@ transformSetOperationTree(ParseState *pstate, SelectStmt *stmt,
* collation.)
*/
rescolcoll = select_common_collation(pstate,
- list_make2(lcolnode, rcolnode),
- (op->op == SETOP_UNION && op->all));
+ list_make2(lcolnode, rcolnode),
+ (op->op == SETOP_UNION && op->all));
/* emit results */
op->colTypes = lappend_oid(op->colTypes, rescoltype);
@@ -1778,7 +1778,7 @@ transformSetOperationTree(ParseState *pstate, SelectStmt *stmt,
rescolnode->collation = rescolcoll;
rescolnode->location = bestlocation;
restle = makeTargetEntry((Expr *) rescolnode,
- 0, /* no need to set resno */
+ 0, /* no need to set resno */
NULL,
false);
*targetlist = lappend(*targetlist, restle);
@@ -2331,10 +2331,10 @@ transformLockingClause(ParseState *pstate, Query *qry, LockingClause *lc,
case RTE_RELATION:
if (rte->relkind == RELKIND_FOREIGN_TABLE)
ereport(ERROR,
- (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("SELECT FOR UPDATE/SHARE cannot be used with foreign table \"%s\"",
- rte->eref->aliasname),
- parser_errposition(pstate, thisrel->location)));
+ (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
+ errmsg("SELECT FOR UPDATE/SHARE cannot be used with foreign table \"%s\"",
+ rte->eref->aliasname),
+ parser_errposition(pstate, thisrel->location)));
applyLockingClause(qry, i,
lc->forUpdate, lc->noWait,
pushedDown);
diff --git a/src/backend/parser/parse_agg.c b/src/backend/parser/parse_agg.c
index 523d6e6989..8356133796 100644
--- a/src/backend/parser/parse_agg.c
+++ b/src/backend/parser/parse_agg.c
@@ -631,7 +631,7 @@ check_ungrouped_columns_walker(Node *node,
/*
* Check whether the Var is known functionally dependent on the GROUP
- * BY columns. If so, we can allow the Var to be used, because the
+ * BY columns. If so, we can allow the Var to be used, because the
* grouping is really a no-op for this table. However, this deduction
* depends on one or more constraints of the table, so we have to add
* those constraints to the query's constraintDeps list, because it's
@@ -642,11 +642,11 @@ check_ungrouped_columns_walker(Node *node,
* Because this is a pretty expensive check, and will have the same
* outcome for all columns of a table, we remember which RTEs we've
* already proven functional dependency for in the func_grouped_rels
- * list. This test also prevents us from adding duplicate entries
- * to the constraintDeps list.
+ * list. This test also prevents us from adding duplicate entries to
+ * the constraintDeps list.
*/
if (list_member_int(*context->func_grouped_rels, var->varno))
- return false; /* previously proven acceptable */
+ return false; /* previously proven acceptable */
Assert(var->varno > 0 &&
(int) var->varno <= list_length(context->pstate->p_rtable));
@@ -661,7 +661,7 @@ check_ungrouped_columns_walker(Node *node,
{
*context->func_grouped_rels =
lappend_int(*context->func_grouped_rels, var->varno);
- return false; /* acceptable */
+ return false; /* acceptable */
}
}
diff --git a/src/backend/parser/parse_clause.c b/src/backend/parser/parse_clause.c
index 6c0a78474c..c5fe6b6a3f 100644
--- a/src/backend/parser/parse_clause.c
+++ b/src/backend/parser/parse_clause.c
@@ -1078,7 +1078,7 @@ buildMergedJoinVar(ParseState *pstate, JoinType jointype,
else if (l_colvar->vartypmod != outcoltypmod)
l_node = (Node *) makeRelabelType((Expr *) l_colvar,
outcoltype, outcoltypmod,
- InvalidOid, /* fixed below */
+ InvalidOid, /* fixed below */
COERCE_IMPLICIT_CAST);
else
l_node = (Node *) l_colvar;
@@ -1090,7 +1090,7 @@ buildMergedJoinVar(ParseState *pstate, JoinType jointype,
else if (r_colvar->vartypmod != outcoltypmod)
r_node = (Node *) makeRelabelType((Expr *) r_colvar,
outcoltype, outcoltypmod,
- InvalidOid, /* fixed below */
+ InvalidOid, /* fixed below */
COERCE_IMPLICIT_CAST);
else
r_node = (Node *) r_colvar;
@@ -1143,8 +1143,8 @@ buildMergedJoinVar(ParseState *pstate, JoinType jointype,
/*
* Apply assign_expr_collations to fix up the collation info in the
- * coercion and CoalesceExpr nodes, if we made any. This must be done
- * now so that the join node's alias vars show correct collation info.
+ * coercion and CoalesceExpr nodes, if we made any. This must be done now
+ * so that the join node's alias vars show correct collation info.
*/
assign_expr_collations(pstate, res_node);
diff --git a/src/backend/parser/parse_coerce.c b/src/backend/parser/parse_coerce.c
index 895c3ad985..0418972517 100644
--- a/src/backend/parser/parse_coerce.c
+++ b/src/backend/parser/parse_coerce.c
@@ -285,7 +285,7 @@ coerce_type(ParseState *pstate, Node *node,
{
/*
* If we have a COLLATE clause, we have to push the coercion
- * underneath the COLLATE. This is really ugly, but there is little
+ * underneath the COLLATE. This is really ugly, but there is little
* choice because the above hacks on Consts and Params wouldn't happen
* otherwise.
*/
@@ -1959,7 +1959,7 @@ find_coercion_pathway(Oid targetTypeId, Oid sourceTypeId,
Oid sourceElem;
if ((targetElem = get_element_type(targetTypeId)) != InvalidOid &&
- (sourceElem = get_base_element_type(sourceTypeId)) != InvalidOid)
+ (sourceElem = get_base_element_type(sourceTypeId)) != InvalidOid)
{
CoercionPathType elempathtype;
Oid elemfuncid;
@@ -2091,8 +2091,8 @@ is_complex_array(Oid typid)
static bool
typeIsOfTypedTable(Oid reltypeId, Oid reloftypeId)
{
- Oid relid = typeidTypeRelid(reltypeId);
- bool result = false;
+ Oid relid = typeidTypeRelid(reltypeId);
+ bool result = false;
if (relid)
{
diff --git a/src/backend/parser/parse_collate.c b/src/backend/parser/parse_collate.c
index 3e557db266..f0cd3f88d2 100644
--- a/src/backend/parser/parse_collate.c
+++ b/src/backend/parser/parse_collate.c
@@ -14,19 +14,19 @@
* 1. The output collation of each expression node, or InvalidOid if it
* returns a noncollatable data type. This can also be InvalidOid if the
* result type is collatable but the collation is indeterminate.
- * 2. The collation to be used in executing each function. InvalidOid means
+ * 2. The collation to be used in executing each function. InvalidOid means
* that there are no collatable inputs or their collation is indeterminate.
* This value is only stored in node types that might call collation-using
* functions.
*
* You might think we could get away with storing only one collation per
- * node, but the two concepts really need to be kept distinct. Otherwise
+ * node, but the two concepts really need to be kept distinct. Otherwise
* it's too confusing when a function produces a collatable output type but
* has no collatable inputs or produces noncollatable output from collatable
* inputs.
*
* Cases with indeterminate collation might result in an error being thrown
- * at runtime. If we knew exactly which functions require collation
+ * at runtime. If we knew exactly which functions require collation
* information, we could throw those errors at parse time instead.
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
@@ -72,7 +72,7 @@ typedef struct
static bool assign_query_collations_walker(Node *node, ParseState *pstate);
static bool assign_collations_walker(Node *node,
- assign_collations_context *context);
+ assign_collations_context *context);
/*
@@ -116,8 +116,8 @@ assign_query_collations_walker(Node *node, ParseState *pstate)
return false;
/*
- * We don't want to recurse into a set-operations tree; it's already
- * been fully processed in transformSetOperationStmt.
+ * We don't want to recurse into a set-operations tree; it's already been
+ * fully processed in transformSetOperationStmt.
*/
if (IsA(node, SetOperationStmt))
return false;
@@ -144,7 +144,7 @@ assign_list_collations(ParseState *pstate, List *exprs)
foreach(lc, exprs)
{
- Node *node = (Node *) lfirst(lc);
+ Node *node = (Node *) lfirst(lc);
assign_expr_collations(pstate, node);
}
@@ -231,7 +231,7 @@ select_common_collation(ParseState *pstate, List *exprs, bool none_ok)
* Recursive guts of collation processing.
*
* Nodes with no children (eg, Vars, Consts, Params) must have been marked
- * when built. All upper-level nodes are marked here.
+ * when built. All upper-level nodes are marked here.
*
* Note: if this is invoked directly on a List, it will attempt to infer a
* common collation for all the list members. In particular, it will throw
@@ -250,9 +250,9 @@ assign_collations_walker(Node *node, assign_collations_context *context)
return false;
/*
- * Prepare for recursion. For most node types, though not all, the
- * first thing we do is recurse to process all nodes below this one.
- * Each level of the tree has its own local context.
+ * Prepare for recursion. For most node types, though not all, the first
+ * thing we do is recurse to process all nodes below this one. Each level
+ * of the tree has its own local context.
*/
loccontext.pstate = context->pstate;
loccontext.collation = InvalidOid;
@@ -323,11 +323,11 @@ assign_collations_walker(Node *node, assign_collations_context *context)
{
/*
* CaseExpr is a special case because we do not want to
- * recurse into the test expression (if any). It was
- * already marked with collations during transformCaseExpr,
- * and furthermore its collation is not relevant to the
- * result of the CASE --- only the output expressions are.
- * So we can't use expression_tree_walker here.
+ * recurse into the test expression (if any). It was already
+ * marked with collations during transformCaseExpr, and
+ * furthermore its collation is not relevant to the result of
+ * the CASE --- only the output expressions are. So we can't
+ * use expression_tree_walker here.
*/
CaseExpr *expr = (CaseExpr *) node;
Oid typcollation;
@@ -338,6 +338,7 @@ assign_collations_walker(Node *node, assign_collations_context *context)
CaseWhen *when = (CaseWhen *) lfirst(lc);
Assert(IsA(when, CaseWhen));
+
/*
* The condition expressions mustn't affect the CASE's
* result collation either; but since they are known to
@@ -401,11 +402,11 @@ assign_collations_walker(Node *node, assign_collations_context *context)
case T_RowExpr:
{
/*
- * RowExpr is a special case because the subexpressions
- * are independent: we don't want to complain if some of
- * them have incompatible explicit collations.
+ * RowExpr is a special case because the subexpressions are
+ * independent: we don't want to complain if some of them have
+ * incompatible explicit collations.
*/
- RowExpr *expr = (RowExpr *) node;
+ RowExpr *expr = (RowExpr *) node;
assign_list_collations(context->pstate, expr->args);
@@ -414,7 +415,7 @@ assign_collations_walker(Node *node, assign_collations_context *context)
* has a collation, we can just stop here: this node has no
* impact on the collation of its parent.
*/
- return false; /* done */
+ return false; /* done */
}
case T_RowCompareExpr:
{
@@ -431,9 +432,9 @@ assign_collations_walker(Node *node, assign_collations_context *context)
forboth(l, expr->largs, r, expr->rargs)
{
- Node *le = (Node *) lfirst(l);
- Node *re = (Node *) lfirst(r);
- Oid coll;
+ Node *le = (Node *) lfirst(l);
+ Node *re = (Node *) lfirst(r);
+ Oid coll;
coll = select_common_collation(context->pstate,
list_make2(le, re),
@@ -443,11 +444,11 @@ assign_collations_walker(Node *node, assign_collations_context *context)
expr->inputcollids = colls;
/*
- * Since the result is always boolean and therefore never
- * has a collation, we can just stop here: this node has no
- * impact on the collation of its parent.
+ * Since the result is always boolean and therefore never has
+ * a collation, we can just stop here: this node has no impact
+ * on the collation of its parent.
*/
- return false; /* done */
+ return false; /* done */
}
case T_CoerceToDomain:
{
@@ -455,12 +456,12 @@ assign_collations_walker(Node *node, assign_collations_context *context)
* If the domain declaration included a non-default COLLATE
* spec, then use that collation as the output collation of
* the coercion. Otherwise allow the input collation to
- * bubble up. (The input should be of the domain's base
- * type, therefore we don't need to worry about it not being
+ * bubble up. (The input should be of the domain's base type,
+ * therefore we don't need to worry about it not being
* collatable when the domain is.)
*/
CoerceToDomain *expr = (CoerceToDomain *) node;
- Oid typcollation = get_typcollation(expr->resulttype);
+ Oid typcollation = get_typcollation(expr->resulttype);
/* ... but first, recurse */
(void) expression_tree_walker(node,
@@ -510,7 +511,7 @@ assign_collations_walker(Node *node, assign_collations_context *context)
/*
* TargetEntry can have only one child, and should bubble that
- * state up to its parent. We can't use the general-case code
+ * state up to its parent. We can't use the general-case code
* below because exprType and friends don't work on TargetEntry.
*/
collation = loccontext.collation;
@@ -525,9 +526,9 @@ assign_collations_walker(Node *node, assign_collations_context *context)
* There are some cases where there might not be a failure, for
* example if the planner chooses to use hash aggregation instead
* of sorting for grouping; but it seems better to predictably
- * throw an error. (Compare transformSetOperationTree, which will
- * throw error for indeterminate collation of set-op columns,
- * even though the planner might be able to implement the set-op
+ * throw an error. (Compare transformSetOperationTree, which will
+ * throw error for indeterminate collation of set-op columns, even
+ * though the planner might be able to implement the set-op
* without sorting.)
*/
if (strength == COLLATE_CONFLICT &&
@@ -548,6 +549,7 @@ assign_collations_walker(Node *node, assign_collations_context *context)
(void) expression_tree_walker(node,
assign_collations_walker,
(void *) &loccontext);
+
/*
* When we're invoked on a query's jointree, we don't need to do
* anything with join nodes except recurse through them to process
@@ -599,6 +601,7 @@ assign_collations_walker(Node *node, assign_collations_context *context)
case T_CaseTestExpr:
case T_SetToDefault:
case T_CurrentOfExpr:
+
/*
* General case for childless expression nodes. These should
* already have a collation assigned; it is not this function's
@@ -610,10 +613,10 @@ assign_collations_walker(Node *node, assign_collations_context *context)
/*
* Note: in most cases, there will be an assigned collation
* whenever type_is_collatable(exprType(node)); but an exception
- * occurs for a Var referencing a subquery output column for
- * which a unique collation was not determinable. That may lead
- * to a runtime failure if a collation-sensitive function is
- * applied to the Var.
+ * occurs for a Var referencing a subquery output column for which
+ * a unique collation was not determinable. That may lead to a
+ * runtime failure if a collation-sensitive function is applied to
+ * the Var.
*/
if (OidIsValid(collation))
@@ -626,10 +629,10 @@ assign_collations_walker(Node *node, assign_collations_context *context)
default:
{
/*
- * General case for most expression nodes with children.
- * First recurse, then figure out what to assign here.
+ * General case for most expression nodes with children. First
+ * recurse, then figure out what to assign here.
*/
- Oid typcollation;
+ Oid typcollation;
(void) expression_tree_walker(node,
assign_collations_walker,
@@ -668,9 +671,9 @@ assign_collations_walker(Node *node, assign_collations_context *context)
}
/*
- * Save the result collation into the expression node.
- * If the state is COLLATE_CONFLICT, we'll set the collation
- * to InvalidOid, which might result in an error at runtime.
+ * Save the result collation into the expression node. If the
+ * state is COLLATE_CONFLICT, we'll set the collation to
+ * InvalidOid, which might result in an error at runtime.
*/
if (strength == COLLATE_CONFLICT)
exprSetCollation(node, InvalidOid);
diff --git a/src/backend/parser/parse_cte.c b/src/backend/parser/parse_cte.c
index c527f7589e..41097263b4 100644
--- a/src/backend/parser/parse_cte.c
+++ b/src/backend/parser/parse_cte.c
@@ -245,7 +245,7 @@ analyzeCTE(ParseState *pstate, CommonTableExpr *cte)
cte->ctequery = (Node *) query;
/*
- * Check that we got something reasonable. These first two cases should
+ * Check that we got something reasonable. These first two cases should
* be prevented by the grammar.
*/
if (!IsA(query, Query))
@@ -310,7 +310,7 @@ analyzeCTE(ParseState *pstate, CommonTableExpr *cte)
continue;
varattno++;
Assert(varattno == te->resno);
- if (lctyp == NULL || lctypmod == NULL || lccoll == NULL) /* shouldn't happen */
+ if (lctyp == NULL || lctypmod == NULL || lccoll == NULL) /* shouldn't happen */
elog(ERROR, "wrong number of output columns in WITH");
texpr = (Node *) te->expr;
if (exprType(texpr) != lfirst_oid(lctyp) ||
@@ -338,7 +338,7 @@ analyzeCTE(ParseState *pstate, CommonTableExpr *cte)
lctypmod = lnext(lctypmod);
lccoll = lnext(lccoll);
}
- if (lctyp != NULL || lctypmod != NULL || lccoll != NULL) /* shouldn't happen */
+ if (lctyp != NULL || lctypmod != NULL || lccoll != NULL) /* shouldn't happen */
elog(ERROR, "wrong number of output columns in WITH");
}
}
@@ -645,7 +645,7 @@ checkWellFormedRecursion(CteState *cstate)
CommonTableExpr *cte = cstate->items[i].cte;
SelectStmt *stmt = (SelectStmt *) cte->ctequery;
- Assert(!IsA(stmt, Query)); /* not analyzed yet */
+ Assert(!IsA(stmt, Query)); /* not analyzed yet */
/* Ignore items that weren't found to be recursive */
if (!cte->cterecursive)
diff --git a/src/backend/parser/parse_expr.c b/src/backend/parser/parse_expr.c
index 4986e0e5fa..08f0439e7e 100644
--- a/src/backend/parser/parse_expr.c
+++ b/src/backend/parser/parse_expr.c
@@ -163,6 +163,7 @@ transformExpr(ParseState *pstate, Node *expr)
typenameTypeIdAndMod(pstate, tc->typeName,
&targetType, &targetTypmod);
+
/*
* If target is a domain over array, work with the base
* array type here. transformTypeCast below will cast the
@@ -1283,9 +1284,9 @@ transformCaseExpr(ParseState *pstate, CaseExpr *c)
/*
* Run collation assignment on the test expression so that we know
- * what collation to mark the placeholder with. In principle we
- * could leave it to parse_collate.c to do that later, but propagating
- * the result to the CaseTestExpr would be unnecessarily complicated.
+ * what collation to mark the placeholder with. In principle we could
+ * leave it to parse_collate.c to do that later, but propagating the
+ * result to the CaseTestExpr would be unnecessarily complicated.
*/
assign_expr_collations(pstate, arg);
@@ -2122,15 +2123,16 @@ static Node *
transformCollateClause(ParseState *pstate, CollateClause *c)
{
CollateExpr *newc;
- Oid argtype;
+ Oid argtype;
newc = makeNode(CollateExpr);
newc->arg = (Expr *) transformExpr(pstate, c->arg);
argtype = exprType((Node *) newc->arg);
+
/*
- * The unknown type is not collatable, but coerce_type() takes
- * care of it separately, so we'll let it go here.
+ * The unknown type is not collatable, but coerce_type() takes care of it
+ * separately, so we'll let it go here.
*/
if (!type_is_collatable(argtype) && argtype != UNKNOWNOID)
ereport(ERROR,
@@ -2351,7 +2353,7 @@ make_row_comparison_op(ParseState *pstate, List *opname,
rcexpr->rctype = rctype;
rcexpr->opnos = opnos;
rcexpr->opfamilies = opfamilies;
- rcexpr->inputcollids = NIL; /* assign_expr_collations will fix this */
+ rcexpr->inputcollids = NIL; /* assign_expr_collations will fix this */
rcexpr->largs = largs;
rcexpr->rargs = rargs;
diff --git a/src/backend/parser/parse_func.c b/src/backend/parser/parse_func.c
index ba699e9a1e..75f1e20475 100644
--- a/src/backend/parser/parse_func.c
+++ b/src/backend/parser/parse_func.c
@@ -288,9 +288,9 @@ ParseFuncOrColumn(ParseState *pstate, List *funcname, List *fargs,
errmsg("function %s does not exist",
func_signature_string(funcname, nargs, argnames,
actual_arg_types)),
- errhint("No aggregate function matches the given name and argument types. "
- "Perhaps you misplaced ORDER BY; ORDER BY must appear "
- "after all regular arguments of the aggregate."),
+ errhint("No aggregate function matches the given name and argument types. "
+ "Perhaps you misplaced ORDER BY; ORDER BY must appear "
+ "after all regular arguments of the aggregate."),
parser_errposition(pstate, location)));
}
else
@@ -1034,7 +1034,7 @@ func_get_detail(List *funcname,
case COERCION_PATH_COERCEVIAIO:
if ((sourceType == RECORDOID ||
ISCOMPLEX(sourceType)) &&
- TypeCategory(targetType) == TYPCATEGORY_STRING)
+ TypeCategory(targetType) == TYPCATEGORY_STRING)
iscoercion = false;
else
iscoercion = true;
diff --git a/src/backend/parser/parse_node.c b/src/backend/parser/parse_node.c
index 07257accc8..7b5c040cb4 100644
--- a/src/backend/parser/parse_node.c
+++ b/src/backend/parser/parse_node.c
@@ -220,7 +220,7 @@ transformArrayType(Oid *arrayType, int32 *arrayTypmod)
* If the input is a domain, smash to base type, and extract the actual
* typmod to be applied to the base type. Subscripting a domain is an
* operation that necessarily works on the base array type, not the domain
- * itself. (Note that we provide no method whereby the creator of a
+ * itself. (Note that we provide no method whereby the creator of a
* domain over an array type could hide its ability to be subscripted.)
*/
*arrayType = getBaseTypeAndTypmod(*arrayType, arrayTypmod);
@@ -290,8 +290,8 @@ transformArraySubscripts(ParseState *pstate,
/*
* Caller may or may not have bothered to determine elementType. Note
- * that if the caller did do so, arrayType/arrayTypMod must be as
- * modified by transformArrayType, ie, smash domain to base type.
+ * that if the caller did do so, arrayType/arrayTypMod must be as modified
+ * by transformArrayType, ie, smash domain to base type.
*/
if (!OidIsValid(elementType))
elementType = transformArrayType(&arrayType, &arrayTypMod);
@@ -542,7 +542,7 @@ make_const(ParseState *pstate, Value *value, int location)
con = makeConst(typeid,
-1, /* typmod -1 is OK for all cases */
- InvalidOid, /* all cases are uncollatable types */
+ InvalidOid, /* all cases are uncollatable types */
typelen,
val,
false,
diff --git a/src/backend/parser/parse_oper.c b/src/backend/parser/parse_oper.c
index 822e0a0a62..15a3bb3a01 100644
--- a/src/backend/parser/parse_oper.c
+++ b/src/backend/parser/parse_oper.c
@@ -214,9 +214,9 @@ get_sort_group_operators(Oid argtype,
/*
* If the datatype is an array, then we can use array_lt and friends ...
* but only if there are suitable operators for the element type.
- * Likewise, array types are only hashable if the element type is.
- * Testing all three operator IDs here should be redundant, but let's do
- * it anyway.
+ * Likewise, array types are only hashable if the element type is. Testing
+ * all three operator IDs here should be redundant, but let's do it
+ * anyway.
*/
if (lt_opr == ARRAY_LT_OP ||
eq_opr == ARRAY_EQ_OP ||
diff --git a/src/backend/parser/parse_param.c b/src/backend/parser/parse_param.c
index 1895f92d7c..3b8a67619e 100644
--- a/src/backend/parser/parse_param.c
+++ b/src/backend/parser/parse_param.c
@@ -233,8 +233,8 @@ variable_coerce_param_hook(ParseState *pstate, Param *param,
/*
* This module always sets a Param's collation to be the default for
- * its datatype. If that's not what you want, you should be using
- * the more general parser substitution hooks.
+ * its datatype. If that's not what you want, you should be using the
+ * more general parser substitution hooks.
*/
param->paramcollid = get_typcollation(param->paramtype);
diff --git a/src/backend/parser/parse_relation.c b/src/backend/parser/parse_relation.c
index 1af3f2f3b5..d603ce2f42 100644
--- a/src/backend/parser/parse_relation.c
+++ b/src/backend/parser/parse_relation.c
@@ -1393,14 +1393,14 @@ addRangeTableEntryForCTE(ParseState *pstate,
*/
if (IsA(cte->ctequery, Query))
{
- Query *ctequery = (Query *) cte->ctequery;
+ Query *ctequery = (Query *) cte->ctequery;
if (ctequery->commandType != CMD_SELECT &&
ctequery->returningList == NIL)
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("WITH query \"%s\" does not have a RETURNING clause",
- cte->ctename),
+ errmsg("WITH query \"%s\" does not have a RETURNING clause",
+ cte->ctename),
parser_errposition(pstate, rv->location)));
}
@@ -1871,7 +1871,7 @@ expandTupleDesc(TupleDesc tupdesc, Alias *eref,
* what type the Const claims to be.
*/
*colvars = lappend(*colvars,
- makeNullConst(INT4OID, -1, InvalidOid));
+ makeNullConst(INT4OID, -1, InvalidOid));
}
}
continue;
@@ -1893,7 +1893,7 @@ expandTupleDesc(TupleDesc tupdesc, Alias *eref,
Var *varnode;
varnode = makeVar(rtindex, attr->attnum,
- attr->atttypid, attr->atttypmod, attr->attcollation,
+ attr->atttypid, attr->atttypmod, attr->attcollation,
sublevels_up);
varnode->location = location;
diff --git a/src/backend/parser/parse_target.c b/src/backend/parser/parse_target.c
index 52c6db2eb5..3f630147b0 100644
--- a/src/backend/parser/parse_target.c
+++ b/src/backend/parser/parse_target.c
@@ -671,7 +671,7 @@ transformAssignmentIndirection(ParseState *pstate,
parser_errposition(pstate, location)));
get_atttypetypmodcoll(typrelid, attnum,
- &fieldTypeId, &fieldTypMod, &fieldCollation);
+ &fieldTypeId, &fieldTypMod, &fieldCollation);
/* recurse to create appropriate RHS for field assign */
rhs = transformAssignmentIndirection(pstate,
@@ -783,8 +783,8 @@ transformAssignmentSubscripts(ParseState *pstate,
/*
* Array normally has same collation as elements, but there's an
- * exception: we might be subscripting a domain over an array type.
- * In that case use collation of the base type.
+ * exception: we might be subscripting a domain over an array type. In
+ * that case use collation of the base type.
*/
if (arrayType == targetTypeId)
collationNeeded = targetCollation;
diff --git a/src/backend/parser/parse_utilcmd.c b/src/backend/parser/parse_utilcmd.c
index b65f5f991c..22411f1608 100644
--- a/src/backend/parser/parse_utilcmd.c
+++ b/src/backend/parser/parse_utilcmd.c
@@ -121,7 +121,7 @@ static void transformFKConstraints(CreateStmtContext *cxt,
bool skipValidation,
bool isAddConstraint);
static void transformConstraintAttrs(CreateStmtContext *cxt,
- List *constraintList);
+ List *constraintList);
static void transformColumnType(CreateStmtContext *cxt, ColumnDef *column);
static void setSchemaName(char *context_schema, char **stmt_schema_name);
@@ -368,8 +368,8 @@ transformColumnDefinition(CreateStmtContext *cxt, ColumnDef *column)
* If this is ALTER ADD COLUMN, make sure the sequence will be owned
* by the table's owner. The current user might be someone else
* (perhaps a superuser, or someone who's only a member of the owning
- * role), but the SEQUENCE OWNED BY mechanisms will bleat unless
- * table and sequence have exactly the same owning role.
+ * role), but the SEQUENCE OWNED BY mechanisms will bleat unless table
+ * and sequence have exactly the same owning role.
*/
if (cxt->rel)
seqstmt->ownerId = cxt->rel->rd_rel->relowner;
@@ -732,7 +732,7 @@ transformInhRelation(CreateStmtContext *cxt, InhRelation *inhRelation)
/* Copy comment on constraint */
if ((inhRelation->options & CREATE_TABLE_LIKE_COMMENTS) &&
(comment = GetComment(get_constraint_oid(RelationGetRelid(relation),
- n->conname, false),
+ n->conname, false),
ConstraintRelationId,
0)) != NULL)
{
@@ -1390,8 +1390,8 @@ transformIndexConstraint(Constraint *constraint, CreateStmtContext *cxt)
/*
* If it's ALTER TABLE ADD CONSTRAINT USING INDEX, look up the index and
* verify it's usable, then extract the implied column name list. (We
- * will not actually need the column name list at runtime, but we need
- * it now to check for duplicate column entries below.)
+ * will not actually need the column name list at runtime, but we need it
+ * now to check for duplicate column entries below.)
*/
if (constraint->indexname != NULL)
{
@@ -1436,8 +1436,8 @@ transformIndexConstraint(Constraint *constraint, CreateStmtContext *cxt)
if (OidIsValid(get_index_constraint(index_oid)))
ereport(ERROR,
(errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
- errmsg("index \"%s\" is already associated with a constraint",
- index_name),
+ errmsg("index \"%s\" is already associated with a constraint",
+ index_name),
parser_errposition(cxt->pstate, constraint->location)));
/* Perform validity checks on the index */
@@ -1482,8 +1482,8 @@ transformIndexConstraint(Constraint *constraint, CreateStmtContext *cxt)
parser_errposition(cxt->pstate, constraint->location)));
/*
- * It's probably unsafe to change a deferred index to non-deferred.
- * (A non-constraint index couldn't be deferred anyway, so this case
+ * It's probably unsafe to change a deferred index to non-deferred. (A
+ * non-constraint index couldn't be deferred anyway, so this case
* should never occur; no need to sweat, but let's check it.)
*/
if (!index_form->indimmediate && !constraint->deferrable)
@@ -1494,7 +1494,7 @@ transformIndexConstraint(Constraint *constraint, CreateStmtContext *cxt)
parser_errposition(cxt->pstate, constraint->location)));
/*
- * Insist on it being a btree. That's the only kind that supports
+ * Insist on it being a btree. That's the only kind that supports
* uniqueness at the moment anyway; but we must have an index that
* exactly matches what you'd get from plain ADD CONSTRAINT syntax,
* else dump and reload will produce a different index (breaking
@@ -1514,15 +1514,15 @@ transformIndexConstraint(Constraint *constraint, CreateStmtContext *cxt)
for (i = 0; i < index_form->indnatts; i++)
{
- int2 attnum = index_form->indkey.values[i];
+ int2 attnum = index_form->indkey.values[i];
Form_pg_attribute attform;
- char *attname;
- Oid defopclass;
+ char *attname;
+ Oid defopclass;
/*
* We shouldn't see attnum == 0 here, since we already rejected
- * expression indexes. If we do, SystemAttributeDefinition
- * will throw an error.
+ * expression indexes. If we do, SystemAttributeDefinition will
+ * throw an error.
*/
if (attnum > 0)
{
@@ -1531,11 +1531,11 @@ transformIndexConstraint(Constraint *constraint, CreateStmtContext *cxt)
}
else
attform = SystemAttributeDefinition(attnum,
- heap_rel->rd_rel->relhasoids);
+ heap_rel->rd_rel->relhasoids);
attname = pstrdup(NameStr(attform->attname));
/*
- * Insist on default opclass and sort options. While the index
+ * Insist on default opclass and sort options. While the index
* would still work as a constraint with non-default settings, it
* might not provide exactly the same uniqueness semantics as
* you'd get from a normally-created constraint; and there's also
@@ -1549,7 +1549,7 @@ transformIndexConstraint(Constraint *constraint, CreateStmtContext *cxt)
(errcode(ERRCODE_WRONG_OBJECT_TYPE),
errmsg("index \"%s\" does not have default sorting behavior", index_name),
errdetail("Cannot create a PRIMARY KEY or UNIQUE constraint using such an index."),
- parser_errposition(cxt->pstate, constraint->location)));
+ parser_errposition(cxt->pstate, constraint->location)));
constraint->keys = lappend(constraint->keys, makeString(attname));
}
@@ -1694,13 +1694,13 @@ transformIndexConstraint(Constraint *constraint, CreateStmtContext *cxt)
(errcode(ERRCODE_DUPLICATE_COLUMN),
errmsg("column \"%s\" appears twice in primary key constraint",
key),
- parser_errposition(cxt->pstate, constraint->location)));
+ parser_errposition(cxt->pstate, constraint->location)));
else
ereport(ERROR,
(errcode(ERRCODE_DUPLICATE_COLUMN),
errmsg("column \"%s\" appears twice in unique constraint",
key),
- parser_errposition(cxt->pstate, constraint->location)));
+ parser_errposition(cxt->pstate, constraint->location)));
}
}
@@ -1743,7 +1743,7 @@ transformFKConstraints(CreateStmtContext *cxt,
Constraint *constraint = (Constraint *) lfirst(fkclist);
constraint->skip_validation = true;
- constraint->initially_valid = true;
+ constraint->initially_valid = true;
}
}
@@ -2120,18 +2120,18 @@ transformRuleStmt(RuleStmt *stmt, const char *queryString,
* However, they were already in the outer rangetable when we
* analyzed the query, so we have to check.
*
- * Note that in the INSERT...SELECT case, we need to examine
- * the CTE lists of both top_subqry and sub_qry.
+ * Note that in the INSERT...SELECT case, we need to examine the
+ * CTE lists of both top_subqry and sub_qry.
*
- * Note that we aren't digging into the body of the query
- * looking for WITHs in nested sub-SELECTs. A WITH down there
- * can legitimately refer to OLD/NEW, because it'd be an
+ * Note that we aren't digging into the body of the query looking
+ * for WITHs in nested sub-SELECTs. A WITH down there can
+ * legitimately refer to OLD/NEW, because it'd be an
* indirect-correlated outer reference.
*/
if (rangeTableEntry_used((Node *) top_subqry->cteList,
PRS2_OLD_VARNO, 0) ||
rangeTableEntry_used((Node *) sub_qry->cteList,
- PRS2_OLD_VARNO, 0))
+ PRS2_OLD_VARNO, 0))
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
errmsg("cannot refer to OLD within WITH query")));
@@ -2226,12 +2226,13 @@ transformAlterTableStmt(AlterTableStmt *stmt, const char *queryString)
lockmode = AlterTableGetLockLevel(stmt->cmds);
/*
- * Acquire appropriate lock on the target relation, which will be held until
- * end of transaction. This ensures any decisions we make here based on
- * the state of the relation will still be good at execution. We must get
- * lock now because execution will later require it; taking a lower grade lock
- * now and trying to upgrade later risks deadlock. Any new commands we add
- * after this must not upgrade the lock level requested here.
+ * Acquire appropriate lock on the target relation, which will be held
+ * until end of transaction. This ensures any decisions we make here
+ * based on the state of the relation will still be good at execution. We
+ * must get lock now because execution will later require it; taking a
+ * lower grade lock now and trying to upgrade later risks deadlock. Any
+ * new commands we add after this must not upgrade the lock level
+ * requested here.
*/
rel = relation_openrv(stmt->relation, lockmode);
@@ -2522,7 +2523,7 @@ transformColumnType(CreateStmtContext *cxt, ColumnDef *column)
if (column->collClause)
{
Form_pg_type typtup = (Form_pg_type) GETSTRUCT(ctype);
- Oid collOid;
+ Oid collOid;
collOid = LookupCollation(cxt->pstate,
column->collClause->collname,
diff --git a/src/backend/port/dynloader/freebsd.c b/src/backend/port/dynloader/freebsd.c
index 373d6aaec8..bc40079178 100644
--- a/src/backend/port/dynloader/freebsd.c
+++ b/src/backend/port/dynloader/freebsd.c
@@ -89,7 +89,7 @@ BSD44_derived_dlsym(void *handle, const char *name)
snprintf(buf, sizeof(buf), "_%s", name);
name = buf;
}
-#endif /* !__ELF__ */
+#endif /* !__ELF__ */
if ((vp = dlsym(handle, (char *) name)) == NULL)
snprintf(error_message, sizeof(error_message),
"dlsym (%s) failed", name);
diff --git a/src/backend/port/dynloader/netbsd.c b/src/backend/port/dynloader/netbsd.c
index d120656141..1bac83784a 100644
--- a/src/backend/port/dynloader/netbsd.c
+++ b/src/backend/port/dynloader/netbsd.c
@@ -89,7 +89,7 @@ BSD44_derived_dlsym(void *handle, const char *name)
snprintf(buf, sizeof(buf), "_%s", name);
name = buf;
}
-#endif /* !__ELF__ */
+#endif /* !__ELF__ */
if ((vp = dlsym(handle, (char *) name)) == NULL)
snprintf(error_message, sizeof(error_message),
"dlsym (%s) failed", name);
diff --git a/src/backend/port/dynloader/openbsd.c b/src/backend/port/dynloader/openbsd.c
index 2d061efb1e..4556a2dfeb 100644
--- a/src/backend/port/dynloader/openbsd.c
+++ b/src/backend/port/dynloader/openbsd.c
@@ -89,7 +89,7 @@ BSD44_derived_dlsym(void *handle, const char *name)
snprintf(buf, sizeof(buf), "_%s", name);
name = buf;
}
-#endif /* !__ELF__ */
+#endif /* !__ELF__ */
if ((vp = dlsym(handle, (char *) name)) == NULL)
snprintf(error_message, sizeof(error_message),
"dlsym (%s) failed", name);
diff --git a/src/backend/port/pipe.c b/src/backend/port/pipe.c
index eeed3fc2e1..b86a53ad34 100644
--- a/src/backend/port/pipe.c
+++ b/src/backend/port/pipe.c
@@ -37,7 +37,7 @@ pgpipe(int handles[2])
serv_addr.sin_family = AF_INET;
serv_addr.sin_port = htons(0);
serv_addr.sin_addr.s_addr = htonl(INADDR_LOOPBACK);
- if (bind(s, (SOCKADDR *) & serv_addr, len) == SOCKET_ERROR)
+ if (bind(s, (SOCKADDR *) &serv_addr, len) == SOCKET_ERROR)
{
ereport(LOG, (errmsg_internal("pgpipe failed to bind: %ui", WSAGetLastError())));
closesocket(s);
@@ -49,7 +49,7 @@ pgpipe(int handles[2])
closesocket(s);
return -1;
}
- if (getsockname(s, (SOCKADDR *) & serv_addr, &len) == SOCKET_ERROR)
+ if (getsockname(s, (SOCKADDR *) &serv_addr, &len) == SOCKET_ERROR)
{
ereport(LOG, (errmsg_internal("pgpipe failed to getsockname: %ui", WSAGetLastError())));
closesocket(s);
@@ -62,13 +62,13 @@ pgpipe(int handles[2])
return -1;
}
- if (connect(handles[1], (SOCKADDR *) & serv_addr, len) == SOCKET_ERROR)
+ if (connect(handles[1], (SOCKADDR *) &serv_addr, len) == SOCKET_ERROR)
{
ereport(LOG, (errmsg_internal("pgpipe failed to connect socket: %ui", WSAGetLastError())));
closesocket(s);
return -1;
}
- if ((handles[0] = accept(s, (SOCKADDR *) & serv_addr, &len)) == INVALID_SOCKET)
+ if ((handles[0] = accept(s, (SOCKADDR *) &serv_addr, &len)) == INVALID_SOCKET)
{
ereport(LOG, (errmsg_internal("pgpipe failed to accept socket: %ui", WSAGetLastError())));
closesocket(handles[1]);
diff --git a/src/backend/port/sysv_shmem.c b/src/backend/port/sysv_shmem.c
index 102a28ed04..754d2ac7e0 100644
--- a/src/backend/port/sysv_shmem.c
+++ b/src/backend/port/sysv_shmem.c
@@ -153,7 +153,7 @@ InternalIpcMemoryCreate(IpcMemoryKey memKey, Size size)
"segment exceeded your kernel's SHMMAX parameter. You can either "
"reduce the request size or reconfigure the kernel with larger SHMMAX. "
"To reduce the request size (currently %lu bytes), reduce "
- "PostgreSQL's shared memory usage, perhaps by reducing shared_buffers "
+ "PostgreSQL's shared memory usage, perhaps by reducing shared_buffers "
"or max_connections.\n"
"If the request size is already small, it's possible that it is less than "
"your kernel's SHMMIN parameter, in which case raising the request size or "
@@ -164,10 +164,10 @@ InternalIpcMemoryCreate(IpcMemoryKey memKey, Size size)
(errno == ENOMEM) ?
errhint("This error usually means that PostgreSQL's request for a shared "
"memory segment exceeded available memory or swap space, "
- "or exceeded your kernel's SHMALL parameter. You can either "
+ "or exceeded your kernel's SHMALL parameter. You can either "
"reduce the request size or reconfigure the kernel with larger SHMALL. "
"To reduce the request size (currently %lu bytes), reduce "
- "PostgreSQL's shared memory usage, perhaps by reducing shared_buffers "
+ "PostgreSQL's shared memory usage, perhaps by reducing shared_buffers "
"or max_connections.\n"
"The PostgreSQL documentation contains more information about shared "
"memory configuration.",
@@ -203,7 +203,7 @@ InternalIpcMemoryCreate(IpcMemoryKey memKey, Size size)
* hurt, but might confuse humans).
*/
{
- char line[64];
+ char line[64];
sprintf(line, "%9lu %9lu",
(unsigned long) memKey, (unsigned long) shmid);
diff --git a/src/backend/port/unix_latch.c b/src/backend/port/unix_latch.c
index 32d0cb5e3f..6dae7c94c0 100644
--- a/src/backend/port/unix_latch.c
+++ b/src/backend/port/unix_latch.c
@@ -37,11 +37,11 @@
*
* for (;;)
* {
- * ResetLatch();
- * if (work to do)
- * Do Stuff();
+ * ResetLatch();
+ * if (work to do)
+ * Do Stuff();
*
- * WaitLatch();
+ * WaitLatch();
* }
*
* It's important to reset the latch *before* checking if there's work to
@@ -100,8 +100,8 @@
static volatile sig_atomic_t waiting = false;
/* Read and write end of the self-pipe */
-static int selfpipe_readfd = -1;
-static int selfpipe_writefd = -1;
+static int selfpipe_readfd = -1;
+static int selfpipe_writefd = -1;
/* private function prototypes */
static void initSelfPipe(void);
@@ -205,7 +205,8 @@ int
WaitLatchOrSocket(volatile Latch *latch, pgsocket sock, bool forRead,
bool forWrite, long timeout)
{
- struct timeval tv, *tvp = NULL;
+ struct timeval tv,
+ *tvp = NULL;
fd_set input_mask;
fd_set output_mask;
int rc;
@@ -225,13 +226,13 @@ WaitLatchOrSocket(volatile Latch *latch, pgsocket sock, bool forRead,
waiting = true;
for (;;)
{
- int hifd;
+ int hifd;
/*
* Clear the pipe, and check if the latch is set already. If someone
- * sets the latch between this and the select() below, the setter
- * will write a byte to the pipe (or signal us and the signal handler
- * will do that), and the select() will return immediately.
+ * sets the latch between this and the select() below, the setter will
+ * write a byte to the pipe (or signal us and the signal handler will
+ * do that), and the select() will return immediately.
*/
drainSelfPipe();
if (latch->is_set)
@@ -278,7 +279,7 @@ WaitLatchOrSocket(volatile Latch *latch, pgsocket sock, bool forRead,
(forWrite && FD_ISSET(sock, &output_mask))))
{
result = 2;
- break; /* data available in socket */
+ break; /* data available in socket */
}
}
waiting = false;
@@ -293,7 +294,7 @@ WaitLatchOrSocket(volatile Latch *latch, pgsocket sock, bool forRead,
void
SetLatch(volatile Latch *latch)
{
- pid_t owner_pid;
+ pid_t owner_pid;
/* Quick exit if already set */
if (latch->is_set)
@@ -302,17 +303,17 @@ SetLatch(volatile Latch *latch)
latch->is_set = true;
/*
- * See if anyone's waiting for the latch. It can be the current process
- * if we're in a signal handler. We use the self-pipe to wake up the
- * select() in that case. If it's another process, send a signal.
+ * See if anyone's waiting for the latch. It can be the current process if
+ * we're in a signal handler. We use the self-pipe to wake up the select()
+ * in that case. If it's another process, send a signal.
*
- * Fetch owner_pid only once, in case the owner simultaneously disowns
- * the latch and clears owner_pid. XXX: This assumes that pid_t is
- * atomic, which isn't guaranteed to be true! In practice, the effective
- * range of pid_t fits in a 32 bit integer, and so should be atomic. In
- * the worst case, we might end up signaling wrong process if the right
- * one disowns the latch just as we fetch owner_pid. Even then, you're
- * very unlucky if a process with that bogus pid exists.
+ * Fetch owner_pid only once, in case the owner simultaneously disowns the
+ * latch and clears owner_pid. XXX: This assumes that pid_t is atomic,
+ * which isn't guaranteed to be true! In practice, the effective range of
+ * pid_t fits in a 32 bit integer, and so should be atomic. In the worst
+ * case, we might end up signaling wrong process if the right one disowns
+ * the latch just as we fetch owner_pid. Even then, you're very unlucky if
+ * a process with that bogus pid exists.
*/
owner_pid = latch->owner_pid;
if (owner_pid == 0)
@@ -351,15 +352,14 @@ latch_sigusr1_handler(void)
static void
initSelfPipe(void)
{
- int pipefd[2];
+ int pipefd[2];
/*
* Set up the self-pipe that allows a signal handler to wake up the
* select() in WaitLatch. Make the write-end non-blocking, so that
* SetLatch won't block if the event has already been set many times
- * filling the kernel buffer. Make the read-end non-blocking too, so
- * that we can easily clear the pipe by reading until EAGAIN or
- * EWOULDBLOCK.
+ * filling the kernel buffer. Make the read-end non-blocking too, so that
+ * we can easily clear the pipe by reading until EAGAIN or EWOULDBLOCK.
*/
if (pipe(pipefd) < 0)
elog(FATAL, "pipe() failed: %m");
@@ -376,8 +376,8 @@ initSelfPipe(void)
static void
sendSelfPipeByte(void)
{
- int rc;
- char dummy = 0;
+ int rc;
+ char dummy = 0;
retry:
rc = write(selfpipe_writefd, &dummy, 1);
@@ -388,16 +388,16 @@ retry:
goto retry;
/*
- * If the pipe is full, we don't need to retry, the data that's
- * there already is enough to wake up WaitLatch.
+ * If the pipe is full, we don't need to retry, the data that's there
+ * already is enough to wake up WaitLatch.
*/
if (errno == EAGAIN || errno == EWOULDBLOCK)
return;
/*
- * Oops, the write() failed for some other reason. We might be in
- * a signal handler, so it's not safe to elog(). We have no choice
- * but silently ignore the error.
+ * Oops, the write() failed for some other reason. We might be in a
+ * signal handler, so it's not safe to elog(). We have no choice but
+ * silently ignore the error.
*/
return;
}
@@ -408,11 +408,11 @@ static void
drainSelfPipe(void)
{
/*
- * There shouldn't normally be more than one byte in the pipe, or maybe
- * a few more if multiple processes run SetLatch at the same instant.
+ * There shouldn't normally be more than one byte in the pipe, or maybe a
+ * few more if multiple processes run SetLatch at the same instant.
*/
- char buf[16];
- int rc;
+ char buf[16];
+ int rc;
for (;;)
{
@@ -420,9 +420,9 @@ drainSelfPipe(void)
if (rc < 0)
{
if (errno == EAGAIN || errno == EWOULDBLOCK)
- break; /* the pipe is empty */
+ break; /* the pipe is empty */
else if (errno == EINTR)
- continue; /* retry */
+ continue; /* retry */
else
elog(ERROR, "read() on self-pipe failed: %m");
}
diff --git a/src/backend/port/win32/crashdump.c b/src/backend/port/win32/crashdump.c
index b58b181ed9..98bde14804 100644
--- a/src/backend/port/win32/crashdump.c
+++ b/src/backend/port/win32/crashdump.c
@@ -1,7 +1,7 @@
/*-------------------------------------------------------------------------
*
* win32_crashdump.c
- * Automatic crash dump creation for PostgreSQL on Windows
+ * Automatic crash dump creation for PostgreSQL on Windows
*
* The crashdump feature traps unhandled win32 exceptions produced by the
* backend, and tries to produce a Windows MiniDump crash
@@ -57,11 +57,11 @@
* http://www.debuginfo.com/articles/effminidumps.html
*/
-typedef BOOL (WINAPI *MINIDUMPWRITEDUMP)(HANDLE hProcess, DWORD dwPid, HANDLE hFile, MINIDUMP_TYPE DumpType,
- CONST PMINIDUMP_EXCEPTION_INFORMATION ExceptionParam,
- CONST PMINIDUMP_USER_STREAM_INFORMATION UserStreamParam,
- CONST PMINIDUMP_CALLBACK_INFORMATION CallbackParam
- );
+typedef BOOL (WINAPI * MINIDUMPWRITEDUMP) (HANDLE hProcess, DWORD dwPid, HANDLE hFile, MINIDUMP_TYPE DumpType,
+ CONST PMINIDUMP_EXCEPTION_INFORMATION ExceptionParam,
+ CONST PMINIDUMP_USER_STREAM_INFORMATION UserStreamParam,
+ CONST PMINIDUMP_CALLBACK_INFORMATION CallbackParam
+);
/*
@@ -76,24 +76,25 @@ typedef BOOL (WINAPI *MINIDUMPWRITEDUMP)(HANDLE hProcess, DWORD dwPid, HANDLE hF
* any PostgreSQL functions.
*/
static LONG WINAPI
-crashDumpHandler(struct _EXCEPTION_POINTERS *pExceptionInfo)
+crashDumpHandler(struct _EXCEPTION_POINTERS * pExceptionInfo)
{
/*
- * We only write crash dumps if the "crashdumps" directory within
- * the postgres data directory exists.
+ * We only write crash dumps if the "crashdumps" directory within the
+ * postgres data directory exists.
*/
- DWORD attribs = GetFileAttributesA("crashdumps");
- if (attribs != INVALID_FILE_ATTRIBUTES && (attribs & FILE_ATTRIBUTE_DIRECTORY) )
+ DWORD attribs = GetFileAttributesA("crashdumps");
+
+ if (attribs != INVALID_FILE_ATTRIBUTES && (attribs & FILE_ATTRIBUTE_DIRECTORY))
{
/* 'crashdumps' exists and is a directory. Try to write a dump' */
- HMODULE hDll = NULL;
+ HMODULE hDll = NULL;
MINIDUMPWRITEDUMP pDump = NULL;
MINIDUMP_TYPE dumpType;
- char dumpPath[_MAX_PATH];
- HANDLE selfProcHandle = GetCurrentProcess();
- DWORD selfPid = GetProcessId(selfProcHandle);
- HANDLE dumpFile;
- DWORD systemTicks;
+ char dumpPath[_MAX_PATH];
+ HANDLE selfProcHandle = GetCurrentProcess();
+ DWORD selfPid = GetProcessId(selfProcHandle);
+ HANDLE dumpFile;
+ DWORD systemTicks;
struct _MINIDUMP_EXCEPTION_INFORMATION ExInfo;
ExInfo.ThreadId = GetCurrentThreadId();
@@ -108,19 +109,18 @@ crashDumpHandler(struct _EXCEPTION_POINTERS *pExceptionInfo)
return EXCEPTION_CONTINUE_SEARCH;
}
- pDump = (MINIDUMPWRITEDUMP)GetProcAddress(hDll, "MiniDumpWriteDump");
+ pDump = (MINIDUMPWRITEDUMP) GetProcAddress(hDll, "MiniDumpWriteDump");
- if (pDump==NULL)
+ if (pDump == NULL)
{
write_stderr("could not load required functions in dbghelp.dll, cannot write crashdump\n");
return EXCEPTION_CONTINUE_SEARCH;
}
/*
- * Dump as much as we can, except shared memory, code segments,
- * and memory mapped files.
- * Exactly what we can dump depends on the version of dbghelp.dll,
- * see:
+ * Dump as much as we can, except shared memory, code segments, and
+ * memory mapped files. Exactly what we can dump depends on the
+ * version of dbghelp.dll, see:
* http://msdn.microsoft.com/en-us/library/ms680519(v=VS.85).aspx
*/
dumpType = MiniDumpNormal | MiniDumpWithHandleData |
@@ -135,25 +135,25 @@ crashDumpHandler(struct _EXCEPTION_POINTERS *pExceptionInfo)
systemTicks = GetTickCount();
snprintf(dumpPath, _MAX_PATH,
- "crashdumps\\postgres-pid%0i-%0i.mdmp", selfPid, systemTicks);
- dumpPath[_MAX_PATH-1] = '\0';
+ "crashdumps\\postgres-pid%0i-%0i.mdmp", selfPid, systemTicks);
+ dumpPath[_MAX_PATH - 1] = '\0';
dumpFile = CreateFile(dumpPath, GENERIC_WRITE, FILE_SHARE_WRITE,
NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL,
NULL);
- if (dumpFile==INVALID_HANDLE_VALUE)
+ if (dumpFile == INVALID_HANDLE_VALUE)
{
write_stderr("could not open crash dump file %s for writing: error code %d\n",
- dumpPath, GetLastError());
+ dumpPath, GetLastError());
return EXCEPTION_CONTINUE_SEARCH;
}
- if ((*pDump)(selfProcHandle, selfPid, dumpFile, dumpType, &ExInfo,
- NULL, NULL))
+ if ((*pDump) (selfProcHandle, selfPid, dumpFile, dumpType, &ExInfo,
+ NULL, NULL))
write_stderr("wrote crash dump to %s\n", dumpPath);
else
write_stderr("could not write crash dump to %s: error code %08x\n",
- dumpPath, GetLastError());
+ dumpPath, GetLastError());
CloseHandle(dumpFile);
}
diff --git a/src/backend/port/win32/timer.c b/src/backend/port/win32/timer.c
index 1eb6de9bdb..e118d96a4b 100644
--- a/src/backend/port/win32/timer.c
+++ b/src/backend/port/win32/timer.c
@@ -27,7 +27,7 @@ typedef struct timerCA
struct itimerval value;
HANDLE event;
CRITICAL_SECTION crit_sec;
-} timerCA;
+} timerCA;
static timerCA timerCommArea;
static HANDLE timerThreadHandle = INVALID_HANDLE_VALUE;
diff --git a/src/backend/port/win32_latch.c b/src/backend/port/win32_latch.c
index f42cfef40e..b158300d57 100644
--- a/src/backend/port/win32_latch.c
+++ b/src/backend/port/win32_latch.c
@@ -50,8 +50,7 @@ InitSharedLatch(volatile Latch *latch)
latch->is_shared = true;
/*
- * Set up security attributes to specify that the events are
- * inherited.
+ * Set up security attributes to specify that the events are inherited.
*/
ZeroMemory(&sa, sizeof(sa));
sa.nLength = sizeof(sa);
@@ -106,7 +105,7 @@ WaitLatchOrSocket(volatile Latch *latch, SOCKET sock, bool forRead,
numevents = 2;
if (sock != PGINVALID_SOCKET && (forRead || forWrite))
{
- int flags = 0;
+ int flags = 0;
if (forRead)
flags |= FD_READ;
@@ -135,7 +134,7 @@ WaitLatchOrSocket(volatile Latch *latch, SOCKET sock, bool forRead,
}
rc = WaitForMultipleObjects(numevents, events, FALSE,
- (timeout >= 0) ? (timeout / 1000) : INFINITE);
+ (timeout >= 0) ? (timeout / 1000) : INFINITE);
if (rc == WAIT_FAILED)
elog(ERROR, "WaitForMultipleObjects() failed: error code %d", (int) GetLastError());
else if (rc == WAIT_TIMEOUT)
@@ -178,7 +177,7 @@ WaitLatchOrSocket(volatile Latch *latch, SOCKET sock, bool forRead,
void
SetLatch(volatile Latch *latch)
{
- HANDLE handle;
+ HANDLE handle;
/* Quick exit if already set */
if (latch->is_set)
@@ -187,21 +186,22 @@ SetLatch(volatile Latch *latch)
latch->is_set = true;
/*
- * See if anyone's waiting for the latch. It can be the current process
- * if we're in a signal handler. Use a local variable here in case the
- * latch is just disowned between the test and the SetEvent call, and
- * event field set to NULL.
+ * See if anyone's waiting for the latch. It can be the current process if
+ * we're in a signal handler. Use a local variable here in case the latch
+ * is just disowned between the test and the SetEvent call, and event
+ * field set to NULL.
*
- * Fetch handle field only once, in case the owner simultaneously
- * disowns the latch and clears handle. This assumes that HANDLE is
- * atomic, which isn't guaranteed to be true! In practice, it should be,
- * and in the worst case we end up calling SetEvent with a bogus handle,
- * and SetEvent will return an error with no harm done.
+ * Fetch handle field only once, in case the owner simultaneously disowns
+ * the latch and clears handle. This assumes that HANDLE is atomic, which
+ * isn't guaranteed to be true! In practice, it should be, and in the
+ * worst case we end up calling SetEvent with a bogus handle, and SetEvent
+ * will return an error with no harm done.
*/
handle = latch->event;
if (handle)
{
SetEvent(handle);
+
/*
* Note that we silently ignore any errors. We might be in a signal
* handler or other critical path where it's not safe to call elog().
diff --git a/src/backend/postmaster/autovacuum.c b/src/backend/postmaster/autovacuum.c
index 619facc752..9fa63a4e6e 100644
--- a/src/backend/postmaster/autovacuum.c
+++ b/src/backend/postmaster/autovacuum.c
@@ -210,7 +210,7 @@ typedef struct WorkerInfoData
int wi_cost_delay;
int wi_cost_limit;
int wi_cost_limit_base;
-} WorkerInfoData;
+} WorkerInfoData;
typedef struct WorkerInfoData *WorkerInfo;
@@ -224,7 +224,7 @@ typedef enum
AutoVacForkFailed, /* failed trying to start a worker */
AutoVacRebalance, /* rebalance the cost limits */
AutoVacNumSignals /* must be last */
-} AutoVacuumSignal;
+} AutoVacuumSignal;
/*-------------
* The main autovacuum shmem struct. On shared memory we store this main
@@ -1527,9 +1527,9 @@ AutoVacWorkerMain(int argc, char *argv[])
SetConfigOption("statement_timeout", "0", PGC_SUSET, PGC_S_OVERRIDE);
/*
- * Force synchronous replication off to allow regular maintenance even
- * if we are waiting for standbys to connect. This is important to
- * ensure we aren't blocked from performing anti-wraparound tasks.
+ * Force synchronous replication off to allow regular maintenance even if
+ * we are waiting for standbys to connect. This is important to ensure we
+ * aren't blocked from performing anti-wraparound tasks.
*/
if (synchronous_commit > SYNCHRONOUS_COMMIT_LOCAL_FLUSH)
SetConfigOption("synchronous_commit", "local", PGC_SUSET, PGC_S_OVERRIDE);
@@ -1690,8 +1690,8 @@ autovac_balance_cost(void)
{
/*
* The idea here is that we ration out I/O equally. The amount of I/O
- * that a worker can consume is determined by cost_limit/cost_delay, so
- * we try to equalize those ratios rather than the raw limit settings.
+ * that a worker can consume is determined by cost_limit/cost_delay, so we
+ * try to equalize those ratios rather than the raw limit settings.
*
* note: in cost_limit, zero also means use value from elsewhere, because
* zero is not a valid value.
@@ -1746,7 +1746,7 @@ autovac_balance_cost(void)
/*
* We put a lower bound of 1 on the cost_limit, to avoid division-
- * by-zero in the vacuum code. Also, in case of roundoff trouble
+ * by-zero in the vacuum code. Also, in case of roundoff trouble
* in these calculations, let's be sure we don't ever set
* cost_limit to more than the base value.
*/
@@ -1785,7 +1785,7 @@ get_database_list(void)
Relation rel;
HeapScanDesc scan;
HeapTuple tup;
- MemoryContext resultcxt;
+ MemoryContext resultcxt;
/* This is the context that we will allocate our output data in */
resultcxt = CurrentMemoryContext;
@@ -1807,13 +1807,13 @@ get_database_list(void)
{
Form_pg_database pgdatabase = (Form_pg_database) GETSTRUCT(tup);
avw_dbase *avdb;
- MemoryContext oldcxt;
+ MemoryContext oldcxt;
/*
- * Allocate our results in the caller's context, not the transaction's.
- * We do this inside the loop, and restore the original context at the
- * end, so that leaky things like heap_getnext() are not called in a
- * potentially long-lived context.
+ * Allocate our results in the caller's context, not the
+ * transaction's. We do this inside the loop, and restore the original
+ * context at the end, so that leaky things like heap_getnext() are
+ * not called in a potentially long-lived context.
*/
oldcxt = MemoryContextSwitchTo(resultcxt);
@@ -2217,9 +2217,9 @@ do_autovacuum(void)
LWLockRelease(AutovacuumScheduleLock);
/*
- * Remember the prevailing values of the vacuum cost GUCs. We have
- * to restore these at the bottom of the loop, else we'll compute
- * wrong values in the next iteration of autovac_balance_cost().
+ * Remember the prevailing values of the vacuum cost GUCs. We have to
+ * restore these at the bottom of the loop, else we'll compute wrong
+ * values in the next iteration of autovac_balance_cost().
*/
stdVacuumCostDelay = VacuumCostDelay;
stdVacuumCostLimit = VacuumCostLimit;
diff --git a/src/backend/postmaster/bgwriter.c b/src/backend/postmaster/bgwriter.c
index 1b450a802b..1f4ac93d8d 100644
--- a/src/backend/postmaster/bgwriter.c
+++ b/src/backend/postmaster/bgwriter.c
@@ -1077,7 +1077,7 @@ RequestCheckpoint(int flags)
* to the requests[] queue without checking for duplicates. The bgwriter
* will have to eliminate dups internally anyway. However, if we discover
* that the queue is full, we make a pass over the entire queue to compact
- * it. This is somewhat expensive, but the alternative is for the backend
+ * it. This is somewhat expensive, but the alternative is for the backend
* to perform its own fsync, which is far more expensive in practice. It
* is theoretically possible a backend fsync might still be necessary, if
* the queue is full and contains no duplicate entries. In that case, we
@@ -1102,13 +1102,13 @@ ForwardFsyncRequest(RelFileNodeBackend rnode, ForkNumber forknum,
/*
* If the background writer isn't running or the request queue is full,
- * the backend will have to perform its own fsync request. But before
+ * the backend will have to perform its own fsync request. But before
* forcing that to happen, we can try to compact the background writer
* request queue.
*/
if (BgWriterShmem->bgwriter_pid == 0 ||
(BgWriterShmem->num_requests >= BgWriterShmem->max_requests
- && !CompactBgwriterRequestQueue()))
+ && !CompactBgwriterRequestQueue()))
{
/*
* Count the subset of writes where backends have to do their own
@@ -1128,12 +1128,12 @@ ForwardFsyncRequest(RelFileNodeBackend rnode, ForkNumber forknum,
/*
* CompactBgwriterRequestQueue
- * Remove duplicates from the request queue to avoid backend fsyncs.
+ * Remove duplicates from the request queue to avoid backend fsyncs.
*
* Although a full fsync request queue is not common, it can lead to severe
* performance problems when it does happen. So far, this situation has
* only been observed to occur when the system is under heavy write load,
- * and especially during the "sync" phase of a checkpoint. Without this
+ * and especially during the "sync" phase of a checkpoint. Without this
* logic, each backend begins doing an fsync for every block written, which
* gets very expensive and can slow down the whole system.
*
@@ -1144,9 +1144,10 @@ ForwardFsyncRequest(RelFileNodeBackend rnode, ForkNumber forknum,
static bool
CompactBgwriterRequestQueue()
{
- struct BgWriterSlotMapping {
- BgWriterRequest request;
- int slot;
+ struct BgWriterSlotMapping
+ {
+ BgWriterRequest request;
+ int slot;
};
int n,
@@ -1172,7 +1173,7 @@ CompactBgwriterRequestQueue()
/* Initialize skip_slot array */
skip_slot = palloc0(sizeof(bool) * BgWriterShmem->num_requests);
- /*
+ /*
* The basic idea here is that a request can be skipped if it's followed
* by a later, identical request. It might seem more sensible to work
* backwards from the end of the queue and check whether a request is
@@ -1189,7 +1190,7 @@ CompactBgwriterRequestQueue()
{
BgWriterRequest *request;
struct BgWriterSlotMapping *slotmap;
- bool found;
+ bool found;
request = &BgWriterShmem->requests[n];
slotmap = hash_search(htab, request, HASH_ENTER, &found);
@@ -1219,8 +1220,8 @@ CompactBgwriterRequestQueue()
BgWriterShmem->requests[preserve_count++] = BgWriterShmem->requests[n];
}
ereport(DEBUG1,
- (errmsg("compacted fsync request queue from %d entries to %d entries",
- BgWriterShmem->num_requests, preserve_count)));
+ (errmsg("compacted fsync request queue from %d entries to %d entries",
+ BgWriterShmem->num_requests, preserve_count)));
BgWriterShmem->num_requests = preserve_count;
/* Cleanup. */
diff --git a/src/backend/postmaster/pgstat.c b/src/backend/postmaster/pgstat.c
index 5f0db513d2..5ed6e8337c 100644
--- a/src/backend/postmaster/pgstat.c
+++ b/src/backend/postmaster/pgstat.c
@@ -1319,7 +1319,7 @@ pgstat_report_analyze(Relation rel, bool adopt_counts,
/* --------
* pgstat_report_recovery_conflict() -
*
- * Tell the collector about a Hot Standby recovery conflict.
+ * Tell the collector about a Hot Standby recovery conflict.
* --------
*/
void
@@ -4075,7 +4075,7 @@ pgstat_recv_resetcounter(PgStat_MsgResetcounter *msg, int len)
dbentry->functions = NULL;
/*
- * Reset database-level stats too. This should match the initialization
+ * Reset database-level stats too. This should match the initialization
* code in pgstat_get_db_entry().
*/
dbentry->n_xact_commit = 0;
@@ -4280,22 +4280,23 @@ pgstat_recv_bgwriter(PgStat_MsgBgWriter *msg, int len)
/* ----------
* pgstat_recv_recoveryconflict() -
*
- * Process as RECOVERYCONFLICT message.
+ * Process as RECOVERYCONFLICT message.
* ----------
*/
static void
pgstat_recv_recoveryconflict(PgStat_MsgRecoveryConflict *msg, int len)
{
PgStat_StatDBEntry *dbentry;
+
dbentry = pgstat_get_db_entry(msg->m_databaseid, true);
switch (msg->m_reason)
{
case PROCSIG_RECOVERY_CONFLICT_DATABASE:
+
/*
- * Since we drop the information about the database as soon
- * as it replicates, there is no point in counting these
- * conflicts.
+ * Since we drop the information about the database as soon as it
+ * replicates, there is no point in counting these conflicts.
*/
break;
case PROCSIG_RECOVERY_CONFLICT_TABLESPACE:
diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c
index 93e59258cc..6e7f66472f 100644
--- a/src/backend/postmaster/postmaster.c
+++ b/src/backend/postmaster/postmaster.c
@@ -385,7 +385,7 @@ typedef struct
HANDLE waitHandle;
HANDLE procHandle;
DWORD procId;
-} win32_deadchild_waitinfo;
+} win32_deadchild_waitinfo;
HANDLE PostmasterHandle;
#endif
@@ -400,7 +400,7 @@ typedef struct
SOCKET origsocket; /* Original socket value, or PGINVALID_SOCKET
* if not a socket */
WSAPROTOCOL_INFO wsainfo;
-} InheritableSocket;
+} InheritableSocket;
#else
typedef int InheritableSocket;
#endif
@@ -447,15 +447,15 @@ typedef struct
char my_exec_path[MAXPGPATH];
char pkglib_path[MAXPGPATH];
char ExtraOptions[MAXPGPATH];
-} BackendParameters;
+} BackendParameters;
static void read_backend_variables(char *id, Port *port);
-static void restore_backend_variables(BackendParameters * param, Port *port);
+static void restore_backend_variables(BackendParameters *param, Port *port);
#ifndef WIN32
-static bool save_backend_variables(BackendParameters * param, Port *port);
+static bool save_backend_variables(BackendParameters *param, Port *port);
#else
-static bool save_backend_variables(BackendParameters * param, Port *port,
+static bool save_backend_variables(BackendParameters *param, Port *port,
HANDLE childProcess, pid_t childPid);
#endif
@@ -1936,9 +1936,9 @@ canAcceptConnections(void)
*
* In state PM_WAIT_BACKUP only superusers can connect (this must be
* allowed so that a superuser can end online backup mode); we return
- * CAC_WAITBACKUP code to indicate that this must be checked later.
- * Note that neither CAC_OK nor CAC_WAITBACKUP can safely be returned
- * until we have checked for too many children.
+ * CAC_WAITBACKUP code to indicate that this must be checked later. Note
+ * that neither CAC_OK nor CAC_WAITBACKUP can safely be returned until we
+ * have checked for too many children.
*/
if (pmState != PM_RUN)
{
@@ -1949,10 +1949,10 @@ canAcceptConnections(void)
else if (!FatalError &&
(pmState == PM_STARTUP ||
pmState == PM_RECOVERY))
- return CAC_STARTUP; /* normal startup */
+ return CAC_STARTUP; /* normal startup */
else if (!FatalError &&
pmState == PM_HOT_STANDBY)
- result = CAC_OK; /* connection OK during hot standby */
+ result = CAC_OK; /* connection OK during hot standby */
else
return CAC_RECOVERY; /* else must be crash recovery */
}
@@ -2004,10 +2004,10 @@ ConnCreate(int serverFd)
/*
* Precompute password salt values to use for this connection. It's
- * slightly annoying to do this long in advance of knowing whether
- * we'll need 'em or not, but we must do the random() calls before we
- * fork, not after. Else the postmaster's random sequence won't get
- * advanced, and all backends would end up using the same salt...
+ * slightly annoying to do this long in advance of knowing whether we'll
+ * need 'em or not, but we must do the random() calls before we fork, not
+ * after. Else the postmaster's random sequence won't get advanced, and
+ * all backends would end up using the same salt...
*/
RandomSalt(port->md5Salt);
@@ -2611,12 +2611,13 @@ CleanupBackend(int pid,
* the active backend list.
*/
#ifdef WIN32
+
/*
- * On win32, also treat ERROR_WAIT_NO_CHILDREN (128) as nonfatal
- * case, since that sometimes happens under load when the process fails
- * to start properly (long before it starts using shared memory).
- * Microsoft reports it is related to mutex failure:
- * http://archives.postgresql.org/pgsql-hackers/2010-09/msg00790.php
+ * On win32, also treat ERROR_WAIT_NO_CHILDREN (128) as nonfatal case,
+ * since that sometimes happens under load when the process fails to start
+ * properly (long before it starts using shared memory). Microsoft reports
+ * it is related to mutex failure:
+ * http://archives.postgresql.org/pgsql-hackers/2010-09/msg00790.php
*/
if (exitstatus == ERROR_WAIT_NO_CHILDREN)
{
@@ -3086,11 +3087,11 @@ PostmasterStateMachine(void)
}
/*
- * If recovery failed, or the user does not want an automatic restart after
- * backend crashes, wait for all non-syslogger children to exit, and then
- * exit postmaster. We don't try to reinitialize when recovery fails,
- * because more than likely it will just fail again and we will keep trying
- * forever.
+ * If recovery failed, or the user does not want an automatic restart
+ * after backend crashes, wait for all non-syslogger children to exit, and
+ * then exit postmaster. We don't try to reinitialize when recovery fails,
+ * because more than likely it will just fail again and we will keep
+ * trying forever.
*/
if (pmState == PM_NO_CHILDREN && (RecoveryError || !restart_after_crash))
ExitPostmaster(1);
@@ -3169,9 +3170,8 @@ SignalSomeChildren(int signal, int target)
continue;
/*
- * Since target == BACKEND_TYPE_ALL is the most common case,
- * we test it first and avoid touching shared memory for
- * every child.
+ * Since target == BACKEND_TYPE_ALL is the most common case, we test
+ * it first and avoid touching shared memory for every child.
*/
if (target != BACKEND_TYPE_ALL)
{
@@ -4409,9 +4409,8 @@ CountChildren(int target)
continue;
/*
- * Since target == BACKEND_TYPE_ALL is the most common case,
- * we test it first and avoid touching shared memory for
- * every child.
+ * Since target == BACKEND_TYPE_ALL is the most common case, we test
+ * it first and avoid touching shared memory for every child.
*/
if (target != BACKEND_TYPE_ALL)
{
@@ -4686,19 +4685,19 @@ extern pgsocket pgStatSock;
#define read_inheritable_socket(dest, src) (*(dest) = *(src))
#else
static bool write_duplicated_handle(HANDLE *dest, HANDLE src, HANDLE child);
-static bool write_inheritable_socket(InheritableSocket * dest, SOCKET src,
+static bool write_inheritable_socket(InheritableSocket *dest, SOCKET src,
pid_t childPid);
-static void read_inheritable_socket(SOCKET * dest, InheritableSocket * src);
+static void read_inheritable_socket(SOCKET *dest, InheritableSocket *src);
#endif
/* Save critical backend variables into the BackendParameters struct */
#ifndef WIN32
static bool
-save_backend_variables(BackendParameters * param, Port *port)
+save_backend_variables(BackendParameters *param, Port *port)
#else
static bool
-save_backend_variables(BackendParameters * param, Port *port,
+save_backend_variables(BackendParameters *param, Port *port,
HANDLE childProcess, pid_t childPid)
#endif
{
@@ -4790,7 +4789,7 @@ write_duplicated_handle(HANDLE *dest, HANDLE src, HANDLE childProcess)
* straight socket inheritance.
*/
static bool
-write_inheritable_socket(InheritableSocket * dest, SOCKET src, pid_t childpid)
+write_inheritable_socket(InheritableSocket *dest, SOCKET src, pid_t childpid)
{
dest->origsocket = src;
if (src != 0 && src != PGINVALID_SOCKET)
@@ -4811,7 +4810,7 @@ write_inheritable_socket(InheritableSocket * dest, SOCKET src, pid_t childpid)
* Read a duplicate socket structure back, and get the socket descriptor.
*/
static void
-read_inheritable_socket(SOCKET * dest, InheritableSocket * src)
+read_inheritable_socket(SOCKET *dest, InheritableSocket *src)
{
SOCKET s;
@@ -4920,7 +4919,7 @@ read_backend_variables(char *id, Port *port)
/* Restore critical backend variables from the BackendParameters struct */
static void
-restore_backend_variables(BackendParameters * param, Port *port)
+restore_backend_variables(BackendParameters *param, Port *port)
{
memcpy(port, ¶m->port, sizeof(Port));
read_inheritable_socket(&port->sock, ¶m->portsocket);
diff --git a/src/backend/postmaster/syslogger.c b/src/backend/postmaster/syslogger.c
index f2eb0ad02b..a00b70f934 100644
--- a/src/backend/postmaster/syslogger.c
+++ b/src/backend/postmaster/syslogger.c
@@ -137,7 +137,7 @@ static void process_pipe_input(char *logbuffer, int *bytes_in_logbuffer);
static void flush_pipe_input(char *logbuffer, int *bytes_in_logbuffer);
static void open_csvlogfile(void);
static FILE *logfile_open(const char *filename, const char *mode,
- bool allow_errors);
+ bool allow_errors);
#ifdef WIN32
static unsigned int __stdcall pipeThread(void *arg);
@@ -1017,8 +1017,8 @@ logfile_open(const char *filename, const char *mode, bool allow_errors)
mode_t oumask;
/*
- * Note we do not let Log_file_mode disable IWUSR, since we certainly
- * want to be able to write the files ourselves.
+ * Note we do not let Log_file_mode disable IWUSR, since we certainly want
+ * to be able to write the files ourselves.
*/
oumask = umask((mode_t) ((~(Log_file_mode | S_IWUSR)) & (S_IRWXU | S_IRWXG | S_IRWXO)));
fh = fopen(filename, mode);
@@ -1035,7 +1035,7 @@ logfile_open(const char *filename, const char *mode, bool allow_errors)
}
else
{
- int save_errno = errno;
+ int save_errno = errno;
ereport(allow_errors ? LOG : FATAL,
(errcode_for_file_access(),
diff --git a/src/backend/regex/regcomp.c b/src/backend/regex/regcomp.c
index a93e99011d..6ed466a9d9 100644
--- a/src/backend/regex/regcomp.c
+++ b/src/backend/regex/regcomp.c
@@ -238,7 +238,7 @@ struct vars
#define NOERR() {if (ISERR()) return;} /* if error seen, return */
#define NOERRN() {if (ISERR()) return NULL;} /* NOERR with retval */
#define NOERRZ() {if (ISERR()) return 0;} /* NOERR with retval */
-#define INSIST(c, e) do { if (!(c)) ERR(e); } while (0) /* error if c false */
+#define INSIST(c, e) do { if (!(c)) ERR(e); } while (0) /* error if c false */
#define NOTE(b) (v->re->re_info |= (b)) /* note visible condition */
#define EMPTYARC(x, y) newarc(v->nfa, EMPTY, 0, x, y)
diff --git a/src/backend/replication/basebackup.c b/src/backend/replication/basebackup.c
index d21568cb21..030a283e81 100644
--- a/src/backend/replication/basebackup.c
+++ b/src/backend/replication/basebackup.c
@@ -39,7 +39,7 @@ typedef struct
bool fastcheckpoint;
bool nowait;
bool includewal;
-} basebackup_options;
+} basebackup_options;
static int64 sendDir(char *path, int basepathlen, bool sizeonly);
@@ -67,7 +67,7 @@ typedef struct
char *oid;
char *path;
int64 size;
-} tablespaceinfo;
+} tablespaceinfo;
/*
@@ -119,7 +119,7 @@ perform_base_backup(basebackup_options *opt, DIR *tblspcdir)
if (readlink(fullpath, linkpath, sizeof(linkpath) - 1) == -1)
{
ereport(WARNING,
- (errmsg("unable to read symbolic link %s: %m", fullpath)));
+ (errmsg("unable to read symbolic link %s: %m", fullpath)));
continue;
}
@@ -219,10 +219,11 @@ perform_base_backup(basebackup_options *opt, DIR *tblspcdir)
ptr.xrecoff = logseg * XLogSegSize + TAR_SEND_SIZE * i;
/*
- * Some old compilers, e.g. gcc 2.95.3/x86, think that passing
- * a struct in the same function as a longjump might clobber
- * a variable. bjm 2011-02-04
- * http://lists.apple.com/archives/xcode-users/2003/Dec//msg00051.html
+ * Some old compilers, e.g. gcc 2.95.3/x86, think that passing
+ * a struct in the same function as a longjump might clobber a
+ * variable. bjm 2011-02-04
+ * http://lists.apple.com/archives/xcode-users/2003/Dec//msg000
+ * 51.html
*/
XLogRead(buf, ptr, TAR_SEND_SIZE);
if (pq_putmessage('d', buf, TAR_SEND_SIZE))
@@ -494,13 +495,14 @@ static void
sendFileWithContent(const char *filename, const char *content)
{
struct stat statbuf;
- int pad, len;
+ int pad,
+ len;
len = strlen(content);
/*
- * Construct a stat struct for the backup_label file we're injecting
- * in the tar.
+ * Construct a stat struct for the backup_label file we're injecting in
+ * the tar.
*/
/* Windows doesn't have the concept of uid and gid */
#ifdef WIN32
@@ -522,7 +524,8 @@ sendFileWithContent(const char *filename, const char *content)
pad = ((len + 511) & ~511) - len;
if (pad > 0)
{
- char buf[512];
+ char buf[512];
+
MemSet(buf, 0, pad);
pq_putmessage('d', buf, pad);
}
@@ -564,13 +567,13 @@ sendDir(char *path, int basepathlen, bool sizeonly)
continue;
/*
- * Check if the postmaster has signaled us to exit, and abort
- * with an error in that case. The error handler further up
- * will call do_pg_abort_backup() for us.
+ * Check if the postmaster has signaled us to exit, and abort with an
+ * error in that case. The error handler further up will call
+ * do_pg_abort_backup() for us.
*/
if (walsender_shutdown_requested || walsender_ready_to_stop)
ereport(ERROR,
- (errmsg("shutdown requested, aborting active base backup")));
+ (errmsg("shutdown requested, aborting active base backup")));
snprintf(pathbuf, MAXPGPATH, "%s/%s", path, de->d_name);
@@ -707,7 +710,7 @@ _tarChecksum(char *header)
/* Given the member, write the TAR header & send the file */
static void
-sendFile(char *readfilename, char *tarfilename, struct stat *statbuf)
+sendFile(char *readfilename, char *tarfilename, struct stat * statbuf)
{
FILE *fp;
char buf[TAR_SEND_SIZE];
@@ -737,7 +740,7 @@ sendFile(char *readfilename, char *tarfilename, struct stat *statbuf)
/* Send the chunk as a CopyData message */
if (pq_putmessage('d', buf, cnt))
ereport(ERROR,
- (errmsg("base backup could not send data, aborting backup")));
+ (errmsg("base backup could not send data, aborting backup")));
len += cnt;
diff --git a/src/backend/replication/syncrep.c b/src/backend/replication/syncrep.c
index 192aac9aea..1d4df8a448 100644
--- a/src/backend/replication/syncrep.c
+++ b/src/backend/replication/syncrep.c
@@ -63,7 +63,7 @@
#include "utils/ps_status.h"
/* User-settable parameters for sync rep */
-char *SyncRepStandbyNames;
+char *SyncRepStandbyNames;
#define SyncStandbysDefined() \
(SyncRepStandbyNames != NULL && SyncRepStandbyNames[0] != '\0')
@@ -73,7 +73,8 @@ static bool announce_next_takeover = true;
static void SyncRepQueueInsert(void);
static void SyncRepCancelWait(void);
-static int SyncRepGetStandbyPriority(void);
+static int SyncRepGetStandbyPriority(void);
+
#ifdef USE_ASSERT_CHECKING
static bool SyncRepQueueIsOrderedByLSN(void);
#endif
@@ -96,13 +97,13 @@ static bool SyncRepQueueIsOrderedByLSN(void);
void
SyncRepWaitForLSN(XLogRecPtr XactCommitLSN)
{
- char *new_status = NULL;
+ char *new_status = NULL;
const char *old_status;
/*
- * Fast exit if user has not requested sync replication, or
- * there are no sync replication standby names defined.
- * Note that those standbys don't need to be connected.
+ * Fast exit if user has not requested sync replication, or there are no
+ * sync replication standby names defined. Note that those standbys don't
+ * need to be connected.
*/
if (!SyncRepRequested() || !SyncStandbysDefined())
return;
@@ -117,12 +118,12 @@ SyncRepWaitForLSN(XLogRecPtr XactCommitLSN)
Assert(MyProc->syncRepState == SYNC_REP_NOT_WAITING);
/*
- * We don't wait for sync rep if WalSndCtl->sync_standbys_defined is
- * not set. See SyncRepUpdateSyncStandbysDefined.
+ * We don't wait for sync rep if WalSndCtl->sync_standbys_defined is not
+ * set. See SyncRepUpdateSyncStandbysDefined.
*
- * Also check that the standby hasn't already replied. Unlikely
- * race condition but we'll be fetching that cache line anyway
- * so its likely to be a low cost check.
+ * Also check that the standby hasn't already replied. Unlikely race
+ * condition but we'll be fetching that cache line anyway so its likely to
+ * be a low cost check.
*/
if (!WalSndCtl->sync_standbys_defined ||
XLByteLE(XactCommitLSN, WalSndCtl->lsn))
@@ -163,12 +164,12 @@ SyncRepWaitForLSN(XLogRecPtr XactCommitLSN)
*/
for (;;)
{
- int syncRepState;
+ int syncRepState;
/*
- * Wait on latch for up to 60 seconds. This allows us to
- * check for postmaster death regularly while waiting.
- * Note that timeout here does not necessarily release from loop.
+ * Wait on latch for up to 60 seconds. This allows us to check for
+ * postmaster death regularly while waiting. Note that timeout here
+ * does not necessarily release from loop.
*/
WaitLatch(&MyProc->waitLatch, 60000000L);
@@ -176,12 +177,13 @@ SyncRepWaitForLSN(XLogRecPtr XactCommitLSN)
ResetLatch(&MyProc->waitLatch);
/*
- * Try checking the state without the lock first. There's no guarantee
- * that we'll read the most up-to-date value, so if it looks like we're
- * still waiting, recheck while holding the lock. But if it looks like
- * we're done, we must really be done, because once walsender changes
- * the state to SYNC_REP_WAIT_COMPLETE, it will never update it again,
- * so we can't be seeing a stale value in that case.
+ * Try checking the state without the lock first. There's no
+ * guarantee that we'll read the most up-to-date value, so if it looks
+ * like we're still waiting, recheck while holding the lock. But if
+ * it looks like we're done, we must really be done, because once
+ * walsender changes the state to SYNC_REP_WAIT_COMPLETE, it will
+ * never update it again, so we can't be seeing a stale value in that
+ * case.
*/
syncRepState = MyProc->syncRepState;
if (syncRepState == SYNC_REP_WAITING)
@@ -195,16 +197,15 @@ SyncRepWaitForLSN(XLogRecPtr XactCommitLSN)
/*
* If a wait for synchronous replication is pending, we can neither
- * acknowledge the commit nor raise ERROR or FATAL. The latter
- * would lead the client to believe that that the transaction
- * aborted, which is not true: it's already committed locally.
- * The former is no good either: the client has requested
- * synchronous replication, and is entitled to assume that an
- * acknowledged commit is also replicated, which may not be true.
- * So in this case we issue a WARNING (which some clients may
- * be able to interpret) and shut off further output. We do NOT
- * reset ProcDiePending, so that the process will die after the
- * commit is cleaned up.
+ * acknowledge the commit nor raise ERROR or FATAL. The latter would
+ * lead the client to believe that that the transaction aborted, which
+ * is not true: it's already committed locally. The former is no good
+ * either: the client has requested synchronous replication, and is
+ * entitled to assume that an acknowledged commit is also replicated,
+ * which may not be true. So in this case we issue a WARNING (which
+ * some clients may be able to interpret) and shut off further output.
+ * We do NOT reset ProcDiePending, so that the process will die after
+ * the commit is cleaned up.
*/
if (ProcDiePending)
{
@@ -220,8 +221,8 @@ SyncRepWaitForLSN(XLogRecPtr XactCommitLSN)
/*
* It's unclear what to do if a query cancel interrupt arrives. We
* can't actually abort at this point, but ignoring the interrupt
- * altogether is not helpful, so we just terminate the wait with
- * a suitable warning.
+ * altogether is not helpful, so we just terminate the wait with a
+ * suitable warning.
*/
if (QueryCancelPending)
{
@@ -234,8 +235,9 @@ SyncRepWaitForLSN(XLogRecPtr XactCommitLSN)
}
/*
- * If the postmaster dies, we'll probably never get an acknowledgement,
- * because all the wal sender processes will exit. So just bail out.
+ * If the postmaster dies, we'll probably never get an
+ * acknowledgement, because all the wal sender processes will exit.
+ * So just bail out.
*/
if (!PostmasterIsAlive(true))
{
@@ -274,7 +276,7 @@ SyncRepWaitForLSN(XLogRecPtr XactCommitLSN)
static void
SyncRepQueueInsert(void)
{
- PGPROC *proc;
+ PGPROC *proc;
proc = (PGPROC *) SHMQueuePrev(&(WalSndCtl->SyncRepQueue),
&(WalSndCtl->SyncRepQueue),
@@ -283,8 +285,8 @@ SyncRepQueueInsert(void)
while (proc)
{
/*
- * Stop at the queue element that we should after to
- * ensure the queue is ordered by LSN.
+ * Stop at the queue element that we should after to ensure the queue
+ * is ordered by LSN.
*/
if (XLByteLT(proc->waitLSN, MyProc->waitLSN))
break;
@@ -339,7 +341,7 @@ SyncRepCleanupAtProcExit(int code, Datum arg)
void
SyncRepInitConfig(void)
{
- int priority;
+ int priority;
/*
* Determine if we are a potential sync standby and remember the result
@@ -352,8 +354,8 @@ SyncRepInitConfig(void)
MyWalSnd->sync_standby_priority = priority;
LWLockRelease(SyncRepLock);
ereport(DEBUG1,
- (errmsg("standby \"%s\" now has synchronous standby priority %u",
- application_name, priority)));
+ (errmsg("standby \"%s\" now has synchronous standby priority %u",
+ application_name, priority)));
}
}
@@ -369,24 +371,24 @@ SyncRepReleaseWaiters(void)
{
volatile WalSndCtlData *walsndctl = WalSndCtl;
volatile WalSnd *syncWalSnd = NULL;
- int numprocs = 0;
+ int numprocs = 0;
int priority = 0;
int i;
/*
* If this WALSender is serving a standby that is not on the list of
- * potential standbys then we have nothing to do. If we are still
- * starting up or still running base backup, then leave quickly also.
+ * potential standbys then we have nothing to do. If we are still starting
+ * up or still running base backup, then leave quickly also.
*/
if (MyWalSnd->sync_standby_priority == 0 ||
MyWalSnd->state < WALSNDSTATE_STREAMING)
return;
/*
- * We're a potential sync standby. Release waiters if we are the
- * highest priority standby. If there are multiple standbys with
- * same priorities then we use the first mentioned standby.
- * If you change this, also change pg_stat_get_wal_senders().
+ * We're a potential sync standby. Release waiters if we are the highest
+ * priority standby. If there are multiple standbys with same priorities
+ * then we use the first mentioned standby. If you change this, also
+ * change pg_stat_get_wal_senders().
*/
LWLockAcquire(SyncRepLock, LW_EXCLUSIVE);
@@ -400,8 +402,8 @@ SyncRepReleaseWaiters(void)
(priority == 0 ||
priority > walsnd->sync_standby_priority))
{
- priority = walsnd->sync_standby_priority;
- syncWalSnd = walsnd;
+ priority = walsnd->sync_standby_priority;
+ syncWalSnd = walsnd;
}
}
@@ -423,8 +425,8 @@ SyncRepReleaseWaiters(void)
if (XLByteLT(walsndctl->lsn, MyWalSnd->flush))
{
/*
- * Set the lsn first so that when we wake backends they will
- * release up to this location.
+ * Set the lsn first so that when we wake backends they will release
+ * up to this location.
*/
walsndctl->lsn = MyWalSnd->flush;
numprocs = SyncRepWakeQueue(false);
@@ -433,9 +435,9 @@ SyncRepReleaseWaiters(void)
LWLockRelease(SyncRepLock);
elog(DEBUG3, "released %d procs up to %X/%X",
- numprocs,
- MyWalSnd->flush.xlogid,
- MyWalSnd->flush.xrecoff);
+ numprocs,
+ MyWalSnd->flush.xlogid,
+ MyWalSnd->flush.xrecoff);
/*
* If we are managing the highest priority standby, though we weren't
@@ -502,7 +504,7 @@ SyncRepGetStandbyPriority(void)
/*
* Walk queue from head. Set the state of any backends that need to be woken,
- * remove them from the queue, and then wake them. Pass all = true to wake
+ * remove them from the queue, and then wake them. Pass all = true to wake
* whole queue; otherwise, just wake up to the walsender's LSN.
*
* Must hold SyncRepLock.
@@ -511,9 +513,9 @@ int
SyncRepWakeQueue(bool all)
{
volatile WalSndCtlData *walsndctl = WalSndCtl;
- PGPROC *proc = NULL;
- PGPROC *thisproc = NULL;
- int numprocs = 0;
+ PGPROC *proc = NULL;
+ PGPROC *thisproc = NULL;
+ int numprocs = 0;
Assert(SyncRepQueueIsOrderedByLSN());
@@ -539,8 +541,8 @@ SyncRepWakeQueue(bool all)
offsetof(PGPROC, syncRepLinks));
/*
- * Set state to complete; see SyncRepWaitForLSN() for discussion
- * of the various states.
+ * Set state to complete; see SyncRepWaitForLSN() for discussion of
+ * the various states.
*/
thisproc->syncRepState = SYNC_REP_WAIT_COMPLETE;
@@ -603,8 +605,8 @@ SyncRepUpdateSyncStandbysDefined(void)
static bool
SyncRepQueueIsOrderedByLSN(void)
{
- PGPROC *proc = NULL;
- XLogRecPtr lastLSN;
+ PGPROC *proc = NULL;
+ XLogRecPtr lastLSN;
lastLSN.xlogid = 0;
lastLSN.xrecoff = 0;
@@ -616,8 +618,8 @@ SyncRepQueueIsOrderedByLSN(void)
while (proc)
{
/*
- * Check the queue is ordered by LSN and that multiple
- * procs don't have matching LSNs
+ * Check the queue is ordered by LSN and that multiple procs don't
+ * have matching LSNs
*/
if (XLByteLE(proc->waitLSN, lastLSN))
return false;
@@ -662,8 +664,8 @@ check_synchronous_standby_names(char **newval, void **extra, GucSource source)
* Any additional validation of standby names should go here.
*
* Don't attempt to set WALSender priority because this is executed by
- * postmaster at startup, not WALSender, so the application_name is
- * not yet correctly set.
+ * postmaster at startup, not WALSender, so the application_name is not
+ * yet correctly set.
*/
pfree(rawstring);
diff --git a/src/backend/replication/walreceiver.c b/src/backend/replication/walreceiver.c
index f6259e4e30..471c844ab2 100644
--- a/src/backend/replication/walreceiver.c
+++ b/src/backend/replication/walreceiver.c
@@ -94,8 +94,8 @@ static struct
XLogRecPtr Flush; /* last byte + 1 flushed in the standby */
} LogstreamResult;
-static StandbyReplyMessage reply_message;
-static StandbyHSFeedbackMessage feedback_message;
+static StandbyReplyMessage reply_message;
+static StandbyHSFeedbackMessage feedback_message;
/*
* About SIGTERM handling:
@@ -329,8 +329,8 @@ WalReceiverMain(void)
else
{
/*
- * We didn't receive anything new, but send a status update to
- * the master anyway, to report any progress in applying WAL.
+ * We didn't receive anything new, but send a status update to the
+ * master anyway, to report any progress in applying WAL.
*/
XLogWalRcvSendReply();
XLogWalRcvSendHSFeedback();
@@ -595,7 +595,7 @@ static void
XLogWalRcvSendReply(void)
{
char buf[sizeof(StandbyReplyMessage) + 1];
- TimestampTz now;
+ TimestampTz now;
/*
* If the user doesn't want status to be reported to the master, be sure
@@ -619,7 +619,7 @@ XLogWalRcvSendReply(void)
if (XLByteEQ(reply_message.write, LogstreamResult.Write)
&& XLByteEQ(reply_message.flush, LogstreamResult.Flush)
&& !TimestampDifferenceExceeds(reply_message.sendTime, now,
- wal_receiver_status_interval * 1000))
+ wal_receiver_status_interval * 1000))
return;
/* Construct a new message */
@@ -629,9 +629,9 @@ XLogWalRcvSendReply(void)
reply_message.sendTime = now;
elog(DEBUG2, "sending write %X/%X flush %X/%X apply %X/%X",
- reply_message.write.xlogid, reply_message.write.xrecoff,
- reply_message.flush.xlogid, reply_message.flush.xrecoff,
- reply_message.apply.xlogid, reply_message.apply.xrecoff);
+ reply_message.write.xlogid, reply_message.write.xrecoff,
+ reply_message.flush.xlogid, reply_message.flush.xrecoff,
+ reply_message.apply.xlogid, reply_message.apply.xrecoff);
/* Prepend with the message type and send it. */
buf[0] = 'r';
@@ -646,11 +646,11 @@ XLogWalRcvSendReply(void)
static void
XLogWalRcvSendHSFeedback(void)
{
- char buf[sizeof(StandbyHSFeedbackMessage) + 1];
- TimestampTz now;
- TransactionId nextXid;
- uint32 nextEpoch;
- TransactionId xmin;
+ char buf[sizeof(StandbyHSFeedbackMessage) + 1];
+ TimestampTz now;
+ TransactionId nextXid;
+ uint32 nextEpoch;
+ TransactionId xmin;
/*
* If the user doesn't want status to be reported to the master, be sure
@@ -666,26 +666,25 @@ XLogWalRcvSendHSFeedback(void)
* Send feedback at most once per wal_receiver_status_interval.
*/
if (!TimestampDifferenceExceeds(feedback_message.sendTime, now,
- wal_receiver_status_interval * 1000))
+ wal_receiver_status_interval * 1000))
return;
/*
- * If Hot Standby is not yet active there is nothing to send.
- * Check this after the interval has expired to reduce number of
- * calls.
+ * If Hot Standby is not yet active there is nothing to send. Check this
+ * after the interval has expired to reduce number of calls.
*/
if (!HotStandbyActive())
return;
/*
- * Make the expensive call to get the oldest xmin once we are
- * certain everything else has been checked.
+ * Make the expensive call to get the oldest xmin once we are certain
+ * everything else has been checked.
*/
xmin = GetOldestXmin(true, false);
/*
- * Get epoch and adjust if nextXid and oldestXmin are different
- * sides of the epoch boundary.
+ * Get epoch and adjust if nextXid and oldestXmin are different sides of
+ * the epoch boundary.
*/
GetNextXidAndEpoch(&nextXid, &nextEpoch);
if (nextXid < xmin)
@@ -699,8 +698,8 @@ XLogWalRcvSendHSFeedback(void)
feedback_message.epoch = nextEpoch;
elog(DEBUG2, "sending hot standby feedback xmin %u epoch %u",
- feedback_message.xmin,
- feedback_message.epoch);
+ feedback_message.xmin,
+ feedback_message.epoch);
/* Prepend with the message type and send it. */
buf[0] = 'h';
diff --git a/src/backend/replication/walreceiverfuncs.c b/src/backend/replication/walreceiverfuncs.c
index 48ab503d89..587949bfdb 100644
--- a/src/backend/replication/walreceiverfuncs.c
+++ b/src/backend/replication/walreceiverfuncs.c
@@ -200,8 +200,8 @@ RequestXLogStreaming(XLogRecPtr recptr, const char *conninfo)
walrcv->startTime = now;
/*
- * If this is the first startup of walreceiver, we initialize
- * receivedUpto and latestChunkStart to receiveStart.
+ * If this is the first startup of walreceiver, we initialize receivedUpto
+ * and latestChunkStart to receiveStart.
*/
if (walrcv->receiveStart.xlogid == 0 &&
walrcv->receiveStart.xrecoff == 0)
diff --git a/src/backend/replication/walsender.c b/src/backend/replication/walsender.c
index 1c11e7ff7a..af3c95a78b 100644
--- a/src/backend/replication/walsender.c
+++ b/src/backend/replication/walsender.c
@@ -66,15 +66,16 @@
WalSndCtlData *WalSndCtl = NULL;
/* My slot in the shared memory array */
-WalSnd *MyWalSnd = NULL;
+WalSnd *MyWalSnd = NULL;
/* Global state */
bool am_walsender = false; /* Am I a walsender process ? */
/* User-settable parameters for walsender */
int max_wal_senders = 0; /* the maximum number of concurrent walsenders */
-int WalSndDelay = 1000; /* max sleep time between some actions */
-int replication_timeout = 60 * 1000; /* maximum time to send one WAL data message */
+int WalSndDelay = 1000; /* max sleep time between some actions */
+int replication_timeout = 60 * 1000; /* maximum time to send one
+ * WAL data message */
/*
* These variables are used similarly to openLogFile/Id/Seg/Off,
@@ -121,7 +122,7 @@ static void WalSndHandshake(void);
static void WalSndKill(int code, Datum arg);
static void XLogSend(char *msgbuf, bool *caughtup);
static void IdentifySystem(void);
-static void StartReplication(StartReplicationCmd * cmd);
+static void StartReplication(StartReplicationCmd *cmd);
static void ProcessStandbyMessage(void);
static void ProcessStandbyReplyMessage(void);
static void ProcessStandbyHSFeedbackMessage(void);
@@ -281,8 +282,8 @@ IdentifySystem(void)
XLogRecPtr logptr;
/*
- * Reply with a result set with one row, three columns. First col is system
- * ID, second is timeline ID, and third is current xlog location.
+ * Reply with a result set with one row, three columns. First col is
+ * system ID, second is timeline ID, and third is current xlog location.
*/
snprintf(sysid, sizeof(sysid), UINT64_FORMAT,
@@ -348,17 +349,16 @@ IdentifySystem(void)
* START_REPLICATION
*/
static void
-StartReplication(StartReplicationCmd * cmd)
+StartReplication(StartReplicationCmd *cmd)
{
StringInfoData buf;
/*
- * Let postmaster know that we're streaming. Once we've declared us as
- * a WAL sender process, postmaster will let us outlive the bgwriter and
- * kill us last in the shutdown sequence, so we get a chance to stream
- * all remaining WAL at shutdown, including the shutdown checkpoint.
- * Note that there's no going back, and we mustn't write any WAL records
- * after this.
+ * Let postmaster know that we're streaming. Once we've declared us as a
+ * WAL sender process, postmaster will let us outlive the bgwriter and
+ * kill us last in the shutdown sequence, so we get a chance to stream all
+ * remaining WAL at shutdown, including the shutdown checkpoint. Note that
+ * there's no going back, and we mustn't write any WAL records after this.
*/
MarkPostmasterChildWalSender();
SendPostmasterSignal(PMSIGNAL_ADVANCE_STATE_MACHINE);
@@ -383,8 +383,8 @@ StartReplication(StartReplicationCmd * cmd)
* For some applications, for example, synchronous replication, it is
* important to have a clear state for this initial catchup mode, so we
* can trigger actions when we change streaming state later. We may stay
- * in this state for a long time, which is exactly why we want to be
- * able to monitor whether or not we are still here.
+ * in this state for a long time, which is exactly why we want to be able
+ * to monitor whether or not we are still here.
*/
WalSndSetState(WALSNDSTATE_CATCHUP);
@@ -476,7 +476,7 @@ ProcessRepliesIfAny(void)
{
unsigned char firstchar;
int r;
- int received = false;
+ int received = false;
for (;;)
{
@@ -519,9 +519,9 @@ ProcessRepliesIfAny(void)
firstchar)));
}
}
+
/*
- * Save the last reply timestamp if we've received at least
- * one reply.
+ * Save the last reply timestamp if we've received at least one reply.
*/
if (received)
last_reply_timestamp = GetCurrentTimestamp();
@@ -533,7 +533,7 @@ ProcessRepliesIfAny(void)
static void
ProcessStandbyMessage(void)
{
- char msgtype;
+ char msgtype;
resetStringInfo(&reply_message);
@@ -577,7 +577,7 @@ ProcessStandbyMessage(void)
static void
ProcessStandbyReplyMessage(void)
{
- StandbyReplyMessage reply;
+ StandbyReplyMessage reply;
pq_copymsgbytes(&reply_message, (char *) &reply, sizeof(StandbyReplyMessage));
@@ -587,8 +587,8 @@ ProcessStandbyReplyMessage(void)
reply.apply.xlogid, reply.apply.xrecoff);
/*
- * Update shared state for this WalSender process
- * based on reply data from standby.
+ * Update shared state for this WalSender process based on reply data from
+ * standby.
*/
{
/* use volatile pointer to prevent code rearrangement */
@@ -610,7 +610,7 @@ ProcessStandbyReplyMessage(void)
static void
ProcessStandbyHSFeedbackMessage(void)
{
- StandbyHSFeedbackMessage reply;
+ StandbyHSFeedbackMessage reply;
TransactionId newxmin = InvalidTransactionId;
pq_copymsgbytes(&reply_message, (char *) &reply, sizeof(StandbyHSFeedbackMessage));
@@ -620,22 +620,21 @@ ProcessStandbyHSFeedbackMessage(void)
reply.epoch);
/*
- * Update the WalSender's proc xmin to allow it to be visible
- * to snapshots. This will hold back the removal of dead rows
- * and thereby prevent the generation of cleanup conflicts
- * on the standby server.
+ * Update the WalSender's proc xmin to allow it to be visible to
+ * snapshots. This will hold back the removal of dead rows and thereby
+ * prevent the generation of cleanup conflicts on the standby server.
*/
if (TransactionIdIsValid(reply.xmin))
{
- TransactionId nextXid;
- uint32 nextEpoch;
- bool epochOK = false;
+ TransactionId nextXid;
+ uint32 nextEpoch;
+ bool epochOK = false;
GetNextXidAndEpoch(&nextXid, &nextEpoch);
/*
- * Epoch of oldestXmin should be same as standby or
- * if the counter has wrapped, then one less than reply.
+ * Epoch of oldestXmin should be same as standby or if the counter has
+ * wrapped, then one less than reply.
*/
if (reply.xmin <= nextXid)
{
@@ -657,6 +656,7 @@ ProcessStandbyHSFeedbackMessage(void)
if (!TransactionIdIsValid(MyProc->xmin))
{
TransactionId oldestXmin = GetOldestXmin(true, true);
+
if (TransactionIdPrecedes(oldestXmin, reply.xmin))
newxmin = reply.xmin;
else
@@ -667,7 +667,7 @@ ProcessStandbyHSFeedbackMessage(void)
if (TransactionIdPrecedes(MyProc->xmin, reply.xmin))
newxmin = reply.xmin;
else
- newxmin = MyProc->xmin; /* stay the same */
+ newxmin = MyProc->xmin; /* stay the same */
}
}
}
@@ -735,8 +735,8 @@ WalSndLoop(void)
}
/*
- * If we don't have any pending data in the output buffer, try to
- * send some more.
+ * If we don't have any pending data in the output buffer, try to send
+ * some more.
*/
if (!pq_is_send_pending())
{
@@ -746,8 +746,8 @@ WalSndLoop(void)
* Even if we wrote all the WAL that was available when we started
* sending, more might have arrived while we were sending this
* batch. We had the latch set while sending, so we have not
- * received any signals from that time. Let's arm the latch
- * again, and after that check that we're still up-to-date.
+ * received any signals from that time. Let's arm the latch again,
+ * and after that check that we're still up-to-date.
*/
if (caughtup && !pq_is_send_pending())
{
@@ -777,17 +777,17 @@ WalSndLoop(void)
!got_SIGHUP &&
!walsender_shutdown_requested)
{
- TimestampTz finish_time = 0;
+ TimestampTz finish_time = 0;
long sleeptime;
/* Reschedule replication timeout */
if (replication_timeout > 0)
{
long secs;
- int usecs;
+ int usecs;
finish_time = TimestampTzPlusMilliseconds(last_reply_timestamp,
- replication_timeout);
+ replication_timeout);
TimestampDifference(GetCurrentTimestamp(),
finish_time, &secs, &usecs);
sleeptime = secs * 1000 + usecs / 1000;
@@ -815,8 +815,8 @@ WalSndLoop(void)
{
/*
* Since typically expiration of replication timeout means
- * communication problem, we don't send the error message
- * to the standby.
+ * communication problem, we don't send the error message to
+ * the standby.
*/
ereport(COMMERROR,
(errmsg("terminating walsender process due to replication timeout")));
@@ -829,14 +829,14 @@ WalSndLoop(void)
* This is an important state change for users, since before this
* point data loss might occur if the primary dies and we need to
* failover to the standby. The state change is also important for
- * synchronous replication, since commits that started to wait at
- * that point might wait for some time.
+ * synchronous replication, since commits that started to wait at that
+ * point might wait for some time.
*/
if (MyWalSnd->state == WALSNDSTATE_CATCHUP && caughtup)
{
ereport(DEBUG1,
(errmsg("standby \"%s\" has now caught up with primary",
- application_name)));
+ application_name)));
WalSndSetState(WALSNDSTATE_STREAMING);
}
@@ -1317,7 +1317,7 @@ WalSndShmemInit(void)
void
WalSndWakeup(void)
{
- int i;
+ int i;
for (i = 0; i < max_wal_senders; i++)
SetLatch(&WalSndCtl->walsnds[i].latch);
@@ -1369,16 +1369,16 @@ WalSndGetStateString(WalSndState state)
Datum
pg_stat_get_wal_senders(PG_FUNCTION_ARGS)
{
-#define PG_STAT_GET_WAL_SENDERS_COLS 8
- ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo;
- TupleDesc tupdesc;
- Tuplestorestate *tupstore;
- MemoryContext per_query_ctx;
- MemoryContext oldcontext;
- int *sync_priority;
- int priority = 0;
- int sync_standby = -1;
- int i;
+#define PG_STAT_GET_WAL_SENDERS_COLS 8
+ ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo;
+ TupleDesc tupdesc;
+ Tuplestorestate *tupstore;
+ MemoryContext per_query_ctx;
+ MemoryContext oldcontext;
+ int *sync_priority;
+ int priority = 0;
+ int sync_standby = -1;
+ int i;
/* check to see if caller supports us returning a tuplestore */
if (rsinfo == NULL || !IsA(rsinfo, ReturnSetInfo))
@@ -1406,9 +1406,9 @@ pg_stat_get_wal_senders(PG_FUNCTION_ARGS)
MemoryContextSwitchTo(oldcontext);
/*
- * Get the priorities of sync standbys all in one go, to minimise
- * lock acquisitions and to allow us to evaluate who is the current
- * sync standby. This code must match the code in SyncRepReleaseWaiters().
+ * Get the priorities of sync standbys all in one go, to minimise lock
+ * acquisitions and to allow us to evaluate who is the current sync
+ * standby. This code must match the code in SyncRepReleaseWaiters().
*/
sync_priority = palloc(sizeof(int) * max_wal_senders);
LWLockAcquire(SyncRepLock, LW_SHARED);
@@ -1442,7 +1442,7 @@ pg_stat_get_wal_senders(PG_FUNCTION_ARGS)
XLogRecPtr write;
XLogRecPtr flush;
XLogRecPtr apply;
- WalSndState state;
+ WalSndState state;
Datum values[PG_STAT_GET_WAL_SENDERS_COLS];
bool nulls[PG_STAT_GET_WAL_SENDERS_COLS];
@@ -1463,8 +1463,8 @@ pg_stat_get_wal_senders(PG_FUNCTION_ARGS)
if (!superuser())
{
/*
- * Only superusers can see details. Other users only get
- * the pid value to know it's a walsender, but no details.
+ * Only superusers can see details. Other users only get the pid
+ * value to know it's a walsender, but no details.
*/
MemSet(&nulls[1], true, PG_STAT_GET_WAL_SENDERS_COLS - 1);
}
@@ -1485,7 +1485,7 @@ pg_stat_get_wal_senders(PG_FUNCTION_ARGS)
if (flush.xlogid == 0 && flush.xrecoff == 0)
nulls[4] = true;
snprintf(location, sizeof(location), "%X/%X",
- flush.xlogid, flush.xrecoff);
+ flush.xlogid, flush.xrecoff);
values[4] = CStringGetTextDatum(location);
if (apply.xlogid == 0 && apply.xrecoff == 0)
@@ -1497,8 +1497,8 @@ pg_stat_get_wal_senders(PG_FUNCTION_ARGS)
values[6] = Int32GetDatum(sync_priority[i]);
/*
- * More easily understood version of standby state.
- * This is purely informational, not different from priority.
+ * More easily understood version of standby state. This is purely
+ * informational, not different from priority.
*/
if (sync_priority[i] == 0)
values[7] = CStringGetTextDatum("ASYNC");
diff --git a/src/backend/rewrite/rewriteDefine.c b/src/backend/rewrite/rewriteDefine.c
index a405dbfe8e..c1b97d141e 100644
--- a/src/backend/rewrite/rewriteDefine.c
+++ b/src/backend/rewrite/rewriteDefine.c
@@ -241,9 +241,9 @@ DefineQueryRewrite(char *rulename,
/*
* If we are installing an ON SELECT rule, we had better grab
* AccessExclusiveLock to ensure no SELECTs are currently running on the
- * event relation. For other types of rules, it is sufficient to
- * grab ShareRowExclusiveLock to lock out insert/update/delete actions
- * and to ensure that we lock out current CREATE RULE statements.
+ * event relation. For other types of rules, it is sufficient to grab
+ * ShareRowExclusiveLock to lock out insert/update/delete actions and to
+ * ensure that we lock out current CREATE RULE statements.
*/
if (event_type == CMD_SELECT)
event_relation = heap_open(event_relid, AccessExclusiveLock);
diff --git a/src/backend/rewrite/rewriteHandler.c b/src/backend/rewrite/rewriteHandler.c
index a695b01239..bfc8fd7ee0 100644
--- a/src/backend/rewrite/rewriteHandler.c
+++ b/src/backend/rewrite/rewriteHandler.c
@@ -53,7 +53,7 @@ static Node *get_assignment_input(Node *node);
static void rewriteValuesRTE(RangeTblEntry *rte, Relation target_relation,
List *attrnos);
static void rewriteTargetListUD(Query *parsetree, RangeTblEntry *target_rte,
- Relation target_relation);
+ Relation target_relation);
static void markQueryForLocking(Query *qry, Node *jtnode,
bool forUpdate, bool noWait, bool pushedDown);
static List *matchLocks(CmdType event, RuleLock *rulelocks,
@@ -743,8 +743,8 @@ rewriteTargetListIU(Query *parsetree, Relation target_relation,
}
/*
- * For an UPDATE on a view, provide a dummy entry whenever there is
- * no explicit assignment.
+ * For an UPDATE on a view, provide a dummy entry whenever there is no
+ * explicit assignment.
*/
if (new_tle == NULL && commandType == CMD_UPDATE &&
target_relation->rd_rel->relkind == RELKIND_VIEW)
@@ -1112,7 +1112,7 @@ rewriteValuesRTE(RangeTblEntry *rte, Relation target_relation, List *attrnos)
* rewriteTargetListUD - rewrite UPDATE/DELETE targetlist as needed
*
* This function adds a "junk" TLE that is needed to allow the executor to
- * find the original row for the update or delete. When the target relation
+ * find the original row for the update or delete. When the target relation
* is a regular table, the junk TLE emits the ctid attribute of the original
* row. When the target relation is a view, there is no ctid, so we instead
* emit a whole-row Var that will contain the "old" values of the view row.
@@ -1145,8 +1145,8 @@ rewriteTargetListUD(Query *parsetree, RangeTblEntry *target_rte,
else
{
/*
- * Emit whole-row Var so that executor will have the "old" view row
- * to pass to the INSTEAD OF trigger.
+ * Emit whole-row Var so that executor will have the "old" view row to
+ * pass to the INSTEAD OF trigger.
*/
var = makeWholeRowVar(target_rte,
parsetree->resultRelation,
@@ -1267,11 +1267,11 @@ ApplyRetrieveRule(Query *parsetree,
* fine as the result relation.
*
* For UPDATE/DELETE, we need to expand the view so as to have source
- * data for the operation. But we also need an unmodified RTE to
+ * data for the operation. But we also need an unmodified RTE to
* serve as the target. So, copy the RTE and add the copy to the
- * rangetable. Note that the copy does not get added to the jointree.
- * Also note that there's a hack in fireRIRrules to avoid calling
- * this function again when it arrives at the copied RTE.
+ * rangetable. Note that the copy does not get added to the jointree.
+ * Also note that there's a hack in fireRIRrules to avoid calling this
+ * function again when it arrives at the copied RTE.
*/
if (parsetree->commandType == CMD_INSERT)
return parsetree;
@@ -1286,9 +1286,9 @@ ApplyRetrieveRule(Query *parsetree,
parsetree->resultRelation = list_length(parsetree->rtable);
/*
- * There's no need to do permissions checks twice, so wipe out
- * the permissions info for the original RTE (we prefer to keep
- * the bits set on the result RTE).
+ * There's no need to do permissions checks twice, so wipe out the
+ * permissions info for the original RTE (we prefer to keep the
+ * bits set on the result RTE).
*/
rte->requiredPerms = 0;
rte->checkAsUser = InvalidOid;
@@ -1988,9 +1988,9 @@ RewriteQuery(Query *parsetree, List *rewrite_events)
*/
foreach(lc1, parsetree->cteList)
{
- CommonTableExpr *cte = (CommonTableExpr *) lfirst(lc1);
- Query *ctequery = (Query *) cte->ctequery;
- List *newstuff;
+ CommonTableExpr *cte = (CommonTableExpr *) lfirst(lc1);
+ Query *ctequery = (Query *) cte->ctequery;
+ List *newstuff;
Assert(IsA(ctequery, Query));
@@ -2021,12 +2021,12 @@ RewriteQuery(Query *parsetree, List *rewrite_events)
}
else
{
- ListCell *lc2;
+ ListCell *lc2;
/* examine queries to determine which error message to issue */
foreach(lc2, newstuff)
{
- Query *q = (Query *) lfirst(lc2);
+ Query *q = (Query *) lfirst(lc2);
if (q->querySource == QSRC_QUAL_INSTEAD_RULE)
ereport(ERROR,
diff --git a/src/backend/rewrite/rewriteSupport.c b/src/backend/rewrite/rewriteSupport.c
index 9feed7345e..7770d032b1 100644
--- a/src/backend/rewrite/rewriteSupport.c
+++ b/src/backend/rewrite/rewriteSupport.c
@@ -127,7 +127,7 @@ get_rewrite_oid(Oid relid, const char *rulename, bool missing_ok)
* Find rule oid, given only a rule name but no rel OID.
*
* If there's more than one, it's an error. If there aren't any, that's an
- * error, too. In general, this should be avoided - it is provided to support
+ * error, too. In general, this should be avoided - it is provided to support
* syntax that is compatible with pre-7.3 versions of PG, where rule names
* were unique across the entire database.
*/
diff --git a/src/backend/storage/buffer/bufmgr.c b/src/backend/storage/buffer/bufmgr.c
index 1f89e52705..f96685db50 100644
--- a/src/backend/storage/buffer/bufmgr.c
+++ b/src/backend/storage/buffer/bufmgr.c
@@ -644,17 +644,17 @@ BufferAlloc(SMgrRelation smgr, char relpersistence, ForkNumber forkNum,
/* OK, do the I/O */
TRACE_POSTGRESQL_BUFFER_WRITE_DIRTY_START(forkNum, blockNum,
- smgr->smgr_rnode.node.spcNode,
- smgr->smgr_rnode.node.dbNode,
- smgr->smgr_rnode.node.relNode);
+ smgr->smgr_rnode.node.spcNode,
+ smgr->smgr_rnode.node.dbNode,
+ smgr->smgr_rnode.node.relNode);
FlushBuffer(buf, NULL);
LWLockRelease(buf->content_lock);
TRACE_POSTGRESQL_BUFFER_WRITE_DIRTY_DONE(forkNum, blockNum,
- smgr->smgr_rnode.node.spcNode,
- smgr->smgr_rnode.node.dbNode,
- smgr->smgr_rnode.node.relNode);
+ smgr->smgr_rnode.node.spcNode,
+ smgr->smgr_rnode.node.dbNode,
+ smgr->smgr_rnode.node.relNode);
}
else
{
@@ -2029,7 +2029,7 @@ PrintBufferDescs(void)
"[%02d] (freeNext=%d, rel=%s, "
"blockNum=%u, flags=0x%x, refcount=%u %d)",
i, buf->freeNext,
- relpathbackend(buf->tag.rnode, InvalidBackendId, buf->tag.forkNum),
+ relpathbackend(buf->tag.rnode, InvalidBackendId, buf->tag.forkNum),
buf->tag.blockNum, buf->flags,
buf->refcount, PrivateRefCount[i]);
}
@@ -2765,7 +2765,7 @@ local_buffer_write_error_callback(void *arg)
if (bufHdr != NULL)
{
char *path = relpathbackend(bufHdr->tag.rnode, MyBackendId,
- bufHdr->tag.forkNum);
+ bufHdr->tag.forkNum);
errcontext("writing block %u of relation %s",
bufHdr->tag.blockNum, path);
diff --git a/src/backend/storage/buffer/freelist.c b/src/backend/storage/buffer/freelist.c
index 72968db026..bf9903b9f3 100644
--- a/src/backend/storage/buffer/freelist.c
+++ b/src/backend/storage/buffer/freelist.c
@@ -77,7 +77,7 @@ typedef struct BufferAccessStrategyData
* struct.
*/
Buffer buffers[1]; /* VARIABLE SIZE ARRAY */
-} BufferAccessStrategyData;
+} BufferAccessStrategyData;
/* Prototypes for internal functions */
diff --git a/src/backend/storage/buffer/localbuf.c b/src/backend/storage/buffer/localbuf.c
index 0a01ed544e..8816a5dfab 100644
--- a/src/backend/storage/buffer/localbuf.c
+++ b/src/backend/storage/buffer/localbuf.c
@@ -150,8 +150,8 @@ LocalBufferAlloc(SMgrRelation smgr, ForkNumber forkNum, BlockNumber blockNum,
#ifdef LBDEBUG
fprintf(stderr, "LB ALLOC (%u,%d,%d) %d\n",
- smgr->smgr_rnode.node.relNode, forkNum, blockNum,
- -nextFreeLocalBuf - 1);
+ smgr->smgr_rnode.node.relNode, forkNum, blockNum,
+ -nextFreeLocalBuf - 1);
#endif
/*
@@ -311,7 +311,7 @@ DropRelFileNodeLocalBuffers(RelFileNode rnode, ForkNumber forkNum,
elog(ERROR, "block %u of %s is still referenced (local %u)",
bufHdr->tag.blockNum,
relpathbackend(bufHdr->tag.rnode, MyBackendId,
- bufHdr->tag.forkNum),
+ bufHdr->tag.forkNum),
LocalRefCount[i]);
/* Remove entry from hashtable */
hresult = (LocalBufferLookupEnt *)
@@ -413,7 +413,7 @@ GetLocalBufferStorage(void)
/*
* We allocate local buffers in a context of their own, so that the
* space eaten for them is easily recognizable in MemoryContextStats
- * output. Create the context on first use.
+ * output. Create the context on first use.
*/
if (LocalBufferContext == NULL)
LocalBufferContext =
diff --git a/src/backend/storage/file/fd.c b/src/backend/storage/file/fd.c
index bdb97b2ad1..11bab38280 100644
--- a/src/backend/storage/file/fd.c
+++ b/src/backend/storage/file/fd.c
@@ -1063,15 +1063,15 @@ FileClose(File file)
* If we get an error, as could happen within the ereport/elog calls,
* we'll come right back here during transaction abort. Reset the
* flag to ensure that we can't get into an infinite loop. This code
- * is arranged to ensure that the worst-case consequence is failing
- * to emit log message(s), not failing to attempt the unlink.
+ * is arranged to ensure that the worst-case consequence is failing to
+ * emit log message(s), not failing to attempt the unlink.
*/
vfdP->fdstate &= ~FD_TEMPORARY;
if (log_temp_files >= 0)
{
struct stat filestats;
- int stat_errno;
+ int stat_errno;
/* first try the stat() */
if (stat(vfdP->fileName, &filestats))
@@ -1900,7 +1900,7 @@ RemovePgTempFiles(void)
RemovePgTempFilesInDir(temp_path);
snprintf(temp_path, sizeof(temp_path), "pg_tblspc/%s/%s",
- spc_de->d_name, TABLESPACE_VERSION_DIRECTORY);
+ spc_de->d_name, TABLESPACE_VERSION_DIRECTORY);
RemovePgTempRelationFiles(temp_path);
}
@@ -1977,7 +1977,7 @@ RemovePgTempRelationFiles(const char *tsdirname)
while ((de = ReadDir(ts_dir, tsdirname)) != NULL)
{
- int i = 0;
+ int i = 0;
/*
* We're only interested in the per-database directories, which have
@@ -2023,7 +2023,7 @@ RemovePgTempRelationFilesInDbspace(const char *dbspacedirname)
snprintf(rm_path, sizeof(rm_path), "%s/%s",
dbspacedirname, de->d_name);
- unlink(rm_path); /* note we ignore any error */
+ unlink(rm_path); /* note we ignore any error */
}
FreeDir(dbspace_dir);
@@ -2055,15 +2055,17 @@ looks_like_temp_rel_name(const char *name)
/* We might have _forkname or .segment or both. */
if (name[pos] == '_')
{
- int forkchar = forkname_chars(&name[pos+1], NULL);
+ int forkchar = forkname_chars(&name[pos + 1], NULL);
+
if (forkchar <= 0)
return false;
pos += forkchar + 1;
}
if (name[pos] == '.')
{
- int segchar;
- for (segchar = 1; isdigit((unsigned char) name[pos+segchar]); ++segchar)
+ int segchar;
+
+ for (segchar = 1; isdigit((unsigned char) name[pos + segchar]); ++segchar)
;
if (segchar <= 1)
return false;
diff --git a/src/backend/storage/file/reinit.c b/src/backend/storage/file/reinit.c
index 54fde73de8..837ab90c8d 100644
--- a/src/backend/storage/file/reinit.c
+++ b/src/backend/storage/file/reinit.c
@@ -24,14 +24,15 @@
#include "utils/memutils.h"
static void ResetUnloggedRelationsInTablespaceDir(const char *tsdirname,
- int op);
+ int op);
static void ResetUnloggedRelationsInDbspaceDir(const char *dbspacedirname,
int op);
static bool parse_filename_for_nontemp_relation(const char *name,
int *oidchars, ForkNumber *fork);
-typedef struct {
- char oid[OIDCHARS+1];
+typedef struct
+{
+ char oid[OIDCHARS + 1];
} unlogged_relation_entry;
/*
@@ -49,13 +50,14 @@ ResetUnloggedRelations(int op)
char temp_path[MAXPGPATH];
DIR *spc_dir;
struct dirent *spc_de;
- MemoryContext tmpctx, oldctx;
+ MemoryContext tmpctx,
+ oldctx;
/* Log it. */
ereport(DEBUG1,
(errmsg("resetting unlogged relations: cleanup %d init %d",
- (op & UNLOGGED_RELATION_CLEANUP) != 0,
- (op & UNLOGGED_RELATION_INIT) != 0)));
+ (op & UNLOGGED_RELATION_CLEANUP) != 0,
+ (op & UNLOGGED_RELATION_INIT) != 0)));
/*
* Just to be sure we don't leak any memory, let's create a temporary
@@ -85,7 +87,7 @@ ResetUnloggedRelations(int op)
continue;
snprintf(temp_path, sizeof(temp_path), "pg_tblspc/%s/%s",
- spc_de->d_name, TABLESPACE_VERSION_DIRECTORY);
+ spc_de->d_name, TABLESPACE_VERSION_DIRECTORY);
ResetUnloggedRelationsInTablespaceDir(temp_path, op);
}
@@ -119,7 +121,7 @@ ResetUnloggedRelationsInTablespaceDir(const char *tsdirname, int op)
while ((de = ReadDir(ts_dir, tsdirname)) != NULL)
{
- int i = 0;
+ int i = 0;
/*
* We're only interested in the per-database directories, which have
@@ -184,8 +186,8 @@ ResetUnloggedRelationsInDbspaceDir(const char *dbspacedirname, int op)
/* Scan the directory. */
while ((de = ReadDir(dbspace_dir, dbspacedirname)) != NULL)
{
- ForkNumber forkNum;
- int oidchars;
+ ForkNumber forkNum;
+ int oidchars;
unlogged_relation_entry ent;
/* Skip anything that doesn't look like a relation data file. */
@@ -198,8 +200,8 @@ ResetUnloggedRelationsInDbspaceDir(const char *dbspacedirname, int op)
continue;
/*
- * Put the OID portion of the name into the hash table, if it isn't
- * already.
+ * Put the OID portion of the name into the hash table, if it
+ * isn't already.
*/
memset(ent.oid, 0, sizeof(ent.oid));
memcpy(ent.oid, de->d_name, oidchars);
@@ -236,9 +238,9 @@ ResetUnloggedRelationsInDbspaceDir(const char *dbspacedirname, int op)
/* Scan the directory. */
while ((de = ReadDir(dbspace_dir, dbspacedirname)) != NULL)
{
- ForkNumber forkNum;
- int oidchars;
- bool found;
+ ForkNumber forkNum;
+ int oidchars;
+ bool found;
unlogged_relation_entry ent;
/* Skip anything that doesn't look like a relation data file. */
@@ -262,7 +264,8 @@ ResetUnloggedRelationsInDbspaceDir(const char *dbspacedirname, int op)
if (found)
{
snprintf(rm_path, sizeof(rm_path), "%s/%s",
- dbspacedirname, de->d_name);
+ dbspacedirname, de->d_name);
+
/*
* It's tempting to actually throw an error here, but since
* this code gets run during database startup, that could
@@ -284,9 +287,9 @@ ResetUnloggedRelationsInDbspaceDir(const char *dbspacedirname, int op)
/*
* Initialization happens after cleanup is complete: we copy each init
* fork file to the corresponding main fork file. Note that if we are
- * asked to do both cleanup and init, we may never get here: if the cleanup
- * code determines that there are no init forks in this dbspace, it will
- * return before we get to this point.
+ * asked to do both cleanup and init, we may never get here: if the
+ * cleanup code determines that there are no init forks in this dbspace,
+ * it will return before we get to this point.
*/
if ((op & UNLOGGED_RELATION_INIT) != 0)
{
@@ -304,11 +307,11 @@ ResetUnloggedRelationsInDbspaceDir(const char *dbspacedirname, int op)
/* Scan the directory. */
while ((de = ReadDir(dbspace_dir, dbspacedirname)) != NULL)
{
- ForkNumber forkNum;
- int oidchars;
- char oidbuf[OIDCHARS+1];
- char srcpath[MAXPGPATH];
- char dstpath[MAXPGPATH];
+ ForkNumber forkNum;
+ int oidchars;
+ char oidbuf[OIDCHARS + 1];
+ char srcpath[MAXPGPATH];
+ char dstpath[MAXPGPATH];
/* Skip anything that doesn't look like a relation data file. */
if (!parse_filename_for_nontemp_relation(de->d_name, &oidchars,
@@ -370,9 +373,9 @@ parse_filename_for_nontemp_relation(const char *name, int *oidchars,
*fork = MAIN_FORKNUM;
else
{
- int forkchar;
+ int forkchar;
- forkchar = forkname_chars(&name[pos+1], fork);
+ forkchar = forkname_chars(&name[pos + 1], fork);
if (forkchar <= 0)
return false;
pos += forkchar + 1;
@@ -381,8 +384,9 @@ parse_filename_for_nontemp_relation(const char *name, int *oidchars,
/* Check for a segment number. */
if (name[pos] == '.')
{
- int segchar;
- for (segchar = 1; isdigit((unsigned char) name[pos+segchar]); ++segchar)
+ int segchar;
+
+ for (segchar = 1; isdigit((unsigned char) name[pos + segchar]); ++segchar)
;
if (segchar <= 1)
return false;
diff --git a/src/backend/storage/ipc/pmsignal.c b/src/backend/storage/ipc/pmsignal.c
index 391d6a6ea0..306e3f9a21 100644
--- a/src/backend/storage/ipc/pmsignal.c
+++ b/src/backend/storage/ipc/pmsignal.c
@@ -279,7 +279,7 @@ PostmasterIsAlive(bool amDirectChild)
#ifndef WIN32
if (amDirectChild)
{
- pid_t ppid = getppid();
+ pid_t ppid = getppid();
/* If the postmaster is still our parent, it must be alive. */
if (ppid == PostmasterPid)
@@ -297,10 +297,10 @@ PostmasterIsAlive(bool amDirectChild)
}
/*
- * Use kill() to see if the postmaster is still alive. This can
- * sometimes give a false positive result, since the postmaster's PID
- * may get recycled, but it is good enough for existing uses by
- * indirect children and in debugging environments.
+ * Use kill() to see if the postmaster is still alive. This can sometimes
+ * give a false positive result, since the postmaster's PID may get
+ * recycled, but it is good enough for existing uses by indirect children
+ * and in debugging environments.
*/
return (kill(PostmasterPid, 0) == 0);
#else /* WIN32 */
diff --git a/src/backend/storage/ipc/procarray.c b/src/backend/storage/ipc/procarray.c
index 65fca7171a..e7593fa2eb 100644
--- a/src/backend/storage/ipc/procarray.c
+++ b/src/backend/storage/ipc/procarray.c
@@ -475,10 +475,10 @@ ProcArrayApplyRecoveryInfo(RunningTransactions running)
return;
/*
- * If our initial RunningTransactionsData had an overflowed snapshot then we knew
- * we were missing some subxids from our snapshot. We can use this data as
- * an initial snapshot, but we cannot yet mark it valid. We know that the
- * missing subxids are equal to or earlier than nextXid. After we
+ * If our initial RunningTransactionsData had an overflowed snapshot then
+ * we knew we were missing some subxids from our snapshot. We can use this
+ * data as an initial snapshot, but we cannot yet mark it valid. We know
+ * that the missing subxids are equal to or earlier than nextXid. After we
* initialise we continue to apply changes during recovery, so once the
* oldestRunningXid is later than the nextXid from the initial snapshot we
* know that we no longer have missing information and can mark the
@@ -510,8 +510,8 @@ ProcArrayApplyRecoveryInfo(RunningTransactions running)
*/
/*
- * Release any locks belonging to old transactions that are not
- * running according to the running-xacts record.
+ * Release any locks belonging to old transactions that are not running
+ * according to the running-xacts record.
*/
StandbyReleaseOldLocks(running->nextXid);
@@ -582,9 +582,8 @@ ProcArrayApplyRecoveryInfo(RunningTransactions running)
* Now we've got the running xids we need to set the global values that
* are used to track snapshots as they evolve further.
*
- * - latestCompletedXid which will be the xmax for snapshots
- * - lastOverflowedXid which shows whether snapshots overflow
- * - nextXid
+ * - latestCompletedXid which will be the xmax for snapshots -
+ * lastOverflowedXid which shows whether snapshots overflow - nextXid
*
* If the snapshot overflowed, then we still initialise with what we know,
* but the recovery snapshot isn't fully valid yet because we know there
@@ -611,9 +610,8 @@ ProcArrayApplyRecoveryInfo(RunningTransactions running)
/*
* If a transaction wrote a commit record in the gap between taking and
- * logging the snapshot then latestCompletedXid may already be higher
- * than the value from the snapshot, so check before we use the incoming
- * value.
+ * logging the snapshot then latestCompletedXid may already be higher than
+ * the value from the snapshot, so check before we use the incoming value.
*/
if (TransactionIdPrecedes(ShmemVariableCache->latestCompletedXid,
running->latestCompletedXid))
@@ -1048,7 +1046,7 @@ GetOldestXmin(bool allDbs, bool ignoreVacuum)
if (allDbs ||
proc->databaseId == MyDatabaseId ||
- proc->databaseId == 0) /* include WalSender */
+ proc->databaseId == 0) /* include WalSender */
{
/* Fetch xid just once - see GetNewTransactionId */
TransactionId xid = proc->xid;
@@ -1075,8 +1073,8 @@ GetOldestXmin(bool allDbs, bool ignoreVacuum)
if (RecoveryInProgress())
{
/*
- * Check to see whether KnownAssignedXids contains an xid value
- * older than the main procarray.
+ * Check to see whether KnownAssignedXids contains an xid value older
+ * than the main procarray.
*/
TransactionId kaxmin = KnownAssignedXidsGetOldestXmin();
@@ -1084,7 +1082,7 @@ GetOldestXmin(bool allDbs, bool ignoreVacuum)
if (TransactionIdIsNormal(kaxmin) &&
TransactionIdPrecedes(kaxmin, result))
- result = kaxmin;
+ result = kaxmin;
}
else
{
@@ -1100,9 +1098,9 @@ GetOldestXmin(bool allDbs, bool ignoreVacuum)
* vacuum_defer_cleanup_age provides some additional "slop" for the
* benefit of hot standby queries on slave servers. This is quick and
* dirty, and perhaps not all that useful unless the master has a
- * predictable transaction rate, but it's what we've got. Note that we
- * are assuming vacuum_defer_cleanup_age isn't large enough to cause
- * wraparound --- so guc.c should limit it to no more than the
+ * predictable transaction rate, but it's what we've got. Note that
+ * we are assuming vacuum_defer_cleanup_age isn't large enough to
+ * cause wraparound --- so guc.c should limit it to no more than the
* xidStopLimit threshold in varsup.c.
*/
result -= vacuum_defer_cleanup_age;
@@ -1483,9 +1481,9 @@ GetRunningTransactionData(void)
suboverflowed = true;
/*
- * Top-level XID of a transaction is always less than any of
- * its subxids, so we don't need to check if any of the subxids
- * are smaller than oldestRunningXid
+ * Top-level XID of a transaction is always less than any of its
+ * subxids, so we don't need to check if any of the subxids are
+ * smaller than oldestRunningXid
*/
}
}
diff --git a/src/backend/storage/ipc/standby.c b/src/backend/storage/ipc/standby.c
index 2e71484126..3fdb5184a9 100644
--- a/src/backend/storage/ipc/standby.c
+++ b/src/backend/storage/ipc/standby.c
@@ -193,7 +193,7 @@ ResolveRecoveryConflictWithVirtualXIDs(VirtualTransactionId *waitlist,
return;
waitStart = GetCurrentTimestamp();
- new_status = NULL; /* we haven't changed the ps display */
+ new_status = NULL; /* we haven't changed the ps display */
while (VirtualTransactionIdIsValid(*waitlist))
{
@@ -963,14 +963,14 @@ void
LogAccessExclusiveLockPrepare(void)
{
/*
- * Ensure that a TransactionId has been assigned to this transaction,
- * for two reasons, both related to lock release on the standby.
- * First, we must assign an xid so that RecordTransactionCommit() and
+ * Ensure that a TransactionId has been assigned to this transaction, for
+ * two reasons, both related to lock release on the standby. First, we
+ * must assign an xid so that RecordTransactionCommit() and
* RecordTransactionAbort() do not optimise away the transaction
- * completion record which recovery relies upon to release locks. It's
- * a hack, but for a corner case not worth adding code for into the
- * main commit path. Second, must must assign an xid before the lock
- * is recorded in shared memory, otherwise a concurrently executing
+ * completion record which recovery relies upon to release locks. It's a
+ * hack, but for a corner case not worth adding code for into the main
+ * commit path. Second, must must assign an xid before the lock is
+ * recorded in shared memory, otherwise a concurrently executing
* GetRunningTransactionLocks() might see a lock associated with an
* InvalidTransactionId which we later assert cannot happen.
*/
diff --git a/src/backend/storage/large_object/inv_api.c b/src/backend/storage/large_object/inv_api.c
index 01e3492cb8..e0441f5bf1 100644
--- a/src/backend/storage/large_object/inv_api.c
+++ b/src/backend/storage/large_object/inv_api.c
@@ -844,8 +844,8 @@ inv_truncate(LargeObjectDesc *obj_desc, int len)
{
/*
* If the first page we found was after the truncation point, we're in
- * a hole that we'll fill, but we need to delete the later page because
- * the loop below won't visit it again.
+ * a hole that we'll fill, but we need to delete the later page
+ * because the loop below won't visit it again.
*/
if (olddata != NULL)
{
diff --git a/src/backend/storage/lmgr/lock.c b/src/backend/storage/lmgr/lock.c
index ed0ea1205f..3fbe14a409 100644
--- a/src/backend/storage/lmgr/lock.c
+++ b/src/backend/storage/lmgr/lock.c
@@ -586,7 +586,8 @@ LockAcquireExtended(const LOCKTAG *locktag,
* standby server. Only AccessExclusiveLocks can conflict with lock types
* that read-only transactions can acquire in a standby server.
*
- * Make sure this definition matches the one in GetRunningTransactionLocks().
+ * Make sure this definition matches the one in
+ * GetRunningTransactionLocks().
*
* First we prepare to log, then after lock acquired we issue log record.
*/
diff --git a/src/backend/storage/lmgr/predicate.c b/src/backend/storage/lmgr/predicate.c
index 7978bef996..72385c2f3e 100644
--- a/src/backend/storage/lmgr/predicate.c
+++ b/src/backend/storage/lmgr/predicate.c
@@ -327,7 +327,7 @@ typedef struct OldSerXidControlData
TransactionId headXid; /* newest valid Xid in the SLRU */
TransactionId tailXid; /* oldest xmin we might be interested in */
bool warningIssued;
-} OldSerXidControlData;
+} OldSerXidControlData;
typedef struct OldSerXidControlData *OldSerXidControl;
@@ -477,7 +477,7 @@ ReleasePredXact(SERIALIZABLEXACT *sxact)
ptle = (PredXactListElement)
(((char *) sxact)
- offsetof(PredXactListElementData, sxact)
- +offsetof(PredXactListElementData, link));
+ + offsetof(PredXactListElementData, link));
SHMQueueDelete(&ptle->link);
SHMQueueInsertBefore(&PredXact->availableList, &ptle->link);
}
@@ -507,7 +507,7 @@ NextPredXact(SERIALIZABLEXACT *sxact)
ptle = (PredXactListElement)
(((char *) sxact)
- offsetof(PredXactListElementData, sxact)
- +offsetof(PredXactListElementData, link));
+ + offsetof(PredXactListElementData, link));
ptle = (PredXactListElement)
SHMQueueNext(&PredXact->activeList,
&ptle->link,
@@ -746,10 +746,10 @@ OldSerXidAdd(TransactionId xid, SerCommitSeqNo minConflictCommitSeqNo)
Assert(TransactionIdIsValid(tailXid));
/*
- * If the SLRU is currently unused, zero out the whole active region
- * from tailXid to headXid before taking it into use. Otherwise zero
- * out only any new pages that enter the tailXid-headXid range as we
- * advance headXid.
+ * If the SLRU is currently unused, zero out the whole active region from
+ * tailXid to headXid before taking it into use. Otherwise zero out only
+ * any new pages that enter the tailXid-headXid range as we advance
+ * headXid.
*/
if (oldSerXidControl->headPage < 0)
{
@@ -855,8 +855,8 @@ OldSerXidSetActiveSerXmin(TransactionId xid)
/*
* When no sxacts are active, nothing overlaps, set the xid values to
* invalid to show that there are no valid entries. Don't clear headPage,
- * though. A new xmin might still land on that page, and we don't want
- * to repeatedly zero out the same page.
+ * though. A new xmin might still land on that page, and we don't want to
+ * repeatedly zero out the same page.
*/
if (!TransactionIdIsValid(xid))
{
@@ -901,7 +901,7 @@ OldSerXidSetActiveSerXmin(TransactionId xid)
void
CheckPointPredicate(void)
{
- int tailPage;
+ int tailPage;
LWLockAcquire(OldSerXidLock, LW_EXCLUSIVE);
@@ -921,16 +921,15 @@ CheckPointPredicate(void)
{
/*
* The SLRU is no longer needed. Truncate everything. If we try to
- * leave the head page around to avoid re-zeroing it, we might not
- * use the SLRU again until we're past the wrap-around point, which
- * makes SLRU unhappy.
+ * leave the head page around to avoid re-zeroing it, we might not use
+ * the SLRU again until we're past the wrap-around point, which makes
+ * SLRU unhappy.
*
* While the API asks you to specify truncation by page, it silently
- * ignores the request unless the specified page is in a segment
- * past some allocated portion of the SLRU. We don't care which
- * page in a later segment we hit, so just add the number of pages
- * per segment to the head page to land us *somewhere* in the next
- * segment.
+ * ignores the request unless the specified page is in a segment past
+ * some allocated portion of the SLRU. We don't care which page in a
+ * later segment we hit, so just add the number of pages per segment
+ * to the head page to land us *somewhere* in the next segment.
*/
tailPage = oldSerXidControl->headPage + SLRU_PAGES_PER_SEGMENT;
oldSerXidControl->headPage = -1;
@@ -1329,12 +1328,12 @@ SummarizeOldestCommittedSxact(void)
/*
* This function is only called if there are no sxact slots available.
* Some of them must belong to old, already-finished transactions, so
- * there should be something in FinishedSerializableTransactions list
- * that we can summarize. However, there's a race condition: while we
- * were not holding any locks, a transaction might have ended and cleaned
- * up all the finished sxact entries already, freeing up their sxact
- * slots. In that case, we have nothing to do here. The caller will find
- * one of the slots released by the other backend when it retries.
+ * there should be something in FinishedSerializableTransactions list that
+ * we can summarize. However, there's a race condition: while we were not
+ * holding any locks, a transaction might have ended and cleaned up all
+ * the finished sxact entries already, freeing up their sxact slots. In
+ * that case, we have nothing to do here. The caller will find one of the
+ * slots released by the other backend when it retries.
*/
if (SHMQueueEmpty(FinishedSerializableTransactions))
{
@@ -2213,7 +2212,7 @@ PredicateLockTuple(const Relation relation, const HeapTuple tuple)
*/
if (relation->rd_index == NULL)
{
- TransactionId myxid;
+ TransactionId myxid;
targetxmin = HeapTupleHeaderGetXmin(tuple->t_data);
@@ -2223,6 +2222,7 @@ PredicateLockTuple(const Relation relation, const HeapTuple tuple)
if (TransactionIdFollowsOrEquals(targetxmin, TransactionXmin))
{
TransactionId xid = SubTransGetTopmostTransaction(targetxmin);
+
if (TransactionIdEquals(xid, myxid))
{
/* We wrote it; we already have a write lock. */
@@ -2272,7 +2272,7 @@ PredicateLockTupleRowVersionLink(const Relation relation,
PREDICATELOCKTARGETTAG oldtupletag;
PREDICATELOCKTARGETTAG oldpagetag;
PREDICATELOCKTARGETTAG newtupletag;
- BlockNumber oldblk,
+ BlockNumber oldblk,
newblk;
OffsetNumber oldoff,
newoff;
@@ -2308,10 +2308,10 @@ PredicateLockTupleRowVersionLink(const Relation relation,
/*
* A page-level lock on the page containing the old tuple counts too.
- * Anyone holding a lock on the page is logically holding a lock on
- * the old tuple, so we need to acquire a lock on his behalf on the
- * new tuple too. However, if the new tuple is on the same page as the
- * old one, the old page-level lock already covers the new tuple.
+ * Anyone holding a lock on the page is logically holding a lock on the
+ * old tuple, so we need to acquire a lock on his behalf on the new tuple
+ * too. However, if the new tuple is on the same page as the old one, the
+ * old page-level lock already covers the new tuple.
*
* A relation-level lock always covers both tuple versions, so we don't
* need to worry about those here.
@@ -2668,10 +2668,10 @@ PredicateLockPageSplit(const Relation relation, const BlockNumber oldblkno,
/*
* Move the locks to the parent. This shouldn't fail.
*
- * Note that here we are removing locks held by other
- * backends, leading to a possible inconsistency in their
- * local lock hash table. This is OK because we're replacing
- * it with a lock that covers the old one.
+ * Note that here we are removing locks held by other backends,
+ * leading to a possible inconsistency in their local lock hash table.
+ * This is OK because we're replacing it with a lock that covers the
+ * old one.
*/
success = TransferPredicateLocksToNewTarget(oldtargettag,
newtargettag,
@@ -2696,16 +2696,15 @@ PredicateLockPageCombine(const Relation relation, const BlockNumber oldblkno,
const BlockNumber newblkno)
{
/*
- * Page combines differ from page splits in that we ought to be
- * able to remove the locks on the old page after transferring
- * them to the new page, instead of duplicating them. However,
- * because we can't edit other backends' local lock tables,
- * removing the old lock would leave them with an entry in their
- * LocalPredicateLockHash for a lock they're not holding, which
- * isn't acceptable. So we wind up having to do the same work as a
- * page split, acquiring a lock on the new page and keeping the old
- * page locked too. That can lead to some false positives, but
- * should be rare in practice.
+ * Page combines differ from page splits in that we ought to be able to
+ * remove the locks on the old page after transferring them to the new
+ * page, instead of duplicating them. However, because we can't edit other
+ * backends' local lock tables, removing the old lock would leave them
+ * with an entry in their LocalPredicateLockHash for a lock they're not
+ * holding, which isn't acceptable. So we wind up having to do the same
+ * work as a page split, acquiring a lock on the new page and keeping the
+ * old page locked too. That can lead to some false positives, but should
+ * be rare in practice.
*/
PredicateLockPageSplit(relation, oldblkno, newblkno);
}
@@ -3652,15 +3651,15 @@ CheckTargetForConflictsIn(PREDICATELOCKTARGETTAG *targettag)
/*
* If we're getting a write lock on the tuple and we're not in a
* subtransaction, we don't need a predicate (SIREAD) lock. We
- * can't use this optimization within a subtransaction because
- * the subtransaction could be rolled back, and we would be left
+ * can't use this optimization within a subtransaction because the
+ * subtransaction could be rolled back, and we would be left
* without any lock at the top level.
- *
+ *
* At this point our transaction already has an ExclusiveRowLock
- * on the relation, so we are OK to drop the predicate lock on
- * the tuple, if found, without fearing that another write
- * against the tuple will occur before the MVCC information
- * makes it to the buffer.
+ * on the relation, so we are OK to drop the predicate lock on the
+ * tuple, if found, without fearing that another write against the
+ * tuple will occur before the MVCC information makes it to the
+ * buffer.
*/
if (!IsSubTransaction()
&& GET_PREDICATELOCKTARGETTAG_OFFSET(*targettag))
@@ -3722,8 +3721,8 @@ CheckTargetForConflictsIn(PREDICATELOCKTARGETTAG *targettag)
/*
* Remove entry in local lock table if it exists and has
* no children. It's OK if it doesn't exist; that means
- * the lock was transferred to a new target by a
- * different backend.
+ * the lock was transferred to a new target by a different
+ * backend.
*/
if (locallock != NULL)
{
@@ -3733,8 +3732,8 @@ CheckTargetForConflictsIn(PREDICATELOCKTARGETTAG *targettag)
{
rmlocallock = (LOCALPREDICATELOCK *)
hash_search_with_hash_value(LocalPredicateLockHash,
- targettag, targettaghash,
- HASH_REMOVE, NULL);
+ targettag, targettaghash,
+ HASH_REMOVE, NULL);
Assert(rmlocallock == locallock);
}
}
@@ -3772,9 +3771,9 @@ CheckTargetForConflictsIn(PREDICATELOCKTARGETTAG *targettag)
LWLockAcquire(partitionLock, LW_SHARED);
/*
- * The list may have been altered by another process
- * while we weren't holding the partition lock. Start
- * over at the front.
+ * The list may have been altered by another process while
+ * we weren't holding the partition lock. Start over at
+ * the front.
*/
nextpredlock = (PREDICATELOCK *)
SHMQueueNext(&(target->predicateLocks),
@@ -3862,8 +3861,8 @@ CheckForSerializableConflictIn(const Relation relation, const HeapTuple tuple,
relation->rd_node.dbNode,
relation->rd_id,
ItemPointerGetBlockNumber(&(tuple->t_data->t_ctid)),
- ItemPointerGetOffsetNumber(&(tuple->t_data->t_ctid)),
- HeapTupleHeaderGetXmin(tuple->t_data));
+ ItemPointerGetOffsetNumber(&(tuple->t_data->t_ctid)),
+ HeapTupleHeaderGetXmin(tuple->t_data));
CheckTargetForConflictsIn(&targettag);
}
diff --git a/src/backend/storage/smgr/md.c b/src/backend/storage/smgr/md.c
index 9d585b6fea..6f8866836d 100644
--- a/src/backend/storage/smgr/md.c
+++ b/src/backend/storage/smgr/md.c
@@ -938,7 +938,7 @@ mdsync(void)
int processed = 0;
instr_time sync_start,
sync_end,
- sync_diff;
+ sync_diff;
uint64 elapsed;
uint64 longest = 0;
uint64 total_elapsed = 0;
@@ -1094,7 +1094,7 @@ mdsync(void)
if (seg != NULL &&
FileSync(seg->mdfd_vfd) >= 0)
{
- if (log_checkpoints && (! INSTR_TIME_IS_ZERO(sync_start)))
+ if (log_checkpoints && (!INSTR_TIME_IS_ZERO(sync_start)))
{
INSTR_TIME_SET_CURRENT(sync_end);
sync_diff = sync_end;
@@ -1104,8 +1104,8 @@ mdsync(void)
longest = elapsed;
total_elapsed += elapsed;
processed++;
- elog(DEBUG1, "checkpoint sync: number=%d file=%s time=%.3f msec",
- processed, FilePathName(seg->mdfd_vfd), (double) elapsed / 1000);
+ elog(DEBUG1, "checkpoint sync: number=%d file=%s time=%.3f msec",
+ processed, FilePathName(seg->mdfd_vfd), (double) elapsed / 1000);
}
break; /* success; break out of retry loop */
@@ -1268,7 +1268,7 @@ register_dirty_segment(SMgrRelation reln, ForkNumber forknum, MdfdVec *seg)
return; /* passed it off successfully */
ereport(DEBUG1,
- (errmsg("could not forward fsync request because request queue is full")));
+ (errmsg("could not forward fsync request because request queue is full")));
if (FileSync(seg->mdfd_vfd) < 0)
ereport(ERROR,
diff --git a/src/backend/storage/smgr/smgr.c b/src/backend/storage/smgr/smgr.c
index 82bf232645..a6610bf4f8 100644
--- a/src/backend/storage/smgr/smgr.c
+++ b/src/backend/storage/smgr/smgr.c
@@ -48,16 +48,16 @@ typedef struct f_smgr
void (*smgr_unlink) (RelFileNodeBackend rnode, ForkNumber forknum,
bool isRedo);
void (*smgr_extend) (SMgrRelation reln, ForkNumber forknum,
- BlockNumber blocknum, char *buffer, bool skipFsync);
+ BlockNumber blocknum, char *buffer, bool skipFsync);
void (*smgr_prefetch) (SMgrRelation reln, ForkNumber forknum,
BlockNumber blocknum);
void (*smgr_read) (SMgrRelation reln, ForkNumber forknum,
BlockNumber blocknum, char *buffer);
void (*smgr_write) (SMgrRelation reln, ForkNumber forknum,
- BlockNumber blocknum, char *buffer, bool skipFsync);
+ BlockNumber blocknum, char *buffer, bool skipFsync);
BlockNumber (*smgr_nblocks) (SMgrRelation reln, ForkNumber forknum);
void (*smgr_truncate) (SMgrRelation reln, ForkNumber forknum,
- BlockNumber nblocks);
+ BlockNumber nblocks);
void (*smgr_immedsync) (SMgrRelation reln, ForkNumber forknum);
void (*smgr_pre_ckpt) (void); /* may be NULL */
void (*smgr_sync) (void); /* may be NULL */
diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c
index cc7945aeb6..805514b07b 100644
--- a/src/backend/tcop/postgres.c
+++ b/src/backend/tcop/postgres.c
@@ -1555,7 +1555,7 @@ exec_bind_message(StringInfo input_message)
/* sizeof(ParamListInfoData) includes the first array element */
params = (ParamListInfo) palloc(sizeof(ParamListInfoData) +
- (numParams - 1) *sizeof(ParamExternData));
+ (numParams - 1) * sizeof(ParamExternData));
/* we have static list of params, so no hooks needed */
params->paramFetch = NULL;
params->paramFetchArg = NULL;
@@ -2982,17 +2982,16 @@ ia64_get_bsp(void)
#ifndef __INTEL_COMPILER
/* the ;; is a "stop", seems to be required before fetching BSP */
- __asm__ __volatile__(
- ";;\n"
- " mov %0=ar.bsp \n"
-: "=r"(ret));
+ __asm__ __volatile__(
+ ";;\n"
+ " mov %0=ar.bsp \n"
+ : "=r"(ret));
#else
- ret = (char *) __getReg(_IA64_REG_AR_BSP);
+ ret = (char *) __getReg(_IA64_REG_AR_BSP);
#endif
- return ret;
+ return ret;
}
-
-#endif /* IA64 */
+#endif /* IA64 */
/*
@@ -3035,7 +3034,7 @@ check_stack_depth(void)
(errcode(ERRCODE_STATEMENT_TOO_COMPLEX),
errmsg("stack depth limit exceeded"),
errhint("Increase the configuration parameter \"max_stack_depth\" (currently %dkB), "
- "after ensuring the platform's stack depth limit is adequate.",
+ "after ensuring the platform's stack depth limit is adequate.",
max_stack_depth)));
}
@@ -3057,10 +3056,10 @@ check_stack_depth(void)
(errcode(ERRCODE_STATEMENT_TOO_COMPLEX),
errmsg("stack depth limit exceeded"),
errhint("Increase the configuration parameter \"max_stack_depth\" (currently %dkB), "
- "after ensuring the platform's stack depth limit is adequate.",
+ "after ensuring the platform's stack depth limit is adequate.",
max_stack_depth)));
}
-#endif /* IA64 */
+#endif /* IA64 */
}
/* GUC check hook for max_stack_depth */
diff --git a/src/backend/tcop/pquery.c b/src/backend/tcop/pquery.c
index 1286edee72..b7649c68fc 100644
--- a/src/backend/tcop/pquery.c
+++ b/src/backend/tcop/pquery.c
@@ -248,8 +248,8 @@ ChoosePortalStrategy(List *stmts)
/*
* PORTAL_ONE_SELECT and PORTAL_UTIL_SELECT need only consider the
* single-statement case, since there are no rewrite rules that can add
- * auxiliary queries to a SELECT or a utility command.
- * PORTAL_ONE_MOD_WITH likewise allows only one top-level statement.
+ * auxiliary queries to a SELECT or a utility command. PORTAL_ONE_MOD_WITH
+ * likewise allows only one top-level statement.
*/
if (list_length(stmts) == 1)
{
@@ -1158,7 +1158,7 @@ PortalRunUtility(Portal portal, Node *utilityStmt, bool isTopLevel,
* list. Transaction control, LOCK, and SET must *not* set a snapshot
* since they need to be executable at the start of a transaction-snapshot
* mode transaction without freezing a snapshot. By extension we allow
- * SHOW not to set a snapshot. The other stmts listed are just efficiency
+ * SHOW not to set a snapshot. The other stmts listed are just efficiency
* hacks. Beware of listing anything that can modify the database --- if,
* say, it has to update an index with expressions that invoke
* user-defined functions, then it had better have a snapshot.
diff --git a/src/backend/tcop/utility.c b/src/backend/tcop/utility.c
index 8e13096246..b1fd5ec04f 100644
--- a/src/backend/tcop/utility.c
+++ b/src/backend/tcop/utility.c
@@ -562,12 +562,12 @@ standard_ProcessUtility(Node *parsetree,
/*
* Unless "IF NOT EXISTS" was specified and the
- * relation already exists, create the pg_foreign_table
- * entry.
+ * relation already exists, create the
+ * pg_foreign_table entry.
*/
if (relOid != InvalidOid)
CreateForeignTable((CreateForeignTableStmt *) stmt,
- relOid);
+ relOid);
}
else
{
@@ -916,6 +916,7 @@ standard_ProcessUtility(Node *parsetree,
break;
case T_AlterEnumStmt: /* ALTER TYPE (enum) */
+
/*
* We disallow this in transaction blocks, because we can't cope
* with enum OID values getting into indexes and then having their
diff --git a/src/backend/tsearch/spell.c b/src/backend/tsearch/spell.c
index d4ddcba631..ecc880f54d 100644
--- a/src/backend/tsearch/spell.c
+++ b/src/backend/tsearch/spell.c
@@ -74,7 +74,7 @@ NIFinishBuild(IspellDict *Conf)
* doesn't need that. The cpalloc and cpalloc0 macros are just documentation
* to indicate which allocations actually require zeroing.
*/
-#define COMPACT_ALLOC_CHUNK 8192 /* must be > aset.c's allocChunkLimit */
+#define COMPACT_ALLOC_CHUNK 8192 /* must be > aset.c's allocChunkLimit */
#define COMPACT_MAX_REQ 1024 /* must be < COMPACT_ALLOC_CHUNK */
static void *
diff --git a/src/backend/tsearch/ts_locale.c b/src/backend/tsearch/ts_locale.c
index c66f4aa8bf..b8ae0fe65e 100644
--- a/src/backend/tsearch/ts_locale.c
+++ b/src/backend/tsearch/ts_locale.c
@@ -28,7 +28,7 @@ t_isdigit(const char *ptr)
{
int clen = pg_mblen(ptr);
wchar_t character[2];
- Oid collation = DEFAULT_COLLATION_OID; /*TODO*/
+ Oid collation = DEFAULT_COLLATION_OID; /* TODO */
if (clen == 1 || lc_ctype_is_c(collation))
return isdigit(TOUCHAR(ptr));
@@ -43,7 +43,7 @@ t_isspace(const char *ptr)
{
int clen = pg_mblen(ptr);
wchar_t character[2];
- Oid collation = DEFAULT_COLLATION_OID; /*TODO*/
+ Oid collation = DEFAULT_COLLATION_OID; /* TODO */
if (clen == 1 || lc_ctype_is_c(collation))
return isspace(TOUCHAR(ptr));
@@ -58,7 +58,7 @@ t_isalpha(const char *ptr)
{
int clen = pg_mblen(ptr);
wchar_t character[2];
- Oid collation = DEFAULT_COLLATION_OID; /*TODO*/
+ Oid collation = DEFAULT_COLLATION_OID; /* TODO */
if (clen == 1 || lc_ctype_is_c(collation))
return isalpha(TOUCHAR(ptr));
@@ -73,7 +73,7 @@ t_isprint(const char *ptr)
{
int clen = pg_mblen(ptr);
wchar_t character[2];
- Oid collation = DEFAULT_COLLATION_OID; /*TODO*/
+ Oid collation = DEFAULT_COLLATION_OID; /* TODO */
if (clen == 1 || lc_ctype_is_c(collation))
return isprint(TOUCHAR(ptr));
@@ -243,8 +243,9 @@ char *
lowerstr_with_len(const char *str, int len)
{
char *out;
+
#ifdef USE_WIDE_UPPER_LOWER
- Oid collation = DEFAULT_COLLATION_OID; /*TODO*/
+ Oid collation = DEFAULT_COLLATION_OID; /* TODO */
#endif
if (len == 0)
diff --git a/src/backend/tsearch/ts_selfuncs.c b/src/backend/tsearch/ts_selfuncs.c
index 7f33c16a24..366fa2ebf4 100644
--- a/src/backend/tsearch/ts_selfuncs.c
+++ b/src/backend/tsearch/ts_selfuncs.c
@@ -304,9 +304,9 @@ tsquery_opr_selec(QueryItem *item, char *operand,
/*
* Our strategy is to scan through the MCV list and add up the
- * frequencies of the ones that match the prefix, thereby
- * assuming that the MCVs are representative of the whole lexeme
- * population in this respect. Compare histogram_selectivity().
+ * frequencies of the ones that match the prefix, thereby assuming
+ * that the MCVs are representative of the whole lexeme population
+ * in this respect. Compare histogram_selectivity().
*
* This is only a good plan if we have a pretty fair number of
* MCVs available; we set the threshold at 100. If no stats or
@@ -401,7 +401,7 @@ tsquery_opr_selec(QueryItem *item, char *operand,
default:
elog(ERROR, "unrecognized operator: %d", item->qoperator.oper);
- selec = 0; /* keep compiler quiet */
+ selec = 0; /* keep compiler quiet */
break;
}
}
diff --git a/src/backend/tsearch/wparser_def.c b/src/backend/tsearch/wparser_def.c
index 3981a50589..47d777a3e6 100644
--- a/src/backend/tsearch/wparser_def.c
+++ b/src/backend/tsearch/wparser_def.c
@@ -299,16 +299,16 @@ TParserInit(char *str, int len)
*/
if (prs->charmaxlen > 1)
{
- Oid collation = DEFAULT_COLLATION_OID; /*TODO*/
-
+ Oid collation = DEFAULT_COLLATION_OID; /* TODO */
+
prs->usewide = true;
- if ( lc_ctype_is_c(collation) )
+ if (lc_ctype_is_c(collation))
{
/*
- * char2wchar doesn't work for C-locale and
- * sizeof(pg_wchar) could be not equal to sizeof(wchar_t)
+ * char2wchar doesn't work for C-locale and sizeof(pg_wchar) could
+ * be not equal to sizeof(wchar_t)
*/
- prs->pgwstr = (pg_wchar*) palloc(sizeof(pg_wchar) * (prs->lenstr + 1));
+ prs->pgwstr = (pg_wchar *) palloc(sizeof(pg_wchar) * (prs->lenstr + 1));
pg_mb2wchar_with_len(prs->str, prs->pgwstr, prs->lenstr);
}
else
@@ -325,10 +325,11 @@ TParserInit(char *str, int len)
prs->state->state = TPS_Base;
#ifdef WPARSER_TRACE
+
/*
- * Use of %.*s here is a bit risky since it can misbehave if the data
- * is not in what libc thinks is the prevailing encoding. However,
- * since this is just a debugging aid, we choose to live with that.
+ * Use of %.*s here is a bit risky since it can misbehave if the data is
+ * not in what libc thinks is the prevailing encoding. However, since
+ * this is just a debugging aid, we choose to live with that.
*/
fprintf(stderr, "parsing \"%.*s\"\n", len, str);
#endif
@@ -425,11 +426,11 @@ TParserCopyClose(TParser *prs)
/*
* Character-type support functions, equivalent to is* macros, but
* working with any possible encodings and locales. Notes:
- * - with multibyte encoding and C-locale isw* function may fail
- * or give wrong result.
- * - multibyte encoding and C-locale often are used for
- * Asian languages.
- * - if locale is C the we use pgwstr instead of wstr
+ * - with multibyte encoding and C-locale isw* function may fail
+ * or give wrong result.
+ * - multibyte encoding and C-locale often are used for
+ * Asian languages.
+ * - if locale is C the we use pgwstr instead of wstr
*/
#ifdef USE_WIDE_UPPER_LOWER
@@ -447,7 +448,7 @@ p_is##type(TParser *prs) { \
} \
\
return is##type( *(unsigned char*)( prs->str + prs->state->posbyte ) ); \
-} \
+} \
\
static int \
p_isnot##type(TParser *prs) { \
@@ -719,7 +720,7 @@ p_isignore(TParser *prs)
static int
p_ishost(TParser *prs)
{
- TParser *tmpprs = TParserCopyInit(prs);
+ TParser *tmpprs = TParserCopyInit(prs);
int res = 0;
tmpprs->wanthost = true;
@@ -741,7 +742,7 @@ p_ishost(TParser *prs)
static int
p_isURLPath(TParser *prs)
{
- TParser *tmpprs = TParserCopyInit(prs);
+ TParser *tmpprs = TParserCopyInit(prs);
int res = 0;
tmpprs->state = newTParserPosition(tmpprs->state);
@@ -773,269 +774,269 @@ p_isspecial(TParser *prs)
/*
* pg_dsplen could return -1 which means error or control character
*/
- if ( pg_dsplen(prs->str + prs->state->posbyte) == 0 )
+ if (pg_dsplen(prs->str + prs->state->posbyte) == 0)
return 1;
#ifdef USE_WIDE_UPPER_LOWER
+
/*
- * Unicode Characters in the 'Mark, Spacing Combining' Category
- * That characters are not alpha although they are not breakers
- * of word too.
- * Check that only in utf encoding, because other encodings
- * aren't supported by postgres or even exists.
+ * Unicode Characters in the 'Mark, Spacing Combining' Category That
+ * characters are not alpha although they are not breakers of word too.
+ * Check that only in utf encoding, because other encodings aren't
+ * supported by postgres or even exists.
*/
- if ( GetDatabaseEncoding() == PG_UTF8 && prs->usewide )
+ if (GetDatabaseEncoding() == PG_UTF8 && prs->usewide)
{
- static pg_wchar strange_letter[] = {
- /*
- * use binary search, so elements
- * should be ordered
- */
- 0x0903, /* DEVANAGARI SIGN VISARGA */
- 0x093E, /* DEVANAGARI VOWEL SIGN AA */
- 0x093F, /* DEVANAGARI VOWEL SIGN I */
- 0x0940, /* DEVANAGARI VOWEL SIGN II */
- 0x0949, /* DEVANAGARI VOWEL SIGN CANDRA O */
- 0x094A, /* DEVANAGARI VOWEL SIGN SHORT O */
- 0x094B, /* DEVANAGARI VOWEL SIGN O */
- 0x094C, /* DEVANAGARI VOWEL SIGN AU */
- 0x0982, /* BENGALI SIGN ANUSVARA */
- 0x0983, /* BENGALI SIGN VISARGA */
- 0x09BE, /* BENGALI VOWEL SIGN AA */
- 0x09BF, /* BENGALI VOWEL SIGN I */
- 0x09C0, /* BENGALI VOWEL SIGN II */
- 0x09C7, /* BENGALI VOWEL SIGN E */
- 0x09C8, /* BENGALI VOWEL SIGN AI */
- 0x09CB, /* BENGALI VOWEL SIGN O */
- 0x09CC, /* BENGALI VOWEL SIGN AU */
- 0x09D7, /* BENGALI AU LENGTH MARK */
- 0x0A03, /* GURMUKHI SIGN VISARGA */
- 0x0A3E, /* GURMUKHI VOWEL SIGN AA */
- 0x0A3F, /* GURMUKHI VOWEL SIGN I */
- 0x0A40, /* GURMUKHI VOWEL SIGN II */
- 0x0A83, /* GUJARATI SIGN VISARGA */
- 0x0ABE, /* GUJARATI VOWEL SIGN AA */
- 0x0ABF, /* GUJARATI VOWEL SIGN I */
- 0x0AC0, /* GUJARATI VOWEL SIGN II */
- 0x0AC9, /* GUJARATI VOWEL SIGN CANDRA O */
- 0x0ACB, /* GUJARATI VOWEL SIGN O */
- 0x0ACC, /* GUJARATI VOWEL SIGN AU */
- 0x0B02, /* ORIYA SIGN ANUSVARA */
- 0x0B03, /* ORIYA SIGN VISARGA */
- 0x0B3E, /* ORIYA VOWEL SIGN AA */
- 0x0B40, /* ORIYA VOWEL SIGN II */
- 0x0B47, /* ORIYA VOWEL SIGN E */
- 0x0B48, /* ORIYA VOWEL SIGN AI */
- 0x0B4B, /* ORIYA VOWEL SIGN O */
- 0x0B4C, /* ORIYA VOWEL SIGN AU */
- 0x0B57, /* ORIYA AU LENGTH MARK */
- 0x0BBE, /* TAMIL VOWEL SIGN AA */
- 0x0BBF, /* TAMIL VOWEL SIGN I */
- 0x0BC1, /* TAMIL VOWEL SIGN U */
- 0x0BC2, /* TAMIL VOWEL SIGN UU */
- 0x0BC6, /* TAMIL VOWEL SIGN E */
- 0x0BC7, /* TAMIL VOWEL SIGN EE */
- 0x0BC8, /* TAMIL VOWEL SIGN AI */
- 0x0BCA, /* TAMIL VOWEL SIGN O */
- 0x0BCB, /* TAMIL VOWEL SIGN OO */
- 0x0BCC, /* TAMIL VOWEL SIGN AU */
- 0x0BD7, /* TAMIL AU LENGTH MARK */
- 0x0C01, /* TELUGU SIGN CANDRABINDU */
- 0x0C02, /* TELUGU SIGN ANUSVARA */
- 0x0C03, /* TELUGU SIGN VISARGA */
- 0x0C41, /* TELUGU VOWEL SIGN U */
- 0x0C42, /* TELUGU VOWEL SIGN UU */
- 0x0C43, /* TELUGU VOWEL SIGN VOCALIC R */
- 0x0C44, /* TELUGU VOWEL SIGN VOCALIC RR */
- 0x0C82, /* KANNADA SIGN ANUSVARA */
- 0x0C83, /* KANNADA SIGN VISARGA */
- 0x0CBE, /* KANNADA VOWEL SIGN AA */
- 0x0CC0, /* KANNADA VOWEL SIGN II */
- 0x0CC1, /* KANNADA VOWEL SIGN U */
- 0x0CC2, /* KANNADA VOWEL SIGN UU */
- 0x0CC3, /* KANNADA VOWEL SIGN VOCALIC R */
- 0x0CC4, /* KANNADA VOWEL SIGN VOCALIC RR */
- 0x0CC7, /* KANNADA VOWEL SIGN EE */
- 0x0CC8, /* KANNADA VOWEL SIGN AI */
- 0x0CCA, /* KANNADA VOWEL SIGN O */
- 0x0CCB, /* KANNADA VOWEL SIGN OO */
- 0x0CD5, /* KANNADA LENGTH MARK */
- 0x0CD6, /* KANNADA AI LENGTH MARK */
- 0x0D02, /* MALAYALAM SIGN ANUSVARA */
- 0x0D03, /* MALAYALAM SIGN VISARGA */
- 0x0D3E, /* MALAYALAM VOWEL SIGN AA */
- 0x0D3F, /* MALAYALAM VOWEL SIGN I */
- 0x0D40, /* MALAYALAM VOWEL SIGN II */
- 0x0D46, /* MALAYALAM VOWEL SIGN E */
- 0x0D47, /* MALAYALAM VOWEL SIGN EE */
- 0x0D48, /* MALAYALAM VOWEL SIGN AI */
- 0x0D4A, /* MALAYALAM VOWEL SIGN O */
- 0x0D4B, /* MALAYALAM VOWEL SIGN OO */
- 0x0D4C, /* MALAYALAM VOWEL SIGN AU */
- 0x0D57, /* MALAYALAM AU LENGTH MARK */
- 0x0D82, /* SINHALA SIGN ANUSVARAYA */
- 0x0D83, /* SINHALA SIGN VISARGAYA */
- 0x0DCF, /* SINHALA VOWEL SIGN AELA-PILLA */
- 0x0DD0, /* SINHALA VOWEL SIGN KETTI AEDA-PILLA */
- 0x0DD1, /* SINHALA VOWEL SIGN DIGA AEDA-PILLA */
- 0x0DD8, /* SINHALA VOWEL SIGN GAETTA-PILLA */
- 0x0DD9, /* SINHALA VOWEL SIGN KOMBUVA */
- 0x0DDA, /* SINHALA VOWEL SIGN DIGA KOMBUVA */
- 0x0DDB, /* SINHALA VOWEL SIGN KOMBU DEKA */
- 0x0DDC, /* SINHALA VOWEL SIGN KOMBUVA HAA AELA-PILLA */
- 0x0DDD, /* SINHALA VOWEL SIGN KOMBUVA HAA DIGA AELA-PILLA */
- 0x0DDE, /* SINHALA VOWEL SIGN KOMBUVA HAA GAYANUKITTA */
- 0x0DDF, /* SINHALA VOWEL SIGN GAYANUKITTA */
- 0x0DF2, /* SINHALA VOWEL SIGN DIGA GAETTA-PILLA */
- 0x0DF3, /* SINHALA VOWEL SIGN DIGA GAYANUKITTA */
- 0x0F3E, /* TIBETAN SIGN YAR TSHES */
- 0x0F3F, /* TIBETAN SIGN MAR TSHES */
- 0x0F7F, /* TIBETAN SIGN RNAM BCAD */
- 0x102B, /* MYANMAR VOWEL SIGN TALL AA */
- 0x102C, /* MYANMAR VOWEL SIGN AA */
- 0x1031, /* MYANMAR VOWEL SIGN E */
- 0x1038, /* MYANMAR SIGN VISARGA */
- 0x103B, /* MYANMAR CONSONANT SIGN MEDIAL YA */
- 0x103C, /* MYANMAR CONSONANT SIGN MEDIAL RA */
- 0x1056, /* MYANMAR VOWEL SIGN VOCALIC R */
- 0x1057, /* MYANMAR VOWEL SIGN VOCALIC RR */
- 0x1062, /* MYANMAR VOWEL SIGN SGAW KAREN EU */
- 0x1063, /* MYANMAR TONE MARK SGAW KAREN HATHI */
- 0x1064, /* MYANMAR TONE MARK SGAW KAREN KE PHO */
- 0x1067, /* MYANMAR VOWEL SIGN WESTERN PWO KAREN EU */
- 0x1068, /* MYANMAR VOWEL SIGN WESTERN PWO KAREN UE */
- 0x1069, /* MYANMAR SIGN WESTERN PWO KAREN TONE-1 */
- 0x106A, /* MYANMAR SIGN WESTERN PWO KAREN TONE-2 */
- 0x106B, /* MYANMAR SIGN WESTERN PWO KAREN TONE-3 */
- 0x106C, /* MYANMAR SIGN WESTERN PWO KAREN TONE-4 */
- 0x106D, /* MYANMAR SIGN WESTERN PWO KAREN TONE-5 */
- 0x1083, /* MYANMAR VOWEL SIGN SHAN AA */
- 0x1084, /* MYANMAR VOWEL SIGN SHAN E */
- 0x1087, /* MYANMAR SIGN SHAN TONE-2 */
- 0x1088, /* MYANMAR SIGN SHAN TONE-3 */
- 0x1089, /* MYANMAR SIGN SHAN TONE-5 */
- 0x108A, /* MYANMAR SIGN SHAN TONE-6 */
- 0x108B, /* MYANMAR SIGN SHAN COUNCIL TONE-2 */
- 0x108C, /* MYANMAR SIGN SHAN COUNCIL TONE-3 */
- 0x108F, /* MYANMAR SIGN RUMAI PALAUNG TONE-5 */
- 0x17B6, /* KHMER VOWEL SIGN AA */
- 0x17BE, /* KHMER VOWEL SIGN OE */
- 0x17BF, /* KHMER VOWEL SIGN YA */
- 0x17C0, /* KHMER VOWEL SIGN IE */
- 0x17C1, /* KHMER VOWEL SIGN E */
- 0x17C2, /* KHMER VOWEL SIGN AE */
- 0x17C3, /* KHMER VOWEL SIGN AI */
- 0x17C4, /* KHMER VOWEL SIGN OO */
- 0x17C5, /* KHMER VOWEL SIGN AU */
- 0x17C7, /* KHMER SIGN REAHMUK */
- 0x17C8, /* KHMER SIGN YUUKALEAPINTU */
- 0x1923, /* LIMBU VOWEL SIGN EE */
- 0x1924, /* LIMBU VOWEL SIGN AI */
- 0x1925, /* LIMBU VOWEL SIGN OO */
- 0x1926, /* LIMBU VOWEL SIGN AU */
- 0x1929, /* LIMBU SUBJOINED LETTER YA */
- 0x192A, /* LIMBU SUBJOINED LETTER RA */
- 0x192B, /* LIMBU SUBJOINED LETTER WA */
- 0x1930, /* LIMBU SMALL LETTER KA */
- 0x1931, /* LIMBU SMALL LETTER NGA */
- 0x1933, /* LIMBU SMALL LETTER TA */
- 0x1934, /* LIMBU SMALL LETTER NA */
- 0x1935, /* LIMBU SMALL LETTER PA */
- 0x1936, /* LIMBU SMALL LETTER MA */
- 0x1937, /* LIMBU SMALL LETTER RA */
- 0x1938, /* LIMBU SMALL LETTER LA */
- 0x19B0, /* NEW TAI LUE VOWEL SIGN VOWEL SHORTENER */
- 0x19B1, /* NEW TAI LUE VOWEL SIGN AA */
- 0x19B2, /* NEW TAI LUE VOWEL SIGN II */
- 0x19B3, /* NEW TAI LUE VOWEL SIGN U */
- 0x19B4, /* NEW TAI LUE VOWEL SIGN UU */
- 0x19B5, /* NEW TAI LUE VOWEL SIGN E */
- 0x19B6, /* NEW TAI LUE VOWEL SIGN AE */
- 0x19B7, /* NEW TAI LUE VOWEL SIGN O */
- 0x19B8, /* NEW TAI LUE VOWEL SIGN OA */
- 0x19B9, /* NEW TAI LUE VOWEL SIGN UE */
- 0x19BA, /* NEW TAI LUE VOWEL SIGN AY */
- 0x19BB, /* NEW TAI LUE VOWEL SIGN AAY */
- 0x19BC, /* NEW TAI LUE VOWEL SIGN UY */
- 0x19BD, /* NEW TAI LUE VOWEL SIGN OY */
- 0x19BE, /* NEW TAI LUE VOWEL SIGN OAY */
- 0x19BF, /* NEW TAI LUE VOWEL SIGN UEY */
- 0x19C0, /* NEW TAI LUE VOWEL SIGN IY */
- 0x19C8, /* NEW TAI LUE TONE MARK-1 */
- 0x19C9, /* NEW TAI LUE TONE MARK-2 */
- 0x1A19, /* BUGINESE VOWEL SIGN E */
- 0x1A1A, /* BUGINESE VOWEL SIGN O */
- 0x1A1B, /* BUGINESE VOWEL SIGN AE */
- 0x1B04, /* BALINESE SIGN BISAH */
- 0x1B35, /* BALINESE VOWEL SIGN TEDUNG */
- 0x1B3B, /* BALINESE VOWEL SIGN RA REPA TEDUNG */
- 0x1B3D, /* BALINESE VOWEL SIGN LA LENGA TEDUNG */
- 0x1B3E, /* BALINESE VOWEL SIGN TALING */
- 0x1B3F, /* BALINESE VOWEL SIGN TALING REPA */
- 0x1B40, /* BALINESE VOWEL SIGN TALING TEDUNG */
- 0x1B41, /* BALINESE VOWEL SIGN TALING REPA TEDUNG */
- 0x1B43, /* BALINESE VOWEL SIGN PEPET TEDUNG */
- 0x1B44, /* BALINESE ADEG ADEG */
- 0x1B82, /* SUNDANESE SIGN PANGWISAD */
- 0x1BA1, /* SUNDANESE CONSONANT SIGN PAMINGKAL */
- 0x1BA6, /* SUNDANESE VOWEL SIGN PANAELAENG */
- 0x1BA7, /* SUNDANESE VOWEL SIGN PANOLONG */
- 0x1BAA, /* SUNDANESE SIGN PAMAAEH */
- 0x1C24, /* LEPCHA SUBJOINED LETTER YA */
- 0x1C25, /* LEPCHA SUBJOINED LETTER RA */
- 0x1C26, /* LEPCHA VOWEL SIGN AA */
- 0x1C27, /* LEPCHA VOWEL SIGN I */
- 0x1C28, /* LEPCHA VOWEL SIGN O */
- 0x1C29, /* LEPCHA VOWEL SIGN OO */
- 0x1C2A, /* LEPCHA VOWEL SIGN U */
- 0x1C2B, /* LEPCHA VOWEL SIGN UU */
- 0x1C34, /* LEPCHA CONSONANT SIGN NYIN-DO */
- 0x1C35, /* LEPCHA CONSONANT SIGN KANG */
- 0xA823, /* SYLOTI NAGRI VOWEL SIGN A */
- 0xA824, /* SYLOTI NAGRI VOWEL SIGN I */
- 0xA827, /* SYLOTI NAGRI VOWEL SIGN OO */
- 0xA880, /* SAURASHTRA SIGN ANUSVARA */
- 0xA881, /* SAURASHTRA SIGN VISARGA */
- 0xA8B4, /* SAURASHTRA CONSONANT SIGN HAARU */
- 0xA8B5, /* SAURASHTRA VOWEL SIGN AA */
- 0xA8B6, /* SAURASHTRA VOWEL SIGN I */
- 0xA8B7, /* SAURASHTRA VOWEL SIGN II */
- 0xA8B8, /* SAURASHTRA VOWEL SIGN U */
- 0xA8B9, /* SAURASHTRA VOWEL SIGN UU */
- 0xA8BA, /* SAURASHTRA VOWEL SIGN VOCALIC R */
- 0xA8BB, /* SAURASHTRA VOWEL SIGN VOCALIC RR */
- 0xA8BC, /* SAURASHTRA VOWEL SIGN VOCALIC L */
- 0xA8BD, /* SAURASHTRA VOWEL SIGN VOCALIC LL */
- 0xA8BE, /* SAURASHTRA VOWEL SIGN E */
- 0xA8BF, /* SAURASHTRA VOWEL SIGN EE */
- 0xA8C0, /* SAURASHTRA VOWEL SIGN AI */
- 0xA8C1, /* SAURASHTRA VOWEL SIGN O */
- 0xA8C2, /* SAURASHTRA VOWEL SIGN OO */
- 0xA8C3, /* SAURASHTRA VOWEL SIGN AU */
- 0xA952, /* REJANG CONSONANT SIGN H */
- 0xA953, /* REJANG VIRAMA */
- 0xAA2F, /* CHAM VOWEL SIGN O */
- 0xAA30, /* CHAM VOWEL SIGN AI */
- 0xAA33, /* CHAM CONSONANT SIGN YA */
- 0xAA34, /* CHAM CONSONANT SIGN RA */
- 0xAA4D /* CHAM CONSONANT SIGN FINAL H */
- };
- pg_wchar *StopLow = strange_letter,
- *StopHigh = strange_letter + lengthof(strange_letter),
- *StopMiddle;
+ static pg_wchar strange_letter[] = {
+ /*
+ * use binary search, so elements should be ordered
+ */
+ 0x0903, /* DEVANAGARI SIGN VISARGA */
+ 0x093E, /* DEVANAGARI VOWEL SIGN AA */
+ 0x093F, /* DEVANAGARI VOWEL SIGN I */
+ 0x0940, /* DEVANAGARI VOWEL SIGN II */
+ 0x0949, /* DEVANAGARI VOWEL SIGN CANDRA O */
+ 0x094A, /* DEVANAGARI VOWEL SIGN SHORT O */
+ 0x094B, /* DEVANAGARI VOWEL SIGN O */
+ 0x094C, /* DEVANAGARI VOWEL SIGN AU */
+ 0x0982, /* BENGALI SIGN ANUSVARA */
+ 0x0983, /* BENGALI SIGN VISARGA */
+ 0x09BE, /* BENGALI VOWEL SIGN AA */
+ 0x09BF, /* BENGALI VOWEL SIGN I */
+ 0x09C0, /* BENGALI VOWEL SIGN II */
+ 0x09C7, /* BENGALI VOWEL SIGN E */
+ 0x09C8, /* BENGALI VOWEL SIGN AI */
+ 0x09CB, /* BENGALI VOWEL SIGN O */
+ 0x09CC, /* BENGALI VOWEL SIGN AU */
+ 0x09D7, /* BENGALI AU LENGTH MARK */
+ 0x0A03, /* GURMUKHI SIGN VISARGA */
+ 0x0A3E, /* GURMUKHI VOWEL SIGN AA */
+ 0x0A3F, /* GURMUKHI VOWEL SIGN I */
+ 0x0A40, /* GURMUKHI VOWEL SIGN II */
+ 0x0A83, /* GUJARATI SIGN VISARGA */
+ 0x0ABE, /* GUJARATI VOWEL SIGN AA */
+ 0x0ABF, /* GUJARATI VOWEL SIGN I */
+ 0x0AC0, /* GUJARATI VOWEL SIGN II */
+ 0x0AC9, /* GUJARATI VOWEL SIGN CANDRA O */
+ 0x0ACB, /* GUJARATI VOWEL SIGN O */
+ 0x0ACC, /* GUJARATI VOWEL SIGN AU */
+ 0x0B02, /* ORIYA SIGN ANUSVARA */
+ 0x0B03, /* ORIYA SIGN VISARGA */
+ 0x0B3E, /* ORIYA VOWEL SIGN AA */
+ 0x0B40, /* ORIYA VOWEL SIGN II */
+ 0x0B47, /* ORIYA VOWEL SIGN E */
+ 0x0B48, /* ORIYA VOWEL SIGN AI */
+ 0x0B4B, /* ORIYA VOWEL SIGN O */
+ 0x0B4C, /* ORIYA VOWEL SIGN AU */
+ 0x0B57, /* ORIYA AU LENGTH MARK */
+ 0x0BBE, /* TAMIL VOWEL SIGN AA */
+ 0x0BBF, /* TAMIL VOWEL SIGN I */
+ 0x0BC1, /* TAMIL VOWEL SIGN U */
+ 0x0BC2, /* TAMIL VOWEL SIGN UU */
+ 0x0BC6, /* TAMIL VOWEL SIGN E */
+ 0x0BC7, /* TAMIL VOWEL SIGN EE */
+ 0x0BC8, /* TAMIL VOWEL SIGN AI */
+ 0x0BCA, /* TAMIL VOWEL SIGN O */
+ 0x0BCB, /* TAMIL VOWEL SIGN OO */
+ 0x0BCC, /* TAMIL VOWEL SIGN AU */
+ 0x0BD7, /* TAMIL AU LENGTH MARK */
+ 0x0C01, /* TELUGU SIGN CANDRABINDU */
+ 0x0C02, /* TELUGU SIGN ANUSVARA */
+ 0x0C03, /* TELUGU SIGN VISARGA */
+ 0x0C41, /* TELUGU VOWEL SIGN U */
+ 0x0C42, /* TELUGU VOWEL SIGN UU */
+ 0x0C43, /* TELUGU VOWEL SIGN VOCALIC R */
+ 0x0C44, /* TELUGU VOWEL SIGN VOCALIC RR */
+ 0x0C82, /* KANNADA SIGN ANUSVARA */
+ 0x0C83, /* KANNADA SIGN VISARGA */
+ 0x0CBE, /* KANNADA VOWEL SIGN AA */
+ 0x0CC0, /* KANNADA VOWEL SIGN II */
+ 0x0CC1, /* KANNADA VOWEL SIGN U */
+ 0x0CC2, /* KANNADA VOWEL SIGN UU */
+ 0x0CC3, /* KANNADA VOWEL SIGN VOCALIC R */
+ 0x0CC4, /* KANNADA VOWEL SIGN VOCALIC RR */
+ 0x0CC7, /* KANNADA VOWEL SIGN EE */
+ 0x0CC8, /* KANNADA VOWEL SIGN AI */
+ 0x0CCA, /* KANNADA VOWEL SIGN O */
+ 0x0CCB, /* KANNADA VOWEL SIGN OO */
+ 0x0CD5, /* KANNADA LENGTH MARK */
+ 0x0CD6, /* KANNADA AI LENGTH MARK */
+ 0x0D02, /* MALAYALAM SIGN ANUSVARA */
+ 0x0D03, /* MALAYALAM SIGN VISARGA */
+ 0x0D3E, /* MALAYALAM VOWEL SIGN AA */
+ 0x0D3F, /* MALAYALAM VOWEL SIGN I */
+ 0x0D40, /* MALAYALAM VOWEL SIGN II */
+ 0x0D46, /* MALAYALAM VOWEL SIGN E */
+ 0x0D47, /* MALAYALAM VOWEL SIGN EE */
+ 0x0D48, /* MALAYALAM VOWEL SIGN AI */
+ 0x0D4A, /* MALAYALAM VOWEL SIGN O */
+ 0x0D4B, /* MALAYALAM VOWEL SIGN OO */
+ 0x0D4C, /* MALAYALAM VOWEL SIGN AU */
+ 0x0D57, /* MALAYALAM AU LENGTH MARK */
+ 0x0D82, /* SINHALA SIGN ANUSVARAYA */
+ 0x0D83, /* SINHALA SIGN VISARGAYA */
+ 0x0DCF, /* SINHALA VOWEL SIGN AELA-PILLA */
+ 0x0DD0, /* SINHALA VOWEL SIGN KETTI AEDA-PILLA */
+ 0x0DD1, /* SINHALA VOWEL SIGN DIGA AEDA-PILLA */
+ 0x0DD8, /* SINHALA VOWEL SIGN GAETTA-PILLA */
+ 0x0DD9, /* SINHALA VOWEL SIGN KOMBUVA */
+ 0x0DDA, /* SINHALA VOWEL SIGN DIGA KOMBUVA */
+ 0x0DDB, /* SINHALA VOWEL SIGN KOMBU DEKA */
+ 0x0DDC, /* SINHALA VOWEL SIGN KOMBUVA HAA AELA-PILLA */
+ 0x0DDD, /* SINHALA VOWEL SIGN KOMBUVA HAA DIGA
+ * AELA-PILLA */
+ 0x0DDE, /* SINHALA VOWEL SIGN KOMBUVA HAA GAYANUKITTA */
+ 0x0DDF, /* SINHALA VOWEL SIGN GAYANUKITTA */
+ 0x0DF2, /* SINHALA VOWEL SIGN DIGA GAETTA-PILLA */
+ 0x0DF3, /* SINHALA VOWEL SIGN DIGA GAYANUKITTA */
+ 0x0F3E, /* TIBETAN SIGN YAR TSHES */
+ 0x0F3F, /* TIBETAN SIGN MAR TSHES */
+ 0x0F7F, /* TIBETAN SIGN RNAM BCAD */
+ 0x102B, /* MYANMAR VOWEL SIGN TALL AA */
+ 0x102C, /* MYANMAR VOWEL SIGN AA */
+ 0x1031, /* MYANMAR VOWEL SIGN E */
+ 0x1038, /* MYANMAR SIGN VISARGA */
+ 0x103B, /* MYANMAR CONSONANT SIGN MEDIAL YA */
+ 0x103C, /* MYANMAR CONSONANT SIGN MEDIAL RA */
+ 0x1056, /* MYANMAR VOWEL SIGN VOCALIC R */
+ 0x1057, /* MYANMAR VOWEL SIGN VOCALIC RR */
+ 0x1062, /* MYANMAR VOWEL SIGN SGAW KAREN EU */
+ 0x1063, /* MYANMAR TONE MARK SGAW KAREN HATHI */
+ 0x1064, /* MYANMAR TONE MARK SGAW KAREN KE PHO */
+ 0x1067, /* MYANMAR VOWEL SIGN WESTERN PWO KAREN EU */
+ 0x1068, /* MYANMAR VOWEL SIGN WESTERN PWO KAREN UE */
+ 0x1069, /* MYANMAR SIGN WESTERN PWO KAREN TONE-1 */
+ 0x106A, /* MYANMAR SIGN WESTERN PWO KAREN TONE-2 */
+ 0x106B, /* MYANMAR SIGN WESTERN PWO KAREN TONE-3 */
+ 0x106C, /* MYANMAR SIGN WESTERN PWO KAREN TONE-4 */
+ 0x106D, /* MYANMAR SIGN WESTERN PWO KAREN TONE-5 */
+ 0x1083, /* MYANMAR VOWEL SIGN SHAN AA */
+ 0x1084, /* MYANMAR VOWEL SIGN SHAN E */
+ 0x1087, /* MYANMAR SIGN SHAN TONE-2 */
+ 0x1088, /* MYANMAR SIGN SHAN TONE-3 */
+ 0x1089, /* MYANMAR SIGN SHAN TONE-5 */
+ 0x108A, /* MYANMAR SIGN SHAN TONE-6 */
+ 0x108B, /* MYANMAR SIGN SHAN COUNCIL TONE-2 */
+ 0x108C, /* MYANMAR SIGN SHAN COUNCIL TONE-3 */
+ 0x108F, /* MYANMAR SIGN RUMAI PALAUNG TONE-5 */
+ 0x17B6, /* KHMER VOWEL SIGN AA */
+ 0x17BE, /* KHMER VOWEL SIGN OE */
+ 0x17BF, /* KHMER VOWEL SIGN YA */
+ 0x17C0, /* KHMER VOWEL SIGN IE */
+ 0x17C1, /* KHMER VOWEL SIGN E */
+ 0x17C2, /* KHMER VOWEL SIGN AE */
+ 0x17C3, /* KHMER VOWEL SIGN AI */
+ 0x17C4, /* KHMER VOWEL SIGN OO */
+ 0x17C5, /* KHMER VOWEL SIGN AU */
+ 0x17C7, /* KHMER SIGN REAHMUK */
+ 0x17C8, /* KHMER SIGN YUUKALEAPINTU */
+ 0x1923, /* LIMBU VOWEL SIGN EE */
+ 0x1924, /* LIMBU VOWEL SIGN AI */
+ 0x1925, /* LIMBU VOWEL SIGN OO */
+ 0x1926, /* LIMBU VOWEL SIGN AU */
+ 0x1929, /* LIMBU SUBJOINED LETTER YA */
+ 0x192A, /* LIMBU SUBJOINED LETTER RA */
+ 0x192B, /* LIMBU SUBJOINED LETTER WA */
+ 0x1930, /* LIMBU SMALL LETTER KA */
+ 0x1931, /* LIMBU SMALL LETTER NGA */
+ 0x1933, /* LIMBU SMALL LETTER TA */
+ 0x1934, /* LIMBU SMALL LETTER NA */
+ 0x1935, /* LIMBU SMALL LETTER PA */
+ 0x1936, /* LIMBU SMALL LETTER MA */
+ 0x1937, /* LIMBU SMALL LETTER RA */
+ 0x1938, /* LIMBU SMALL LETTER LA */
+ 0x19B0, /* NEW TAI LUE VOWEL SIGN VOWEL SHORTENER */
+ 0x19B1, /* NEW TAI LUE VOWEL SIGN AA */
+ 0x19B2, /* NEW TAI LUE VOWEL SIGN II */
+ 0x19B3, /* NEW TAI LUE VOWEL SIGN U */
+ 0x19B4, /* NEW TAI LUE VOWEL SIGN UU */
+ 0x19B5, /* NEW TAI LUE VOWEL SIGN E */
+ 0x19B6, /* NEW TAI LUE VOWEL SIGN AE */
+ 0x19B7, /* NEW TAI LUE VOWEL SIGN O */
+ 0x19B8, /* NEW TAI LUE VOWEL SIGN OA */
+ 0x19B9, /* NEW TAI LUE VOWEL SIGN UE */
+ 0x19BA, /* NEW TAI LUE VOWEL SIGN AY */
+ 0x19BB, /* NEW TAI LUE VOWEL SIGN AAY */
+ 0x19BC, /* NEW TAI LUE VOWEL SIGN UY */
+ 0x19BD, /* NEW TAI LUE VOWEL SIGN OY */
+ 0x19BE, /* NEW TAI LUE VOWEL SIGN OAY */
+ 0x19BF, /* NEW TAI LUE VOWEL SIGN UEY */
+ 0x19C0, /* NEW TAI LUE VOWEL SIGN IY */
+ 0x19C8, /* NEW TAI LUE TONE MARK-1 */
+ 0x19C9, /* NEW TAI LUE TONE MARK-2 */
+ 0x1A19, /* BUGINESE VOWEL SIGN E */
+ 0x1A1A, /* BUGINESE VOWEL SIGN O */
+ 0x1A1B, /* BUGINESE VOWEL SIGN AE */
+ 0x1B04, /* BALINESE SIGN BISAH */
+ 0x1B35, /* BALINESE VOWEL SIGN TEDUNG */
+ 0x1B3B, /* BALINESE VOWEL SIGN RA REPA TEDUNG */
+ 0x1B3D, /* BALINESE VOWEL SIGN LA LENGA TEDUNG */
+ 0x1B3E, /* BALINESE VOWEL SIGN TALING */
+ 0x1B3F, /* BALINESE VOWEL SIGN TALING REPA */
+ 0x1B40, /* BALINESE VOWEL SIGN TALING TEDUNG */
+ 0x1B41, /* BALINESE VOWEL SIGN TALING REPA TEDUNG */
+ 0x1B43, /* BALINESE VOWEL SIGN PEPET TEDUNG */
+ 0x1B44, /* BALINESE ADEG ADEG */
+ 0x1B82, /* SUNDANESE SIGN PANGWISAD */
+ 0x1BA1, /* SUNDANESE CONSONANT SIGN PAMINGKAL */
+ 0x1BA6, /* SUNDANESE VOWEL SIGN PANAELAENG */
+ 0x1BA7, /* SUNDANESE VOWEL SIGN PANOLONG */
+ 0x1BAA, /* SUNDANESE SIGN PAMAAEH */
+ 0x1C24, /* LEPCHA SUBJOINED LETTER YA */
+ 0x1C25, /* LEPCHA SUBJOINED LETTER RA */
+ 0x1C26, /* LEPCHA VOWEL SIGN AA */
+ 0x1C27, /* LEPCHA VOWEL SIGN I */
+ 0x1C28, /* LEPCHA VOWEL SIGN O */
+ 0x1C29, /* LEPCHA VOWEL SIGN OO */
+ 0x1C2A, /* LEPCHA VOWEL SIGN U */
+ 0x1C2B, /* LEPCHA VOWEL SIGN UU */
+ 0x1C34, /* LEPCHA CONSONANT SIGN NYIN-DO */
+ 0x1C35, /* LEPCHA CONSONANT SIGN KANG */
+ 0xA823, /* SYLOTI NAGRI VOWEL SIGN A */
+ 0xA824, /* SYLOTI NAGRI VOWEL SIGN I */
+ 0xA827, /* SYLOTI NAGRI VOWEL SIGN OO */
+ 0xA880, /* SAURASHTRA SIGN ANUSVARA */
+ 0xA881, /* SAURASHTRA SIGN VISARGA */
+ 0xA8B4, /* SAURASHTRA CONSONANT SIGN HAARU */
+ 0xA8B5, /* SAURASHTRA VOWEL SIGN AA */
+ 0xA8B6, /* SAURASHTRA VOWEL SIGN I */
+ 0xA8B7, /* SAURASHTRA VOWEL SIGN II */
+ 0xA8B8, /* SAURASHTRA VOWEL SIGN U */
+ 0xA8B9, /* SAURASHTRA VOWEL SIGN UU */
+ 0xA8BA, /* SAURASHTRA VOWEL SIGN VOCALIC R */
+ 0xA8BB, /* SAURASHTRA VOWEL SIGN VOCALIC RR */
+ 0xA8BC, /* SAURASHTRA VOWEL SIGN VOCALIC L */
+ 0xA8BD, /* SAURASHTRA VOWEL SIGN VOCALIC LL */
+ 0xA8BE, /* SAURASHTRA VOWEL SIGN E */
+ 0xA8BF, /* SAURASHTRA VOWEL SIGN EE */
+ 0xA8C0, /* SAURASHTRA VOWEL SIGN AI */
+ 0xA8C1, /* SAURASHTRA VOWEL SIGN O */
+ 0xA8C2, /* SAURASHTRA VOWEL SIGN OO */
+ 0xA8C3, /* SAURASHTRA VOWEL SIGN AU */
+ 0xA952, /* REJANG CONSONANT SIGN H */
+ 0xA953, /* REJANG VIRAMA */
+ 0xAA2F, /* CHAM VOWEL SIGN O */
+ 0xAA30, /* CHAM VOWEL SIGN AI */
+ 0xAA33, /* CHAM CONSONANT SIGN YA */
+ 0xAA34, /* CHAM CONSONANT SIGN RA */
+ 0xAA4D /* CHAM CONSONANT SIGN FINAL H */
+ };
+ pg_wchar *StopLow = strange_letter,
+ *StopHigh = strange_letter + lengthof(strange_letter),
+ *StopMiddle;
pg_wchar c;
- if ( prs->pgwstr )
+ if (prs->pgwstr)
c = *(prs->pgwstr + prs->state->poschar);
else
c = (pg_wchar) *(prs->wstr + prs->state->poschar);
- while( StopLow < StopHigh )
+ while (StopLow < StopHigh)
{
StopMiddle = StopLow + ((StopHigh - StopLow) >> 1);
- if ( *StopMiddle == c )
+ if (*StopMiddle == c)
return 1;
- else if ( *StopMiddle < c )
+ else if (*StopMiddle < c)
StopLow = StopMiddle + 1;
else
StopHigh = StopMiddle;
@@ -1288,7 +1289,7 @@ static const TParserStateActionItem actionTPS_InTagFirst[] = {
static const TParserStateActionItem actionTPS_InXMLBegin[] = {
{p_isEOF, 0, A_POP, TPS_Null, 0, NULL},
/* words[i].type))
prs->words[i].replace = 1;
- else if ( HLIDSKIP(prs->words[i].type) )
+ else if (HLIDSKIP(prs->words[i].type))
prs->words[i].skip = 1;
}
else
@@ -2130,27 +2131,29 @@ mark_fragment(HeadlineParsedText *prs, int highlight, int startpos, int endpos)
typedef struct
{
- int4 startpos;
- int4 endpos;
- int4 poslen;
- int4 curlen;
- int2 in;
- int2 excluded;
+ int4 startpos;
+ int4 endpos;
+ int4 poslen;
+ int4 curlen;
+ int2 in;
+ int2 excluded;
} CoverPos;
static void
get_next_fragment(HeadlineParsedText *prs, int *startpos, int *endpos,
- int *curlen, int *poslen, int max_words)
+ int *curlen, int *poslen, int max_words)
{
- int i;
- /* Objective: Generate a fragment of words between startpos and endpos
- * such that it has at most max_words and both ends has query words.
- * If the startpos and endpos are the endpoints of the cover and the
- * cover has fewer words than max_words, then this function should
- * just return the cover
+ int i;
+
+ /*
+ * Objective: Generate a fragment of words between startpos and endpos
+ * such that it has at most max_words and both ends has query words. If
+ * the startpos and endpos are the endpoints of the cover and the cover
+ * has fewer words than max_words, then this function should just return
+ * the cover
*/
/* first move startpos to an item */
- for(i = *startpos; i <= *endpos; i++)
+ for (i = *startpos; i <= *endpos; i++)
{
*startpos = i;
if (prs->words[i].item && !prs->words[i].repeated)
@@ -2159,7 +2162,7 @@ get_next_fragment(HeadlineParsedText *prs, int *startpos, int *endpos,
/* cut endpos to have only max_words */
*curlen = 0;
*poslen = 0;
- for(i = *startpos; i <= *endpos && *curlen < max_words; i++)
+ for (i = *startpos; i <= *endpos && *curlen < max_words; i++)
{
if (!NONWORDTOKEN(prs->words[i].type))
*curlen += 1;
@@ -2170,7 +2173,7 @@ get_next_fragment(HeadlineParsedText *prs, int *startpos, int *endpos,
if (*endpos > i)
{
*endpos = i;
- for(i = *endpos; i >= *startpos; i --)
+ for (i = *endpos; i >= *startpos; i--)
{
*endpos = i;
if (prs->words[i].item && !prs->words[i].repeated)
@@ -2183,22 +2186,30 @@ get_next_fragment(HeadlineParsedText *prs, int *startpos, int *endpos,
static void
mark_hl_fragments(HeadlineParsedText *prs, TSQuery query, int highlight,
- int shortword, int min_words,
- int max_words, int max_fragments)
+ int shortword, int min_words,
+ int max_words, int max_fragments)
{
- int4 poslen, curlen, i, f, num_f = 0;
- int4 stretch, maxstretch, posmarker;
-
- int4 startpos = 0,
- endpos = 0,
- p = 0,
- q = 0;
+ int4 poslen,
+ curlen,
+ i,
+ f,
+ num_f = 0;
+ int4 stretch,
+ maxstretch,
+ posmarker;
+
+ int4 startpos = 0,
+ endpos = 0,
+ p = 0,
+ q = 0;
int4 numcovers = 0,
- maxcovers = 32;
+ maxcovers = 32;
- int4 minI, minwords, maxitems;
- CoverPos *covers;
+ int4 minI,
+ minwords,
+ maxitems;
+ CoverPos *covers;
covers = palloc(maxcovers * sizeof(CoverPos));
@@ -2206,12 +2217,13 @@ mark_hl_fragments(HeadlineParsedText *prs, TSQuery query, int highlight,
while (hlCover(prs, query, &p, &q))
{
startpos = p;
- endpos = q;
+ endpos = q;
- /* Break the cover into smaller fragments such that each fragment
- * has at most max_words. Also ensure that each end of the fragment
- * is a query word. This will allow us to stretch the fragment in
- * either direction
+ /*
+ * Break the cover into smaller fragments such that each fragment has
+ * at most max_words. Also ensure that each end of the fragment is a
+ * query word. This will allow us to stretch the fragment in either
+ * direction
*/
while (startpos <= endpos)
@@ -2220,17 +2232,17 @@ mark_hl_fragments(HeadlineParsedText *prs, TSQuery query, int highlight,
if (numcovers >= maxcovers)
{
maxcovers *= 2;
- covers = repalloc(covers, sizeof(CoverPos) * maxcovers);
+ covers = repalloc(covers, sizeof(CoverPos) * maxcovers);
}
covers[numcovers].startpos = startpos;
- covers[numcovers].endpos = endpos;
- covers[numcovers].curlen = curlen;
- covers[numcovers].poslen = poslen;
- covers[numcovers].in = 0;
+ covers[numcovers].endpos = endpos;
+ covers[numcovers].curlen = curlen;
+ covers[numcovers].poslen = poslen;
+ covers[numcovers].in = 0;
covers[numcovers].excluded = 0;
- numcovers ++;
+ numcovers++;
startpos = endpos + 1;
- endpos = q;
+ endpos = q;
}
/* move p to generate the next cover */
p++;
@@ -2242,19 +2254,20 @@ mark_hl_fragments(HeadlineParsedText *prs, TSQuery query, int highlight,
maxitems = 0;
minwords = 0x7fffffff;
minI = -1;
- /* Choose the cover that contains max items.
- * In case of tie choose the one with smaller
- * number of words.
+
+ /*
+ * Choose the cover that contains max items. In case of tie choose the
+ * one with smaller number of words.
*/
- for (i = 0; i < numcovers; i ++)
+ for (i = 0; i < numcovers; i++)
{
- if (!covers[i].in && !covers[i].excluded &&
+ if (!covers[i].in && !covers[i].excluded &&
(maxitems < covers[i].poslen || (maxitems == covers[i].poslen
- && minwords > covers[i].curlen)))
+ && minwords > covers[i].curlen)))
{
maxitems = covers[i].poslen;
minwords = covers[i].curlen;
- minI = i;
+ minI = i;
}
}
/* if a cover was found mark it */
@@ -2263,27 +2276,27 @@ mark_hl_fragments(HeadlineParsedText *prs, TSQuery query, int highlight,
covers[minI].in = 1;
/* adjust the size of cover */
startpos = covers[minI].startpos;
- endpos = covers[minI].endpos;
- curlen = covers[minI].curlen;
+ endpos = covers[minI].endpos;
+ curlen = covers[minI].curlen;
/* stretch the cover if cover size is lower than max_words */
if (curlen < max_words)
{
/* divide the stretch on both sides of cover */
- maxstretch = (max_words - curlen)/2;
- /* first stretch the startpos
- * stop stretching if
- * 1. we hit the beginning of document
- * 2. exceed maxstretch
- * 3. we hit an already marked fragment
+ maxstretch = (max_words - curlen) / 2;
+
+ /*
+ * first stretch the startpos stop stretching if 1. we hit the
+ * beginning of document 2. exceed maxstretch 3. we hit an
+ * already marked fragment
*/
- stretch = 0;
+ stretch = 0;
posmarker = startpos;
for (i = startpos - 1; i >= 0 && stretch < maxstretch && !prs->words[i].in; i--)
{
if (!NONWORDTOKEN(prs->words[i].type))
{
- curlen ++;
- stretch ++;
+ curlen++;
+ stretch++;
}
posmarker = i;
}
@@ -2291,35 +2304,35 @@ mark_hl_fragments(HeadlineParsedText *prs, TSQuery query, int highlight,
for (i = posmarker; i < startpos && (NOENDTOKEN(prs->words[i].type) || prs->words[i].len <= shortword); i++)
{
if (!NONWORDTOKEN(prs->words[i].type))
- curlen --;
+ curlen--;
}
startpos = i;
- /* now stretch the endpos as much as possible*/
+ /* now stretch the endpos as much as possible */
posmarker = endpos;
for (i = endpos + 1; i < prs->curwords && curlen < max_words && !prs->words[i].in; i++)
{
if (!NONWORDTOKEN(prs->words[i].type))
- curlen ++;
+ curlen++;
posmarker = i;
}
/* cut back endpos till we find a non-short token */
- for ( i = posmarker; i > endpos && (NOENDTOKEN(prs->words[i].type) || prs->words[i].len <= shortword); i--)
+ for (i = posmarker; i > endpos && (NOENDTOKEN(prs->words[i].type) || prs->words[i].len <= shortword); i--)
{
if (!NONWORDTOKEN(prs->words[i].type))
- curlen --;
+ curlen--;
}
endpos = i;
}
covers[minI].startpos = startpos;
- covers[minI].endpos = endpos;
- covers[minI].curlen = curlen;
+ covers[minI].endpos = endpos;
+ covers[minI].curlen = curlen;
/* Mark the chosen fragments (covers) */
mark_fragment(prs, highlight, startpos, endpos);
- num_f ++;
+ num_f++;
/* exclude overlapping covers */
- for (i = 0; i < numcovers; i ++)
+ for (i = 0; i < numcovers; i++)
{
- if (i != minI && ( (covers[i].startpos >= covers[minI].startpos && covers[i].startpos <= covers[minI].endpos) || (covers[i].endpos >= covers[minI].startpos && covers[i].endpos <= covers[minI].endpos)))
+ if (i != minI && ((covers[i].startpos >= covers[minI].startpos && covers[i].startpos <= covers[minI].endpos) || (covers[i].endpos >= covers[minI].startpos && covers[i].endpos <= covers[minI].endpos)))
covers[i].excluded = 1;
}
}
@@ -2327,7 +2340,7 @@ mark_hl_fragments(HeadlineParsedText *prs, TSQuery query, int highlight,
break;
}
- /* show at least min_words we have not marked anything*/
+ /* show at least min_words we have not marked anything */
if (num_f <= 0)
{
startpos = endpos = curlen = 0;
@@ -2344,7 +2357,7 @@ mark_hl_fragments(HeadlineParsedText *prs, TSQuery query, int highlight,
static void
mark_hl_words(HeadlineParsedText *prs, TSQuery query, int highlight,
- int shortword, int min_words, int max_words)
+ int shortword, int min_words, int max_words)
{
int p = 0,
q = 0;
@@ -2408,7 +2421,7 @@ mark_hl_words(HeadlineParsedText *prs, TSQuery query, int highlight,
curlen++;
if (prs->words[i].item && !prs->words[i].repeated)
poslen++;
- if ( curlen >= max_words )
+ if (curlen >= max_words)
break;
if (NOENDTOKEN(prs->words[i].type) || prs->words[i].len <= shortword)
continue;
@@ -2472,7 +2485,7 @@ mark_hl_words(HeadlineParsedText *prs, TSQuery query, int highlight,
{
if (HLIDREPLACE(prs->words[i].type))
prs->words[i].replace = 1;
- else if ( HLIDSKIP(prs->words[i].type) )
+ else if (HLIDSKIP(prs->words[i].type))
prs->words[i].skip = 1;
}
else
@@ -2494,11 +2507,11 @@ prsd_headline(PG_FUNCTION_ARGS)
TSQuery query = PG_GETARG_TSQUERY(2);
/* from opt + start and and tag */
- int min_words = 15;
- int max_words = 35;
- int shortword = 3;
+ int min_words = 15;
+ int max_words = 35;
+ int shortword = 3;
int max_fragments = 0;
- int highlight = 0;
+ int highlight = 0;
ListCell *l;
/* config */
diff --git a/src/backend/utils/adt/acl.c b/src/backend/utils/adt/acl.c
index 2f27018b25..dc75ad86ce 100644
--- a/src/backend/utils/adt/acl.c
+++ b/src/backend/utils/adt/acl.c
@@ -113,7 +113,7 @@ static AclMode convert_role_priv_string(text *priv_type_text);
static AclResult pg_role_aclcheck(Oid role_oid, Oid roleid, AclMode mode);
static void RoleMembershipCacheCallback(Datum arg, int cacheid, ItemPointer tuplePtr);
-static Oid get_role_oid_or_public(const char *rolname);
+static Oid get_role_oid_or_public(const char *rolname);
/*
@@ -4829,7 +4829,7 @@ get_role_oid(const char *rolname, bool missing_ok)
/*
* get_role_oid_or_public - As above, but return ACL_ID_PUBLIC if the
- * role name is "public".
+ * role name is "public".
*/
static Oid
get_role_oid_or_public(const char *rolname)
diff --git a/src/backend/utils/adt/arrayfuncs.c b/src/backend/utils/adt/arrayfuncs.c
index e023b2458e..0869de66ce 100644
--- a/src/backend/utils/adt/arrayfuncs.c
+++ b/src/backend/utils/adt/arrayfuncs.c
@@ -72,7 +72,7 @@ typedef struct ArrayIteratorData
/* current position information, updated on each iteration */
char *data_ptr; /* our current position in the array */
int current_item; /* the item # we're at in the array */
-} ArrayIteratorData;
+} ArrayIteratorData;
static bool array_isspace(char ch);
static int ArrayCount(const char *str, int *dim, char typdelim);
@@ -1268,7 +1268,8 @@ array_recv(PG_FUNCTION_ARGS)
*/
if (dim[i] != 0)
{
- int ub = lBound[i] + dim[i] - 1;
+ int ub = lBound[i] + dim[i] - 1;
+
if (lBound[i] > ub)
ereport(ERROR,
(errcode(ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE),
diff --git a/src/backend/utils/adt/cash.c b/src/backend/utils/adt/cash.c
index 4c3279759d..faef6f8381 100644
--- a/src/backend/utils/adt/cash.c
+++ b/src/backend/utils/adt/cash.c
@@ -945,11 +945,11 @@ numeric_cash(PG_FUNCTION_ARGS)
Datum
int4_cash(PG_FUNCTION_ARGS)
{
- int32 amount = PG_GETARG_INT32(0);
- Cash result;
- int fpoint;
- int64 scale;
- int i;
+ int32 amount = PG_GETARG_INT32(0);
+ Cash result;
+ int fpoint;
+ int64 scale;
+ int i;
struct lconv *lconvert = PGLC_localeconv();
/* see comments about frac_digits in cash_in() */
@@ -964,7 +964,7 @@ int4_cash(PG_FUNCTION_ARGS)
/* compute amount * scale, checking for overflow */
result = DatumGetInt64(DirectFunctionCall2(int8mul, Int64GetDatum(amount),
- Int64GetDatum(scale)));
+ Int64GetDatum(scale)));
PG_RETURN_CASH(result);
}
@@ -975,11 +975,11 @@ int4_cash(PG_FUNCTION_ARGS)
Datum
int8_cash(PG_FUNCTION_ARGS)
{
- int64 amount = PG_GETARG_INT64(0);
- Cash result;
- int fpoint;
- int64 scale;
- int i;
+ int64 amount = PG_GETARG_INT64(0);
+ Cash result;
+ int fpoint;
+ int64 scale;
+ int i;
struct lconv *lconvert = PGLC_localeconv();
/* see comments about frac_digits in cash_in() */
@@ -994,7 +994,7 @@ int8_cash(PG_FUNCTION_ARGS)
/* compute amount * scale, checking for overflow */
result = DatumGetInt64(DirectFunctionCall2(int8mul, Int64GetDatum(amount),
- Int64GetDatum(scale)));
+ Int64GetDatum(scale)));
PG_RETURN_CASH(result);
}
diff --git a/src/backend/utils/adt/date.c b/src/backend/utils/adt/date.c
index f96fa6cb72..e737e720f5 100644
--- a/src/backend/utils/adt/date.c
+++ b/src/backend/utils/adt/date.c
@@ -472,7 +472,7 @@ date2timestamptz(DateADT dateVal)
double
date2timestamp_no_overflow(DateADT dateVal)
{
- double result;
+ double result;
if (DATE_IS_NOBEGIN(dateVal))
result = -DBL_MAX;
diff --git a/src/backend/utils/adt/datetime.c b/src/backend/utils/adt/datetime.c
index 0410b8384e..db0a6487ac 100644
--- a/src/backend/utils/adt/datetime.c
+++ b/src/backend/utils/adt/datetime.c
@@ -2397,7 +2397,7 @@ DecodeTime(char *str, int fmask, int range,
/* do a sanity check */
#ifdef HAVE_INT64_TIMESTAMP
- if (tm->tm_hour < 0 || tm->tm_min < 0 || tm->tm_min > MINS_PER_HOUR -1 ||
+ if (tm->tm_hour < 0 || tm->tm_min < 0 || tm->tm_min > MINS_PER_HOUR - 1 ||
tm->tm_sec < 0 || tm->tm_sec > SECS_PER_MINUTE ||
*fsec < INT64CONST(0) ||
*fsec > USECS_PER_SEC)
diff --git a/src/backend/utils/adt/dbsize.c b/src/backend/utils/adt/dbsize.c
index 543a244bf9..73a6ad3280 100644
--- a/src/backend/utils/adt/dbsize.c
+++ b/src/backend/utils/adt/dbsize.c
@@ -634,7 +634,7 @@ pg_relation_filepath(PG_FUNCTION_ARGS)
break;
default:
elog(ERROR, "invalid relpersistence: %c", relform->relpersistence);
- backend = InvalidBackendId; /* placate compiler */
+ backend = InvalidBackendId; /* placate compiler */
break;
}
diff --git a/src/backend/utils/adt/enum.c b/src/backend/utils/adt/enum.c
index be4f984ed6..8f65c84d30 100644
--- a/src/backend/utils/adt/enum.c
+++ b/src/backend/utils/adt/enum.c
@@ -461,7 +461,7 @@ enum_range_internal(Oid enumtypoid, Oid lower, Oid upper)
Datum *elems;
int max,
cnt;
- bool left_found;
+ bool left_found;
/*
* Scan the enum members in order using pg_enum_typid_sortorder_index.
@@ -486,7 +486,7 @@ enum_range_internal(Oid enumtypoid, Oid lower, Oid upper)
while (HeapTupleIsValid(enum_tuple = systable_getnext_ordered(enum_scan, ForwardScanDirection)))
{
- Oid enum_oid = HeapTupleGetOid(enum_tuple);
+ Oid enum_oid = HeapTupleGetOid(enum_tuple);
if (!left_found && lower == enum_oid)
left_found = true;
diff --git a/src/backend/utils/adt/formatting.c b/src/backend/utils/adt/formatting.c
index 45e36f92e5..f895bbbb8b 100644
--- a/src/backend/utils/adt/formatting.c
+++ b/src/backend/utils/adt/formatting.c
@@ -662,7 +662,7 @@ typedef enum
/* last */
_DCH_last_
-} DCH_poz;
+} DCH_poz;
typedef enum
{
@@ -705,7 +705,7 @@ typedef enum
/* last */
_NUM_last_
-} NUM_poz;
+} NUM_poz;
/* ----------
* KeyWords for DATE-TIME version
@@ -1497,7 +1497,7 @@ str_tolower(const char *buff, size_t nbytes, Oid collid)
#ifdef USE_WIDE_UPPER_LOWER
else if (pg_database_encoding_max_length() > 1)
{
- pg_locale_t mylocale = 0;
+ pg_locale_t mylocale = 0;
wchar_t *workspace;
size_t curr_char;
size_t result_size;
@@ -1549,7 +1549,7 @@ str_tolower(const char *buff, size_t nbytes, Oid collid)
#endif /* USE_WIDE_UPPER_LOWER */
else
{
- pg_locale_t mylocale = 0;
+ pg_locale_t mylocale = 0;
char *p;
if (collid != DEFAULT_COLLATION_OID)
@@ -1618,7 +1618,7 @@ str_toupper(const char *buff, size_t nbytes, Oid collid)
#ifdef USE_WIDE_UPPER_LOWER
else if (pg_database_encoding_max_length() > 1)
{
- pg_locale_t mylocale = 0;
+ pg_locale_t mylocale = 0;
wchar_t *workspace;
size_t curr_char;
size_t result_size;
@@ -1670,7 +1670,7 @@ str_toupper(const char *buff, size_t nbytes, Oid collid)
#endif /* USE_WIDE_UPPER_LOWER */
else
{
- pg_locale_t mylocale = 0;
+ pg_locale_t mylocale = 0;
char *p;
if (collid != DEFAULT_COLLATION_OID)
@@ -1736,7 +1736,7 @@ str_initcap(const char *buff, size_t nbytes, Oid collid)
for (p = result; *p; p++)
{
- char c;
+ char c;
if (wasalnum)
*p = c = pg_ascii_tolower((unsigned char) *p);
@@ -1751,7 +1751,7 @@ str_initcap(const char *buff, size_t nbytes, Oid collid)
#ifdef USE_WIDE_UPPER_LOWER
else if (pg_database_encoding_max_length() > 1)
{
- pg_locale_t mylocale = 0;
+ pg_locale_t mylocale = 0;
wchar_t *workspace;
size_t curr_char;
size_t result_size;
@@ -1815,7 +1815,7 @@ str_initcap(const char *buff, size_t nbytes, Oid collid)
#endif /* USE_WIDE_UPPER_LOWER */
else
{
- pg_locale_t mylocale = 0;
+ pg_locale_t mylocale = 0;
char *p;
if (collid != DEFAULT_COLLATION_OID)
@@ -1838,7 +1838,7 @@ str_initcap(const char *buff, size_t nbytes, Oid collid)
/*
* Note: we assume that toupper_l()/tolower_l() will not be so broken
- * as to need guard tests. When using the default collation, we apply
+ * as to need guard tests. When using the default collation, we apply
* the traditional Postgres behavior that forces ASCII-style treatment
* of I/i, but in non-default collations you get exactly what the
* collation says.
@@ -2318,7 +2318,7 @@ DCH_to_char(FormatNode *node, bool is_interval, TmToChar *in, char *out, Oid col
* intervals
*/
sprintf(s, "%0*d", S_FM(n->suffix) ? 0 : 2,
- tm->tm_hour % (HOURS_PER_DAY / 2) == 0 ? HOURS_PER_DAY / 2 :
+ tm->tm_hour % (HOURS_PER_DAY / 2) == 0 ? HOURS_PER_DAY / 2 :
tm->tm_hour % (HOURS_PER_DAY / 2));
if (S_THth(n->suffix))
str_numth(s, s, S_TH_TYPE(n->suffix));
@@ -2423,7 +2423,7 @@ DCH_to_char(FormatNode *node, bool is_interval, TmToChar *in, char *out, Oid col
strcpy(s, str_toupper_z(localized_full_months[tm->tm_mon - 1], collid));
else
sprintf(s, "%*s", S_FM(n->suffix) ? 0 : -9,
- str_toupper_z(months_full[tm->tm_mon - 1], collid));
+ str_toupper_z(months_full[tm->tm_mon - 1], collid));
s += strlen(s);
break;
case DCH_Month:
diff --git a/src/backend/utils/adt/genfile.c b/src/backend/utils/adt/genfile.c
index 7c59e9a20e..6b3f77fec1 100644
--- a/src/backend/utils/adt/genfile.c
+++ b/src/backend/utils/adt/genfile.c
@@ -56,18 +56,19 @@ convert_and_check_filename(text *arg)
/* Disallow '/a/b/data/..' */
if (path_contains_parent_reference(filename))
ereport(ERROR,
- (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- (errmsg("reference to parent directory (\"..\") not allowed"))));
+ (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
+ (errmsg("reference to parent directory (\"..\") not allowed"))));
+
/*
- * Allow absolute paths if within DataDir or Log_directory, even
- * though Log_directory might be outside DataDir.
+ * Allow absolute paths if within DataDir or Log_directory, even
+ * though Log_directory might be outside DataDir.
*/
if (!path_is_prefix_of_path(DataDir, filename) &&
(!is_absolute_path(Log_directory) ||
!path_is_prefix_of_path(Log_directory, filename)))
ereport(ERROR,
- (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- (errmsg("absolute path not allowed"))));
+ (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
+ (errmsg("absolute path not allowed"))));
}
else if (!path_is_relative_and_below_cwd(filename))
ereport(ERROR,
diff --git a/src/backend/utils/adt/like.c b/src/backend/utils/adt/like.c
index b060faa6a9..0934c69ebe 100644
--- a/src/backend/utils/adt/like.c
+++ b/src/backend/utils/adt/like.c
@@ -30,19 +30,19 @@
#define LIKE_ABORT (-1)
-static int SB_MatchText(char *t, int tlen, char *p, int plen,
- pg_locale_t locale, bool locale_is_c);
+static int SB_MatchText(char *t, int tlen, char *p, int plen,
+ pg_locale_t locale, bool locale_is_c);
static text *SB_do_like_escape(text *, text *);
-static int MB_MatchText(char *t, int tlen, char *p, int plen,
- pg_locale_t locale, bool locale_is_c);
+static int MB_MatchText(char *t, int tlen, char *p, int plen,
+ pg_locale_t locale, bool locale_is_c);
static text *MB_do_like_escape(text *, text *);
-static int UTF8_MatchText(char *t, int tlen, char *p, int plen,
- pg_locale_t locale, bool locale_is_c);
+static int UTF8_MatchText(char *t, int tlen, char *p, int plen,
+ pg_locale_t locale, bool locale_is_c);
-static int SB_IMatchText(char *t, int tlen, char *p, int plen,
- pg_locale_t locale, bool locale_is_c);
+static int SB_IMatchText(char *t, int tlen, char *p, int plen,
+ pg_locale_t locale, bool locale_is_c);
static int GenericMatchText(char *s, int slen, char *p, int plen);
static int Generic_Text_IC_like(text *str, text *pat, Oid collation);
@@ -188,11 +188,11 @@ Generic_Text_IC_like(text *str, text *pat, Oid collation)
else
{
/*
- * Here we need to prepare locale information for SB_lower_char.
- * This should match the methods used in str_tolower().
+ * Here we need to prepare locale information for SB_lower_char. This
+ * should match the methods used in str_tolower().
*/
- pg_locale_t locale = 0;
- bool locale_is_c = false;
+ pg_locale_t locale = 0;
+ bool locale_is_c = false;
if (lc_ctype_is_c(collation))
locale_is_c = true;
diff --git a/src/backend/utils/adt/nabstime.c b/src/backend/utils/adt/nabstime.c
index 4b61b21cbe..6771e78af8 100644
--- a/src/backend/utils/adt/nabstime.c
+++ b/src/backend/utils/adt/nabstime.c
@@ -182,8 +182,8 @@ tm2abstime(struct pg_tm * tm, int tz)
tm->tm_mon < 1 || tm->tm_mon > MONTHS_PER_YEAR ||
tm->tm_mday < 1 || tm->tm_mday > 31 ||
tm->tm_hour < 0 ||
- tm->tm_hour > HOURS_PER_DAY || /* test for > 24:00:00 */
- (tm->tm_hour == HOURS_PER_DAY && (tm->tm_min > 0 || tm->tm_sec > 0)) ||
+ tm->tm_hour > HOURS_PER_DAY || /* test for > 24:00:00 */
+ (tm->tm_hour == HOURS_PER_DAY && (tm->tm_min > 0 || tm->tm_sec > 0)) ||
tm->tm_min < 0 || tm->tm_min > MINS_PER_HOUR - 1 ||
tm->tm_sec < 0 || tm->tm_sec > SECS_PER_MINUTE)
return INVALID_ABSTIME;
@@ -1163,7 +1163,7 @@ tintervalsame(PG_FUNCTION_ARGS)
* 1. The interval length computations overflow at 2^31 seconds, causing
* intervals longer than that to sort oddly compared to those shorter.
* 2. infinity and minus infinity (NOEND_ABSTIME and NOSTART_ABSTIME) are
- * just ordinary integers. Since this code doesn't handle them specially,
+ * just ordinary integers. Since this code doesn't handle them specially,
* it's possible for [a b] to be considered longer than [c infinity] for
* finite abstimes a, b, c. In combination with the previous point, the
* interval [-infinity infinity] is treated as being shorter than many finite
diff --git a/src/backend/utils/adt/network.c b/src/backend/utils/adt/network.c
index 8cac11134c..80e5915b3e 100644
--- a/src/backend/utils/adt/network.c
+++ b/src/backend/utils/adt/network.c
@@ -319,7 +319,7 @@ inet_to_cidr(PG_FUNCTION_ARGS)
inet *src = PG_GETARG_INET_P(0);
inet *dst;
int bits;
- int byte;
+ int byte;
int nbits;
int maxbytes;
@@ -340,15 +340,15 @@ inet_to_cidr(PG_FUNCTION_ARGS)
/* clear the first byte, this might be a partial byte */
if (nbits != 0)
{
- ip_addr(dst)[byte] &=~(0xFF >> nbits);
- byte ++;
+ ip_addr(dst)[byte] &= ~(0xFF >> nbits);
+ byte++;
}
/* clear remaining bytes */
maxbytes = ip_addrsize(dst);
- while (byte > nbits);
- byte ++;
+ ip_addr(dst)[byte] &= ~(0xFF >> nbits);
+ byte++;
}
/* clear remaining bytes */
maxbytes = ip_addrsize(dst);
- while (byte = 8)
{
@@ -750,7 +750,7 @@ network_broadcast(PG_FUNCTION_ARGS)
bits = 0;
}
- b[byte] = a[byte] |mask;
+ b[byte] = a[byte] | mask;
}
ip_family(dst) = ip_family(ip);
@@ -765,7 +765,7 @@ network_network(PG_FUNCTION_ARGS)
{
inet *ip = PG_GETARG_INET_P(0);
inet *dst;
- int byte;
+ int byte;
int bits;
unsigned char mask;
unsigned char *a,
@@ -793,8 +793,8 @@ network_network(PG_FUNCTION_ARGS)
bits = 0;
}
- b[byte] = a[byte] &mask;
- byte ++;
+ b[byte] = a[byte] & mask;
+ byte++;
}
ip_family(dst) = ip_family(ip);
@@ -809,7 +809,7 @@ network_netmask(PG_FUNCTION_ARGS)
{
inet *ip = PG_GETARG_INET_P(0);
inet *dst;
- int byte;
+ int byte;
int bits;
unsigned char mask;
unsigned char *b;
@@ -836,7 +836,7 @@ network_netmask(PG_FUNCTION_ARGS)
}
b[byte] = mask;
- byte ++;
+ byte++;
}
ip_family(dst) = ip_family(ip);
@@ -851,7 +851,7 @@ network_hostmask(PG_FUNCTION_ARGS)
{
inet *ip = PG_GETARG_INET_P(0);
inet *dst;
- int byte;
+ int byte;
int bits;
int maxbytes;
unsigned char mask;
@@ -884,7 +884,7 @@ network_hostmask(PG_FUNCTION_ARGS)
}
b[byte] = mask;
- byte --;
+ byte--;
}
ip_family(dst) = ip_family(ip);
@@ -994,7 +994,7 @@ bitncmp(void *l, void *r, int n)
static bool
addressOK(unsigned char *a, int bits, int family)
{
- int byte;
+ int byte;
int nbits;
int maxbits;
int maxbytes;
@@ -1022,12 +1022,12 @@ addressOK(unsigned char *a, int bits, int family)
if (bits != 0)
mask >>= nbits;
- while (byte >= 8;
- byte ++;
+ byte++;
}
/*
* If input is narrower than int64, overflow is not possible, but we
* have to do proper sign extension.
*/
- if (carry == 0 && byte > 16) & 0xffff;
/*
- * This formula computes the maximum number of NumericDigits we could
- * need in order to store the specified number of decimal digits.
- * Because the weight is stored as a number of NumericDigits rather
- * than a number of decimal digits, it's possible that the first
- * NumericDigit will contain only a single decimal digit. Thus, the
- * first two decimal digits can require two NumericDigits to store,
- * but it isn't until we reach DEC_DIGITS + 2 decimal digits that we
- * potentially need a third NumericDigit.
+ * This formula computes the maximum number of NumericDigits we could need
+ * in order to store the specified number of decimal digits. Because the
+ * weight is stored as a number of NumericDigits rather than a number of
+ * decimal digits, it's possible that the first NumericDigit will contain
+ * only a single decimal digit. Thus, the first two decimal digits can
+ * require two NumericDigits to store, but it isn't until we reach
+ * DEC_DIGITS + 2 decimal digits that we potentially need a third
+ * NumericDigit.
*/
numeric_digits = (precision + 2 * (DEC_DIGITS - 1)) / DEC_DIGITS;
/*
* In most cases, the size of a numeric will be smaller than the value
* computed below, because the varlena header will typically get toasted
- * down to a single byte before being stored on disk, and it may also
- * be possible to use a short numeric header. But our job here is to
- * compute the worst case.
+ * down to a single byte before being stored on disk, and it may also be
+ * possible to use a short numeric header. But our job here is to compute
+ * the worst case.
*/
return NUMERIC_HDRSZ + (numeric_digits * sizeof(NumericDigit));
}
@@ -761,12 +761,13 @@ numeric (PG_FUNCTION_ARGS)
* If the number is certainly in bounds and due to the target scale no
* rounding could be necessary, just make a copy of the input and modify
* its scale fields, unless the larger scale forces us to abandon the
- * short representation. (Note we assume the existing dscale is honest...)
+ * short representation. (Note we assume the existing dscale is
+ * honest...)
*/
ddigits = (NUMERIC_WEIGHT(num) + 1) * DEC_DIGITS;
if (ddigits <= maxdigits && scale >= NUMERIC_DSCALE(num)
&& (NUMERIC_CAN_BE_SHORT(scale, NUMERIC_WEIGHT(num))
- || !NUMERIC_IS_SHORT(num)))
+ || !NUMERIC_IS_SHORT(num)))
{
new = (Numeric) palloc(VARSIZE(num));
memcpy(new, num, VARSIZE(num));
@@ -1427,7 +1428,7 @@ hash_numeric(PG_FUNCTION_ARGS)
int end_offset;
int i;
int hash_len;
- NumericDigit *digits;
+ NumericDigit *digits;
/* If it's NaN, don't try to hash the rest of the fields */
if (NUMERIC_IS_NAN(key))
@@ -3727,7 +3728,7 @@ make_result(NumericVar *var)
SET_VARSIZE(result, len);
result->choice.n_short.n_header =
(sign == NUMERIC_NEG ? (NUMERIC_SHORT | NUMERIC_SHORT_SIGN_MASK)
- : NUMERIC_SHORT)
+ : NUMERIC_SHORT)
| (var->dscale << NUMERIC_SHORT_DSCALE_SHIFT)
| (weight < 0 ? NUMERIC_SHORT_WEIGHT_SIGN_MASK : 0)
| (weight & NUMERIC_SHORT_WEIGHT_MASK);
diff --git a/src/backend/utils/adt/numutils.c b/src/backend/utils/adt/numutils.c
index 38ce38821e..37d208994c 100644
--- a/src/backend/utils/adt/numutils.c
+++ b/src/backend/utils/adt/numutils.c
@@ -136,7 +136,7 @@ pg_ltoa(int32 value, char *a)
* Avoid problems with the most negative integer not being representable
* as a positive integer.
*/
- if (value == (-2147483647-1))
+ if (value == (-2147483647 - 1))
{
memcpy(a, "-2147483648", 12);
return;
@@ -150,8 +150,8 @@ pg_ltoa(int32 value, char *a)
/* Compute the result string backwards. */
do
{
- int32 remainder;
- int32 oldval = value;
+ int32 remainder;
+ int32 oldval = value;
value /= 10;
remainder = oldval - value * 10;
@@ -167,7 +167,7 @@ pg_ltoa(int32 value, char *a)
/* Reverse string. */
while (start < a)
{
- char swap = *start;
+ char swap = *start;
*start++ = *a;
*a-- = swap;
@@ -190,7 +190,7 @@ pg_lltoa(int64 value, char *a)
* Avoid problems with the most negative integer not being representable
* as a positive integer.
*/
- if (value == (-INT64CONST(0x7FFFFFFFFFFFFFFF)-1))
+ if (value == (-INT64CONST(0x7FFFFFFFFFFFFFFF) - 1))
{
memcpy(a, "-9223372036854775808", 21);
return;
@@ -204,8 +204,8 @@ pg_lltoa(int64 value, char *a)
/* Compute the result string backwards. */
do
{
- int64 remainder;
- int64 oldval = value;
+ int64 remainder;
+ int64 oldval = value;
value /= 10;
remainder = oldval - value * 10;
@@ -221,7 +221,7 @@ pg_lltoa(int64 value, char *a)
/* Reverse string. */
while (start < a)
{
- char swap = *start;
+ char swap = *start;
*start++ = *a;
*a-- = swap;
diff --git a/src/backend/utils/adt/pg_locale.c b/src/backend/utils/adt/pg_locale.c
index 09ff926cba..0e6723d469 100644
--- a/src/backend/utils/adt/pg_locale.c
+++ b/src/backend/utils/adt/pg_locale.c
@@ -107,7 +107,7 @@ typedef struct
bool collate_is_c; /* is collation's LC_COLLATE C? */
bool ctype_is_c; /* is collation's LC_CTYPE C? */
bool flags_valid; /* true if above flags are valid */
- pg_locale_t locale; /* locale_t struct, or 0 if not valid */
+ pg_locale_t locale; /* locale_t struct, or 0 if not valid */
} collation_cache_entry;
static HTAB *collation_cache = NULL;
@@ -242,7 +242,7 @@ check_locale(int category, const char *value)
*
* For most locale categories, the assign hook doesn't actually set the locale
* permanently, just reset flags so that the next use will cache the
- * appropriate values. (See explanation at the top of this file.)
+ * appropriate values. (See explanation at the top of this file.)
*
* Note: we accept value = "" as selecting the postmaster's environment
* value, whatever it was (so long as the environment setting is legal).
@@ -728,7 +728,6 @@ IsoLocaleName(const char *winlocname)
return NULL; /* Not supported on this version of msvc/mingw */
#endif /* _MSC_VER >= 1400 */
}
-
#endif /* WIN32 && LC_MESSAGES */
@@ -750,7 +749,7 @@ IsoLocaleName(const char *winlocname)
* could fail if the locale is C, so str_tolower() shouldn't call it
* in that case.
*
- * Note that we currently lack any way to flush the cache. Since we don't
+ * Note that we currently lack any way to flush the cache. Since we don't
* support ALTER COLLATION, this is OK. The worst case is that someone
* drops a collation, and a useless cache entry hangs around in existing
* backends.
@@ -826,15 +825,15 @@ bool
lc_collate_is_c(Oid collation)
{
/*
- * If we're asked about "collation 0", return false, so that the code
- * will go into the non-C path and report that the collation is bogus.
+ * If we're asked about "collation 0", return false, so that the code will
+ * go into the non-C path and report that the collation is bogus.
*/
if (!OidIsValid(collation))
return false;
/*
- * If we're asked about the default collation, we have to inquire of
- * the C library. Cache the result so we only have to compute it once.
+ * If we're asked about the default collation, we have to inquire of the C
+ * library. Cache the result so we only have to compute it once.
*/
if (collation == DEFAULT_COLLATION_OID)
{
@@ -876,15 +875,15 @@ bool
lc_ctype_is_c(Oid collation)
{
/*
- * If we're asked about "collation 0", return false, so that the code
- * will go into the non-C path and report that the collation is bogus.
+ * If we're asked about "collation 0", return false, so that the code will
+ * go into the non-C path and report that the collation is bogus.
*/
if (!OidIsValid(collation))
return false;
/*
- * If we're asked about the default collation, we have to inquire of
- * the C library. Cache the result so we only have to compute it once.
+ * If we're asked about the default collation, we have to inquire of the C
+ * library. Cache the result so we only have to compute it once.
*/
if (collation == DEFAULT_COLLATION_OID)
{
@@ -921,7 +920,7 @@ lc_ctype_is_c(Oid collation)
/*
- * Create a locale_t from a collation OID. Results are cached for the
+ * Create a locale_t from a collation OID. Results are cached for the
* lifetime of the backend. Thus, do not free the result with freelocale().
*
* As a special optimization, the default/database collation returns 0.
@@ -987,7 +986,7 @@ pg_newlocale_from_collation(Oid collid)
{
#ifndef WIN32
/* We need two newlocale() steps */
- locale_t loc1;
+ locale_t loc1;
loc1 = newlocale(LC_COLLATE_MASK, collcollate, NULL);
if (!loc1)
@@ -1002,10 +1001,11 @@ pg_newlocale_from_collation(Oid collid)
errmsg("could not create locale \"%s\": %m",
collctype)));
#else
+
/*
- * XXX The _create_locale() API doesn't appear to support
- * this. Could perhaps be worked around by changing
- * pg_locale_t to contain two separate fields.
+ * XXX The _create_locale() API doesn't appear to support this.
+ * Could perhaps be worked around by changing pg_locale_t to
+ * contain two separate fields.
*/
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
@@ -1016,8 +1016,7 @@ pg_newlocale_from_collation(Oid collid)
cache_entry->locale = result;
ReleaseSysCache(tp);
-
-#else /* not HAVE_LOCALE_T */
+#else /* not HAVE_LOCALE_T */
/*
* For platforms that don't support locale_t, we can't do anything
@@ -1025,8 +1024,8 @@ pg_newlocale_from_collation(Oid collid)
*/
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("nondefault collations are not supported on this platform")));
-#endif /* not HAVE_LOCALE_T */
+ errmsg("nondefault collations are not supported on this platform")));
+#endif /* not HAVE_LOCALE_T */
}
return cache_entry->locale;
diff --git a/src/backend/utils/adt/pgstatfuncs.c b/src/backend/utils/adt/pgstatfuncs.c
index 137c811bc3..f811245cea 100644
--- a/src/backend/utils/adt/pgstatfuncs.c
+++ b/src/backend/utils/adt/pgstatfuncs.c
@@ -364,7 +364,7 @@ pg_stat_get_vacuum_count(PG_FUNCTION_ARGS)
{
Oid relid = PG_GETARG_OID(0);
int64 result;
- PgStat_StatTabEntry *tabentry;
+ PgStat_StatTabEntry *tabentry;
if ((tabentry = pgstat_fetch_stat_tabentry(relid)) == NULL)
result = 0;
@@ -379,7 +379,7 @@ pg_stat_get_autovacuum_count(PG_FUNCTION_ARGS)
{
Oid relid = PG_GETARG_OID(0);
int64 result;
- PgStat_StatTabEntry *tabentry;
+ PgStat_StatTabEntry *tabentry;
if ((tabentry = pgstat_fetch_stat_tabentry(relid)) == NULL)
result = 0;
@@ -394,7 +394,7 @@ pg_stat_get_analyze_count(PG_FUNCTION_ARGS)
{
Oid relid = PG_GETARG_OID(0);
int64 result;
- PgStat_StatTabEntry *tabentry;
+ PgStat_StatTabEntry *tabentry;
if ((tabentry = pgstat_fetch_stat_tabentry(relid)) == NULL)
result = 0;
@@ -409,7 +409,7 @@ pg_stat_get_autoanalyze_count(PG_FUNCTION_ARGS)
{
Oid relid = PG_GETARG_OID(0);
int64 result;
- PgStat_StatTabEntry *tabentry;
+ PgStat_StatTabEntry *tabentry;
if ((tabentry = pgstat_fetch_stat_tabentry(relid)) == NULL)
result = 0;
@@ -1263,11 +1263,11 @@ pg_stat_get_db_conflict_all(PG_FUNCTION_ARGS)
result = 0;
else
result = (int64) (
- dbentry->n_conflict_tablespace +
- dbentry->n_conflict_lock +
- dbentry->n_conflict_snapshot +
- dbentry->n_conflict_bufferpin +
- dbentry->n_conflict_startup_deadlock);
+ dbentry->n_conflict_tablespace +
+ dbentry->n_conflict_lock +
+ dbentry->n_conflict_snapshot +
+ dbentry->n_conflict_bufferpin +
+ dbentry->n_conflict_startup_deadlock);
PG_RETURN_INT64(result);
}
diff --git a/src/backend/utils/adt/ri_triggers.c b/src/backend/utils/adt/ri_triggers.c
index 591d2eb16b..84797191ef 100644
--- a/src/backend/utils/adt/ri_triggers.c
+++ b/src/backend/utils/adt/ri_triggers.c
@@ -2608,7 +2608,7 @@ RI_FKey_keyequal_upd_fk(Trigger *trigger, Relation fk_rel,
* This is not a trigger procedure, but is called during ALTER TABLE
* ADD FOREIGN KEY to validate the initial table contents.
*
- * We expect that the caller has made provision to prevent any problems
+ * We expect that the caller has made provision to prevent any problems
* caused by concurrent actions. This could be either by locking rel and
* pkrel at ShareRowExclusiveLock or higher, or by otherwise ensuring
* that triggers implementing the checks are already active.
@@ -2629,8 +2629,8 @@ RI_Initial_Check(Trigger *trigger, Relation fk_rel, Relation pk_rel)
char fkrelname[MAX_QUOTED_REL_NAME_LEN];
char pkattname[MAX_QUOTED_NAME_LEN + 3];
char fkattname[MAX_QUOTED_NAME_LEN + 3];
- RangeTblEntry *pkrte;
- RangeTblEntry *fkrte;
+ RangeTblEntry *pkrte;
+ RangeTblEntry *fkrte;
const char *sep;
int i;
int old_work_mem;
@@ -2662,7 +2662,7 @@ RI_Initial_Check(Trigger *trigger, Relation fk_rel, Relation pk_rel)
for (i = 0; i < riinfo.nkeys; i++)
{
- int attno;
+ int attno;
attno = riinfo.pk_attnums[i] - FirstLowInvalidHeapAttributeNumber;
pkrte->selectedCols = bms_add_member(pkrte->selectedCols, attno);
@@ -2789,10 +2789,10 @@ RI_Initial_Check(Trigger *trigger, Relation fk_rel, Relation pk_rel)
/*
* Run the plan. For safety we force a current snapshot to be used. (In
- * transaction-snapshot mode, this arguably violates transaction
- * isolation rules, but we really haven't got much choice.)
- * We don't need to register the snapshot, because SPI_execute_snapshot
- * will see to it. We need at most one tuple returned, so pass limit = 1.
+ * transaction-snapshot mode, this arguably violates transaction isolation
+ * rules, but we really haven't got much choice.) We don't need to
+ * register the snapshot, because SPI_execute_snapshot will see to it. We
+ * need at most one tuple returned, so pass limit = 1.
*/
spi_result = SPI_execute_snapshot(qplan,
NULL, NULL,
@@ -3337,8 +3337,8 @@ ri_PerformCheck(RI_QueryKey *qkey, SPIPlanPtr qplan,
/*
* In READ COMMITTED mode, we just need to use an up-to-date regular
* snapshot, and we will see all rows that could be interesting. But in
- * transaction-snapshot mode, we can't change the transaction snapshot.
- * If the caller passes detectNewRows == false then it's okay to do the query
+ * transaction-snapshot mode, we can't change the transaction snapshot. If
+ * the caller passes detectNewRows == false then it's okay to do the query
* with the transaction snapshot; otherwise we use a current snapshot, and
* tell the executor to error out if it finds any rows under the current
* snapshot that wouldn't be visible per the transaction snapshot. Note
diff --git a/src/backend/utils/adt/ruleutils.c b/src/backend/utils/adt/ruleutils.c
index 326079a75b..e436a1ee59 100644
--- a/src/backend/utils/adt/ruleutils.c
+++ b/src/backend/utils/adt/ruleutils.c
@@ -169,11 +169,11 @@ static void set_deparse_planstate(deparse_namespace *dpns, PlanState *ps);
static void push_child_plan(deparse_namespace *dpns, PlanState *ps,
deparse_namespace *save_dpns);
static void pop_child_plan(deparse_namespace *dpns,
- deparse_namespace *save_dpns);
+ deparse_namespace *save_dpns);
static void push_ancestor_plan(deparse_namespace *dpns, ListCell *ancestor_cell,
deparse_namespace *save_dpns);
static void pop_ancestor_plan(deparse_namespace *dpns,
- deparse_namespace *save_dpns);
+ deparse_namespace *save_dpns);
static void make_ruledef(StringInfo buf, HeapTuple ruletup, TupleDesc rulettc,
int prettyFlags);
static void make_viewdef(StringInfo buf, HeapTuple ruletup, TupleDesc rulettc,
@@ -948,7 +948,7 @@ pg_get_indexdef_worker(Oid indexrelid, int colno,
if (!attrsOnly && (!colno || colno == keyno + 1))
{
- Oid indcoll;
+ Oid indcoll;
/* Add collation, if not default for column */
indcoll = indcollation->values[keyno];
@@ -2207,7 +2207,7 @@ set_deparse_planstate(deparse_namespace *dpns, PlanState *ps)
* We special-case Append and MergeAppend to pretend that the first child
* plan is the OUTER referent; we have to interpret OUTER Vars in their
* tlists according to one of the children, and the first one is the most
- * natural choice. Likewise special-case ModifyTable to pretend that the
+ * natural choice. Likewise special-case ModifyTable to pretend that the
* first child plan is the OUTER referent; this is to support RETURNING
* lists containing references to non-target relations.
*/
@@ -2263,8 +2263,8 @@ push_child_plan(deparse_namespace *dpns, PlanState *ps,
/*
* Currently we don't bother to adjust the ancestors list, because an
- * OUTER or INNER reference really shouldn't contain any Params that
- * would be set by the parent node itself. If we did want to adjust it,
+ * OUTER or INNER reference really shouldn't contain any Params that would
+ * be set by the parent node itself. If we did want to adjust it,
* lcons'ing dpns->planstate onto dpns->ancestors would be the appropriate
* thing --- and pop_child_plan would need to undo the change to the list.
*/
@@ -3780,8 +3780,8 @@ get_variable(Var *var, int levelsup, bool showstar, deparse_context *context)
* subquery's alias, that's not possible for resjunk items since they have
* no alias. So in that case, drill down to the subplan and print the
* contents of the referenced tlist item. This works because in a plan
- * tree, such Vars can only occur in a SubqueryScan or CteScan node,
- * and we'll have set dpns->inner_plan to reference the child plan node.
+ * tree, such Vars can only occur in a SubqueryScan or CteScan node, and
+ * we'll have set dpns->inner_plan to reference the child plan node.
*/
if ((rte->rtekind == RTE_SUBQUERY || rte->rtekind == RTE_CTE) &&
attnum > list_length(rte->eref->colnames) &&
@@ -4145,7 +4145,7 @@ get_name_for_var_field(Var *var, int fieldno,
if (lc != NULL)
{
Query *ctequery = (Query *) cte->ctequery;
- TargetEntry *ste = get_tle_by_resno(GetCTETargetList(cte),
+ TargetEntry *ste = get_tle_by_resno(GetCTETargetList(cte),
attnum);
if (ste == NULL || ste->resjunk)
@@ -4279,11 +4279,11 @@ static void
get_parameter(Param *param, deparse_context *context)
{
/*
- * If it's a PARAM_EXEC parameter, try to locate the expression from
- * which the parameter was computed. This will necessarily be in some
- * ancestor of the current expression's PlanState. Note that failing
- * to find a referent isn't an error, since the Param might well be a
- * subplan output rather than an input.
+ * If it's a PARAM_EXEC parameter, try to locate the expression from which
+ * the parameter was computed. This will necessarily be in some ancestor
+ * of the current expression's PlanState. Note that failing to find a
+ * referent isn't an error, since the Param might well be a subplan output
+ * rather than an input.
*/
if (param->paramkind == PARAM_EXEC)
{
@@ -4302,9 +4302,9 @@ get_parameter(Param *param, deparse_context *context)
ListCell *lc2;
/*
- * NestLoops transmit params to their inner child only; also,
- * once we've crawled up out of a subplan, this couldn't
- * possibly be the right match.
+ * NestLoops transmit params to their inner child only; also, once
+ * we've crawled up out of a subplan, this couldn't possibly be
+ * the right match.
*/
if (IsA(ps, NestLoopState) &&
child_ps == innerPlanState(ps) &&
@@ -4314,7 +4314,7 @@ get_parameter(Param *param, deparse_context *context)
foreach(lc2, nl->nestParams)
{
- NestLoopParam *nlp = (NestLoopParam *) lfirst(lc2);
+ NestLoopParam *nlp = (NestLoopParam *) lfirst(lc2);
if (nlp->paramno == param->paramid)
{
@@ -4342,8 +4342,8 @@ get_parameter(Param *param, deparse_context *context)
/* Matched subplan, so check its arguments */
forboth(lc3, subplan->parParam, lc4, subplan->args)
{
- int paramid = lfirst_int(lc3);
- Node *arg = (Node *) lfirst(lc4);
+ int paramid = lfirst_int(lc3);
+ Node *arg = (Node *) lfirst(lc4);
if (paramid == param->paramid)
{
@@ -4898,7 +4898,7 @@ get_rule_expr(Node *node, deparse_context *context,
appendStringInfo(buf, " %s %s (",
generate_operator_name(expr->opno,
exprType(arg1),
- get_base_element_type(exprType(arg2))),
+ get_base_element_type(exprType(arg2))),
expr->useOr ? "ANY" : "ALL");
get_rule_expr_paren(arg2, context, true, node);
appendStringInfoChar(buf, ')');
@@ -6126,7 +6126,7 @@ get_const_collation(Const *constval, deparse_context *context)
if (OidIsValid(constval->constcollid))
{
- Oid typcollation = get_typcollation(constval->consttype);
+ Oid typcollation = get_typcollation(constval->consttype);
if (constval->constcollid != typcollation)
{
@@ -6384,7 +6384,7 @@ get_from_clause_item(Node *jtnode, Query *query, deparse_context *context)
gavealias = true;
}
else if (rte->rtekind == RTE_RELATION &&
- strcmp(rte->eref->aliasname, get_relation_name(rte->relid)) != 0)
+ strcmp(rte->eref->aliasname, get_relation_name(rte->relid)) != 0)
{
/*
* Apparently the rel has been renamed since the rule was made.
diff --git a/src/backend/utils/adt/selfuncs.c b/src/backend/utils/adt/selfuncs.c
index 092dc15a02..41c5202146 100644
--- a/src/backend/utils/adt/selfuncs.c
+++ b/src/backend/utils/adt/selfuncs.c
@@ -6329,28 +6329,28 @@ gincostestimate(PG_FUNCTION_ARGS)
Cost *indexTotalCost = (Cost *) PG_GETARG_POINTER(6);
Selectivity *indexSelectivity = (Selectivity *) PG_GETARG_POINTER(7);
double *indexCorrelation = (double *) PG_GETARG_POINTER(8);
- ListCell *l;
- List *selectivityQuals;
- double numPages = index->pages,
- numTuples = index->tuples;
- double numEntryPages,
- numDataPages,
- numPendingPages,
- numEntries;
- bool haveFullScan = false;
- double partialEntriesInQuals = 0.0;
- double searchEntriesInQuals = 0.0;
- double exactEntriesInQuals = 0.0;
- double entryPagesFetched,
- dataPagesFetched,
- dataPagesFetchedBySel;
- double qual_op_cost,
- qual_arg_cost,
- spc_random_page_cost,
- num_scans;
- QualCost index_qual_cost;
- Relation indexRel;
- GinStatsData ginStats;
+ ListCell *l;
+ List *selectivityQuals;
+ double numPages = index->pages,
+ numTuples = index->tuples;
+ double numEntryPages,
+ numDataPages,
+ numPendingPages,
+ numEntries;
+ bool haveFullScan = false;
+ double partialEntriesInQuals = 0.0;
+ double searchEntriesInQuals = 0.0;
+ double exactEntriesInQuals = 0.0;
+ double entryPagesFetched,
+ dataPagesFetched,
+ dataPagesFetchedBySel;
+ double qual_op_cost,
+ qual_arg_cost,
+ spc_random_page_cost,
+ num_scans;
+ QualCost index_qual_cost;
+ Relation indexRel;
+ GinStatsData ginStats;
/*
* Obtain statistic information from the meta page
@@ -6366,7 +6366,7 @@ gincostestimate(PG_FUNCTION_ARGS)
/*
* nPendingPages can be trusted, but the other fields are as of the last
- * VACUUM. Scale them by the ratio numPages / nTotalPages to account for
+ * VACUUM. Scale them by the ratio numPages / nTotalPages to account for
* growth since then. If the fields are zero (implying no VACUUM at all,
* and an index created pre-9.1), assume all pages are entry pages.
*/
@@ -6374,11 +6374,11 @@ gincostestimate(PG_FUNCTION_ARGS)
{
numEntryPages = numPages;
numDataPages = 0;
- numEntries = numTuples; /* bogus, but no other info available */
+ numEntries = numTuples; /* bogus, but no other info available */
}
else
{
- double scale = numPages / ginStats.nTotalPages;
+ double scale = numPages / ginStats.nTotalPages;
numEntryPages = ceil(numEntryPages * scale);
numDataPages = ceil(numDataPages * scale);
@@ -6389,7 +6389,8 @@ gincostestimate(PG_FUNCTION_ARGS)
}
/*
- * Include predicate in selectivityQuals (should match genericcostestimate)
+ * Include predicate in selectivityQuals (should match
+ * genericcostestimate)
*/
if (index->indpred != NIL)
{
@@ -6411,12 +6412,12 @@ gincostestimate(PG_FUNCTION_ARGS)
/* Estimate the fraction of main-table tuples that will be visited */
*indexSelectivity = clauselist_selectivity(root, selectivityQuals,
- index->rel->relid,
- JOIN_INNER,
- NULL);
+ index->rel->relid,
+ JOIN_INNER,
+ NULL);
/* fetch estimated page cost for schema containing index */
- get_tablespace_page_costs(index->reltablespace,
+ get_tablespace_page_costs(index->reltablespace,
&spc_random_page_cost,
NULL);
@@ -6430,22 +6431,22 @@ gincostestimate(PG_FUNCTION_ARGS)
*/
foreach(l, indexQuals)
{
- RestrictInfo *rinfo = (RestrictInfo *) lfirst(l);
- Expr *clause;
- Node *leftop,
- *rightop,
- *operand;
- Oid extractProcOid;
- Oid clause_op;
- int strategy_op;
- Oid lefttype,
- righttype;
- int32 nentries = 0;
- bool *partial_matches = NULL;
- Pointer *extra_data = NULL;
- bool *nullFlags = NULL;
- int32 searchMode = GIN_SEARCH_MODE_DEFAULT;
- int indexcol;
+ RestrictInfo *rinfo = (RestrictInfo *) lfirst(l);
+ Expr *clause;
+ Node *leftop,
+ *rightop,
+ *operand;
+ Oid extractProcOid;
+ Oid clause_op;
+ int strategy_op;
+ Oid lefttype,
+ righttype;
+ int32 nentries = 0;
+ bool *partial_matches = NULL;
+ Pointer *extra_data = NULL;
+ bool *nullFlags = NULL;
+ int32 searchMode = GIN_SEARCH_MODE_DEFAULT;
+ int indexcol;
Assert(IsA(rinfo, RestrictInfo));
clause = rinfo->clause;
@@ -6466,16 +6467,16 @@ gincostestimate(PG_FUNCTION_ARGS)
else
{
elog(ERROR, "could not match index to operand");
- operand = NULL; /* keep compiler quiet */
+ operand = NULL; /* keep compiler quiet */
}
if (IsA(operand, RelabelType))
operand = (Node *) ((RelabelType *) operand)->arg;
/*
- * It's impossible to call extractQuery method for unknown operand.
- * So unless operand is a Const we can't do much; just assume there
- * will be one ordinary search entry from the operand at runtime.
+ * It's impossible to call extractQuery method for unknown operand. So
+ * unless operand is a Const we can't do much; just assume there will
+ * be one ordinary search entry from the operand at runtime.
*/
if (!IsA(operand, Const))
{
@@ -6484,7 +6485,7 @@ gincostestimate(PG_FUNCTION_ARGS)
}
/* If Const is null, there can be no matches */
- if (((Const*) operand)->constisnull)
+ if (((Const *) operand)->constisnull)
{
*indexStartupCost = 0;
*indexTotalCost = 0;
@@ -6494,9 +6495,9 @@ gincostestimate(PG_FUNCTION_ARGS)
/*
* Get the operator's strategy number and declared input data types
- * within the index opfamily. (We don't need the latter, but we
- * use get_op_opfamily_properties because it will throw error if
- * it fails to find a matching pg_amop entry.)
+ * within the index opfamily. (We don't need the latter, but we use
+ * get_op_opfamily_properties because it will throw error if it fails
+ * to find a matching pg_amop entry.)
*/
get_op_opfamily_properties(clause_op, index->opfamily[indexcol], false,
&strategy_op, &lefttype, &righttype);
@@ -6515,12 +6516,12 @@ gincostestimate(PG_FUNCTION_ARGS)
{
/* should not happen; throw same error as index_getprocinfo */
elog(ERROR, "missing support function %d for attribute %d of index \"%s\"",
- GIN_EXTRACTQUERY_PROC, indexcol+1,
+ GIN_EXTRACTQUERY_PROC, indexcol + 1,
get_rel_name(index->indexoid));
}
OidFunctionCall7(extractProcOid,
- ((Const*) operand)->constvalue,
+ ((Const *) operand)->constvalue,
PointerGetDatum(&nentries),
UInt16GetDatum(strategy_op),
PointerGetDatum(&partial_matches),
@@ -6538,9 +6539,9 @@ gincostestimate(PG_FUNCTION_ARGS)
}
else
{
- int32 i;
+ int32 i;
- for (i=0; i dataPagesFetched)
{
/*
- * At least one of entries is very frequent and, unfortunately,
- * we couldn't get statistic about entries (only tsvector has
- * such statistics). So, we obviously have too small estimation of
- * pages fetched from data tree. Re-estimate it from known
- * capacity of data pages
+ * At least one of entries is very frequent and, unfortunately, we
+ * couldn't get statistic about entries (only tsvector has such
+ * statistics). So, we obviously have too small estimation of pages
+ * fetched from data tree. Re-estimate it from known capacity of data
+ * pages
*/
dataPagesFetched = dataPagesFetchedBySel;
}
@@ -6670,7 +6669,7 @@ gincostestimate(PG_FUNCTION_ARGS)
qual_op_cost = cpu_operator_cost *
(list_length(indexQuals) + list_length(indexOrderBys));
qual_arg_cost -= qual_op_cost;
- if (qual_arg_cost < 0) /* just in case... */
+ if (qual_arg_cost < 0) /* just in case... */
qual_arg_cost = 0;
*indexStartupCost += qual_arg_cost;
diff --git a/src/backend/utils/adt/tsginidx.c b/src/backend/utils/adt/tsginidx.c
index 41700bfcf1..4cb961146b 100644
--- a/src/backend/utils/adt/tsginidx.c
+++ b/src/backend/utils/adt/tsginidx.c
@@ -95,10 +95,12 @@ gin_extract_tsquery(PG_FUNCTION_ARGS)
{
TSQuery query = PG_GETARG_TSQUERY(0);
int32 *nentries = (int32 *) PG_GETARG_POINTER(1);
+
/* StrategyNumber strategy = PG_GETARG_UINT16(2); */
bool **ptr_partialmatch = (bool **) PG_GETARG_POINTER(3);
Pointer **extra_data = (Pointer **) PG_GETARG_POINTER(4);
- /* bool **nullFlags = (bool **) PG_GETARG_POINTER(5); */
+
+ /* bool **nullFlags = (bool **) PG_GETARG_POINTER(5); */
int32 *searchMode = (int32 *) PG_GETARG_POINTER(6);
Datum *entries = NULL;
@@ -114,8 +116,8 @@ gin_extract_tsquery(PG_FUNCTION_ARGS)
/*
* If the query doesn't have any required positive matches (for
- * instance, it's something like '! foo'), we have to do a full
- * index scan.
+ * instance, it's something like '! foo'), we have to do a full index
+ * scan.
*/
if (tsquery_requires_match(item))
*searchMode = GIN_SEARCH_MODE_DEFAULT;
@@ -235,7 +237,7 @@ gin_tsquery_consistent(PG_FUNCTION_ARGS)
* Formerly, gin_extract_tsvector had only two arguments. Now it has three,
* but we still need a pg_proc entry with two args to support reloading
* pre-9.1 contrib/tsearch2 opclass declarations. This compatibility
- * function should go away eventually. (Note: you might say "hey, but the
+ * function should go away eventually. (Note: you might say "hey, but the
* code above is only *using* two args, so let's just declare it that way".
* If you try that you'll find the opr_sanity regression test complains.)
*/
diff --git a/src/backend/utils/adt/tsvector_op.c b/src/backend/utils/adt/tsvector_op.c
index b7a822d354..66674917f0 100644
--- a/src/backend/utils/adt/tsvector_op.c
+++ b/src/backend/utils/adt/tsvector_op.c
@@ -711,6 +711,7 @@ tsquery_requires_match(QueryItem *curitem)
switch (curitem->qoperator.oper)
{
case OP_NOT:
+
/*
* Assume there are no required matches underneath a NOT. For
* some cases with nested NOTs, we could prove there's a required
diff --git a/src/backend/utils/adt/varbit.c b/src/backend/utils/adt/varbit.c
index 0eb6071e12..3fa81175fd 100644
--- a/src/backend/utils/adt/varbit.c
+++ b/src/backend/utils/adt/varbit.c
@@ -237,6 +237,7 @@ bit_out(PG_FUNCTION_ARGS)
/* same as varbit output */
return varbit_out(fcinfo);
#else
+
/*
* This is how one would print a hex string, in case someone wants to
* write a formatting function.
diff --git a/src/backend/utils/adt/varlena.c b/src/backend/utils/adt/varlena.c
index 7a54521475..9d96013d57 100644
--- a/src/backend/utils/adt/varlena.c
+++ b/src/backend/utils/adt/varlena.c
@@ -81,7 +81,7 @@ void text_format_string_conversion(StringInfo buf, char conversion,
static Datum text_to_array_internal(PG_FUNCTION_ARGS);
static text *array_to_text_internal(FunctionCallInfo fcinfo, ArrayType *v,
- char *fldsep, char *null_string);
+ char *fldsep, char *null_string);
/*****************************************************************************
@@ -1299,7 +1299,7 @@ varstr_cmp(char *arg1, int len1, char *arg2, int len2, Oid collid)
char a2buf[STACKBUFLEN];
char *a1p,
*a2p;
- pg_locale_t mylocale = 0;
+ pg_locale_t mylocale = 0;
if (collid != DEFAULT_COLLATION_OID)
{
@@ -1379,7 +1379,7 @@ varstr_cmp(char *arg1, int len1, char *arg2, int len2, Oid collid)
result = wcscoll_l((LPWSTR) a1p, (LPWSTR) a2p, mylocale);
else
#endif
- result = wcscoll((LPWSTR) a1p, (LPWSTR) a2p);
+ result = wcscoll((LPWSTR) a1p, (LPWSTR) a2p);
if (result == 2147483647) /* _NLSCMPERROR; missing from mingw
* headers */
ereport(ERROR,
@@ -1426,7 +1426,7 @@ varstr_cmp(char *arg1, int len1, char *arg2, int len2, Oid collid)
result = strcoll_l(a1p, a2p, mylocale);
else
#endif
- result = strcoll(a1p, a2p);
+ result = strcoll(a1p, a2p);
/*
* In some locales strcoll() can claim that nonidentical strings are
@@ -1487,10 +1487,10 @@ texteq(PG_FUNCTION_ARGS)
/*
* Since we only care about equality or not-equality, we can avoid all the
- * expense of strcoll() here, and just do bitwise comparison. In fact,
- * we don't even have to do a bitwise comparison if we can show the
- * lengths of the strings are unequal; which might save us from having
- * to detoast one or both values.
+ * expense of strcoll() here, and just do bitwise comparison. In fact, we
+ * don't even have to do a bitwise comparison if we can show the lengths
+ * of the strings are unequal; which might save us from having to detoast
+ * one or both values.
*/
len1 = toast_raw_datum_size(arg1);
len2 = toast_raw_datum_size(arg2);
@@ -2031,7 +2031,7 @@ byteaGetByte(PG_FUNCTION_ARGS)
bytea *v = PG_GETARG_BYTEA_PP(0);
int32 n = PG_GETARG_INT32(1);
int len;
- int byte;
+ int byte;
len = VARSIZE_ANY_EXHDR(v);
@@ -2062,7 +2062,7 @@ byteaGetBit(PG_FUNCTION_ARGS)
int byteNo,
bitNo;
int len;
- int byte;
+ int byte;
len = VARSIZE_ANY_EXHDR(v);
@@ -2077,7 +2077,7 @@ byteaGetBit(PG_FUNCTION_ARGS)
byte = ((unsigned char *) VARDATA_ANY(v))[byteNo];
- if (byte &(1 << bitNo))
+ if (byte & (1 << bitNo))
PG_RETURN_INT32(1);
else
PG_RETURN_INT32(0);
@@ -3144,7 +3144,7 @@ text_to_array_internal(PG_FUNCTION_ARGS)
/* single element can be a NULL too */
is_null = null_string ? text_isequal(inputstring, null_string) : false;
PG_RETURN_ARRAYTYPE_P(create_singleton_array(fcinfo, TEXTOID,
- PointerGetDatum(inputstring),
+ PointerGetDatum(inputstring),
is_null, 1));
}
@@ -3152,7 +3152,7 @@ text_to_array_internal(PG_FUNCTION_ARGS)
/* start_ptr points to the start_posn'th character of inputstring */
start_ptr = VARDATA_ANY(inputstring);
- for (fldnum = 1;; fldnum++) /* field number is 1 based */
+ for (fldnum = 1;; fldnum++) /* field number is 1 based */
{
CHECK_FOR_INTERRUPTS();
@@ -3197,8 +3197,8 @@ text_to_array_internal(PG_FUNCTION_ARGS)
{
/*
* When fldsep is NULL, each character in the inputstring becomes an
- * element in the result array. The separator is effectively the space
- * between characters.
+ * element in the result array. The separator is effectively the
+ * space between characters.
*/
inputstring_len = VARSIZE_ANY_EXHDR(inputstring);
@@ -3210,7 +3210,7 @@ text_to_array_internal(PG_FUNCTION_ARGS)
while (inputstring_len > 0)
{
- int chunk_len = pg_mblen(start_ptr);
+ int chunk_len = pg_mblen(start_ptr);
CHECK_FOR_INTERRUPTS();
@@ -3625,9 +3625,9 @@ string_agg_finalfn(PG_FUNCTION_ARGS)
static text *
concat_internal(const char *sepstr, int seplen, int argidx, FunctionCallInfo fcinfo)
{
- StringInfoData str;
- text *result;
- int i;
+ StringInfoData str;
+ text *result;
+ int i;
initStringInfo(&str);
@@ -3635,10 +3635,10 @@ concat_internal(const char *sepstr, int seplen, int argidx, FunctionCallInfo fci
{
if (!PG_ARGISNULL(i))
{
- Oid valtype;
- Datum value;
- Oid typOutput;
- bool typIsVarlena;
+ Oid valtype;
+ Datum value;
+ Oid typOutput;
+ bool typIsVarlena;
if (i > argidx)
appendBinaryStringInfo(&str, sepstr, seplen);
@@ -3648,7 +3648,7 @@ concat_internal(const char *sepstr, int seplen, int argidx, FunctionCallInfo fci
valtype = get_fn_expr_argtype(fcinfo->flinfo, i);
getTypeOutputInfo(valtype, &typOutput, &typIsVarlena);
appendStringInfoString(&str,
- OidOutputFunctionCall(typOutput, value));
+ OidOutputFunctionCall(typOutput, value));
}
}
@@ -3674,7 +3674,7 @@ text_concat(PG_FUNCTION_ARGS)
Datum
text_concat_ws(PG_FUNCTION_ARGS)
{
- text *sep;
+ text *sep;
/* return NULL when separator is NULL */
if (PG_ARGISNULL(0))
@@ -3683,7 +3683,7 @@ text_concat_ws(PG_FUNCTION_ARGS)
sep = PG_GETARG_TEXT_PP(0);
PG_RETURN_TEXT_P(concat_internal(
- VARDATA_ANY(sep), VARSIZE_ANY_EXHDR(sep), 1, fcinfo));
+ VARDATA_ANY(sep), VARSIZE_ANY_EXHDR(sep), 1, fcinfo));
}
/*
@@ -3734,15 +3734,15 @@ text_right(PG_FUNCTION_ARGS)
Datum
text_reverse(PG_FUNCTION_ARGS)
{
- text *str = PG_GETARG_TEXT_PP(0);
- const char *p = VARDATA_ANY(str);
- int len = VARSIZE_ANY_EXHDR(str);
- const char *endp = p + len;
- text *result;
- char *dst;
+ text *str = PG_GETARG_TEXT_PP(0);
+ const char *p = VARDATA_ANY(str);
+ int len = VARSIZE_ANY_EXHDR(str);
+ const char *endp = p + len;
+ text *result;
+ char *dst;
result = palloc(len + VARHDRSZ);
- dst = (char*) VARDATA(result) + len;
+ dst = (char *) VARDATA(result) + len;
SET_VARSIZE(result, len + VARHDRSZ);
if (pg_database_encoding_max_length() > 1)
@@ -3750,7 +3750,7 @@ text_reverse(PG_FUNCTION_ARGS)
/* multibyte version */
while (p < endp)
{
- int sz;
+ int sz;
sz = pg_mblen(p);
dst -= sz;
@@ -3775,7 +3775,7 @@ Datum
text_format(PG_FUNCTION_ARGS)
{
text *fmt;
- StringInfoData str;
+ StringInfoData str;
const char *cp;
const char *start_ptr;
const char *end_ptr;
@@ -3795,9 +3795,9 @@ text_format(PG_FUNCTION_ARGS)
/* Scan format string, looking for conversion specifiers. */
for (cp = start_ptr; cp < end_ptr; cp++)
{
- Datum value;
- bool isNull;
- Oid typid;
+ Datum value;
+ bool isNull;
+ Oid typid;
/*
* If it's not the start of a conversion specifier, just copy it to
@@ -3830,11 +3830,12 @@ text_format(PG_FUNCTION_ARGS)
++arg;
else
{
- bool unterminated = false;
+ bool unterminated = false;
/* Parse digit string. */
arg = 0;
- do {
+ do
+ {
/* Treat overflowing arg position as unterminated. */
if (arg > INT_MAX / 10)
break;
@@ -3863,8 +3864,8 @@ text_format(PG_FUNCTION_ARGS)
/* There's no argument 0. */
if (arg == 0)
ereport(ERROR,
- (errcode(ERRCODE_INVALID_PARAMETER_VALUE),
- errmsg("conversion specifies argument 0, but arguments are numbered from 1")));
+ (errcode(ERRCODE_INVALID_PARAMETER_VALUE),
+ errmsg("conversion specifies argument 0, but arguments are numbered from 1")));
}
/* Not enough arguments? Deduct 1 to avoid counting format string. */
@@ -3874,9 +3875,9 @@ text_format(PG_FUNCTION_ARGS)
errmsg("too few arguments for format conversion")));
/*
- * At this point, we should see the main conversion specifier.
- * Whether or not an argument position was present, it's known
- * that at least one character remains in the string at this point.
+ * At this point, we should see the main conversion specifier. Whether
+ * or not an argument position was present, it's known that at least
+ * one character remains in the string at this point.
*/
value = PG_GETARG_DATUM(arg);
isNull = PG_ARGISNULL(arg);
@@ -3893,7 +3894,7 @@ text_format(PG_FUNCTION_ARGS)
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
errmsg("unrecognized conversion specifier: %c",
- *cp)));
+ *cp)));
}
}
@@ -3907,11 +3908,11 @@ text_format(PG_FUNCTION_ARGS)
/* Format a %s, %I, or %L conversion. */
void
text_format_string_conversion(StringInfo buf, char conversion,
- Oid typid, Datum value, bool isNull)
+ Oid typid, Datum value, bool isNull)
{
- Oid typOutput;
- bool typIsVarlena;
- char *str;
+ Oid typOutput;
+ bool typIsVarlena;
+ char *str;
/* Handle NULL arguments before trying to stringify the value. */
if (isNull)
@@ -3919,7 +3920,7 @@ text_format_string_conversion(StringInfo buf, char conversion,
if (conversion == 'L')
appendStringInfoString(buf, "NULL");
else if (conversion == 'I')
- ereport(ERROR,
+ ereport(ERROR,
(errcode(ERRCODE_NULL_VALUE_NOT_ALLOWED),
errmsg("NULL cannot be escaped as an SQL identifier")));
return;
@@ -3937,7 +3938,8 @@ text_format_string_conversion(StringInfo buf, char conversion,
}
else if (conversion == 'L')
{
- char *qstr = quote_literal_cstr(str);
+ char *qstr = quote_literal_cstr(str);
+
appendStringInfoString(buf, qstr);
/* quote_literal_cstr() always allocates a new string */
pfree(qstr);
@@ -3951,7 +3953,7 @@ text_format_string_conversion(StringInfo buf, char conversion,
/*
* text_format_nv - nonvariadic wrapper for text_format function.
- *
+ *
* note: this wrapper is necessary to be sanity_checks test ok
*/
Datum
diff --git a/src/backend/utils/adt/xml.c b/src/backend/utils/adt/xml.c
index c175e4f4ca..ee82d4616c 100644
--- a/src/backend/utils/adt/xml.c
+++ b/src/backend/utils/adt/xml.c
@@ -1200,9 +1200,10 @@ xml_parse(text *data, XmlOptionType xmloption_arg, bool preserve_whitespace,
{
/*
* Note, that here we try to apply DTD defaults
- * (XML_PARSE_DTDATTR) according to SQL/XML:2008 GR 10.16.7.d: 'Default
- * values defined by internal DTD are applied'. As for external
- * DTDs, we try to support them too, (see SQL/XML:2008 GR 10.16.7.e)
+ * (XML_PARSE_DTDATTR) according to SQL/XML:2008 GR 10.16.7.d:
+ * 'Default values defined by internal DTD are applied'. As for
+ * external DTDs, we try to support them too, (see SQL/XML:2008 GR
+ * 10.16.7.e)
*/
doc = xmlCtxtReadDoc(ctxt, utf8string,
NULL,
@@ -3435,10 +3436,10 @@ xpath_internal(text *xpath_expr_text, xmltype *data, ArrayType *namespaces,
/*
* Version 2.6.27 introduces a function named
- * xmlXPathCompiledEvalToBoolean, which would be enough for
- * xmlexists, but we can derive the existence by whether any
- * nodes are returned, thereby preventing a library version
- * upgrade and keeping the code the same.
+ * xmlXPathCompiledEvalToBoolean, which would be enough for xmlexists,
+ * but we can derive the existence by whether any nodes are returned,
+ * thereby preventing a library version upgrade and keeping the code
+ * the same.
*/
xpathobj = xmlXPathCompiledEval(xpathcomp, xpathctx);
if (xpathobj == NULL) /* TODO: reason? */
@@ -3488,7 +3489,7 @@ xpath_internal(text *xpath_expr_text, xmltype *data, ArrayType *namespaces,
xmlFreeDoc(doc);
xmlFreeParserCtxt(ctxt);
}
-#endif /* USE_LIBXML */
+#endif /* USE_LIBXML */
/*
* Evaluate XPath expression and return array of XML values.
@@ -3524,7 +3525,8 @@ xpath(PG_FUNCTION_ARGS)
* Determines if the node specified by the supplied XPath exists
* in a given XML document, returning a boolean.
*/
-Datum xmlexists(PG_FUNCTION_ARGS)
+Datum
+xmlexists(PG_FUNCTION_ARGS)
{
#ifdef USE_LIBXML
text *xpath_expr_text = PG_GETARG_TEXT_P(0);
diff --git a/src/backend/utils/cache/inval.c b/src/backend/utils/cache/inval.c
index fe89b71df2..ebc83440de 100644
--- a/src/backend/utils/cache/inval.c
+++ b/src/backend/utils/cache/inval.c
@@ -514,7 +514,8 @@ LocalExecuteInvalidationMessage(SharedInvalidationMessage *msg)
* We could have smgr entries for relations of other databases, so no
* short-circuit test is possible here.
*/
- RelFileNodeBackend rnode;
+ RelFileNodeBackend rnode;
+
rnode.node = msg->sm.rnode;
rnode.backend = (msg->sm.backend_hi << 16) | (int) msg->sm.backend_lo;
smgrclosenode(rnode);
diff --git a/src/backend/utils/cache/lsyscache.c b/src/backend/utils/cache/lsyscache.c
index 877e50d873..d3b2a5a557 100644
--- a/src/backend/utils/cache/lsyscache.c
+++ b/src/backend/utils/cache/lsyscache.c
@@ -1122,7 +1122,7 @@ op_input_types(Oid opno, Oid *lefttype, Oid *righttype)
*
* In some cases (currently only array_eq), mergejoinability depends on the
* specific input data type the operator is invoked for, so that must be
- * passed as well. We currently assume that only one input's type is needed
+ * passed as well. We currently assume that only one input's type is needed
* to check this --- by convention, pass the left input's data type.
*/
bool
@@ -1172,7 +1172,7 @@ op_mergejoinable(Oid opno, Oid inputtype)
*
* In some cases (currently only array_eq), hashjoinability depends on the
* specific input data type the operator is invoked for, so that must be
- * passed as well. We currently assume that only one input's type is needed
+ * passed as well. We currently assume that only one input's type is needed
* to check this --- by convention, pass the left input's data type.
*/
bool
@@ -2709,9 +2709,9 @@ get_attstatsslot(HeapTuple statstuple,
/*
* Need to get info about the array element type. We look at the
* actual element type embedded in the array, which might be only
- * binary-compatible with the passed-in atttype. The info we
- * extract here should be the same either way, but deconstruct_array
- * is picky about having an exact type OID match.
+ * binary-compatible with the passed-in atttype. The info we extract
+ * here should be the same either way, but deconstruct_array is picky
+ * about having an exact type OID match.
*/
arrayelemtype = ARR_ELEMTYPE(statarray);
typeTuple = SearchSysCache1(TYPEOID, ObjectIdGetDatum(arrayelemtype));
diff --git a/src/backend/utils/cache/plancache.c b/src/backend/utils/cache/plancache.c
index 949608001e..08ddfa9bcb 100644
--- a/src/backend/utils/cache/plancache.c
+++ b/src/backend/utils/cache/plancache.c
@@ -512,8 +512,8 @@ RevalidateCachedPlan(CachedPlanSource *plansource, bool useResOwner)
TupleDesc resultDesc;
/*
- * Restore the search_path that was in use when the plan was made.
- * See comments for PushOverrideSearchPath about limitations of this.
+ * Restore the search_path that was in use when the plan was made. See
+ * comments for PushOverrideSearchPath about limitations of this.
*
* (XXX is there anything else we really need to restore?)
*/
diff --git a/src/backend/utils/cache/relcache.c b/src/backend/utils/cache/relcache.c
index 274b48c895..d7e94ffc12 100644
--- a/src/backend/utils/cache/relcache.c
+++ b/src/backend/utils/cache/relcache.c
@@ -1070,9 +1070,9 @@ RelationInitIndexAccessInfo(Relation relation)
MemoryContextAllocZero(indexcxt, natts * sizeof(int16));
/*
- * indcollation cannot be referenced directly through the C struct, because it
- * comes after the variable-width indkey field. Must extract the datum
- * the hard way...
+ * indcollation cannot be referenced directly through the C struct,
+ * because it comes after the variable-width indkey field. Must extract
+ * the datum the hard way...
*/
indcollDatum = fastgetattr(relation->rd_indextuple,
Anum_pg_index_indcollation,
@@ -1096,7 +1096,7 @@ RelationInitIndexAccessInfo(Relation relation)
/*
* Fill the support procedure OID array, as well as the info about
- * opfamilies and opclass input types. (aminfo and supportinfo are left
+ * opfamilies and opclass input types. (aminfo and supportinfo are left
* as zeroes, and are filled on-the-fly when used)
*/
IndexSupportInitialize(indclass, relation->rd_support,
diff --git a/src/backend/utils/cache/syscache.c b/src/backend/utils/cache/syscache.c
index 715341f842..2b5e37e2f0 100644
--- a/src/backend/utils/cache/syscache.c
+++ b/src/backend/utils/cache/syscache.c
@@ -422,7 +422,7 @@ static const struct cachedesc cacheinfo[] = {
},
32
},
- {ForeignTableRelationId, /* FOREIGNTABLEREL */
+ {ForeignTableRelationId, /* FOREIGNTABLEREL */
ForeignTableRelidIndexId,
1,
{
diff --git a/src/backend/utils/cache/ts_cache.c b/src/backend/utils/cache/ts_cache.c
index fc93551d06..a8c4d76565 100644
--- a/src/backend/utils/cache/ts_cache.c
+++ b/src/backend/utils/cache/ts_cache.c
@@ -582,7 +582,7 @@ getTSCurrentConfig(bool emitError)
/* Look up the config */
TSCurrentConfigCache =
get_ts_config_oid(stringToQualifiedNameList(TSCurrentConfig),
- !emitError);
+ !emitError);
return TSCurrentConfigCache;
}
diff --git a/src/backend/utils/cache/typcache.c b/src/backend/utils/cache/typcache.c
index 54e1942c31..2769a30acd 100644
--- a/src/backend/utils/cache/typcache.c
+++ b/src/backend/utils/cache/typcache.c
@@ -77,7 +77,7 @@ typedef struct TypeCacheEnumData
Oid bitmap_base; /* OID corresponding to bit 0 of bitmapset */
Bitmapset *sorted_values; /* Set of OIDs known to be in order */
int num_values; /* total number of values in enum */
- EnumItem enum_values[1]; /* VARIABLE LENGTH ARRAY */
+ EnumItem enum_values[1]; /* VARIABLE LENGTH ARRAY */
} TypeCacheEnumData;
/*
@@ -227,10 +227,10 @@ lookup_type_cache(Oid type_id, int flags)
{
/*
* In case we find a btree opclass where previously we only found
- * a hash opclass, reset eq_opr and derived information so that
- * we can fetch the btree equality operator instead of the hash
- * equality operator. (They're probably the same operator, but
- * we don't assume that here.)
+ * a hash opclass, reset eq_opr and derived information so that we
+ * can fetch the btree equality operator instead of the hash
+ * equality operator. (They're probably the same operator, but we
+ * don't assume that here.)
*/
typentry->eq_opr = InvalidOid;
typentry->eq_opr_finfo.fn_oid = InvalidOid;
@@ -612,7 +612,8 @@ TypeCacheRelCallback(Datum arg, Oid relid)
while ((typentry = (TypeCacheEntry *) hash_seq_search(&status)) != NULL)
{
if (typentry->tupDesc == NULL)
- continue; /* not composite, or tupdesc hasn't been requested */
+ continue; /* not composite, or tupdesc hasn't been
+ * requested */
/* Delete if match, or if we're zapping all composite types */
if (relid == typentry->typrelid || relid == InvalidOid)
@@ -671,8 +672,8 @@ compare_values_of_enum(TypeCacheEntry *tcache, Oid arg1, Oid arg2)
EnumItem *item2;
/*
- * Equal OIDs are certainly equal --- this case was probably handled
- * by our caller, but we may as well check.
+ * Equal OIDs are certainly equal --- this case was probably handled by
+ * our caller, but we may as well check.
*/
if (arg1 == arg2)
return 0;
@@ -704,8 +705,8 @@ compare_values_of_enum(TypeCacheEntry *tcache, Oid arg1, Oid arg2)
{
/*
* We couldn't find one or both values. That means the enum has
- * changed under us, so re-initialize the cache and try again.
- * We don't bother retrying the known-sorted case in this path.
+ * changed under us, so re-initialize the cache and try again. We
+ * don't bother retrying the known-sorted case in this path.
*/
load_enum_cache_data(tcache);
enumdata = tcache->enumData;
@@ -714,8 +715,8 @@ compare_values_of_enum(TypeCacheEntry *tcache, Oid arg1, Oid arg2)
item2 = find_enumitem(enumdata, arg2);
/*
- * If we still can't find the values, complain: we must have
- * corrupt data.
+ * If we still can't find the values, complain: we must have corrupt
+ * data.
*/
if (item1 == NULL)
elog(ERROR, "enum value %u not found in cache for enum %s",
@@ -761,21 +762,21 @@ load_enum_cache_data(TypeCacheEntry *tcache)
format_type_be(tcache->type_id))));
/*
- * Read all the information for members of the enum type. We collect
- * the info in working memory in the caller's context, and then transfer
- * it to permanent memory in CacheMemoryContext. This minimizes the risk
- * of leaking memory from CacheMemoryContext in the event of an error
- * partway through.
+ * Read all the information for members of the enum type. We collect the
+ * info in working memory in the caller's context, and then transfer it to
+ * permanent memory in CacheMemoryContext. This minimizes the risk of
+ * leaking memory from CacheMemoryContext in the event of an error partway
+ * through.
*/
maxitems = 64;
items = (EnumItem *) palloc(sizeof(EnumItem) * maxitems);
numitems = 0;
/*
- * Scan pg_enum for the members of the target enum type. We use a
- * current MVCC snapshot, *not* SnapshotNow, so that we see a consistent
- * set of rows even if someone commits a renumbering of the enum meanwhile.
- * See comments for RenumberEnumType in catalog/pg_enum.c for more info.
+ * Scan pg_enum for the members of the target enum type. We use a current
+ * MVCC snapshot, *not* SnapshotNow, so that we see a consistent set of
+ * rows even if someone commits a renumbering of the enum meanwhile. See
+ * comments for RenumberEnumType in catalog/pg_enum.c for more info.
*/
ScanKeyInit(&skey,
Anum_pg_enum_enumtypid,
@@ -817,8 +818,8 @@ load_enum_cache_data(TypeCacheEntry *tcache)
* and we'd rather not do binary searches unnecessarily.
*
* This is somewhat heuristic, and might identify a subset of OIDs that
- * isn't exactly what the type started with. That's okay as long as
- * the subset is correctly sorted.
+ * isn't exactly what the type started with. That's okay as long as the
+ * subset is correctly sorted.
*/
bitmap_base = InvalidOid;
bitmap = NULL;
@@ -829,15 +830,15 @@ load_enum_cache_data(TypeCacheEntry *tcache)
/*
* Identify longest sorted subsequence starting at start_pos
*/
- Bitmapset *this_bitmap = bms_make_singleton(0);
- int this_bm_size = 1;
- Oid start_oid = items[start_pos].enum_oid;
- float4 prev_order = items[start_pos].sort_order;
- int i;
+ Bitmapset *this_bitmap = bms_make_singleton(0);
+ int this_bm_size = 1;
+ Oid start_oid = items[start_pos].enum_oid;
+ float4 prev_order = items[start_pos].sort_order;
+ int i;
for (i = start_pos + 1; i < numitems; i++)
{
- Oid offset;
+ Oid offset;
offset = items[i].enum_oid - start_oid;
/* quit if bitmap would be too large; cutoff is arbitrary */
@@ -864,10 +865,10 @@ load_enum_cache_data(TypeCacheEntry *tcache)
bms_free(this_bitmap);
/*
- * Done if it's not possible to find a longer sequence in the rest
- * of the list. In typical cases this will happen on the first
- * iteration, which is why we create the bitmaps on the fly instead
- * of doing a second pass over the list.
+ * Done if it's not possible to find a longer sequence in the rest of
+ * the list. In typical cases this will happen on the first
+ * iteration, which is why we create the bitmaps on the fly instead of
+ * doing a second pass over the list.
*/
if (bm_size >= (numitems - start_pos - 1))
break;
diff --git a/src/backend/utils/error/elog.c b/src/backend/utils/error/elog.c
index 9e58735aee..337b875fe2 100644
--- a/src/backend/utils/error/elog.c
+++ b/src/backend/utils/error/elog.c
@@ -5,7 +5,7 @@
*
* Because of the extremely high rate at which log messages can be generated,
* we need to be mindful of the performance cost of obtaining any information
- * that may be logged. Also, it's important to keep in mind that this code may
+ * that may be logged. Also, it's important to keep in mind that this code may
* get called from within an aborted transaction, in which case operations
* such as syscache lookups are unsafe.
*
@@ -1175,7 +1175,7 @@ elog_finish(int elevel, const char *fmt,...)
* The result of format_elog_string() is stored in ErrorContext, and will
* therefore survive until FlushErrorState() is called.
*/
-static int save_format_errnumber;
+static int save_format_errnumber;
static const char *save_format_domain;
void
@@ -1188,7 +1188,7 @@ pre_format_elog_string(int errnumber, const char *domain)
}
char *
-format_elog_string(const char *fmt, ...)
+format_elog_string(const char *fmt,...)
{
ErrorData errdata;
ErrorData *edata;
@@ -1725,8 +1725,9 @@ write_console(const char *line, int len)
* WriteConsoleW() will fail of stdout is redirected, so just fall through
* to writing unconverted to the logfile in this case.
*
- * Since we palloc the structure required for conversion, also fall through
- * to writing unconverted if we have not yet set up CurrentMemoryContext.
+ * Since we palloc the structure required for conversion, also fall
+ * through to writing unconverted if we have not yet set up
+ * CurrentMemoryContext.
*/
if (GetDatabaseEncoding() != GetPlatformEncoding() &&
!in_error_recursion_trouble() &&
diff --git a/src/backend/utils/fmgr/fmgr.c b/src/backend/utils/fmgr/fmgr.c
index e193e560ea..0288fbab4b 100644
--- a/src/backend/utils/fmgr/fmgr.c
+++ b/src/backend/utils/fmgr/fmgr.c
@@ -34,7 +34,7 @@
* Hooks for function calls
*/
PGDLLIMPORT needs_fmgr_hook_type needs_fmgr_hook = NULL;
-PGDLLIMPORT fmgr_hook_type fmgr_hook = NULL;
+PGDLLIMPORT fmgr_hook_type fmgr_hook = NULL;
/*
* Declaration for old-style function pointer type. This is now used only
@@ -192,7 +192,7 @@ fmgr_info_cxt_security(Oid functionId, FmgrInfo *finfo, MemoryContext mcxt,
* elogs.
*/
finfo->fn_oid = InvalidOid;
- finfo->fn_collation = InvalidOid; /* caller may set this later */
+ finfo->fn_collation = InvalidOid; /* caller may set this later */
finfo->fn_extra = NULL;
finfo->fn_mcxt = mcxt;
finfo->fn_expr = NULL; /* caller may set this later */
@@ -951,7 +951,7 @@ fmgr_security_definer(PG_FUNCTION_ARGS)
/* function manager hook */
if (fmgr_hook)
- (*fmgr_hook)(FHET_START, &fcache->flinfo, &fcache->arg);
+ (*fmgr_hook) (FHET_START, &fcache->flinfo, &fcache->arg);
/*
* We don't need to restore GUC or userid settings on error, because the
@@ -982,7 +982,7 @@ fmgr_security_definer(PG_FUNCTION_ARGS)
{
fcinfo->flinfo = save_flinfo;
if (fmgr_hook)
- (*fmgr_hook)(FHET_ABORT, &fcache->flinfo, &fcache->arg);
+ (*fmgr_hook) (FHET_ABORT, &fcache->flinfo, &fcache->arg);
PG_RE_THROW();
}
PG_END_TRY();
@@ -994,7 +994,7 @@ fmgr_security_definer(PG_FUNCTION_ARGS)
if (OidIsValid(fcache->userid))
SetUserIdAndSecContext(save_userid, save_sec_context);
if (fmgr_hook)
- (*fmgr_hook)(FHET_END, &fcache->flinfo, &fcache->arg);
+ (*fmgr_hook) (FHET_END, &fcache->flinfo, &fcache->arg);
return result;
}
@@ -1278,7 +1278,7 @@ DirectFunctionCall9(PGFunction func, Datum arg1, Datum arg2,
/*
* These are the same as DirectFunctionCallN except that a nonzero
- * collation can be specified. No other fields of FmgrInfo are made valid.
+ * collation can be specified. No other fields of FmgrInfo are made valid.
*/
Datum
DirectFunctionCall1WithCollation(PGFunction func, Oid collation, Datum arg1)
diff --git a/src/backend/utils/fmgr/funcapi.c b/src/backend/utils/fmgr/funcapi.c
index cad4a371b7..aa249fabfe 100644
--- a/src/backend/utils/fmgr/funcapi.c
+++ b/src/backend/utils/fmgr/funcapi.c
@@ -489,8 +489,8 @@ resolve_polymorphic_tupdesc(TupleDesc tupdesc, oidvector *declared_args,
return false;
/*
- * Identify the collation to use for polymorphic OUT parameters.
- * (It'll necessarily be the same for both anyelement and anyarray.)
+ * Identify the collation to use for polymorphic OUT parameters. (It'll
+ * necessarily be the same for both anyelement and anyarray.)
*/
anycollation = get_typcollation(OidIsValid(anyelement_type) ? anyelement_type : anyarray_type);
if (OidIsValid(anycollation))
@@ -500,7 +500,7 @@ resolve_polymorphic_tupdesc(TupleDesc tupdesc, oidvector *declared_args,
* collation. We do so if we can identify the input collation used
* for the function.
*/
- Oid inputcollation = exprInputCollation(call_expr);
+ Oid inputcollation = exprInputCollation(call_expr);
if (OidIsValid(inputcollation))
anycollation = inputcollation;
diff --git a/src/backend/utils/init/miscinit.c b/src/backend/utils/init/miscinit.c
index ef6422e75c..347a777da9 100644
--- a/src/backend/utils/init/miscinit.c
+++ b/src/backend/utils/init/miscinit.c
@@ -394,8 +394,8 @@ SetUserIdAndContext(Oid userid, bool sec_def_context)
bool
is_authenticated_user_replication_role(void)
{
- bool result = false;
- HeapTuple utup;
+ bool result = false;
+ HeapTuple utup;
utup = SearchSysCache1(AUTHOID, ObjectIdGetDatum(AuthenticatedUserId));
if (HeapTupleIsValid(utup))
@@ -866,7 +866,7 @@ CreateLockFile(const char *filename, bool amPostmaster,
"(key %lu, ID %lu) is still in use",
id1, id2),
errhint("If you're sure there are no old "
- "server processes still running, remove "
+ "server processes still running, remove "
"the shared memory block "
"or just delete the file \"%s\".",
filename)));
@@ -889,8 +889,8 @@ CreateLockFile(const char *filename, bool amPostmaster,
}
/*
- * Successfully created the file, now fill it. See comment in miscadmin.h
- * about the contents. Note that we write the same info into both datadir
+ * Successfully created the file, now fill it. See comment in miscadmin.h
+ * about the contents. Note that we write the same info into both datadir
* and socket lockfiles; although more stuff may get added to the datadir
* lockfile later.
*/
@@ -904,7 +904,7 @@ CreateLockFile(const char *filename, bool amPostmaster,
#else
""
#endif
- );
+ );
errno = 0;
if (write(fd, buffer, strlen(buffer)) != strlen(buffer))
diff --git a/src/backend/utils/init/postinit.c b/src/backend/utils/init/postinit.c
index f3ca5a5cd6..a4c5d4c69a 100644
--- a/src/backend/utils/init/postinit.c
+++ b/src/backend/utils/init/postinit.c
@@ -222,8 +222,8 @@ PerformAuthentication(Port *port)
{
if (am_walsender)
ereport(LOG,
- (errmsg("replication connection authorized: user=%s",
- port->user_name)));
+ (errmsg("replication connection authorized: user=%s",
+ port->user_name)));
else
ereport(LOG,
(errmsg("connection authorized: user=%s database=%s",
@@ -639,9 +639,9 @@ InitPostgres(const char *in_dbname, Oid dboid, const char *username,
errmsg("remaining connection slots are reserved for non-replication superuser connections")));
/*
- * If walsender, we don't want to connect to any particular database.
- * Just finish the backend startup by processing any options from the
- * startup packet, and we're done.
+ * If walsender, we don't want to connect to any particular database. Just
+ * finish the backend startup by processing any options from the startup
+ * packet, and we're done.
*/
if (am_walsender)
{
diff --git a/src/backend/utils/mb/mbutils.c b/src/backend/utils/mb/mbutils.c
index b128177803..234bb0cf6e 100644
--- a/src/backend/utils/mb/mbutils.c
+++ b/src/backend/utils/mb/mbutils.c
@@ -77,7 +77,7 @@ static int cliplen(const char *str, int len, int limit);
/*
- * Prepare for a future call to SetClientEncoding. Success should mean
+ * Prepare for a future call to SetClientEncoding. Success should mean
* that SetClientEncoding is guaranteed to succeed for this encoding request.
*
* (But note that success before backend_startup_complete does not guarantee
@@ -149,7 +149,7 @@ PrepareClientEncoding(int encoding)
/*
* We cannot yet remove any older entry for the same encoding pair,
- * since it could still be in use. SetClientEncoding will clean up.
+ * since it could still be in use. SetClientEncoding will clean up.
*/
return 0; /* success */
@@ -218,8 +218,8 @@ SetClientEncoding(int encoding)
/*
* Search the cache for the entry previously prepared by
* PrepareClientEncoding; if there isn't one, we lose. While at it,
- * release any duplicate entries so that repeated Prepare/Set cycles
- * don't leak memory.
+ * release any duplicate entries so that repeated Prepare/Set cycles don't
+ * leak memory.
*/
found = false;
foreach(lc, ConvProcList)
@@ -591,7 +591,7 @@ pg_any_to_server(const char *s, int len, int encoding)
return perform_default_encoding_conversion(s, len, true);
else
return (char *) pg_do_encoding_conversion(
- (unsigned char *) s, len, encoding, DatabaseEncoding->encoding);
+ (unsigned char *) s, len, encoding, DatabaseEncoding->encoding);
}
/*
@@ -626,7 +626,7 @@ pg_server_to_any(const char *s, int len, int encoding)
return perform_default_encoding_conversion(s, len, false);
else
return (char *) pg_do_encoding_conversion(
- (unsigned char *) s, len, DatabaseEncoding->encoding, encoding);
+ (unsigned char *) s, len, DatabaseEncoding->encoding, encoding);
}
/*
diff --git a/src/backend/utils/misc/guc.c b/src/backend/utils/misc/guc.c
index 5e4904aeb7..738e2152ba 100644
--- a/src/backend/utils/misc/guc.c
+++ b/src/backend/utils/misc/guc.c
@@ -146,23 +146,23 @@ extern bool optimize_bounded_sort;
static int GUC_check_errcode_value;
/* global variables for check hook support */
-char *GUC_check_errmsg_string;
-char *GUC_check_errdetail_string;
-char *GUC_check_errhint_string;
+char *GUC_check_errmsg_string;
+char *GUC_check_errdetail_string;
+char *GUC_check_errhint_string;
static void set_config_sourcefile(const char *name, char *sourcefile,
int sourceline);
-static bool call_bool_check_hook(struct config_bool *conf, bool *newval,
- void **extra, GucSource source, int elevel);
-static bool call_int_check_hook(struct config_int *conf, int *newval,
- void **extra, GucSource source, int elevel);
-static bool call_real_check_hook(struct config_real *conf, double *newval,
- void **extra, GucSource source, int elevel);
-static bool call_string_check_hook(struct config_string *conf, char **newval,
- void **extra, GucSource source, int elevel);
-static bool call_enum_check_hook(struct config_enum *conf, int *newval,
- void **extra, GucSource source, int elevel);
+static bool call_bool_check_hook(struct config_bool * conf, bool *newval,
+ void **extra, GucSource source, int elevel);
+static bool call_int_check_hook(struct config_int * conf, int *newval,
+ void **extra, GucSource source, int elevel);
+static bool call_real_check_hook(struct config_real * conf, double *newval,
+ void **extra, GucSource source, int elevel);
+static bool call_string_check_hook(struct config_string * conf, char **newval,
+ void **extra, GucSource source, int elevel);
+static bool call_enum_check_hook(struct config_enum * conf, int *newval,
+ void **extra, GucSource source, int elevel);
static bool check_log_destination(char **newval, void **extra, GucSource source);
static void assign_log_destination(const char *newval, void *extra);
@@ -1571,7 +1571,7 @@ static struct config_int ConfigureNamesInt[] =
GUC_UNIT_S
},
&wal_receiver_status_interval,
- 10, 0, INT_MAX/1000,
+ 10, 0, INT_MAX / 1000,
NULL, NULL, NULL
},
@@ -1878,7 +1878,7 @@ static struct config_int ConfigureNamesInt[] =
{"max_pred_locks_per_transaction", PGC_POSTMASTER, LOCK_MANAGEMENT,
gettext_noop("Sets the maximum number of predicate locks per transaction."),
gettext_noop("The shared predicate lock table is sized on the assumption that "
- "at most max_pred_locks_per_transaction * max_connections distinct "
+ "at most max_pred_locks_per_transaction * max_connections distinct "
"objects will need to be locked at any one time.")
},
&max_predicate_locks_per_xact,
@@ -3165,9 +3165,10 @@ static struct config_enum ConfigureNamesEnum[] =
" the level, the fewer messages are sent.")
},
&trace_recovery_messages,
+
/*
- * client_message_level_options allows too many values, really,
- * but it's not worth having a separate options array for this.
+ * client_message_level_options allows too many values, really, but
+ * it's not worth having a separate options array for this.
*/
LOG, client_message_level_options,
NULL, NULL, NULL
@@ -5100,8 +5101,8 @@ set_config_option(const char *name, const char *value,
{
/*
* Historically we've just silently ignored attempts to set
- * PGC_INTERNAL variables from the config file. Maybe it'd
- * be better to use the prohibitValueChange logic for this?
+ * PGC_INTERNAL variables from the config file. Maybe it'd be
+ * better to use the prohibitValueChange logic for this?
*/
return true;
}
@@ -5559,8 +5560,8 @@ set_config_option(const char *name, const char *value,
if (value)
{
/*
- * The value passed by the caller could be transient,
- * so we always strdup it.
+ * The value passed by the caller could be transient, so
+ * we always strdup it.
*/
newval = guc_strdup(elevel, value);
if (newval == NULL)
@@ -7922,7 +7923,7 @@ validate_option_array_item(const char *name, const char *value,
* ERRCODE_INVALID_PARAMETER_VALUE SQLSTATE for check hook failures.
*
* Note that GUC_check_errmsg() etc are just macros that result in a direct
- * assignment to the associated variables. That is ugly, but forced by the
+ * assignment to the associated variables. That is ugly, but forced by the
* limitations of C's macro mechanisms.
*/
void
@@ -7939,7 +7940,7 @@ GUC_check_errcode(int sqlerrcode)
*/
static bool
-call_bool_check_hook(struct config_bool *conf, bool *newval, void **extra,
+call_bool_check_hook(struct config_bool * conf, bool *newval, void **extra,
GucSource source, int elevel)
{
/* Quick success if no hook */
@@ -7973,7 +7974,7 @@ call_bool_check_hook(struct config_bool *conf, bool *newval, void **extra,
}
static bool
-call_int_check_hook(struct config_int *conf, int *newval, void **extra,
+call_int_check_hook(struct config_int * conf, int *newval, void **extra,
GucSource source, int elevel)
{
/* Quick success if no hook */
@@ -8007,7 +8008,7 @@ call_int_check_hook(struct config_int *conf, int *newval, void **extra,
}
static bool
-call_real_check_hook(struct config_real *conf, double *newval, void **extra,
+call_real_check_hook(struct config_real * conf, double *newval, void **extra,
GucSource source, int elevel)
{
/* Quick success if no hook */
@@ -8041,7 +8042,7 @@ call_real_check_hook(struct config_real *conf, double *newval, void **extra,
}
static bool
-call_string_check_hook(struct config_string *conf, char **newval, void **extra,
+call_string_check_hook(struct config_string * conf, char **newval, void **extra,
GucSource source, int elevel)
{
/* Quick success if no hook */
@@ -8075,7 +8076,7 @@ call_string_check_hook(struct config_string *conf, char **newval, void **extra,
}
static bool
-call_enum_check_hook(struct config_enum *conf, int *newval, void **extra,
+call_enum_check_hook(struct config_enum * conf, int *newval, void **extra,
GucSource source, int elevel)
{
/* Quick success if no hook */
@@ -8365,9 +8366,9 @@ static bool
check_canonical_path(char **newval, void **extra, GucSource source)
{
/*
- * Since canonicalize_path never enlarges the string, we can just
- * modify newval in-place. But watch out for NULL, which is the
- * default value for external_pid_file.
+ * Since canonicalize_path never enlarges the string, we can just modify
+ * newval in-place. But watch out for NULL, which is the default value
+ * for external_pid_file.
*/
if (*newval)
canonicalize_path(*newval);
@@ -8378,12 +8379,12 @@ static bool
check_timezone_abbreviations(char **newval, void **extra, GucSource source)
{
/*
- * The boot_val given above for timezone_abbreviations is NULL.
- * When we see this we just do nothing. If this value isn't overridden
- * from the config file then pg_timezone_abbrev_initialize() will
- * eventually replace it with "Default". This hack has two purposes: to
- * avoid wasting cycles loading values that might soon be overridden from
- * the config file, and to avoid trying to read the timezone abbrev files
+ * The boot_val given above for timezone_abbreviations is NULL. When we
+ * see this we just do nothing. If this value isn't overridden from the
+ * config file then pg_timezone_abbrev_initialize() will eventually
+ * replace it with "Default". This hack has two purposes: to avoid
+ * wasting cycles loading values that might soon be overridden from the
+ * config file, and to avoid trying to read the timezone abbrev files
* during InitializeGUCOptions(). The latter doesn't work in an
* EXEC_BACKEND subprocess because my_exec_path hasn't been set yet and so
* we can't locate PGSHAREDIR.
@@ -8443,15 +8444,15 @@ static void
assign_tcp_keepalives_idle(int newval, void *extra)
{
/*
- * The kernel API provides no way to test a value without setting it;
- * and once we set it we might fail to unset it. So there seems little
- * point in fully implementing the check-then-assign GUC API for these
+ * The kernel API provides no way to test a value without setting it; and
+ * once we set it we might fail to unset it. So there seems little point
+ * in fully implementing the check-then-assign GUC API for these
* variables. Instead we just do the assignment on demand. pqcomm.c
* reports any problems via elog(LOG).
*
- * This approach means that the GUC value might have little to do with
- * the actual kernel value, so we use a show_hook that retrieves the
- * kernel value rather than trusting GUC's copy.
+ * This approach means that the GUC value might have little to do with the
+ * actual kernel value, so we use a show_hook that retrieves the kernel
+ * value rather than trusting GUC's copy.
*/
(void) pq_setkeepalivesidle(newval, MyProcPort);
}
@@ -8574,7 +8575,7 @@ check_effective_io_concurrency(int *newval, void **extra, GucSource source)
/* This range check shouldn't fail, but let's be paranoid */
if (new_prefetch_pages >= 0.0 && new_prefetch_pages < (double) INT_MAX)
{
- int *myextra = (int *) guc_malloc(ERROR, sizeof(int));
+ int *myextra = (int *) guc_malloc(ERROR, sizeof(int));
*myextra = (int) rint(new_prefetch_pages);
*extra = (void *) myextra;
diff --git a/src/backend/utils/misc/rbtree.c b/src/backend/utils/misc/rbtree.c
index 7a8ddf0a17..f8143724d0 100644
--- a/src/backend/utils/misc/rbtree.c
+++ b/src/backend/utils/misc/rbtree.c
@@ -75,7 +75,7 @@ struct RBTree
*/
#define RBNIL (&sentinel)
-static RBNode sentinel = {InitialState, RBBLACK, RBNIL, RBNIL, NULL};
+static RBNode sentinel = {InitialState, RBBLACK, RBNIL, RBNIL, NULL};
/*
@@ -99,10 +99,10 @@ static RBNode sentinel = {InitialState, RBBLACK, RBNIL, RBNIL, NULL};
*
* The freefunc should just be pfree or equivalent; it should NOT attempt
* to free any subsidiary data, because the node passed to it may not contain
- * valid data! freefunc can be NULL if caller doesn't require retail
+ * valid data! freefunc can be NULL if caller doesn't require retail
* space reclamation.
*
- * The RBTree node is palloc'd in the caller's memory context. Note that
+ * The RBTree node is palloc'd in the caller's memory context. Note that
* all contents of the tree are actually allocated by the caller, not here.
*
* Since tree contents are managed by the caller, there is currently not
@@ -130,6 +130,7 @@ rb_create(Size node_size,
tree->combiner = combiner;
tree->allocfunc = allocfunc;
tree->freefunc = freefunc;
+
tree->arg = arg;
return tree;
@@ -161,7 +162,7 @@ rb_find(RBTree *rb, const RBNode *data)
while (node != RBNIL)
{
- int cmp = rb->comparator(data, node, rb->arg);
+ int cmp = rb->comparator(data, node, rb->arg);
if (cmp == 0)
return node;
@@ -434,10 +435,11 @@ rb_insert(RBTree *rb, const RBNode *data, bool *isNew)
*/
*isNew = true;
- x = rb->allocfunc(rb->arg);
+ x = rb->allocfunc (rb->arg);
x->iteratorState = InitialState;
x->color = RBRED;
+
x->left = RBNIL;
x->right = RBNIL;
x->parent = parent;
@@ -629,7 +631,7 @@ rb_delete_node(RBTree *rb, RBNode *z)
/* Now we can recycle the y node */
if (rb->freefunc)
- rb->freefunc(y, rb->arg);
+ rb->freefunc (y, rb->arg);
}
/*
diff --git a/src/backend/utils/misc/tzparser.c b/src/backend/utils/misc/tzparser.c
index b2f6dd3a2b..b52942db72 100644
--- a/src/backend/utils/misc/tzparser.c
+++ b/src/backend/utils/misc/tzparser.c
@@ -4,7 +4,7 @@
* Functions for parsing timezone offset files
*
* Note: this code is invoked from the check_hook for the GUC variable
- * timezone_abbreviations. Therefore, it should report problems using
+ * timezone_abbreviations. Therefore, it should report problems using
* GUC_check_errmsg() and related functions, and try to avoid throwing
* elog(ERROR). This is not completely bulletproof at present --- in
* particular out-of-memory will throw an error. Could probably fix with
diff --git a/src/backend/utils/mmgr/aset.c b/src/backend/utils/mmgr/aset.c
index b28dc47420..e95dcb6b7c 100644
--- a/src/backend/utils/mmgr/aset.c
+++ b/src/backend/utils/mmgr/aset.c
@@ -165,7 +165,7 @@ typedef struct AllocBlockData
AllocBlock next; /* next block in aset's blocks list */
char *freeptr; /* start of free space in this block */
char *endptr; /* end of space in this block */
-} AllocBlockData;
+} AllocBlockData;
/*
* AllocChunk
@@ -184,7 +184,7 @@ typedef struct AllocChunkData
/* this is zero in a free chunk */
Size requested_size;
#endif
-} AllocChunkData;
+} AllocChunkData;
/*
* AllocPointerIsValid
diff --git a/src/backend/utils/mmgr/portalmem.c b/src/backend/utils/mmgr/portalmem.c
index 7fa66b4221..186548dcba 100644
--- a/src/backend/utils/mmgr/portalmem.c
+++ b/src/backend/utils/mmgr/portalmem.c
@@ -413,8 +413,8 @@ MarkPortalDone(Portal portal)
portal->status = PORTAL_DONE;
/*
- * Allow portalcmds.c to clean up the state it knows about. We might
- * as well do that now, since the portal can't be executed any more.
+ * Allow portalcmds.c to clean up the state it knows about. We might as
+ * well do that now, since the portal can't be executed any more.
*
* In some cases involving execution of a ROLLBACK command in an already
* aborted transaction, this prevents an assertion failure from reaching
@@ -449,7 +449,7 @@ PortalDrop(Portal portal, bool isTopCommit)
/*
* Allow portalcmds.c to clean up the state it knows about, in particular
- * shutting down the executor if still active. This step potentially runs
+ * shutting down the executor if still active. This step potentially runs
* user-defined code so failure has to be expected. It's the cleanup
* hook's responsibility to not try to do that more than once, in the case
* that failure occurs and then we come back to drop the portal again
@@ -577,7 +577,7 @@ PortalHashTableDeleteAll(void)
* Holdable cursors created in this transaction need to be converted to
* materialized form, since we are going to close down the executor and
* release locks. Non-holdable portals created in this transaction are
- * simply removed. Portals remaining from prior transactions should be
+ * simply removed. Portals remaining from prior transactions should be
* left untouched.
*
* Returns TRUE if any portals changed state (possibly causing user-defined
@@ -678,9 +678,9 @@ PreCommit_Portals(bool isPrepare)
}
/*
- * After either freezing or dropping a portal, we have to restart
- * the iteration, because we could have invoked user-defined code
- * that caused a drop of the next portal in the hash chain.
+ * After either freezing or dropping a portal, we have to restart the
+ * iteration, because we could have invoked user-defined code that
+ * caused a drop of the next portal in the hash chain.
*/
hash_seq_term(&status);
hash_seq_init(&status, PortalHashTable);
diff --git a/src/backend/utils/resowner/resowner.c b/src/backend/utils/resowner/resowner.c
index c1ba5ad8e6..e5461e660e 100644
--- a/src/backend/utils/resowner/resowner.c
+++ b/src/backend/utils/resowner/resowner.c
@@ -78,7 +78,7 @@ typedef struct ResourceOwnerData
int nfiles; /* number of owned temporary files */
File *files; /* dynamically allocated array */
int maxfiles; /* currently allocated array size */
-} ResourceOwnerData;
+} ResourceOwnerData;
/*****************************************************************************
diff --git a/src/backend/utils/sort/tuplesort.c b/src/backend/utils/sort/tuplesort.c
index a1850b83c5..bd5b4b0a7d 100644
--- a/src/backend/utils/sort/tuplesort.c
+++ b/src/backend/utils/sort/tuplesort.c
@@ -351,7 +351,7 @@ struct Tuplesortstate
* indexScanKey.
*/
IndexInfo *indexInfo; /* info about index being used for reference */
- EState *estate; /* for evaluating index expressions */
+ EState *estate; /* for evaluating index expressions */
/*
* These variables are specific to the IndexTuple case; they are set by
@@ -469,12 +469,12 @@ static void readtup_heap(Tuplesortstate *state, SortTuple *stup,
int tapenum, unsigned int len);
static void reversedirection_heap(Tuplesortstate *state);
static int comparetup_cluster(const SortTuple *a, const SortTuple *b,
- Tuplesortstate *state);
+ Tuplesortstate *state);
static void copytup_cluster(Tuplesortstate *state, SortTuple *stup, void *tup);
static void writetup_cluster(Tuplesortstate *state, int tapenum,
- SortTuple *stup);
+ SortTuple *stup);
static void readtup_cluster(Tuplesortstate *state, SortTuple *stup,
- int tapenum, unsigned int len);
+ int tapenum, unsigned int len);
static int comparetup_index_btree(const SortTuple *a, const SortTuple *b,
Tuplesortstate *state);
static int comparetup_index_hash(const SortTuple *a, const SortTuple *b,
@@ -582,7 +582,7 @@ tuplesort_begin_common(int workMem, bool randomAccess)
Tuplesortstate *
tuplesort_begin_heap(TupleDesc tupDesc,
int nkeys, AttrNumber *attNums,
- Oid *sortOperators, Oid *collations, bool *nullsFirstFlags,
+ Oid *sortOperators, Oid *collations, bool *nullsFirstFlags,
int workMem, bool randomAccess)
{
Tuplesortstate *state = tuplesort_begin_common(workMem, randomAccess);
@@ -699,7 +699,7 @@ tuplesort_begin_cluster(TupleDesc tupDesc,
if (state->indexInfo->ii_Expressions != NULL)
{
TupleTableSlot *slot;
- ExprContext *econtext;
+ ExprContext *econtext;
/*
* We will need to use FormIndexDatum to evaluate the index
@@ -796,7 +796,7 @@ tuplesort_begin_index_hash(Relation indexRel,
Tuplesortstate *
tuplesort_begin_datum(Oid datumType,
- Oid sortOperator, Oid sortCollation, bool nullsFirstFlag,
+ Oid sortOperator, Oid sortCollation, bool nullsFirstFlag,
int workMem, bool randomAccess)
{
Tuplesortstate *state = tuplesort_begin_common(workMem, randomAccess);
@@ -945,7 +945,7 @@ tuplesort_end(Tuplesortstate *state)
/* Free any execution state created for CLUSTER case */
if (state->estate != NULL)
{
- ExprContext *econtext = GetPerTupleExprContext(state->estate);
+ ExprContext *econtext = GetPerTupleExprContext(state->estate);
ExecDropSingleTupleTableSlot(econtext->ecxt_scantuple);
FreeExecutorState(state->estate);
@@ -1546,7 +1546,7 @@ tuplesort_gettupleslot(Tuplesortstate *state, bool forward,
/*
* Fetch the next tuple in either forward or back direction.
- * Returns NULL if no more tuples. If *should_free is set, the
+ * Returns NULL if no more tuples. If *should_free is set, the
* caller must pfree the returned tuple when done with it.
*/
HeapTuple
diff --git a/src/backend/utils/time/snapmgr.c b/src/backend/utils/time/snapmgr.c
index 9100c818f8..ef66466baf 100644
--- a/src/backend/utils/time/snapmgr.c
+++ b/src/backend/utils/time/snapmgr.c
@@ -41,7 +41,7 @@
* CurrentSnapshot points to the only snapshot taken in transaction-snapshot
* mode, and to the latest one taken in a read-committed transaction.
* SecondarySnapshot is a snapshot that's always up-to-date as of the current
- * instant, even in transaction-snapshot mode. It should only be used for
+ * instant, even in transaction-snapshot mode. It should only be used for
* special-purpose code (say, RI checking.)
*
* These SnapshotData structs are static to simplify memory allocation
@@ -533,8 +533,8 @@ void
AtEarlyCommit_Snapshot(void)
{
/*
- * In transaction-snapshot mode we must unregister our private refcount
- * to the transaction-snapshot.
+ * In transaction-snapshot mode we must unregister our private refcount to
+ * the transaction-snapshot.
*/
if (registered_xact_snapshot)
UnregisterSnapshotFromOwner(CurrentSnapshot,
diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c
index e87edb88a9..fd1f20ee86 100644
--- a/src/bin/initdb/initdb.c
+++ b/src/bin/initdb/initdb.c
@@ -230,7 +230,7 @@ do { \
#define PG_CMD_PRINTF3(fmt, arg1, arg2, arg3) \
do { \
- if (fprintf(cmdfd, fmt, arg1, arg2, arg3) < 0 || fflush(cmdfd) < 0) \
+ if (fprintf(cmdfd, fmt, arg1, arg2, arg3) < 0 || fflush(cmdfd) < 0) \
output_failed = true, output_errno = errno; \
} while (0)
@@ -1503,7 +1503,7 @@ setup_description(void)
/* Create default descriptions for operator implementation functions */
PG_CMD_PUTS("WITH funcdescs AS ( "
"SELECT p.oid as p_oid, oprname, "
- "coalesce(obj_description(o.oid, 'pg_operator'),'') as opdesc "
+ "coalesce(obj_description(o.oid, 'pg_operator'),'') as opdesc "
"FROM pg_proc p JOIN pg_operator o ON oprcode = p.oid ) "
"INSERT INTO pg_description "
" SELECT p_oid, 'pg_proc'::regclass, 0, "
@@ -1511,7 +1511,7 @@ setup_description(void)
" FROM funcdescs "
" WHERE opdesc NOT LIKE 'deprecated%' AND "
" NOT EXISTS (SELECT 1 FROM pg_description "
- " WHERE objoid = p_oid AND classoid = 'pg_proc'::regclass);\n");
+ " WHERE objoid = p_oid AND classoid = 'pg_proc'::regclass);\n");
PG_CMD_CLOSE;
@@ -1528,9 +1528,9 @@ setup_description(void)
static bool
normalize_locale_name(char *new, const char *old)
{
- char *n = new;
+ char *n = new;
const char *o = old;
- bool changed = false;
+ bool changed = false;
while (*o)
{
@@ -1552,7 +1552,7 @@ normalize_locale_name(char *new, const char *old)
return changed;
}
-#endif /* HAVE_LOCALE_T */
+#endif /* HAVE_LOCALE_T */
/*
* populate pg_collation
@@ -1561,10 +1561,11 @@ static void
setup_collation(void)
{
#ifdef HAVE_LOCALE_T
- int i;
- FILE *locale_a_handle;
- char localebuf[NAMEDATALEN];
- int count = 0;
+ int i;
+ FILE *locale_a_handle;
+ char localebuf[NAMEDATALEN];
+ int count = 0;
+
PG_CMD_DECL;
#endif
@@ -1590,10 +1591,10 @@ setup_collation(void)
while (fgets(localebuf, sizeof(localebuf), locale_a_handle))
{
- size_t len;
- int enc;
- bool skip;
- char alias[NAMEDATALEN];
+ size_t len;
+ int enc;
+ bool skip;
+ char alias[NAMEDATALEN];
len = strlen(localebuf);
@@ -1607,11 +1608,11 @@ setup_collation(void)
localebuf[len - 1] = '\0';
/*
- * Some systems have locale names that don't consist entirely
- * of ASCII letters (such as "bokmål" or
- * "français"). This is pretty silly, since we need
- * the locale itself to interpret the non-ASCII characters.
- * We can't do much with those, so we filter them out.
+ * Some systems have locale names that don't consist entirely of ASCII
+ * letters (such as "bokmål" or "français"). This is
+ * pretty silly, since we need the locale itself to interpret the
+ * non-ASCII characters. We can't do much with those, so we filter
+ * them out.
*/
skip = false;
for (i = 0; i < len; i++)
@@ -1647,30 +1648,28 @@ setup_collation(void)
escape_quotes(localebuf), enc);
/*
- * Generate aliases such as "en_US" in addition to
- * "en_US.utf8" for ease of use. Note that collation names
- * are unique per encoding only, so this doesn't clash with
- * "en_US" for LATIN1, say.
+ * Generate aliases such as "en_US" in addition to "en_US.utf8" for
+ * ease of use. Note that collation names are unique per encoding
+ * only, so this doesn't clash with "en_US" for LATIN1, say.
*/
if (normalize_locale_name(alias, localebuf))
PG_CMD_PRINTF3("INSERT INTO tmp_pg_collation (collname, locale, encoding) VALUES ('%s', '%s', %d);\n",
- escape_quotes(alias), escape_quotes(localebuf), enc);
+ escape_quotes(alias), escape_quotes(localebuf), enc);
}
/* Add an SQL-standard name */
PG_CMD_PRINTF1("INSERT INTO tmp_pg_collation (collname, locale, encoding) VALUES ('ucs_basic', 'C', %d);\n", PG_UTF8);
/*
- * When copying collations to the final location, eliminate
- * aliases that conflict with an existing locale name for the same
- * encoding. For example, "br_FR.iso88591" is normalized to
- * "br_FR", both for encoding LATIN1. But the unnormalized locale
- * "br_FR" already exists for LATIN1. Prefer the collation that
- * matches the OS locale name, else the first name by sort order
- * (arbitrary choice to be deterministic).
+ * When copying collations to the final location, eliminate aliases that
+ * conflict with an existing locale name for the same encoding. For
+ * example, "br_FR.iso88591" is normalized to "br_FR", both for encoding
+ * LATIN1. But the unnormalized locale "br_FR" already exists for LATIN1.
+ * Prefer the collation that matches the OS locale name, else the first
+ * name by sort order (arbitrary choice to be deterministic).
*/
PG_CMD_PUTS("INSERT INTO pg_collation (collname, collnamespace, collowner, collencoding, collcollate, collctype) "
- " SELECT DISTINCT ON (final_collname, collnamespace, encoding)"
+ " SELECT DISTINCT ON (final_collname, collnamespace, encoding)"
" COALESCE(collname, locale) AS final_collname, "
" (SELECT oid FROM pg_namespace WHERE nspname = 'pg_catalog') AS collnamespace, "
" (SELECT relowner FROM pg_class WHERE relname = 'pg_collation') AS collowner, "
@@ -1687,10 +1686,10 @@ setup_collation(void)
printf(_("No usable system locales were found.\n"));
printf(_("Use the option \"--debug\" to see details.\n"));
}
-#else /* not HAVE_LOCALE_T */
+#else /* not HAVE_LOCALE_T */
printf(_("not supported on this platform\n"));
fflush(stdout);
-#endif /* not HAVE_LOCALE_T */
+#endif /* not HAVE_LOCALE_T */
}
/*
diff --git a/src/bin/pg_basebackup/pg_basebackup.c b/src/bin/pg_basebackup/pg_basebackup.c
index 9f926bd242..aeec8136c4 100644
--- a/src/bin/pg_basebackup/pg_basebackup.c
+++ b/src/bin/pg_basebackup/pg_basebackup.c
@@ -129,7 +129,7 @@ usage(void)
printf(_(" -Z, --compress=0-9 compress tar output\n"));
printf(_("\nGeneral options:\n"));
printf(_(" -c, --checkpoint=fast|spread\n"
- " set fast or spread checkpointing\n"));
+ " set fast or spread checkpointing\n"));
printf(_(" -l, --label=label set backup label\n"));
printf(_(" -P, --progress show progress information\n"));
printf(_(" -v, --verbose output verbose messages\n"));
@@ -202,7 +202,8 @@ verify_dir_is_empty_or_create(char *dirname)
static void
progress_report(int tablespacenum, char *fn)
{
- int percent = (int) ((totaldone / 1024) * 100 / totalsize);
+ int percent = (int) ((totaldone / 1024) * 100 / totalsize);
+
if (percent > 100)
percent = 100;
@@ -502,7 +503,7 @@ ReceiveAndUnpackTarFile(PGconn *conn, PGresult *res, int rownum)
if (file == NULL)
{
- int filemode;
+ int filemode;
/*
* No current file, so this must be the header for a new file
@@ -795,7 +796,7 @@ BaseBackup(void)
showprogress ? "PROGRESS" : "",
includewal ? "WAL" : "",
fastcheckpoint ? "FAST" : "",
- includewal ? "NOWAIT" : "");
+ includewal ? "NOWAIT" : "");
if (PQsendQuery(conn, current_path) == 0)
{
@@ -896,7 +897,7 @@ BaseBackup(void)
if (PQresultStatus(res) != PGRES_TUPLES_OK)
{
fprintf(stderr, _("%s: could not get end xlog position from server.\n"),
- progname);
+ progname);
disconnect_and_exit(1);
}
if (PQntuples(res) != 1)
diff --git a/src/bin/pg_ctl/pg_ctl.c b/src/bin/pg_ctl/pg_ctl.c
index e553c9b9d4..4e8d0b1d39 100644
--- a/src/bin/pg_ctl/pg_ctl.c
+++ b/src/bin/pg_ctl/pg_ctl.c
@@ -416,7 +416,7 @@ test_postmaster_connection(bool do_checkpoint)
int i;
connstr[0] = '\0';
-
+
for (i = 0; i < wait_seconds; i++)
{
/* Do we need a connection string? */
@@ -433,7 +433,7 @@ test_postmaster_connection(bool do_checkpoint)
* 6 9.1+ server, shared memory not created
* 7 9.1+ server, shared memory created
*
- * This code does not support pre-9.1 servers. On Unix machines
+ * This code does not support pre-9.1 servers. On Unix machines
* we could consider extracting the port number from the shmem
* key, but that (a) is not robust, and (b) doesn't help with
* finding out the socket directory. And it wouldn't work anyway
@@ -462,11 +462,11 @@ test_postmaster_connection(bool do_checkpoint)
optlines[5] != NULL)
{
/* File is complete enough for us, parse it */
- time_t pmstart;
- int portnum;
- char *sockdir;
- char *hostaddr;
- char host_str[MAXPGPATH];
+ time_t pmstart;
+ int portnum;
+ char *sockdir;
+ char *hostaddr;
+ char host_str[MAXPGPATH];
/*
* Easy cross-check that we are looking at the right data
@@ -483,8 +483,8 @@ test_postmaster_connection(bool do_checkpoint)
}
/*
- * OK, extract port number and host string to use.
- * Prefer using Unix socket if available.
+ * OK, extract port number and host string to use. Prefer
+ * using Unix socket if available.
*/
portnum = atoi(optlines[LOCK_FILE_LINE_PORT - 1]);
@@ -524,7 +524,7 @@ test_postmaster_connection(bool do_checkpoint)
* first.
*/
snprintf(connstr, sizeof(connstr),
- "dbname=postgres port=%d host='%s' connect_timeout=5",
+ "dbname=postgres port=%d host='%s' connect_timeout=5",
portnum, host_str);
}
}
@@ -543,11 +543,10 @@ test_postmaster_connection(bool do_checkpoint)
if (do_checkpoint)
{
/*
- * Increment the wait hint by 6 secs (connection timeout +
- * sleep) We must do this to indicate to the SCM that our
- * startup time is changing, otherwise it'll usually send a
- * stop signal after 20 seconds, despite incrementing the
- * checkpoint counter.
+ * Increment the wait hint by 6 secs (connection timeout + sleep)
+ * We must do this to indicate to the SCM that our startup time is
+ * changing, otherwise it'll usually send a stop signal after 20
+ * seconds, despite incrementing the checkpoint counter.
*/
status.dwWaitHint += 6000;
status.dwCheckPoint++;
@@ -557,7 +556,7 @@ test_postmaster_connection(bool do_checkpoint)
#endif
print_msg(".");
- pg_usleep(1000000); /* 1 sec */
+ pg_usleep(1000000); /* 1 sec */
}
/* return result of last call to PQping */
@@ -834,8 +833,8 @@ do_stop(void)
else
{
/*
- * If backup_label exists, an online backup is running. Warn the
- * user that smart shutdown will wait for it to finish. However, if
+ * If backup_label exists, an online backup is running. Warn the user
+ * that smart shutdown will wait for it to finish. However, if
* recovery.conf is also present, we're recovering from an online
* backup instead of performing one.
*/
@@ -867,7 +866,7 @@ do_stop(void)
write_stderr(_("%s: server does not shut down\n"), progname);
if (shutdown_mode == SMART_MODE)
write_stderr(_("HINT: The \"-m fast\" option immediately disconnects sessions rather than\n"
- "waiting for session-initiated disconnection.\n"));
+ "waiting for session-initiated disconnection.\n"));
exit(1);
}
print_msg(_(" done\n"));
@@ -922,8 +921,8 @@ do_restart(void)
}
/*
- * If backup_label exists, an online backup is running. Warn the
- * user that smart shutdown will wait for it to finish. However, if
+ * If backup_label exists, an online backup is running. Warn the user
+ * that smart shutdown will wait for it to finish. However, if
* recovery.conf is also present, we're recovering from an online
* backup instead of performing one.
*/
@@ -957,7 +956,7 @@ do_restart(void)
write_stderr(_("%s: server does not shut down\n"), progname);
if (shutdown_mode == SMART_MODE)
write_stderr(_("HINT: The \"-m fast\" option immediately disconnects sessions rather than\n"
- "waiting for session-initiated disconnection.\n"));
+ "waiting for session-initiated disconnection.\n"));
exit(1);
}
@@ -1259,7 +1258,7 @@ pgwin32_doRegister(void)
}
if ((hService = CreateService(hSCM, register_servicename, register_servicename,
- SERVICE_ALL_ACCESS, SERVICE_WIN32_OWN_PROCESS,
+ SERVICE_ALL_ACCESS, SERVICE_WIN32_OWN_PROCESS,
pgctl_start_type, SERVICE_ERROR_NORMAL,
pgwin32_CommandLine(true),
NULL, NULL, "RPCSS\0", register_username, register_password)) == NULL)
@@ -1700,7 +1699,7 @@ do_help(void)
printf(_(" %s kill SIGNALNAME PID\n"), progname);
#if defined(WIN32) || defined(__CYGWIN__)
printf(_(" %s register [-N SERVICENAME] [-U USERNAME] [-P PASSWORD] [-D DATADIR]\n"
- " [-S START-TYPE] [-w] [-t SECS] [-o \"OPTIONS\"]\n"), progname);
+ " [-S START-TYPE] [-w] [-t SECS] [-o \"OPTIONS\"]\n"), progname);
printf(_(" %s unregister [-N SERVICENAME]\n"), progname);
#endif
diff --git a/src/bin/pg_dump/compress_io.c b/src/bin/pg_dump/compress_io.c
index fb280ab672..66d2419725 100644
--- a/src/bin/pg_dump/compress_io.c
+++ b/src/bin/pg_dump/compress_io.c
@@ -1,8 +1,8 @@
/*-------------------------------------------------------------------------
*
* compress_io.c
- * Routines for archivers to write an uncompressed or compressed data
- * stream.
+ * Routines for archivers to write an uncompressed or compressed data
+ * stream.
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
@@ -18,36 +18,36 @@
* Compressor API
* --------------
*
- * The interface for writing to an archive consists of three functions:
- * AllocateCompressor, WriteDataToArchive and EndCompressor. First you call
- * AllocateCompressor, then write all the data by calling WriteDataToArchive
- * as many times as needed, and finally EndCompressor. WriteDataToArchive
- * and EndCompressor will call the WriteFunc that was provided to
- * AllocateCompressor for each chunk of compressed data.
+ * The interface for writing to an archive consists of three functions:
+ * AllocateCompressor, WriteDataToArchive and EndCompressor. First you call
+ * AllocateCompressor, then write all the data by calling WriteDataToArchive
+ * as many times as needed, and finally EndCompressor. WriteDataToArchive
+ * and EndCompressor will call the WriteFunc that was provided to
+ * AllocateCompressor for each chunk of compressed data.
*
- * The interface for reading an archive consists of just one function:
- * ReadDataFromArchive. ReadDataFromArchive reads the whole compressed input
- * stream, by repeatedly calling the given ReadFunc. ReadFunc returns the
- * compressed data chunk at a time, and ReadDataFromArchive decompresses it
- * and passes the decompressed data to ahwrite(), until ReadFunc returns 0
- * to signal EOF.
+ * The interface for reading an archive consists of just one function:
+ * ReadDataFromArchive. ReadDataFromArchive reads the whole compressed input
+ * stream, by repeatedly calling the given ReadFunc. ReadFunc returns the
+ * compressed data chunk at a time, and ReadDataFromArchive decompresses it
+ * and passes the decompressed data to ahwrite(), until ReadFunc returns 0
+ * to signal EOF.
*
- * The interface is the same for compressed and uncompressed streams.
+ * The interface is the same for compressed and uncompressed streams.
*
* Compressed stream API
* ----------------------
*
- * The compressed stream API is a wrapper around the C standard fopen() and
- * libz's gzopen() APIs. It allows you to use the same functions for
- * compressed and uncompressed streams. cfopen_read() first tries to open
- * the file with given name, and if it fails, it tries to open the same
- * file with the .gz suffix. cfopen_write() opens a file for writing, an
- * extra argument specifies if the file should be compressed, and adds the
- * .gz suffix to the filename if so. This allows you to easily handle both
- * compressed and uncompressed files.
+ * The compressed stream API is a wrapper around the C standard fopen() and
+ * libz's gzopen() APIs. It allows you to use the same functions for
+ * compressed and uncompressed streams. cfopen_read() first tries to open
+ * the file with given name, and if it fails, it tries to open the same
+ * file with the .gz suffix. cfopen_write() opens a file for writing, an
+ * extra argument specifies if the file should be compressed, and adds the
+ * .gz suffix to the filename if so. This allows you to easily handle both
+ * compressed and uncompressed files.
*
* IDENTIFICATION
- * src/bin/pg_dump/compress_io.c
+ * src/bin/pg_dump/compress_io.c
*
*-------------------------------------------------------------------------
*/
@@ -63,36 +63,35 @@
struct CompressorState
{
CompressionAlgorithm comprAlg;
- WriteFunc writeF;
+ WriteFunc writeF;
#ifdef HAVE_LIBZ
- z_streamp zp;
- char *zlibOut;
- size_t zlibOutSize;
+ z_streamp zp;
+ char *zlibOut;
+ size_t zlibOutSize;
#endif
};
static const char *modulename = gettext_noop("compress_io");
static void ParseCompressionOption(int compression, CompressionAlgorithm *alg,
- int *level);
+ int *level);
/* Routines that support zlib compressed data I/O */
#ifdef HAVE_LIBZ
static void InitCompressorZlib(CompressorState *cs, int level);
static void DeflateCompressorZlib(ArchiveHandle *AH, CompressorState *cs,
- bool flush);
+ bool flush);
static void ReadDataFromArchiveZlib(ArchiveHandle *AH, ReadFunc readF);
static size_t WriteDataToArchiveZlib(ArchiveHandle *AH, CompressorState *cs,
- const char *data, size_t dLen);
+ const char *data, size_t dLen);
static void EndCompressorZlib(ArchiveHandle *AH, CompressorState *cs);
-
#endif
/* Routines that support uncompressed data I/O */
static void ReadDataFromArchiveNone(ArchiveHandle *AH, ReadFunc readF);
static size_t WriteDataToArchiveNone(ArchiveHandle *AH, CompressorState *cs,
- const char *data, size_t dLen);
+ const char *data, size_t dLen);
/*
* Interprets a numeric 'compression' value. The algorithm implied by the
@@ -127,7 +126,7 @@ AllocateCompressor(int compression, WriteFunc writeF)
{
CompressorState *cs;
CompressionAlgorithm alg;
- int level;
+ int level;
ParseCompressionOption(compression, &alg, &level);
@@ -183,7 +182,7 @@ size_t
WriteDataToArchive(ArchiveHandle *AH, CompressorState *cs,
const void *data, size_t dLen)
{
- switch(cs->comprAlg)
+ switch (cs->comprAlg)
{
case COMPR_ALG_LIBZ:
#ifdef HAVE_LIBZ
@@ -194,7 +193,7 @@ WriteDataToArchive(ArchiveHandle *AH, CompressorState *cs,
case COMPR_ALG_NONE:
return WriteDataToArchiveNone(AH, cs, data, dLen);
}
- return 0; /* keep compiler quiet */
+ return 0; /* keep compiler quiet */
}
/*
@@ -220,7 +219,7 @@ EndCompressor(ArchiveHandle *AH, CompressorState *cs)
static void
InitCompressorZlib(CompressorState *cs, int level)
{
- z_streamp zp;
+ z_streamp zp;
zp = cs->zp = (z_streamp) malloc(sizeof(z_stream));
if (cs->zp == NULL)
@@ -230,9 +229,9 @@ InitCompressorZlib(CompressorState *cs, int level)
zp->opaque = Z_NULL;
/*
- * zlibOutSize is the buffer size we tell zlib it can output
- * to. We actually allocate one extra byte because some routines
- * want to append a trailing zero byte to the zlib output.
+ * zlibOutSize is the buffer size we tell zlib it can output to. We
+ * actually allocate one extra byte because some routines want to append a
+ * trailing zero byte to the zlib output.
*/
cs->zlibOut = (char *) malloc(ZLIB_OUT_SIZE + 1);
cs->zlibOutSize = ZLIB_OUT_SIZE;
@@ -253,7 +252,7 @@ InitCompressorZlib(CompressorState *cs, int level)
static void
EndCompressorZlib(ArchiveHandle *AH, CompressorState *cs)
{
- z_streamp zp = cs->zp;
+ z_streamp zp = cs->zp;
zp->next_in = NULL;
zp->avail_in = 0;
@@ -295,10 +294,11 @@ DeflateCompressorZlib(ArchiveHandle *AH, CompressorState *cs, bool flush)
if (zp->avail_out < cs->zlibOutSize)
{
/*
- * Any write function shoud do its own error checking but
- * to make sure we do a check here as well...
+ * Any write function shoud do its own error checking but to
+ * make sure we do a check here as well...
*/
- size_t len = cs->zlibOutSize - zp->avail_out;
+ size_t len = cs->zlibOutSize - zp->avail_out;
+
if (cs->writeF(AH, out, len) != len)
die_horribly(AH, modulename,
"could not write to output file: %s\n",
@@ -320,8 +320,11 @@ WriteDataToArchiveZlib(ArchiveHandle *AH, CompressorState *cs,
cs->zp->next_in = (void *) data;
cs->zp->avail_in = dLen;
DeflateCompressorZlib(AH, cs, false);
- /* we have either succeeded in writing dLen bytes or we have called
- * die_horribly() */
+
+ /*
+ * we have either succeeded in writing dLen bytes or we have called
+ * die_horribly()
+ */
return dLen;
}
@@ -400,8 +403,7 @@ ReadDataFromArchiveZlib(ArchiveHandle *AH, ReadFunc readF)
free(out);
free(zp);
}
-
-#endif /* HAVE_LIBZ */
+#endif /* HAVE_LIBZ */
/*
@@ -433,8 +435,8 @@ WriteDataToArchiveNone(ArchiveHandle *AH, CompressorState *cs,
const char *data, size_t dLen)
{
/*
- * Any write function should do its own error checking but to make
- * sure we do a check here as well...
+ * Any write function should do its own error checking but to make sure we
+ * do a check here as well...
*/
if (cs->writeF(AH, data, dLen) != dLen)
die_horribly(AH, modulename,
@@ -455,9 +457,9 @@ WriteDataToArchiveNone(ArchiveHandle *AH, CompressorState *cs,
*/
struct cfp
{
- FILE *uncompressedfp;
+ FILE *uncompressedfp;
#ifdef HAVE_LIBZ
- gzFile compressedfp;
+ gzFile compressedfp;
#endif
};
@@ -476,7 +478,7 @@ static int hasSuffix(const char *filename, const char *suffix);
cfp *
cfopen_read(const char *path, const char *mode)
{
- cfp *fp;
+ cfp *fp;
#ifdef HAVE_LIBZ
if (hasSuffix(path, ".gz"))
@@ -488,8 +490,9 @@ cfopen_read(const char *path, const char *mode)
#ifdef HAVE_LIBZ
if (fp == NULL)
{
- int fnamelen = strlen(path) + 4;
- char *fname = malloc(fnamelen);
+ int fnamelen = strlen(path) + 4;
+ char *fname = malloc(fnamelen);
+
if (fname == NULL)
die_horribly(NULL, modulename, "Out of memory\n");
@@ -514,15 +517,16 @@ cfopen_read(const char *path, const char *mode)
cfp *
cfopen_write(const char *path, const char *mode, int compression)
{
- cfp *fp;
+ cfp *fp;
if (compression == 0)
fp = cfopen(path, mode, 0);
else
{
#ifdef HAVE_LIBZ
- int fnamelen = strlen(path) + 4;
- char *fname = malloc(fnamelen);
+ int fnamelen = strlen(path) + 4;
+ char *fname = malloc(fnamelen);
+
if (fname == NULL)
die_horribly(NULL, modulename, "Out of memory\n");
@@ -543,7 +547,8 @@ cfopen_write(const char *path, const char *mode, int compression)
cfp *
cfopen(const char *path, const char *mode, int compression)
{
- cfp *fp = malloc(sizeof(cfp));
+ cfp *fp = malloc(sizeof(cfp));
+
if (fp == NULL)
die_horribly(NULL, modulename, "Out of memory\n");
@@ -625,7 +630,7 @@ cfgets(cfp *fp, char *buf, int len)
int
cfclose(cfp *fp)
{
- int result;
+ int result;
if (fp == NULL)
{
@@ -664,14 +669,15 @@ cfeof(cfp *fp)
static int
hasSuffix(const char *filename, const char *suffix)
{
- int filenamelen = strlen(filename);
- int suffixlen = strlen(suffix);
+ int filenamelen = strlen(filename);
+ int suffixlen = strlen(suffix);
if (filenamelen < suffixlen)
return 0;
return memcmp(&filename[filenamelen - suffixlen],
- suffix,
- suffixlen) == 0;
+ suffix,
+ suffixlen) == 0;
}
+
#endif
diff --git a/src/bin/pg_dump/compress_io.h b/src/bin/pg_dump/compress_io.h
index 9963cef9fc..f5908c0d7a 100644
--- a/src/bin/pg_dump/compress_io.h
+++ b/src/bin/pg_dump/compress_io.h
@@ -1,13 +1,13 @@
/*-------------------------------------------------------------------------
*
* compress_io.h
- * Interface to compress_io.c routines
+ * Interface to compress_io.c routines
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * src/bin/pg_dump/compress_io.h
+ * src/bin/pg_dump/compress_io.h
*
*-------------------------------------------------------------------------
*/
@@ -29,7 +29,7 @@ typedef enum
} CompressionAlgorithm;
/* Prototype for callback function to WriteDataToArchive() */
-typedef size_t (*WriteFunc)(ArchiveHandle *AH, const char *buf, size_t len);
+typedef size_t (*WriteFunc) (ArchiveHandle *AH, const char *buf, size_t len);
/*
* Prototype for callback function to ReadDataFromArchive()
@@ -42,16 +42,16 @@ typedef size_t (*WriteFunc)(ArchiveHandle *AH, const char *buf, size_t len);
*
* Returns the number of bytes read into *buf, or 0 on EOF.
*/
-typedef size_t (*ReadFunc)(ArchiveHandle *AH, char **buf, size_t *buflen);
+typedef size_t (*ReadFunc) (ArchiveHandle *AH, char **buf, size_t *buflen);
/* struct definition appears in compress_io.c */
typedef struct CompressorState CompressorState;
extern CompressorState *AllocateCompressor(int compression, WriteFunc writeF);
extern void ReadDataFromArchive(ArchiveHandle *AH, int compression,
- ReadFunc readF);
+ ReadFunc readF);
extern size_t WriteDataToArchive(ArchiveHandle *AH, CompressorState *cs,
- const void *data, size_t dLen);
+ const void *data, size_t dLen);
extern void EndCompressor(ArchiveHandle *AH, CompressorState *cs);
@@ -60,11 +60,11 @@ typedef struct cfp cfp;
extern cfp *cfopen(const char *path, const char *mode, int compression);
extern cfp *cfopen_read(const char *path, const char *mode);
extern cfp *cfopen_write(const char *path, const char *mode, int compression);
-extern int cfread(void *ptr, int size, cfp *fp);
-extern int cfwrite(const void *ptr, int size, cfp *fp);
-extern int cfgetc(cfp *fp);
+extern int cfread(void *ptr, int size, cfp *fp);
+extern int cfwrite(const void *ptr, int size, cfp *fp);
+extern int cfgetc(cfp *fp);
extern char *cfgets(cfp *fp, char *buf, int len);
-extern int cfclose(cfp *fp);
-extern int cfeof(cfp *fp);
+extern int cfclose(cfp *fp);
+extern int cfeof(cfp *fp);
#endif
diff --git a/src/bin/pg_dump/dumputils.c b/src/bin/pg_dump/dumputils.c
index 0f814f142f..6e5e625e6d 100644
--- a/src/bin/pg_dump/dumputils.c
+++ b/src/bin/pg_dump/dumputils.c
@@ -21,7 +21,7 @@
#include "parser/keywords.h"
-int quote_all_identifiers = 0;
+int quote_all_identifiers = 0;
#define supports_grant_options(version) ((version) >= 70400)
diff --git a/src/bin/pg_dump/dumputils.h b/src/bin/pg_dump/dumputils.h
index 556883b229..44d90669b6 100644
--- a/src/bin/pg_dump/dumputils.h
+++ b/src/bin/pg_dump/dumputils.h
@@ -19,7 +19,7 @@
#include "libpq-fe.h"
#include "pqexpbuffer.h"
-extern int quote_all_identifiers;
+extern int quote_all_identifiers;
extern void init_parallel_dump_utils(void);
extern const char *fmtId(const char *identifier);
diff --git a/src/bin/pg_dump/pg_backup_archiver.c b/src/bin/pg_dump/pg_backup_archiver.c
index 7af3db5d64..7e1ce20745 100644
--- a/src/bin/pg_dump/pg_backup_archiver.c
+++ b/src/bin/pg_dump/pg_backup_archiver.c
@@ -88,8 +88,8 @@ const char *progname;
static const char *modulename = gettext_noop("archiver");
/* index array created by fix_dependencies -- only used in parallel restore */
-static TocEntry **tocsByDumpId; /* index by dumpId - 1 */
-static DumpId maxDumpId; /* length of above array */
+static TocEntry **tocsByDumpId; /* index by dumpId - 1 */
+static DumpId maxDumpId; /* length of above array */
static ArchiveHandle *_allocAH(const char *FileSpec, const ArchiveFormat fmt,
@@ -1529,7 +1529,6 @@ _moveAfter(ArchiveHandle *AH, TocEntry *pos, TocEntry *te)
pos->next->prev = te;
pos->next = te;
}
-
#endif
static void
@@ -1771,7 +1770,7 @@ _discoverArchiveFormat(ArchiveHandle *AH)
if (AH->fSpec)
{
- struct stat st;
+ struct stat st;
wantClose = 1;
@@ -1782,6 +1781,7 @@ _discoverArchiveFormat(ArchiveHandle *AH)
if (stat(AH->fSpec, &st) == 0 && S_ISDIR(st.st_mode))
{
char buf[MAXPGPATH];
+
if (snprintf(buf, MAXPGPATH, "%s/toc.dat", AH->fSpec) >= MAXPGPATH)
die_horribly(AH, modulename, "directory name too long: \"%s\"\n",
AH->fSpec);
@@ -1803,7 +1803,7 @@ _discoverArchiveFormat(ArchiveHandle *AH)
#endif
die_horribly(AH, modulename, "directory \"%s\" does not appear to be a valid archive (\"toc.dat\" does not exist)\n",
AH->fSpec);
- fh = NULL; /* keep compiler quiet */
+ fh = NULL; /* keep compiler quiet */
}
else
{
@@ -3238,7 +3238,7 @@ dumpTimestamp(ArchiveHandle *AH, const char *msg, time_t tim)
*
* Work is done in three phases.
* First we process all SECTION_PRE_DATA tocEntries, in a single connection,
- * just as for a standard restore. Second we process the remaining non-ACL
+ * just as for a standard restore. Second we process the remaining non-ACL
* steps in parallel worker children (threads on Windows, processes on Unix),
* each of which connects separately to the database. Finally we process all
* the ACL entries in a single connection (that happens back in
@@ -3278,9 +3278,9 @@ restore_toc_entries_parallel(ArchiveHandle *AH)
* Do all the early stuff in a single connection in the parent. There's no
* great point in running it in parallel, in fact it will actually run
* faster in a single connection because we avoid all the connection and
- * setup overhead. Also, pg_dump is not currently very good about
- * showing all the dependencies of SECTION_PRE_DATA items, so we do not
- * risk trying to process them out-of-order.
+ * setup overhead. Also, pg_dump is not currently very good about showing
+ * all the dependencies of SECTION_PRE_DATA items, so we do not risk
+ * trying to process them out-of-order.
*/
skipped_some = false;
for (next_work_item = AH->toc->next; next_work_item != AH->toc; next_work_item = next_work_item->next)
@@ -3967,8 +3967,8 @@ fix_dependencies(ArchiveHandle *AH)
/*
* Count the incoming dependencies for each item. Also, it is possible
- * that the dependencies list items that are not in the archive at
- * all. Subtract such items from the depCounts.
+ * that the dependencies list items that are not in the archive at all.
+ * Subtract such items from the depCounts.
*/
for (te = AH->toc->next; te != AH->toc; te = te->next)
{
@@ -3984,8 +3984,8 @@ fix_dependencies(ArchiveHandle *AH)
}
/*
- * Allocate space for revDeps[] arrays, and reset nRevDeps so we can
- * use it as a counter below.
+ * Allocate space for revDeps[] arrays, and reset nRevDeps so we can use
+ * it as a counter below.
*/
for (te = AH->toc->next; te != AH->toc; te = te->next)
{
@@ -3995,8 +3995,8 @@ fix_dependencies(ArchiveHandle *AH)
}
/*
- * Build the revDeps[] arrays of incoming-dependency dumpIds. This
- * had better agree with the loops above.
+ * Build the revDeps[] arrays of incoming-dependency dumpIds. This had
+ * better agree with the loops above.
*/
for (te = AH->toc->next; te != AH->toc; te = te->next)
{
diff --git a/src/bin/pg_dump/pg_backup_archiver.h b/src/bin/pg_dump/pg_backup_archiver.h
index 8d3bbe012c..fd0b174b78 100644
--- a/src/bin/pg_dump/pg_backup_archiver.h
+++ b/src/bin/pg_dump/pg_backup_archiver.h
@@ -261,11 +261,10 @@ typedef struct _archiveHandle
DumpId maxDumpId; /* largest DumpId among all TOC entries */
struct _tocEntry *currToc; /* Used when dumping data */
- int compression; /* Compression requested on open
- * Possible values for compression:
- * -1 Z_DEFAULT_COMPRESSION
- * 0 COMPRESSION_NONE
- * 1-9 levels for gzip compression */
+ int compression; /* Compression requested on open Possible
+ * values for compression: -1
+ * Z_DEFAULT_COMPRESSION 0 COMPRESSION_NONE
+ * 1-9 levels for gzip compression */
ArchiveMode mode; /* File mode - r or w */
void *formatData; /* Header data specific to file format */
diff --git a/src/bin/pg_dump/pg_backup_custom.c b/src/bin/pg_dump/pg_backup_custom.c
index 87c6fb6ec2..a28c15ab3e 100644
--- a/src/bin/pg_dump/pg_backup_custom.c
+++ b/src/bin/pg_dump/pg_backup_custom.c
@@ -311,7 +311,7 @@ static size_t
_WriteData(ArchiveHandle *AH, const void *data, size_t dLen)
{
lclContext *ctx = (lclContext *) AH->formatData;
- CompressorState *cs = ctx->cs;
+ CompressorState *cs = ctx->cs;
if (dLen == 0)
return 0;
@@ -793,6 +793,7 @@ static void
_DeClone(ArchiveHandle *AH)
{
lclContext *ctx = (lclContext *) AH->formatData;
+
free(ctx);
}
@@ -911,7 +912,7 @@ _CustomReadFunc(ArchiveHandle *AH, char **buf, size_t *buflen)
"could not read from input file: end of file\n");
else
die_horribly(AH, modulename,
- "could not read from input file: %s\n", strerror(errno));
+ "could not read from input file: %s\n", strerror(errno));
}
return cnt;
}
diff --git a/src/bin/pg_dump/pg_backup_directory.c b/src/bin/pg_dump/pg_backup_directory.c
index 540ca5405a..111c3e822a 100644
--- a/src/bin/pg_dump/pg_backup_directory.c
+++ b/src/bin/pg_dump/pg_backup_directory.c
@@ -45,11 +45,11 @@ typedef struct
* Our archive location. This is basically what the user specified as his
* backup file but of course here it is a directory.
*/
- char *directory;
+ char *directory;
- cfp *dataFH; /* currently open data file */
+ cfp *dataFH; /* currently open data file */
- cfp *blobsTocFH; /* file handle for blobs.toc */
+ cfp *blobsTocFH; /* file handle for blobs.toc */
} lclContext;
typedef struct
@@ -168,9 +168,10 @@ InitArchiveFmt_Directory(ArchiveHandle *AH)
fname, strerror(errno));
ctx->dataFH = tocFH;
+
/*
- * The TOC of a directory format dump shares the format code of
- * the tar format.
+ * The TOC of a directory format dump shares the format code of the
+ * tar format.
*/
AH->format = archTar;
ReadHead(AH);
@@ -193,8 +194,8 @@ InitArchiveFmt_Directory(ArchiveHandle *AH)
static void
_ArchiveEntry(ArchiveHandle *AH, TocEntry *te)
{
- lclTocEntry *tctx;
- char fn[MAXPGPATH];
+ lclTocEntry *tctx;
+ char fn[MAXPGPATH];
tctx = (lclTocEntry *) calloc(1, sizeof(lclTocEntry));
if (!tctx)
@@ -286,9 +287,9 @@ _PrintExtraToc(ArchiveHandle *AH, TocEntry *te)
static void
_StartData(ArchiveHandle *AH, TocEntry *te)
{
- lclTocEntry *tctx = (lclTocEntry *) te->formatData;
- lclContext *ctx = (lclContext *) AH->formatData;
- char *fname;
+ lclTocEntry *tctx = (lclTocEntry *) te->formatData;
+ lclContext *ctx = (lclContext *) AH->formatData;
+ char *fname;
fname = prependDirectory(AH, tctx->filename);
@@ -310,7 +311,7 @@ _StartData(ArchiveHandle *AH, TocEntry *te)
static size_t
_WriteData(ArchiveHandle *AH, const void *data, size_t dLen)
{
- lclContext *ctx = (lclContext *) AH->formatData;
+ lclContext *ctx = (lclContext *) AH->formatData;
if (dLen == 0)
return 0;
@@ -327,7 +328,7 @@ _WriteData(ArchiveHandle *AH, const void *data, size_t dLen)
static void
_EndData(ArchiveHandle *AH, TocEntry *te)
{
- lclContext *ctx = (lclContext *) AH->formatData;
+ lclContext *ctx = (lclContext *) AH->formatData;
/* Close the file */
cfclose(ctx->dataFH);
@@ -349,7 +350,8 @@ _PrintFileData(ArchiveHandle *AH, char *filename, RestoreOptions *ropt)
if (!filename)
return;
- cfp = cfopen_read(filename, PG_BINARY_R);
+ cfp = cfopen_read(filename, PG_BINARY_R);
+
if (!cfp)
die_horribly(AH, modulename, "could not open input file \"%s\": %s\n",
filename, strerror(errno));
@@ -380,7 +382,8 @@ _PrintTocData(ArchiveHandle *AH, TocEntry *te, RestoreOptions *ropt)
_LoadBlobs(AH, ropt);
else
{
- char *fname = prependDirectory(AH, tctx->filename);
+ char *fname = prependDirectory(AH, tctx->filename);
+
_PrintFileData(AH, fname, ropt);
}
}
@@ -388,10 +391,10 @@ _PrintTocData(ArchiveHandle *AH, TocEntry *te, RestoreOptions *ropt)
static void
_LoadBlobs(ArchiveHandle *AH, RestoreOptions *ropt)
{
- Oid oid;
- lclContext *ctx = (lclContext *) AH->formatData;
- char *fname;
- char line[MAXPGPATH];
+ Oid oid;
+ lclContext *ctx = (lclContext *) AH->formatData;
+ char *fname;
+ char line[MAXPGPATH];
StartRestoreBlobs(AH);
@@ -518,10 +521,11 @@ static void
_CloseArchive(ArchiveHandle *AH)
{
lclContext *ctx = (lclContext *) AH->formatData;
+
if (AH->mode == archModeWrite)
{
- cfp *tocFH;
- char *fname = prependDirectory(AH, "toc.dat");
+ cfp *tocFH;
+ char *fname = prependDirectory(AH, "toc.dat");
/* The TOC is always created uncompressed */
tocFH = cfopen_write(fname, PG_BINARY_W, 0);
@@ -529,6 +533,7 @@ _CloseArchive(ArchiveHandle *AH)
die_horribly(AH, modulename, "could not open output file \"%s\": %s\n",
fname, strerror(errno));
ctx->dataFH = tocFH;
+
/*
* Write 'tar' in the format field of the toc.dat file. The directory
* is compatible with 'tar', so there's no point having a different
@@ -555,14 +560,14 @@ _CloseArchive(ArchiveHandle *AH)
* Called by the archiver when starting to save all BLOB DATA (not schema).
* It is called just prior to the dumper's DataDumper routine.
*
- * We open the large object TOC file here, so that we can append a line to
+ * We open the large object TOC file here, so that we can append a line to
* it for each blob.
*/
static void
_StartBlobs(ArchiveHandle *AH, TocEntry *te)
{
- lclContext *ctx = (lclContext *) AH->formatData;
- char *fname;
+ lclContext *ctx = (lclContext *) AH->formatData;
+ char *fname;
fname = prependDirectory(AH, "blobs.toc");
@@ -581,8 +586,8 @@ _StartBlobs(ArchiveHandle *AH, TocEntry *te)
static void
_StartBlob(ArchiveHandle *AH, TocEntry *te, Oid oid)
{
- lclContext *ctx = (lclContext *) AH->formatData;
- char fname[MAXPGPATH];
+ lclContext *ctx = (lclContext *) AH->formatData;
+ char fname[MAXPGPATH];
snprintf(fname, MAXPGPATH, "%s/blob_%u.dat", ctx->directory, oid);
@@ -601,9 +606,9 @@ _StartBlob(ArchiveHandle *AH, TocEntry *te, Oid oid)
static void
_EndBlob(ArchiveHandle *AH, TocEntry *te, Oid oid)
{
- lclContext *ctx = (lclContext *) AH->formatData;
- char buf[50];
- int len;
+ lclContext *ctx = (lclContext *) AH->formatData;
+ char buf[50];
+ int len;
/* Close the BLOB data file itself */
cfclose(ctx->dataFH);
@@ -612,7 +617,7 @@ _EndBlob(ArchiveHandle *AH, TocEntry *te, Oid oid)
/* register the blob in blobs.toc */
len = snprintf(buf, sizeof(buf), "%u blob_%u.dat\n", oid, oid);
if (cfwrite(buf, len, ctx->blobsTocFH) != len)
- die_horribly(AH, modulename, "could not write to blobs TOC file\n");
+ die_horribly(AH, modulename, "could not write to blobs TOC file\n");
}
/*
@@ -632,7 +637,7 @@ _EndBlobs(ArchiveHandle *AH, TocEntry *te)
static void
createDirectory(const char *dir)
{
- struct stat st;
+ struct stat st;
/* the directory must not exist yet. */
if (stat(dir, &st) == 0)
@@ -661,14 +666,14 @@ createDirectory(const char *dir)
static char *
prependDirectory(ArchiveHandle *AH, const char *relativeFilename)
{
- lclContext *ctx = (lclContext *) AH->formatData;
- static char buf[MAXPGPATH];
- char *dname;
+ lclContext *ctx = (lclContext *) AH->formatData;
+ static char buf[MAXPGPATH];
+ char *dname;
dname = ctx->directory;
if (strlen(dname) + 1 + strlen(relativeFilename) + 1 > MAXPGPATH)
- die_horribly(AH, modulename, "path name too long: %s", dname);
+ die_horribly(AH, modulename, "path name too long: %s", dname);
strcpy(buf, dname);
strcat(buf, "/");
diff --git a/src/bin/pg_dump/pg_backup_tar.c b/src/bin/pg_dump/pg_backup_tar.c
index d0f6a589b3..041f9f9cbb 100644
--- a/src/bin/pg_dump/pg_backup_tar.c
+++ b/src/bin/pg_dump/pg_backup_tar.c
@@ -4,7 +4,7 @@
*
* This file is copied from the 'files' format file, but dumps data into
* one temp file then sends it to the output TAR archive.
- *
+ *
* NOTE: If you untar the created 'tar' file, the resulting files are
* compatible with the 'directory' format. Please keep the two formats in
* sync.
diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c
index 1ccdb4dab9..afda7950d1 100644
--- a/src/bin/pg_dump/pg_dump.c
+++ b/src/bin/pg_dump/pg_dump.c
@@ -155,11 +155,11 @@ static void dumpComment(Archive *fout, const char *target,
static int findComments(Archive *fout, Oid classoid, Oid objoid,
CommentItem **items);
static int collectComments(Archive *fout, CommentItem **items);
-static void dumpSecLabel(Archive *fout, const char *target,
- const char *namespace, const char *owner,
- CatalogId catalogId, int subid, DumpId dumpId);
-static int findSecLabels(Archive *fout, Oid classoid, Oid objoid,
- SecLabelItem **items);
+static void dumpSecLabel(Archive *fout, const char *target,
+ const char *namespace, const char *owner,
+ CatalogId catalogId, int subid, DumpId dumpId);
+static int findSecLabels(Archive *fout, Oid classoid, Oid objoid,
+ SecLabelItem **items);
static int collectSecLabels(Archive *fout, SecLabelItem **items);
static void dumpDumpableObject(Archive *fout, DumpableObject *dobj);
static void dumpNamespace(Archive *fout, NamespaceInfo *nspinfo);
@@ -236,10 +236,10 @@ static void binary_upgrade_set_type_oids_by_type_oid(
static bool binary_upgrade_set_type_oids_by_rel_oid(
PQExpBuffer upgrade_buffer, Oid pg_rel_oid);
static void binary_upgrade_set_pg_class_oids(PQExpBuffer upgrade_buffer,
- Oid pg_class_oid, bool is_index);
+ Oid pg_class_oid, bool is_index);
static void binary_upgrade_extension_member(PQExpBuffer upgrade_buffer,
- DumpableObject *dobj,
- const char *objlabel);
+ DumpableObject *dobj,
+ const char *objlabel);
static const char *getAttrName(int attrnum, TableInfo *tblInfo);
static const char *fmtCopyColumnList(const TableInfo *ti);
static void do_sql_command(PGconn *conn, const char *query);
@@ -278,7 +278,7 @@ main(int argc, char **argv)
int optindex;
RestoreOptions *ropt;
ArchiveFormat archiveFormat = archUnknown;
- ArchiveMode archiveMode;
+ ArchiveMode archiveMode;
static int disable_triggers = 0;
static int outputNoTablespaces = 0;
@@ -911,6 +911,7 @@ parseArchiveFormat(const char *format, ArchiveMode *mode)
else if (pg_strcasecmp(format, "directory") == 0)
archiveFormat = archDirectory;
else if (pg_strcasecmp(format, "f") == 0 || pg_strcasecmp(format, "file") == 0)
+
/*
* Dump files into the current directory; for demonstration only, not
* documented.
@@ -1588,7 +1589,7 @@ makeTableDataInfo(TableInfo *tbinfo, bool oids)
tdinfo->dobj.namespace = tbinfo->dobj.namespace;
tdinfo->tdtable = tbinfo;
tdinfo->oids = oids;
- tdinfo->filtercond = NULL; /* might get set later */
+ tdinfo->filtercond = NULL; /* might get set later */
addObjectDependency(&tdinfo->dobj, tbinfo->dobj.dumpId);
tbinfo->dataObj = tdinfo;
@@ -1932,7 +1933,7 @@ dumpDatabase(Archive *AH)
int i_relfrozenxid;
/*
- * pg_largeobject
+ * pg_largeobject
*/
appendPQExpBuffer(loFrozenQry, "SELECT relfrozenxid\n"
"FROM pg_catalog.pg_class\n"
@@ -1966,29 +1967,29 @@ dumpDatabase(Archive *AH)
PQclear(lo_res);
/*
- * pg_largeobject_metadata
+ * pg_largeobject_metadata
*/
if (g_fout->remoteVersion >= 90000)
{
resetPQExpBuffer(loFrozenQry);
resetPQExpBuffer(loOutQry);
-
+
appendPQExpBuffer(loFrozenQry, "SELECT relfrozenxid\n"
"FROM pg_catalog.pg_class\n"
"WHERE oid = %u;\n",
LargeObjectMetadataRelationId);
-
+
lo_res = PQexec(g_conn, loFrozenQry->data);
check_sql_result(lo_res, g_conn, loFrozenQry->data, PGRES_TUPLES_OK);
-
+
if (PQntuples(lo_res) != 1)
{
write_msg(NULL, "dumpDatabase(): could not find pg_largeobject_metadata.relfrozenxid\n");
exit_nicely();
}
-
+
i_relfrozenxid = PQfnumber(lo_res, "relfrozenxid");
-
+
appendPQExpBuffer(loOutQry, "\n-- For binary upgrade, set pg_largeobject_metadata.relfrozenxid\n");
appendPQExpBuffer(loOutQry, "UPDATE pg_catalog.pg_class\n"
"SET relfrozenxid = '%u'\n"
@@ -2001,7 +2002,7 @@ dumpDatabase(Archive *AH)
loOutQry->data, "", NULL,
NULL, 0,
NULL, NULL);
-
+
PQclear(lo_res);
}
@@ -2437,7 +2438,7 @@ binary_upgrade_set_type_oids_by_rel_oid(PQExpBuffer upgrade_buffer,
static void
binary_upgrade_set_pg_class_oids(PQExpBuffer upgrade_buffer, Oid pg_class_oid,
- bool is_index)
+ bool is_index)
{
PQExpBuffer upgrade_query = createPQExpBuffer();
int ntups;
@@ -2446,7 +2447,7 @@ binary_upgrade_set_pg_class_oids(PQExpBuffer upgrade_buffer, Oid pg_class_oid,
Oid pg_class_reltoastidxid;
appendPQExpBuffer(upgrade_query,
- "SELECT c.reltoastrelid, t.reltoastidxid "
+ "SELECT c.reltoastrelid, t.reltoastidxid "
"FROM pg_catalog.pg_class c LEFT JOIN "
"pg_catalog.pg_class t ON (c.reltoastrelid = t.oid) "
"WHERE c.oid = '%u'::pg_catalog.oid;",
@@ -2470,7 +2471,7 @@ binary_upgrade_set_pg_class_oids(PQExpBuffer upgrade_buffer, Oid pg_class_oid,
pg_class_reltoastidxid = atooid(PQgetvalue(upgrade_res, 0, PQfnumber(upgrade_res, "reltoastidxid")));
appendPQExpBuffer(upgrade_buffer,
- "\n-- For binary upgrade, must preserve pg_class oids\n");
+ "\n-- For binary upgrade, must preserve pg_class oids\n");
if (!is_index)
{
@@ -2485,14 +2486,14 @@ binary_upgrade_set_pg_class_oids(PQExpBuffer upgrade_buffer, Oid pg_class_oid,
* the creation of a TOAST table, and the TOAST table might have
* been created long after table creation, when the table was
* loaded with wide data. By setting the TOAST oid we force
- * creation of the TOAST heap and TOAST index by the backend
- * so we can cleanly copy the files during binary upgrade.
+ * creation of the TOAST heap and TOAST index by the backend so we
+ * can cleanly copy the files during binary upgrade.
*/
-
+
appendPQExpBuffer(upgrade_buffer,
"SELECT binary_upgrade.set_next_toast_pg_class_oid('%u'::pg_catalog.oid);\n",
pg_class_reltoastrelid);
-
+
/* every toast table has an index */
appendPQExpBuffer(upgrade_buffer,
"SELECT binary_upgrade.set_next_index_pg_class_oid('%u'::pg_catalog.oid);\n",
@@ -2526,10 +2527,10 @@ binary_upgrade_extension_member(PQExpBuffer upgrade_buffer,
return;
/*
- * Find the parent extension. We could avoid this search if we wanted
- * to add a link field to DumpableObject, but the space costs of that
- * would be considerable. We assume that member objects could only have
- * a direct dependency on their own extension, not any others.
+ * Find the parent extension. We could avoid this search if we wanted to
+ * add a link field to DumpableObject, but the space costs of that would
+ * be considerable. We assume that member objects could only have a
+ * direct dependency on their own extension, not any others.
*/
for (i = 0; i < dobj->nDeps; i++)
{
@@ -2545,7 +2546,7 @@ binary_upgrade_extension_member(PQExpBuffer upgrade_buffer,
}
appendPQExpBuffer(upgrade_buffer,
- "\n-- For binary upgrade, handle extension membership the hard way\n");
+ "\n-- For binary upgrade, handle extension membership the hard way\n");
appendPQExpBuffer(upgrade_buffer, "ALTER EXTENSION %s ADD %s;\n",
fmtId(extobj->name),
objlabel);
@@ -3664,10 +3665,10 @@ getFuncs(int *numFuncs)
selectSourceSchema("pg_catalog");
/*
- * Find all user-defined functions. Normally we can exclude functions
- * in pg_catalog, which is worth doing since there are several thousand
- * of 'em. However, there are some extensions that create functions in
- * pg_catalog. In normal dumps we can still ignore those --- but in
+ * Find all user-defined functions. Normally we can exclude functions in
+ * pg_catalog, which is worth doing since there are several thousand of
+ * 'em. However, there are some extensions that create functions in
+ * pg_catalog. In normal dumps we can still ignore those --- but in
* binary-upgrade mode, we must dump the member objects of the extension,
* so be sure to fetch any such functions.
*/
@@ -5594,19 +5595,19 @@ getTableAttrs(TableInfo *tblinfo, int numTables)
if (g_fout->remoteVersion >= 90100)
{
/*
- * attcollation is new in 9.1. Since we only want to dump
- * COLLATE clauses for attributes whose collation is different
- * from their type's default, we use a CASE here to suppress
- * uninteresting attcollations cheaply.
+ * attcollation is new in 9.1. Since we only want to dump COLLATE
+ * clauses for attributes whose collation is different from their
+ * type's default, we use a CASE here to suppress uninteresting
+ * attcollations cheaply.
*/
appendPQExpBuffer(q, "SELECT a.attnum, a.attname, a.atttypmod, "
"a.attstattarget, a.attstorage, t.typstorage, "
"a.attnotnull, a.atthasdef, a.attisdropped, "
"a.attlen, a.attalign, a.attislocal, "
"pg_catalog.format_type(t.oid,a.atttypmod) AS atttypname, "
- "array_to_string(a.attoptions, ', ') AS attoptions, "
+ "array_to_string(a.attoptions, ', ') AS attoptions, "
"CASE WHEN a.attcollation <> t.typcollation "
- "THEN a.attcollation ELSE 0 END AS attcollation "
+ "THEN a.attcollation ELSE 0 END AS attcollation "
"FROM pg_catalog.pg_attribute a LEFT JOIN pg_catalog.pg_type t "
"ON a.atttypid = t.oid "
"WHERE a.attrelid = '%u'::pg_catalog.oid "
@@ -5622,7 +5623,7 @@ getTableAttrs(TableInfo *tblinfo, int numTables)
"a.attnotnull, a.atthasdef, a.attisdropped, "
"a.attlen, a.attalign, a.attislocal, "
"pg_catalog.format_type(t.oid,a.atttypmod) AS atttypname, "
- "array_to_string(a.attoptions, ', ') AS attoptions, "
+ "array_to_string(a.attoptions, ', ') AS attoptions, "
"0 AS attcollation "
"FROM pg_catalog.pg_attribute a LEFT JOIN pg_catalog.pg_type t "
"ON a.atttypid = t.oid "
@@ -7151,8 +7152,8 @@ dumpExtension(Archive *fout, ExtensionInfo *extinfo)
}
else
{
- int i;
- int n;
+ int i;
+ int n;
appendPQExpBuffer(q, "-- For binary upgrade, create an empty extension and insert objects into it\n");
appendPQExpBuffer(q,
@@ -7164,10 +7165,11 @@ dumpExtension(Archive *fout, ExtensionInfo *extinfo)
appendPQExpBuffer(q, "%s, ", extinfo->relocatable ? "true" : "false");
appendStringLiteralAH(q, extinfo->extversion, fout);
appendPQExpBuffer(q, ", ");
+
/*
* Note that we're pushing extconfig (an OID array) back into
- * pg_extension exactly as-is. This is OK because pg_class OIDs
- * are preserved in binary upgrade.
+ * pg_extension exactly as-is. This is OK because pg_class OIDs are
+ * preserved in binary upgrade.
*/
if (strlen(extinfo->extconfig) > 2)
appendStringLiteralAH(q, extinfo->extconfig, fout);
@@ -7810,13 +7812,13 @@ dumpDomain(Archive *fout, TypeInfo *tyinfo)
{
/* typcollation is new in 9.1 */
appendPQExpBuffer(query, "SELECT t.typnotnull, "
- "pg_catalog.format_type(t.typbasetype, t.typtypmod) AS typdefn, "
+ "pg_catalog.format_type(t.typbasetype, t.typtypmod) AS typdefn, "
"pg_catalog.pg_get_expr(t.typdefaultbin, 'pg_catalog.pg_type'::pg_catalog.regclass) AS typdefaultbin, "
"t.typdefault, "
"CASE WHEN t.typcollation <> u.typcollation "
"THEN t.typcollation ELSE 0 END AS typcollation "
"FROM pg_catalog.pg_type t "
- "LEFT JOIN pg_catalog.pg_type u ON (t.typbasetype = u.oid) "
+ "LEFT JOIN pg_catalog.pg_type u ON (t.typbasetype = u.oid) "
"WHERE t.oid = '%u'::pg_catalog.oid",
tyinfo->dobj.catId.oid);
}
@@ -7824,7 +7826,7 @@ dumpDomain(Archive *fout, TypeInfo *tyinfo)
{
/* We assume here that remoteVersion must be at least 70300 */
appendPQExpBuffer(query, "SELECT typnotnull, "
- "pg_catalog.format_type(typbasetype, typtypmod) AS typdefn, "
+ "pg_catalog.format_type(typbasetype, typtypmod) AS typdefn, "
"pg_catalog.pg_get_expr(typdefaultbin, 'pg_catalog.pg_type'::pg_catalog.regclass) AS typdefaultbin, "
"typdefault, 0 AS typcollation "
"FROM pg_catalog.pg_type "
@@ -7870,7 +7872,7 @@ dumpDomain(Archive *fout, TypeInfo *tyinfo)
/* Print collation only if different from base type's collation */
if (OidIsValid(typcollation))
{
- CollInfo *coll;
+ CollInfo *coll;
coll = findCollationByOid(typcollation);
if (coll)
@@ -9677,11 +9679,11 @@ dumpOpclass(Archive *fout, OpclassInfo *opcinfo)
* Print only those opfamily members that are tied to the opclass by
* pg_depend entries.
*
- * XXX RECHECK is gone as of 8.4, but we'll still print it if dumping
- * an older server's opclass in which it is used. This is to avoid
+ * XXX RECHECK is gone as of 8.4, but we'll still print it if dumping an
+ * older server's opclass in which it is used. This is to avoid
* hard-to-detect breakage if a newer pg_dump is used to dump from an
- * older server and then reload into that old version. This can go
- * away once 8.3 is so old as to not be of interest to anyone.
+ * older server and then reload into that old version. This can go away
+ * once 8.3 is so old as to not be of interest to anyone.
*/
resetPQExpBuffer(query);
@@ -9691,11 +9693,11 @@ dumpOpclass(Archive *fout, OpclassInfo *opcinfo)
"amopopr::pg_catalog.regoperator, "
"opfname AS sortfamily, "
"nspname AS sortfamilynsp "
- "FROM pg_catalog.pg_amop ao JOIN pg_catalog.pg_depend ON "
+ "FROM pg_catalog.pg_amop ao JOIN pg_catalog.pg_depend ON "
"(classid = 'pg_catalog.pg_amop'::pg_catalog.regclass AND objid = ao.oid) "
- "LEFT JOIN pg_catalog.pg_opfamily f ON f.oid = amopsortfamily "
- "LEFT JOIN pg_catalog.pg_namespace n ON n.oid = opfnamespace "
- "WHERE refclassid = 'pg_catalog.pg_opclass'::pg_catalog.regclass "
+ "LEFT JOIN pg_catalog.pg_opfamily f ON f.oid = amopsortfamily "
+ "LEFT JOIN pg_catalog.pg_namespace n ON n.oid = opfnamespace "
+ "WHERE refclassid = 'pg_catalog.pg_opclass'::pg_catalog.regclass "
"AND refobjid = '%u'::pg_catalog.oid "
"AND amopfamily = '%s'::pg_catalog.oid "
"ORDER BY amopstrategy",
@@ -9733,8 +9735,8 @@ dumpOpclass(Archive *fout, OpclassInfo *opcinfo)
else
{
/*
- * Here, we print all entries since there are no opfamilies and
- * hence no loose operators to worry about.
+ * Here, we print all entries since there are no opfamilies and hence
+ * no loose operators to worry about.
*/
appendPQExpBuffer(query, "SELECT amopstrategy, amopreqcheck, "
"amopopr::pg_catalog.regoperator, "
@@ -9939,11 +9941,11 @@ dumpOpfamily(Archive *fout, OpfamilyInfo *opfinfo)
* Fetch only those opfamily members that are tied directly to the
* opfamily by pg_depend entries.
*
- * XXX RECHECK is gone as of 8.4, but we'll still print it if dumping
- * an older server's opclass in which it is used. This is to avoid
+ * XXX RECHECK is gone as of 8.4, but we'll still print it if dumping an
+ * older server's opclass in which it is used. This is to avoid
* hard-to-detect breakage if a newer pg_dump is used to dump from an
- * older server and then reload into that old version. This can go
- * away once 8.3 is so old as to not be of interest to anyone.
+ * older server and then reload into that old version. This can go away
+ * once 8.3 is so old as to not be of interest to anyone.
*/
if (g_fout->remoteVersion >= 90100)
{
@@ -9951,11 +9953,11 @@ dumpOpfamily(Archive *fout, OpfamilyInfo *opfinfo)
"amopopr::pg_catalog.regoperator, "
"opfname AS sortfamily, "
"nspname AS sortfamilynsp "
- "FROM pg_catalog.pg_amop ao JOIN pg_catalog.pg_depend ON "
+ "FROM pg_catalog.pg_amop ao JOIN pg_catalog.pg_depend ON "
"(classid = 'pg_catalog.pg_amop'::pg_catalog.regclass AND objid = ao.oid) "
- "LEFT JOIN pg_catalog.pg_opfamily f ON f.oid = amopsortfamily "
- "LEFT JOIN pg_catalog.pg_namespace n ON n.oid = opfnamespace "
- "WHERE refclassid = 'pg_catalog.pg_opfamily'::pg_catalog.regclass "
+ "LEFT JOIN pg_catalog.pg_opfamily f ON f.oid = amopsortfamily "
+ "LEFT JOIN pg_catalog.pg_namespace n ON n.oid = opfnamespace "
+ "WHERE refclassid = 'pg_catalog.pg_opfamily'::pg_catalog.regclass "
"AND refobjid = '%u'::pg_catalog.oid "
"AND amopfamily = '%u'::pg_catalog.oid "
"ORDER BY amopstrategy",
@@ -11288,7 +11290,7 @@ dumpUserMappings(Archive *fout,
* to fail if run by a non-superuser. Note that the view will show
* umoptions as null if the user hasn't got privileges for the associated
* server; this means that pg_dump will dump such a mapping, but with no
- * OPTIONS clause. A possible alternative is to skip such mappings
+ * OPTIONS clause. A possible alternative is to skip such mappings
* altogether, but it's not clear that that's an improvement.
*/
selectSourceSchema("pg_catalog");
@@ -11495,10 +11497,10 @@ dumpSecLabel(Archive *fout, const char *target,
const char *namespace, const char *owner,
CatalogId catalogId, int subid, DumpId dumpId)
{
- SecLabelItem *labels;
- int nlabels;
- int i;
- PQExpBuffer query;
+ SecLabelItem *labels;
+ int nlabels;
+ int i;
+ PQExpBuffer query;
/* do nothing, if --no-security-label is supplied */
if (no_security_label)
@@ -11557,11 +11559,11 @@ dumpSecLabel(Archive *fout, const char *target,
static void
dumpTableSecLabel(Archive *fout, TableInfo *tbinfo, const char *reltypename)
{
- SecLabelItem *labels;
- int nlabels;
- int i;
- PQExpBuffer query;
- PQExpBuffer target;
+ SecLabelItem *labels;
+ int nlabels;
+ int i;
+ PQExpBuffer query;
+ PQExpBuffer target;
/* do nothing, if --no-security-label is supplied */
if (no_security_label)
@@ -11587,9 +11589,9 @@ dumpTableSecLabel(Archive *fout, TableInfo *tbinfo, const char *reltypename)
for (i = 0; i < nlabels; i++)
{
const char *colname;
- const char *provider = labels[i].provider;
- const char *label = labels[i].label;
- int objsubid = labels[i].objsubid;
+ const char *provider = labels[i].provider;
+ const char *label = labels[i].label;
+ int objsubid = labels[i].objsubid;
resetPQExpBuffer(target);
if (objsubid == 0)
@@ -11639,12 +11641,12 @@ findSecLabels(Archive *fout, Oid classoid, Oid objoid, SecLabelItem **items)
{
/* static storage for table of security labels */
static SecLabelItem *labels = NULL;
- static int nlabels = -1;
+ static int nlabels = -1;
- SecLabelItem *middle = NULL;
- SecLabelItem *low;
- SecLabelItem *high;
- int nmatch;
+ SecLabelItem *middle = NULL;
+ SecLabelItem *low;
+ SecLabelItem *high;
+ int nmatch;
/* Get security labels if we didn't already */
if (nlabels < 0)
@@ -11668,10 +11670,10 @@ findSecLabels(Archive *fout, Oid classoid, Oid objoid, SecLabelItem **items)
else if (objoid > middle->objoid)
low = middle + 1;
else
- break; /* found a match */
+ break; /* found a match */
}
- if (low > high) /* no matches */
+ if (low > high) /* no matches */
{
*items = NULL;
return 0;
@@ -11718,16 +11720,16 @@ findSecLabels(Archive *fout, Oid classoid, Oid objoid, SecLabelItem **items)
static int
collectSecLabels(Archive *fout, SecLabelItem **items)
{
- PGresult *res;
- PQExpBuffer query;
- int i_label;
- int i_provider;
- int i_classoid;
- int i_objoid;
- int i_objsubid;
- int ntups;
- int i;
- SecLabelItem *labels;
+ PGresult *res;
+ PQExpBuffer query;
+ int i_label;
+ int i_provider;
+ int i_classoid;
+ int i_objoid;
+ int i_objsubid;
+ int ntups;
+ int i;
+ SecLabelItem *labels;
query = createPQExpBuffer();
@@ -11740,11 +11742,11 @@ collectSecLabels(Archive *fout, SecLabelItem **items)
check_sql_result(res, g_conn, query->data, PGRES_TUPLES_OK);
/* Construct lookup table containing OIDs in numeric form */
- i_label = PQfnumber(res, "label");
- i_provider = PQfnumber(res, "provider");
- i_classoid = PQfnumber(res, "classoid");
- i_objoid = PQfnumber(res, "objoid");
- i_objsubid = PQfnumber(res, "objsubid");
+ i_label = PQfnumber(res, "label");
+ i_provider = PQfnumber(res, "provider");
+ i_classoid = PQfnumber(res, "classoid");
+ i_objoid = PQfnumber(res, "objoid");
+ i_objsubid = PQfnumber(res, "objsubid");
ntups = PQntuples(res);
@@ -11752,15 +11754,15 @@ collectSecLabels(Archive *fout, SecLabelItem **items)
for (i = 0; i < ntups; i++)
{
- labels[i].label = PQgetvalue(res, i, i_label);
- labels[i].provider = PQgetvalue(res, i, i_provider);
+ labels[i].label = PQgetvalue(res, i, i_label);
+ labels[i].provider = PQgetvalue(res, i, i_provider);
labels[i].classoid = atooid(PQgetvalue(res, i, i_classoid));
labels[i].objoid = atooid(PQgetvalue(res, i, i_objoid));
labels[i].objsubid = atoi(PQgetvalue(res, i, i_objsubid));
}
/* Do NOT free the PGresult since we are keeping pointers into it */
- destroyPQExpBuffer(query);
+ destroyPQExpBuffer(query);
*items = labels;
return ntups;
@@ -11937,19 +11939,19 @@ dumpTableSchema(Archive *fout, TableInfo *tbinfo)
{
if (tbinfo->relkind == RELKIND_FOREIGN_TABLE)
{
- int i_srvname;
- int i_ftoptions;
+ int i_srvname;
+ int i_ftoptions;
reltypename = "FOREIGN TABLE";
- /* retrieve name of foreign server and generic options */
+ /* retrieve name of foreign server and generic options */
appendPQExpBuffer(query,
- "SELECT fs.srvname, array_to_string(ARRAY("
+ "SELECT fs.srvname, array_to_string(ARRAY("
" SELECT option_name || ' ' || quote_literal(option_value)"
- " FROM pg_options_to_table(ftoptions)), ', ') AS ftoptions "
- "FROM pg_foreign_table ft JOIN pg_foreign_server fs "
- " ON (fs.oid = ft.ftserver) "
- "WHERE ft.ftrelid = %u", tbinfo->dobj.catId.oid);
+ " FROM pg_options_to_table(ftoptions)), ', ') AS ftoptions "
+ "FROM pg_foreign_table ft JOIN pg_foreign_server fs "
+ " ON (fs.oid = ft.ftserver) "
+ "WHERE ft.ftrelid = %u", tbinfo->dobj.catId.oid);
res = PQexec(g_conn, query->data);
check_sql_result(res, g_conn, query->data, PGRES_TUPLES_OK);
i_srvname = PQfnumber(res, "srvname");
@@ -11984,7 +11986,7 @@ dumpTableSchema(Archive *fout, TableInfo *tbinfo)
appendPQExpBuffer(q, "CREATE %s%s %s",
tbinfo->relpersistence == RELPERSISTENCE_UNLOGGED ?
- "UNLOGGED " : "",
+ "UNLOGGED " : "",
reltypename,
fmtId(tbinfo->dobj.name));
if (tbinfo->reloftype)
@@ -12063,14 +12065,14 @@ dumpTableSchema(Archive *fout, TableInfo *tbinfo)
/* Add collation if not default for the type */
if (OidIsValid(tbinfo->attcollation[j]))
{
- CollInfo *coll;
+ CollInfo *coll;
coll = findCollationByOid(tbinfo->attcollation[j]);
if (coll)
{
/* always schema-qualify, don't try to be smart */
appendPQExpBuffer(q, " COLLATE %s.",
- fmtId(coll->dobj.namespace->dobj.name));
+ fmtId(coll->dobj.namespace->dobj.name));
appendPQExpBuffer(q, "%s",
fmtId(coll->dobj.name));
}
@@ -13546,9 +13548,9 @@ getExtensionMembership(ExtensionInfo extinfo[], int numExtensions)
/*
* Normally, mark the member object as not to be dumped. But in
- * binary upgrades, we still dump the members individually, since
- * the idea is to exactly reproduce the database contents rather
- * than replace the extension contents with something different.
+ * binary upgrades, we still dump the members individually, since the
+ * idea is to exactly reproduce the database contents rather than
+ * replace the extension contents with something different.
*/
if (!binary_upgrade)
dobj->dump = false;
@@ -13563,29 +13565,29 @@ getExtensionMembership(ExtensionInfo extinfo[], int numExtensions)
* objects for them, ensuring their data will be dumped even though the
* tables themselves won't be.
*
- * Note that we create TableDataInfo objects even in schemaOnly mode,
- * ie, user data in a configuration table is treated like schema data.
- * This seems appropriate since system data in a config table would
- * get reloaded by CREATE EXTENSION.
+ * Note that we create TableDataInfo objects even in schemaOnly mode, ie,
+ * user data in a configuration table is treated like schema data. This
+ * seems appropriate since system data in a config table would get
+ * reloaded by CREATE EXTENSION.
*/
for (i = 0; i < numExtensions; i++)
{
- char *extconfig = extinfo[i].extconfig;
- char *extcondition = extinfo[i].extcondition;
- char **extconfigarray = NULL;
- char **extconditionarray = NULL;
- int nconfigitems;
- int nconditionitems;
+ char *extconfig = extinfo[i].extconfig;
+ char *extcondition = extinfo[i].extcondition;
+ char **extconfigarray = NULL;
+ char **extconditionarray = NULL;
+ int nconfigitems;
+ int nconditionitems;
if (parsePGArray(extconfig, &extconfigarray, &nconfigitems) &&
- parsePGArray(extcondition, &extconditionarray, &nconditionitems) &&
+ parsePGArray(extcondition, &extconditionarray, &nconditionitems) &&
nconfigitems == nconditionitems)
{
- int j;
+ int j;
for (j = 0; j < nconfigitems; j++)
{
- TableInfo *configtbl;
+ TableInfo *configtbl;
configtbl = findTableByOid(atooid(extconfigarray[j]));
if (configtbl && configtbl->dataObj == NULL)
diff --git a/src/bin/pg_dump/pg_dump.h b/src/bin/pg_dump/pg_dump.h
index 6559e23df1..c95614b16f 100644
--- a/src/bin/pg_dump/pg_dump.h
+++ b/src/bin/pg_dump/pg_dump.h
@@ -145,11 +145,11 @@ typedef struct _namespaceInfo
typedef struct _extensionInfo
{
DumpableObject dobj;
- char *namespace; /* schema containing extension's objects */
+ char *namespace; /* schema containing extension's objects */
bool relocatable;
char *extversion;
- char *extconfig; /* info about configuration tables */
- char *extcondition;
+ char *extconfig; /* info about configuration tables */
+ char *extcondition;
} ExtensionInfo;
typedef struct _typeInfo
@@ -239,7 +239,7 @@ typedef struct _tableInfo
char *rolname; /* name of owner, or empty string */
char *relacl;
char relkind;
- char relpersistence; /* relation persistence */
+ char relpersistence; /* relation persistence */
char *reltablespace; /* relation tablespace */
char *reloptions; /* options specified by WITH (...) */
char *toast_reloptions; /* ditto, for the TOAST table */
@@ -249,7 +249,7 @@ typedef struct _tableInfo
bool hasoids; /* does it have OIDs? */
uint32 frozenxid; /* for restore frozen xid */
Oid toast_oid; /* for restore toast frozen xid */
- uint32 toast_frozenxid;/* for restore toast frozen xid */
+ uint32 toast_frozenxid; /* for restore toast frozen xid */
int ncheck; /* # of CHECK expressions */
char *reloftype; /* underlying type for typed table */
/* these two are set only if table is a sequence owned by a column: */
diff --git a/src/bin/pg_dump/pg_dumpall.c b/src/bin/pg_dump/pg_dumpall.c
index 9082653552..0843ffe09f 100644
--- a/src/bin/pg_dump/pg_dumpall.c
+++ b/src/bin/pg_dump/pg_dumpall.c
@@ -735,7 +735,7 @@ dumpRoles(PGconn *conn)
appendPQExpBuffer(buf, "\n-- For binary upgrade, must preserve pg_authid.oid\n");
appendPQExpBuffer(buf,
- "SELECT binary_upgrade.set_next_pg_authid_oid('%u'::pg_catalog.oid);\n\n",
+ "SELECT binary_upgrade.set_next_pg_authid_oid('%u'::pg_catalog.oid);\n\n",
auth_oid);
}
diff --git a/src/bin/psql/command.c b/src/bin/psql/command.c
index d7cdcf6434..31a9ab909c 100644
--- a/src/bin/psql/command.c
+++ b/src/bin/psql/command.c
@@ -498,7 +498,7 @@ exec_command(const char *cmd,
break;
}
break;
- case 'x': /* Extensions */
+ case 'x': /* Extensions */
if (show_verbose)
success = listExtensionContents(pattern);
else
@@ -1103,7 +1103,7 @@ exec_command(const char *cmd,
else if (strcmp(cmd, "sf") == 0 || strcmp(cmd, "sf+") == 0)
{
bool show_linenumbers = (strcmp(cmd, "sf+") == 0);
- PQExpBuffer func_buf;
+ PQExpBuffer func_buf;
char *func;
Oid foid = InvalidOid;
@@ -1127,8 +1127,8 @@ exec_command(const char *cmd,
}
else
{
- FILE *output;
- bool is_pager;
+ FILE *output;
+ bool is_pager;
/* Select output stream: stdout, pager, or file */
if (pset.queryFout == stdout)
@@ -1174,7 +1174,7 @@ exec_command(const char *cmd,
*/
while (*lines != '\0')
{
- char *eol;
+ char *eol;
if (in_header && strncmp(lines, "AS ", 3) == 0)
in_header = false;
@@ -1573,7 +1573,7 @@ do_connect(char *dbname, char *user, char *host, char *port)
if (param_is_newly_set(PQhost(o_conn), PQhost(pset.db)) ||
param_is_newly_set(PQport(o_conn), PQport(pset.db)))
{
- char *host = PQhost(pset.db);
+ char *host = PQhost(pset.db);
if (host == NULL)
host = DEFAULT_PGSOCKET_DIR;
@@ -1778,7 +1778,7 @@ editFile(const char *fname, int lineno)
/* Allocate sufficient memory for command line. */
if (lineno > 0)
sys = pg_malloc(strlen(editorName)
- + strlen(editor_lineno_switch) + 10 /* for integer */
+ + strlen(editor_lineno_switch) + 10 /* for integer */
+ 1 + strlen(fname) + 10 + 1);
else
sys = pg_malloc(strlen(editorName) + strlen(fname) + 10 + 1);
@@ -2473,8 +2473,8 @@ strip_lineno_from_funcdesc(char *func)
* multibyte environment: there is no reason to believe that we are
* looking at the first byte of a character, nor are we necessarily
* working in a "safe" encoding. Fortunately the bitpatterns we are
- * looking for are unlikely to occur as non-first bytes, but beware
- * of trying to expand the set of cases that can be recognized. We must
+ * looking for are unlikely to occur as non-first bytes, but beware of
+ * trying to expand the set of cases that can be recognized. We must
* guard the macros by using isascii() first, too.
*/
diff --git a/src/bin/psql/describe.c b/src/bin/psql/describe.c
index a30eaeb10f..bab67174a2 100644
--- a/src/bin/psql/describe.c
+++ b/src/bin/psql/describe.c
@@ -706,7 +706,7 @@ permissionsList(const char *pattern)
gettext_noop("Schema"),
gettext_noop("Name"),
gettext_noop("table"), gettext_noop("view"), gettext_noop("sequence"),
- gettext_noop("foreign table"),
+ gettext_noop("foreign table"),
gettext_noop("Type"));
printACLColumn(&buf, "c.relacl");
@@ -1745,7 +1745,7 @@ describeOneTableDetails(const char *schemaname,
{
printfPQExpBuffer(&buf,
"SELECT conname,\n"
- " pg_catalog.pg_get_constraintdef(r.oid, true) as condef\n");
+ " pg_catalog.pg_get_constraintdef(r.oid, true) as condef\n");
if (pset.sversion >= 90100)
appendPQExpBuffer(&buf, " ,convalidated\n");
appendPQExpBuffer(&buf, "FROM pg_catalog.pg_constraint r\n"
@@ -1909,119 +1909,118 @@ describeOneTableDetails(const char *schemaname,
*/
if (tableinfo.hastriggers)
{
- PGresult *result;
- int tuples;
+ PGresult *result;
+ int tuples;
- printfPQExpBuffer(&buf,
- "SELECT t.tgname, "
- "pg_catalog.pg_get_triggerdef(t.oid%s), "
- "t.tgenabled\n"
- "FROM pg_catalog.pg_trigger t\n"
- "WHERE t.tgrelid = '%s' AND ",
- (pset.sversion >= 90000 ? ", true" : ""),
- oid);
- if (pset.sversion >= 90000)
- appendPQExpBuffer(&buf, "NOT t.tgisinternal");
- else if (pset.sversion >= 80300)
- appendPQExpBuffer(&buf, "t.tgconstraint = 0");
- else
- appendPQExpBuffer(&buf,
- "(NOT tgisconstraint "
- " OR NOT EXISTS"
- " (SELECT 1 FROM pg_catalog.pg_depend d "
- " JOIN pg_catalog.pg_constraint c ON (d.refclassid = c.tableoid AND d.refobjid = c.oid) "
- " WHERE d.classid = t.tableoid AND d.objid = t.oid AND d.deptype = 'i' AND c.contype = 'f'))");
- appendPQExpBuffer(&buf, "\nORDER BY 1");
+ printfPQExpBuffer(&buf,
+ "SELECT t.tgname, "
+ "pg_catalog.pg_get_triggerdef(t.oid%s), "
+ "t.tgenabled\n"
+ "FROM pg_catalog.pg_trigger t\n"
+ "WHERE t.tgrelid = '%s' AND ",
+ (pset.sversion >= 90000 ? ", true" : ""),
+ oid);
+ if (pset.sversion >= 90000)
+ appendPQExpBuffer(&buf, "NOT t.tgisinternal");
+ else if (pset.sversion >= 80300)
+ appendPQExpBuffer(&buf, "t.tgconstraint = 0");
+ else
+ appendPQExpBuffer(&buf,
+ "(NOT tgisconstraint "
+ " OR NOT EXISTS"
+ " (SELECT 1 FROM pg_catalog.pg_depend d "
+ " JOIN pg_catalog.pg_constraint c ON (d.refclassid = c.tableoid AND d.refobjid = c.oid) "
+ " WHERE d.classid = t.tableoid AND d.objid = t.oid AND d.deptype = 'i' AND c.contype = 'f'))");
+ appendPQExpBuffer(&buf, "\nORDER BY 1");
- result = PSQLexec(buf.data, false);
- if (!result)
- goto error_return;
- else
- tuples = PQntuples(result);
+ result = PSQLexec(buf.data, false);
+ if (!result)
+ goto error_return;
+ else
+ tuples = PQntuples(result);
- if (tuples > 0)
+ if (tuples > 0)
+ {
+ bool have_heading;
+ int category;
+
+ /*
+ * split the output into 4 different categories. Enabled triggers,
+ * disabled triggers and the two special ALWAYS and REPLICA
+ * configurations.
+ */
+ for (category = 0; category < 4; category++)
{
- bool have_heading;
- int category;
-
- /*
- * split the output into 4 different categories. Enabled
- * triggers, disabled triggers and the two special ALWAYS and
- * REPLICA configurations.
- */
- for (category = 0; category < 4; category++)
+ have_heading = false;
+ for (i = 0; i < tuples; i++)
{
- have_heading = false;
- for (i = 0; i < tuples; i++)
+ bool list_trigger;
+ const char *tgdef;
+ const char *usingpos;
+ const char *tgenabled;
+
+ /*
+ * Check if this trigger falls into the current category
+ */
+ tgenabled = PQgetvalue(result, i, 2);
+ list_trigger = false;
+ switch (category)
+ {
+ case 0:
+ if (*tgenabled == 'O' || *tgenabled == 't')
+ list_trigger = true;
+ break;
+ case 1:
+ if (*tgenabled == 'D' || *tgenabled == 'f')
+ list_trigger = true;
+ break;
+ case 2:
+ if (*tgenabled == 'A')
+ list_trigger = true;
+ break;
+ case 3:
+ if (*tgenabled == 'R')
+ list_trigger = true;
+ break;
+ }
+ if (list_trigger == false)
+ continue;
+
+ /* Print the category heading once */
+ if (have_heading == false)
{
- bool list_trigger;
- const char *tgdef;
- const char *usingpos;
- const char *tgenabled;
-
- /*
- * Check if this trigger falls into the current
- * category
- */
- tgenabled = PQgetvalue(result, i, 2);
- list_trigger = false;
switch (category)
{
case 0:
- if (*tgenabled == 'O' || *tgenabled == 't')
- list_trigger = true;
+ printfPQExpBuffer(&buf, _("Triggers:"));
break;
case 1:
- if (*tgenabled == 'D' || *tgenabled == 'f')
- list_trigger = true;
+ printfPQExpBuffer(&buf, _("Disabled triggers:"));
break;
case 2:
- if (*tgenabled == 'A')
- list_trigger = true;
+ printfPQExpBuffer(&buf, _("Triggers firing always:"));
break;
case 3:
- if (*tgenabled == 'R')
- list_trigger = true;
+ printfPQExpBuffer(&buf, _("Triggers firing on replica only:"));
break;
- }
- if (list_trigger == false)
- continue;
-
- /* Print the category heading once */
- if (have_heading == false)
- {
- switch (category)
- {
- case 0:
- printfPQExpBuffer(&buf, _("Triggers:"));
- break;
- case 1:
- printfPQExpBuffer(&buf, _("Disabled triggers:"));
- break;
- case 2:
- printfPQExpBuffer(&buf, _("Triggers firing always:"));
- break;
- case 3:
- printfPQExpBuffer(&buf, _("Triggers firing on replica only:"));
- break;
- }
- printTableAddFooter(&cont, buf.data);
- have_heading = true;
}
-
- /* Everything after "TRIGGER" is echoed verbatim */
- tgdef = PQgetvalue(result, i, 1);
- usingpos = strstr(tgdef, " TRIGGER ");
- if (usingpos)
- tgdef = usingpos + 9;
-
- printfPQExpBuffer(&buf, " %s", tgdef);
printTableAddFooter(&cont, buf.data);
+ have_heading = true;
}
+
+ /* Everything after "TRIGGER" is echoed verbatim */
+ tgdef = PQgetvalue(result, i, 1);
+ usingpos = strstr(tgdef, " TRIGGER ");
+ if (usingpos)
+ tgdef = usingpos + 9;
+
+ printfPQExpBuffer(&buf, " %s", tgdef);
+ printTableAddFooter(&cont, buf.data);
}
}
- PQclear(result);
+ }
+ PQclear(result);
}
/*
@@ -2052,7 +2051,7 @@ describeOneTableDetails(const char *schemaname,
}
printfPQExpBuffer(&buf, "Server: %s",
- PQgetvalue(result, 0, 0));
+ PQgetvalue(result, 0, 0));
printTableAddFooter(&cont, buf.data);
PQclear(result);
}
@@ -2293,7 +2292,7 @@ describeRoles(const char *pattern, bool verbose)
}
if (pset.sversion >= 90100)
{
- appendPQExpBufferStr(&buf,"\n, r.rolreplication");
+ appendPQExpBufferStr(&buf, "\n, r.rolreplication");
}
appendPQExpBufferStr(&buf, "\nFROM pg_catalog.pg_roles r\n");
@@ -2525,8 +2524,8 @@ listTables(const char *tabtypes, const char *pattern, bool verbose, bool showSys
if (verbose)
{
/*
- * As of PostgreSQL 9.0, use pg_table_size() to show a more acurate size
- * of a table, including FSM, VM and TOAST tables.
+ * As of PostgreSQL 9.0, use pg_table_size() to show a more acurate
+ * size of a table, including FSM, VM and TOAST tables.
*/
if (pset.sversion >= 90000)
appendPQExpBuffer(&buf,
@@ -2622,7 +2621,7 @@ bool
listLanguages(const char *pattern, bool verbose, bool showSystem)
{
PQExpBufferData buf;
- PGresult *res;
+ PGresult *res;
printQueryOpt myopt = pset.popt;
initPQExpBuffer(&buf);
@@ -2631,9 +2630,9 @@ listLanguages(const char *pattern, bool verbose, bool showSystem)
"SELECT l.lanname AS \"%s\",\n",
gettext_noop("Name"));
if (pset.sversion >= 80300)
- appendPQExpBuffer(&buf,
- " pg_catalog.pg_get_userbyid(l.lanowner) as \"%s\",\n",
- gettext_noop("Owner"));
+ appendPQExpBuffer(&buf,
+ " pg_catalog.pg_get_userbyid(l.lanowner) as \"%s\",\n",
+ gettext_noop("Owner"));
appendPQExpBuffer(&buf,
" l.lanpltrusted AS \"%s\"",
@@ -2641,17 +2640,17 @@ listLanguages(const char *pattern, bool verbose, bool showSystem)
if (verbose)
{
- appendPQExpBuffer(&buf,
- ",\n NOT l.lanispl AS \"%s\",\n"
- " l.lanplcallfoid::regprocedure AS \"%s\",\n"
- " l.lanvalidator::regprocedure AS \"%s\",\n ",
- gettext_noop("Internal Language"),
- gettext_noop("Call Handler"),
- gettext_noop("Validator"));
- if (pset.sversion >= 90000)
- appendPQExpBuffer(&buf, "l.laninline::regprocedure AS \"%s\",\n ",
- gettext_noop("Inline Handler"));
- printACLColumn(&buf, "l.lanacl");
+ appendPQExpBuffer(&buf,
+ ",\n NOT l.lanispl AS \"%s\",\n"
+ " l.lanplcallfoid::regprocedure AS \"%s\",\n"
+ " l.lanvalidator::regprocedure AS \"%s\",\n ",
+ gettext_noop("Internal Language"),
+ gettext_noop("Call Handler"),
+ gettext_noop("Validator"));
+ if (pset.sversion >= 90000)
+ appendPQExpBuffer(&buf, "l.laninline::regprocedure AS \"%s\",\n ",
+ gettext_noop("Inline Handler"));
+ printACLColumn(&buf, "l.lanacl");
}
appendPQExpBuffer(&buf,
@@ -2907,11 +2906,11 @@ listCollations(const char *pattern, bool verbose, bool showSystem)
if (verbose)
appendPQExpBuffer(&buf,
- ",\n pg_catalog.obj_description(c.oid, 'pg_collation') AS \"%s\"",
+ ",\n pg_catalog.obj_description(c.oid, 'pg_collation') AS \"%s\"",
gettext_noop("Description"));
appendPQExpBuffer(&buf,
- "\nFROM pg_catalog.pg_collation c, pg_catalog.pg_namespace n\n"
+ "\nFROM pg_catalog.pg_collation c, pg_catalog.pg_namespace n\n"
"WHERE n.oid = c.collnamespace\n");
if (!showSystem && !pattern)
@@ -2981,7 +2980,7 @@ listSchemas(const char *pattern, bool verbose, bool showSystem)
if (!showSystem && !pattern)
appendPQExpBuffer(&buf,
- "WHERE n.nspname !~ '^pg_' AND n.nspname <> 'information_schema'\n");
+ "WHERE n.nspname !~ '^pg_' AND n.nspname <> 'information_schema'\n");
processSQLNamePattern(pset.db, &buf, pattern,
!showSystem && !pattern, false,
@@ -3838,11 +3837,11 @@ listExtensions(const char *pattern)
initPQExpBuffer(&buf);
printfPQExpBuffer(&buf,
"SELECT e.extname AS \"%s\", "
- "e.extversion AS \"%s\", n.nspname AS \"%s\", c.description AS \"%s\"\n"
+ "e.extversion AS \"%s\", n.nspname AS \"%s\", c.description AS \"%s\"\n"
"FROM pg_catalog.pg_extension e "
- "LEFT JOIN pg_catalog.pg_namespace n ON n.oid = e.extnamespace "
- "LEFT JOIN pg_catalog.pg_description c ON c.objoid = e.oid "
- "AND c.classoid = 'pg_catalog.pg_extension'::pg_catalog.regclass\n",
+ "LEFT JOIN pg_catalog.pg_namespace n ON n.oid = e.extnamespace "
+ "LEFT JOIN pg_catalog.pg_description c ON c.objoid = e.oid "
+ "AND c.classoid = 'pg_catalog.pg_extension'::pg_catalog.regclass\n",
gettext_noop("Name"),
gettext_noop("Version"),
gettext_noop("Schema"),
@@ -3954,7 +3953,7 @@ listOneExtensionContents(const char *extname, const char *oid)
initPQExpBuffer(&buf);
printfPQExpBuffer(&buf,
- "SELECT pg_catalog.pg_describe_object(classid, objid, 0) AS \"%s\"\n"
+ "SELECT pg_catalog.pg_describe_object(classid, objid, 0) AS \"%s\"\n"
"FROM pg_catalog.pg_depend\n"
"WHERE refclassid = 'pg_catalog.pg_extension'::pg_catalog.regclass AND refobjid = '%s' AND deptype = 'e'\n"
"ORDER BY 1;",
diff --git a/src/bin/psql/tab-complete.c b/src/bin/psql/tab-complete.c
index 994c05373f..3ef2fa421d 100644
--- a/src/bin/psql/tab-complete.c
+++ b/src/bin/psql/tab-complete.c
@@ -629,7 +629,7 @@ static const pgsql_thing_t words_after_create[] = {
{"INDEX", NULL, &Query_for_list_of_indexes},
{"OPERATOR", NULL, NULL}, /* Querying for this is probably not such a
* good idea. */
- {"OWNED", NULL, NULL, THING_NO_CREATE}, /* for DROP OWNED BY ... */
+ {"OWNED", NULL, NULL, THING_NO_CREATE}, /* for DROP OWNED BY ... */
{"PARSER", Query_for_list_of_ts_parsers, NULL, THING_NO_SHOW},
{"ROLE", Query_for_list_of_roles},
{"RULE", "SELECT pg_catalog.quote_ident(rulename) FROM pg_catalog.pg_rules WHERE substring(pg_catalog.quote_ident(rulename),1,%d)='%s'"},
@@ -638,17 +638,18 @@ static const pgsql_thing_t words_after_create[] = {
{"SERVER", Query_for_list_of_servers},
{"TABLE", NULL, &Query_for_list_of_tables},
{"TABLESPACE", Query_for_list_of_tablespaces},
- {"TEMP", NULL, NULL, THING_NO_DROP}, /* for CREATE TEMP TABLE ... */
+ {"TEMP", NULL, NULL, THING_NO_DROP}, /* for CREATE TEMP TABLE ... */
{"TEMPLATE", Query_for_list_of_ts_templates, NULL, THING_NO_SHOW},
{"TEXT SEARCH", NULL, NULL},
{"TRIGGER", "SELECT pg_catalog.quote_ident(tgname) FROM pg_catalog.pg_trigger WHERE substring(pg_catalog.quote_ident(tgname),1,%d)='%s'"},
{"TYPE", NULL, &Query_for_list_of_datatypes},
- {"UNIQUE", NULL, NULL, THING_NO_DROP}, /* for CREATE UNIQUE INDEX ... */
- {"UNLOGGED", NULL, NULL, THING_NO_DROP},/* for CREATE UNLOGGED TABLE ... */
+ {"UNIQUE", NULL, NULL, THING_NO_DROP}, /* for CREATE UNIQUE INDEX ... */
+ {"UNLOGGED", NULL, NULL, THING_NO_DROP}, /* for CREATE UNLOGGED TABLE
+ * ... */
{"USER", Query_for_list_of_roles},
{"USER MAPPING FOR", NULL, NULL},
{"VIEW", NULL, &Query_for_list_of_views},
- {NULL} /* end of list */
+ {NULL} /* end of list */
};
@@ -663,7 +664,7 @@ static char *_complete_from_query(int is_schema_query,
static char *complete_from_list(const char *text, int state);
static char *complete_from_const(const char *text, int state);
static char **complete_from_variables(char *text,
- const char *prefix, const char *suffix);
+ const char *prefix, const char *suffix);
static PGresult *exec_query(const char *query);
@@ -806,11 +807,11 @@ psql_completion(char *text, int start, int end)
{
static const char *const list_ALTER[] =
{"AGGREGATE", "COLLATION", "CONVERSION", "DATABASE", "DEFAULT PRIVILEGES", "DOMAIN",
- "EXTENSION", "FOREIGN DATA WRAPPER", "FOREIGN TABLE", "FUNCTION",
- "GROUP", "INDEX", "LANGUAGE", "LARGE OBJECT", "OPERATOR",
- "ROLE", "SCHEMA", "SERVER", "SEQUENCE", "TABLE",
- "TABLESPACE", "TEXT SEARCH", "TRIGGER", "TYPE",
- "USER", "USER MAPPING FOR", "VIEW", NULL};
+ "EXTENSION", "FOREIGN DATA WRAPPER", "FOREIGN TABLE", "FUNCTION",
+ "GROUP", "INDEX", "LANGUAGE", "LARGE OBJECT", "OPERATOR",
+ "ROLE", "SCHEMA", "SERVER", "SEQUENCE", "TABLE",
+ "TABLESPACE", "TEXT SEARCH", "TRIGGER", "TYPE",
+ "USER", "USER MAPPING FOR", "VIEW", NULL};
COMPLETE_WITH_LIST(list_ALTER);
}
@@ -1137,7 +1138,7 @@ psql_completion(char *text, int start, int end)
{
static const char *const list_ALTER2[] =
{"ADD", "ALTER", "CLUSTER ON", "DISABLE", "DROP", "ENABLE", "INHERIT",
- "NO INHERIT", "RENAME", "RESET", "OWNER TO", "SET",
+ "NO INHERIT", "RENAME", "RESET", "OWNER TO", "SET",
"VALIDATE CONSTRAINT", NULL};
COMPLETE_WITH_LIST(list_ALTER2);
@@ -1423,7 +1424,7 @@ psql_completion(char *text, int start, int end)
{
static const char *const list_ALTERTYPE[] =
{"ADD ATTRIBUTE", "ADD VALUE", "ALTER ATTRIBUTE", "DROP ATTRIBUTE",
- "OWNER TO", "RENAME", "SET SCHEMA", NULL};
+ "OWNER TO", "RENAME", "SET SCHEMA", NULL};
COMPLETE_WITH_LIST(list_ALTERTYPE);
}
@@ -1437,7 +1438,7 @@ psql_completion(char *text, int start, int end)
COMPLETE_WITH_LIST(list_ALTERTYPE);
}
- /* ALTER TYPE RENAME */
+ /* ALTER TYPE RENAME */
else if (pg_strcasecmp(prev4_wd, "ALTER") == 0 &&
pg_strcasecmp(prev3_wd, "TYPE") == 0 &&
pg_strcasecmp(prev_wd, "RENAME") == 0)
@@ -1453,7 +1454,10 @@ psql_completion(char *text, int start, int end)
pg_strcasecmp(prev2_wd, "ATTRIBUTE") == 0)
COMPLETE_WITH_CONST("TO");
- /* If we have TYPE ALTER/DROP/RENAME ATTRIBUTE, provide list of attributes */
+ /*
+ * If we have TYPE ALTER/DROP/RENAME ATTRIBUTE, provide list of
+ * attributes
+ */
else if (pg_strcasecmp(prev4_wd, "TYPE") == 0 &&
(pg_strcasecmp(prev2_wd, "ALTER") == 0 ||
pg_strcasecmp(prev2_wd, "DROP") == 0 ||
@@ -2193,7 +2197,7 @@ psql_completion(char *text, int start, int end)
else if (pg_strcasecmp(prev3_wd, "CREATE") != 0 &&
pg_strcasecmp(prev2_wd, "FOREIGN") == 0 &&
pg_strcasecmp(prev_wd, "TABLE") == 0)
- COMPLETE_WITH_SCHEMA_QUERY(Query_for_list_of_foreign_tables, NULL);
+ COMPLETE_WITH_SCHEMA_QUERY(Query_for_list_of_foreign_tables, NULL);
/* GRANT && REVOKE */
/* Complete GRANT/REVOKE with a list of privileges */
@@ -2454,7 +2458,8 @@ psql_completion(char *text, int start, int end)
pg_strcasecmp(prev_wd, "LABEL") == 0)
{
static const char *const list_SECURITY_LABEL_preposition[] =
- {"ON", "FOR"};
+ {"ON", "FOR"};
+
COMPLETE_WITH_LIST(list_SECURITY_LABEL_preposition);
}
else if (pg_strcasecmp(prev4_wd, "SECURITY") == 0 &&
@@ -2464,14 +2469,14 @@ psql_completion(char *text, int start, int end)
else if ((pg_strcasecmp(prev3_wd, "SECURITY") == 0 &&
pg_strcasecmp(prev2_wd, "LABEL") == 0 &&
pg_strcasecmp(prev_wd, "ON") == 0) ||
- (pg_strcasecmp(prev5_wd, "SECURITY") == 0 &&
+ (pg_strcasecmp(prev5_wd, "SECURITY") == 0 &&
pg_strcasecmp(prev4_wd, "LABEL") == 0 &&
pg_strcasecmp(prev3_wd, "FOR") == 0 &&
pg_strcasecmp(prev_wd, "ON") == 0))
{
static const char *const list_SECURITY_LABEL[] =
{"LANGUAGE", "SCHEMA", "SEQUENCE", "TABLE", "TYPE", "VIEW", "COLUMN",
- "AGGREGATE", "FUNCTION", "DOMAIN", "LARGE OBJECT",
+ "AGGREGATE", "FUNCTION", "DOMAIN", "LARGE OBJECT",
NULL};
COMPLETE_WITH_LIST(list_SECURITY_LABEL);
@@ -2847,15 +2852,15 @@ psql_completion(char *text, int start, int end)
if (strcmp(prev_wd, "format") == 0)
{
static const char *const my_list[] =
- {"unaligned", "aligned", "wrapped", "html", "latex",
- "troff-ms", NULL};
+ {"unaligned", "aligned", "wrapped", "html", "latex",
+ "troff-ms", NULL};
COMPLETE_WITH_LIST(my_list);
}
else if (strcmp(prev_wd, "linestyle") == 0)
{
static const char *const my_list[] =
- {"ascii", "old-ascii", "unicode", NULL};
+ {"ascii", "old-ascii", "unicode", NULL};
COMPLETE_WITH_LIST(my_list);
}
@@ -3305,13 +3310,13 @@ complete_from_variables(char *text, const char *prefix, const char *suffix)
for (ptr = pset.vars->next; ptr; ptr = ptr->next)
{
- char *buffer;
+ char *buffer;
if (nvars >= maxvars)
{
maxvars *= 2;
varnames = (const char **) realloc(varnames,
- (maxvars + 1) * sizeof(char *));
+ (maxvars + 1) * sizeof(char *));
if (!varnames)
{
psql_error("out of memory\n");
diff --git a/src/bin/scripts/droplang.c b/src/bin/scripts/droplang.c
index 83c1b531c7..7fadee0d51 100644
--- a/src/bin/scripts/droplang.c
+++ b/src/bin/scripts/droplang.c
@@ -195,8 +195,8 @@ main(int argc, char *argv[])
PQclear(result);
/*
- * Attempt to drop the language. We do not use CASCADE, so that
- * the drop will fail if there are any functions in the language.
+ * Attempt to drop the language. We do not use CASCADE, so that the drop
+ * will fail if there are any functions in the language.
*/
printfPQExpBuffer(&sql, "DROP EXTENSION \"%s\";\n", langname);
diff --git a/src/include/access/gin.h b/src/include/access/gin.h
index cf9603c7c4..31e9733546 100644
--- a/src/include/access/gin.h
+++ b/src/include/access/gin.h
@@ -39,9 +39,9 @@
typedef struct GinStatsData
{
BlockNumber nPendingPages;
- BlockNumber nTotalPages;
- BlockNumber nEntryPages;
- BlockNumber nDataPages;
+ BlockNumber nTotalPages;
+ BlockNumber nEntryPages;
+ BlockNumber nDataPages;
int64 nEntries;
int32 ginVersion;
} GinStatsData;
diff --git a/src/include/access/gin_private.h b/src/include/access/gin_private.h
index 6381bffb21..74c1098458 100644
--- a/src/include/access/gin_private.h
+++ b/src/include/access/gin_private.h
@@ -73,14 +73,14 @@ typedef struct GinMetaPageData
/*
* Statistics for planner use (accurate as of last VACUUM)
*/
- BlockNumber nTotalPages;
- BlockNumber nEntryPages;
- BlockNumber nDataPages;
+ BlockNumber nTotalPages;
+ BlockNumber nEntryPages;
+ BlockNumber nDataPages;
int64 nEntries;
/*
- * GIN version number (ideally this should have been at the front, but
- * too late now. Don't move it!)
+ * GIN version number (ideally this should have been at the front, but too
+ * late now. Don't move it!)
*
* Currently 1 (for indexes initialized in 9.1 or later)
*
@@ -207,7 +207,7 @@ typedef signed char GinNullCategory;
#define GinGetPostingTree(itup) GinItemPointerGetBlockNumber(&(itup)->t_tid)
#define GinGetPostingOffset(itup) GinItemPointerGetBlockNumber(&(itup)->t_tid)
-#define GinSetPostingOffset(itup,n) ItemPointerSetBlockNumber(&(itup)->t_tid,n)
+#define GinSetPostingOffset(itup,n) ItemPointerSetBlockNumber(&(itup)->t_tid,n)
#define GinGetPosting(itup) ((ItemPointer) ((char*)(itup) + GinGetPostingOffset(itup)))
#define GinMaxItemSize \
@@ -427,12 +427,12 @@ extern Buffer GinNewBuffer(Relation index);
extern void GinInitBuffer(Buffer b, uint32 f);
extern void GinInitPage(Page page, uint32 f, Size pageSize);
extern void GinInitMetabuffer(Buffer b);
-extern int ginCompareEntries(GinState *ginstate, OffsetNumber attnum,
- Datum a, GinNullCategory categorya,
- Datum b, GinNullCategory categoryb);
-extern int ginCompareAttEntries(GinState *ginstate,
+extern int ginCompareEntries(GinState *ginstate, OffsetNumber attnum,
+ Datum a, GinNullCategory categorya,
+ Datum b, GinNullCategory categoryb);
+extern int ginCompareAttEntries(GinState *ginstate,
OffsetNumber attnuma, Datum a, GinNullCategory categorya,
- OffsetNumber attnumb, Datum b, GinNullCategory categoryb);
+ OffsetNumber attnumb, Datum b, GinNullCategory categoryb);
extern Datum *ginExtractEntries(GinState *ginstate, OffsetNumber attnum,
Datum value, bool isNull,
int32 *nentries, GinNullCategory **categories);
@@ -508,7 +508,7 @@ extern GinBtreeStack *ginPrepareFindLeafPage(GinBtree btree, BlockNumber blkno);
extern GinBtreeStack *ginFindLeafPage(GinBtree btree, GinBtreeStack *stack);
extern void freeGinBtreeStack(GinBtreeStack *stack);
extern void ginInsertValue(GinBtree btree, GinBtreeStack *stack,
- GinStatsData *buildStats);
+ GinStatsData *buildStats);
extern void ginFindParents(GinBtree btree, GinBtreeStack *stack, BlockNumber rootBlkno);
/* ginentrypage.c */
@@ -525,8 +525,8 @@ extern IndexTuple ginPageGetLinkItup(Buffer buf);
/* gindatapage.c */
extern int ginCompareItemPointers(ItemPointer a, ItemPointer b);
extern uint32 ginMergeItemPointers(ItemPointerData *dst,
- ItemPointerData *a, uint32 na,
- ItemPointerData *b, uint32 nb);
+ ItemPointerData *a, uint32 na,
+ ItemPointerData *b, uint32 nb);
extern void GinDataPageAddItem(Page page, void *data, OffsetNumber offset);
extern void GinPageDeletePostingItem(Page page, OffsetNumber offset);
@@ -538,10 +538,10 @@ typedef struct
} GinPostingTreeScan;
extern GinPostingTreeScan *ginPrepareScanPostingTree(Relation index,
- BlockNumber rootBlkno, bool searchMode);
+ BlockNumber rootBlkno, bool searchMode);
extern void ginInsertItemPointers(GinPostingTreeScan *gdi,
- ItemPointerData *items, uint32 nitem,
- GinStatsData *buildStats);
+ ItemPointerData *items, uint32 nitem,
+ GinStatsData *buildStats);
extern Buffer ginScanBeginPostingTree(GinPostingTreeScan *gdi);
extern void ginDataFillRoot(GinBtree btree, Buffer root, Buffer lbuf, Buffer rbuf);
extern void ginPrepareDataScan(GinBtree btree, Relation index);
@@ -561,7 +561,7 @@ extern void ginPrepareDataScan(GinBtree btree, Relation index);
*
* In each GinScanKeyData, nentries is the true number of entries, while
* nuserentries is the number that extractQueryFn returned (which is what
- * we report to consistentFn). The "user" entries must come first.
+ * we report to consistentFn). The "user" entries must come first.
*/
typedef struct GinScanKeyData *GinScanKey;
@@ -591,17 +591,17 @@ typedef struct GinScanKeyData
OffsetNumber attnum;
/*
- * Match status data. curItem is the TID most recently tested (could be
- * a lossy-page pointer). curItemMatches is TRUE if it passes the
+ * Match status data. curItem is the TID most recently tested (could be a
+ * lossy-page pointer). curItemMatches is TRUE if it passes the
* consistentFn test; if so, recheckCurItem is the recheck flag.
- * isFinished means that all the input entry streams are finished, so
- * this key cannot succeed for any later TIDs.
+ * isFinished means that all the input entry streams are finished, so this
+ * key cannot succeed for any later TIDs.
*/
ItemPointerData curItem;
bool curItemMatches;
bool recheckCurItem;
bool isFinished;
-} GinScanKeyData;
+} GinScanKeyData;
typedef struct GinScanEntryData
{
@@ -633,7 +633,7 @@ typedef struct GinScanEntryData
bool isFinished;
bool reduceResult;
uint32 predictNumberResult;
-} GinScanEntryData;
+} GinScanEntryData;
typedef struct GinScanOpaqueData
{
diff --git a/src/include/access/gist.h b/src/include/access/gist.h
index 230e138f08..df9f39c7b8 100644
--- a/src/include/access/gist.h
+++ b/src/include/access/gist.h
@@ -53,7 +53,7 @@
#define RTOverAboveStrategyNumber 12
#define RTOldContainsStrategyNumber 13 /* for old spelling of @> */
#define RTOldContainedByStrategyNumber 14 /* for old spelling of <@ */
-#define RTKNNSearchStrategyNumber 15
+#define RTKNNSearchStrategyNumber 15
/*
* Page opaque data in a GiST index page.
diff --git a/src/include/access/gist_private.h b/src/include/access/gist_private.h
index 70638705c2..ecc188f7df 100644
--- a/src/include/access/gist_private.h
+++ b/src/include/access/gist_private.h
@@ -79,13 +79,13 @@ typedef struct GISTSearchItem
BlockNumber blkno; /* index page number, or InvalidBlockNumber */
union
{
- GistNSN parentlsn; /* parent page's LSN, if index page */
+ GistNSN parentlsn; /* parent page's LSN, if index page */
/* we must store parentlsn to detect whether a split occurred */
GISTSearchHeapItem heap; /* heap info, if heap tuple */
} data;
-} GISTSearchItem;
+} GISTSearchItem;
-#define GISTSearchItemIsHeap(item) ((item).blkno == InvalidBlockNumber)
+#define GISTSearchItemIsHeap(item) ((item).blkno == InvalidBlockNumber)
/*
* Within a GISTSearchTreeItem's chain, heap items always appear before
@@ -132,9 +132,9 @@ typedef GISTScanOpaqueData *GISTScanOpaque;
/* XLog stuff */
#define XLOG_GIST_PAGE_UPDATE 0x00
-/* #define XLOG_GIST_NEW_ROOT 0x20 */ /* not used anymore */
+ /* #define XLOG_GIST_NEW_ROOT 0x20 */ /* not used anymore */
#define XLOG_GIST_PAGE_SPLIT 0x30
-/* #define XLOG_GIST_INSERT_COMPLETE 0x40 */ /* not used anymore */
+ /* #define XLOG_GIST_INSERT_COMPLETE 0x40 */ /* not used anymore */
#define XLOG_GIST_CREATE_INDEX 0x50
#define XLOG_GIST_PAGE_DELETE 0x60
@@ -147,7 +147,7 @@ typedef struct gistxlogPageUpdate
* If this operation completes a page split, by inserting a downlink for
* the split page, leftchild points to the left half of the split.
*/
- BlockNumber leftchild;
+ BlockNumber leftchild;
/* number of deleted offsets */
uint16 ntodelete;
@@ -161,7 +161,7 @@ typedef struct gistxlogPageSplit
{
RelFileNode node;
BlockNumber origblkno; /* splitted page */
- BlockNumber origrlink; /* rightlink of the page before split */
+ BlockNumber origrlink; /* rightlink of the page before split */
GistNSN orignsn; /* NSN of the page before split */
bool origleaf; /* was splitted page a leaf page? */
@@ -210,8 +210,8 @@ typedef struct GISTInsertStack
Page page;
/*
- * log sequence number from page->lsn to recognize page update and
- * compare it with page's nsn to recognize page split
+ * log sequence number from page->lsn to recognize page update and compare
+ * it with page's nsn to recognize page split
*/
GistNSN lsn;
@@ -300,7 +300,7 @@ extern void gist_xlog_cleanup(void);
extern XLogRecPtr gistXLogUpdate(RelFileNode node, Buffer buffer,
OffsetNumber *todelete, int ntodelete,
- IndexTuple *itup, int ntup,
+ IndexTuple *itup, int ntup,
Buffer leftchild);
extern XLogRecPtr gistXLogSplit(RelFileNode node,
diff --git a/src/include/access/hio.h b/src/include/access/hio.h
index 6951dfb010..6b661a3e87 100644
--- a/src/include/access/hio.h
+++ b/src/include/access/hio.h
@@ -31,13 +31,13 @@ typedef struct BulkInsertStateData
{
BufferAccessStrategy strategy; /* our BULKWRITE strategy object */
Buffer current_buf; /* current insertion target page */
-} BulkInsertStateData;
+} BulkInsertStateData;
extern void RelationPutHeapTuple(Relation relation, Buffer buffer,
HeapTuple tuple);
extern Buffer RelationGetBufferForTuple(Relation relation, Size len,
Buffer otherBuffer, int options,
- struct BulkInsertStateData *bistate);
+ struct BulkInsertStateData * bistate);
#endif /* HIO_H */
diff --git a/src/include/access/htup.h b/src/include/access/htup.h
index 0e626e8469..c147707169 100644
--- a/src/include/access/htup.h
+++ b/src/include/access/htup.h
@@ -201,7 +201,7 @@ typedef HeapTupleHeaderData *HeapTupleHeader;
* any visibility information, so we can overlay it on a visibility flag
* instead of using up a dedicated bit.
*/
-#define HEAP_TUPLE_HAS_MATCH HEAP_ONLY_TUPLE /* tuple has a join match */
+#define HEAP_TUPLE_HAS_MATCH HEAP_ONLY_TUPLE /* tuple has a join match */
/*
* HeapTupleHeader accessor macros
diff --git a/src/include/access/itup.h b/src/include/access/itup.h
index cab7193964..29247068fd 100644
--- a/src/include/access/itup.h
+++ b/src/include/access/itup.h
@@ -55,7 +55,7 @@ typedef IndexTupleData *IndexTuple;
typedef struct IndexAttributeBitMapData
{
bits8 bits[(INDEX_MAX_KEYS + 8 - 1) / 8];
-} IndexAttributeBitMapData;
+} IndexAttributeBitMapData;
typedef IndexAttributeBitMapData *IndexAttributeBitMap;
diff --git a/src/include/access/relscan.h b/src/include/access/relscan.h
index f703280b27..7663033723 100644
--- a/src/include/access/relscan.h
+++ b/src/include/access/relscan.h
@@ -50,7 +50,7 @@ typedef struct HeapScanDescData
int rs_mindex; /* marked tuple's saved index */
int rs_ntuples; /* number of visible tuples on page */
OffsetNumber rs_vistuples[MaxHeapTuplesPerPage]; /* their offsets */
-} HeapScanDescData;
+} HeapScanDescData;
/*
* We use the same IndexScanDescData structure for both amgettuple-based
@@ -64,9 +64,9 @@ typedef struct IndexScanDescData
Relation indexRelation; /* index relation descriptor */
Snapshot xs_snapshot; /* snapshot to see */
int numberOfKeys; /* number of index qualifier conditions */
- int numberOfOrderBys; /* number of ordering operators */
- ScanKey keyData; /* array of index qualifier descriptors */
- ScanKey orderByData; /* array of ordering op descriptors */
+ int numberOfOrderBys; /* number of ordering operators */
+ ScanKey keyData; /* array of index qualifier descriptors */
+ ScanKey orderByData; /* array of ordering op descriptors */
/* signaling to index AM about killing index tuples */
bool kill_prior_tuple; /* last-returned tuple is dead */
@@ -87,7 +87,7 @@ typedef struct IndexScanDescData
bool xs_hot_dead; /* T if all members of HOT chain are dead */
OffsetNumber xs_next_hot; /* next member of HOT chain, if any */
TransactionId xs_prev_xmax; /* previous HOT chain member's XMAX, if any */
-} IndexScanDescData;
+} IndexScanDescData;
/* Struct for heap-or-index scans of system tables */
typedef struct SysScanDescData
@@ -96,6 +96,6 @@ typedef struct SysScanDescData
Relation irel; /* NULL if doing heap scan */
HeapScanDesc scan; /* only valid in heap-scan case */
IndexScanDesc iscan; /* only valid in index-scan case */
-} SysScanDescData;
+} SysScanDescData;
#endif /* RELSCAN_H */
diff --git a/src/include/access/tupdesc.h b/src/include/access/tupdesc.h
index fb8ee0ad4f..99448efe12 100644
--- a/src/include/access/tupdesc.h
+++ b/src/include/access/tupdesc.h
@@ -115,8 +115,8 @@ extern void TupleDescInitEntry(TupleDesc desc,
int attdim);
extern void TupleDescInitEntryCollation(TupleDesc desc,
- AttrNumber attributeNumber,
- Oid collationid);
+ AttrNumber attributeNumber,
+ Oid collationid);
extern TupleDesc BuildDescForRelation(List *schema);
diff --git a/src/include/access/xact.h b/src/include/access/xact.h
index 8b60e8f163..cb440d41f1 100644
--- a/src/include/access/xact.h
+++ b/src/include/access/xact.h
@@ -54,13 +54,13 @@ extern bool XactDeferrable;
typedef enum
{
- SYNCHRONOUS_COMMIT_OFF, /* asynchronous commit */
- SYNCHRONOUS_COMMIT_LOCAL_FLUSH, /* wait for local flush only */
- SYNCHRONOUS_COMMIT_REMOTE_FLUSH /* wait for local and remote flush */
-} SyncCommitLevel;
+ SYNCHRONOUS_COMMIT_OFF, /* asynchronous commit */
+ SYNCHRONOUS_COMMIT_LOCAL_FLUSH, /* wait for local flush only */
+ SYNCHRONOUS_COMMIT_REMOTE_FLUSH /* wait for local and remote flush */
+} SyncCommitLevel;
/* Define the default setting for synchonous_commit */
-#define SYNCHRONOUS_COMMIT_ON SYNCHRONOUS_COMMIT_REMOTE_FLUSH
+#define SYNCHRONOUS_COMMIT_ON SYNCHRONOUS_COMMIT_REMOTE_FLUSH
/* Synchronous commit level */
extern int synchronous_commit;
diff --git a/src/include/access/xlog.h b/src/include/access/xlog.h
index 7e9bad6e3a..7056fd6189 100644
--- a/src/include/access/xlog.h
+++ b/src/include/access/xlog.h
@@ -259,12 +259,12 @@ typedef struct CheckpointStatsData
int ckpt_segs_removed; /* # of xlog segments deleted */
int ckpt_segs_recycled; /* # of xlog segments recycled */
- int ckpt_sync_rels; /* # of relations synced */
- uint64 ckpt_longest_sync; /* Longest sync for one relation */
- uint64 ckpt_agg_sync_time; /* The sum of all the individual sync
- * times, which is not necessarily the
- * same as the total elapsed time for
- * the entire sync phase. */
+ int ckpt_sync_rels; /* # of relations synced */
+ uint64 ckpt_longest_sync; /* Longest sync for one relation */
+ uint64 ckpt_agg_sync_time; /* The sum of all the individual sync
+ * times, which is not necessarily the
+ * same as the total elapsed time for
+ * the entire sync phase. */
} CheckpointStatsData;
extern CheckpointStatsData CheckpointStats;
diff --git a/src/include/access/xlogdefs.h b/src/include/access/xlogdefs.h
index 2982a4799c..6530df06ac 100644
--- a/src/include/access/xlogdefs.h
+++ b/src/include/access/xlogdefs.h
@@ -88,7 +88,7 @@ typedef uint32 TimeLineID;
* read those buffers except during crash recovery or if wal_level != minimal,
* it is a win to use it in all cases where we sync on each write(). We could
* allow O_DIRECT with fsync(), but it is unclear if fsync() could process
- * writes not buffered in the kernel. Also, O_DIRECT is never enough to force
+ * writes not buffered in the kernel. Also, O_DIRECT is never enough to force
* data to the drives, it merely tries to bypass the kernel cache, so we still
* need O_SYNC/O_DSYNC.
*/
diff --git a/src/include/catalog/catalog.h b/src/include/catalog/catalog.h
index bb3aa781f2..e4f1535db3 100644
--- a/src/include/catalog/catalog.h
+++ b/src/include/catalog/catalog.h
@@ -25,10 +25,10 @@
extern const char *forkNames[];
extern ForkNumber forkname_to_number(char *forkName);
-extern int forkname_chars(const char *str, ForkNumber *);
+extern int forkname_chars(const char *str, ForkNumber *);
extern char *relpathbackend(RelFileNode rnode, BackendId backend,
- ForkNumber forknum);
+ ForkNumber forknum);
extern char *GetDatabasePath(Oid dbNode, Oid spcNode);
/* First argument is a RelFileNodeBackend */
@@ -55,7 +55,7 @@ extern bool IsSharedRelation(Oid relationId);
extern Oid GetNewOid(Relation relation);
extern Oid GetNewOidWithIndex(Relation relation, Oid indexId,
AttrNumber oidcolumn);
-extern Oid GetNewRelFileNode(Oid reltablespace, Relation pg_class,
+extern Oid GetNewRelFileNode(Oid reltablespace, Relation pg_class,
char relpersistence);
#endif /* CATALOG_H */
diff --git a/src/include/catalog/dependency.h b/src/include/catalog/dependency.h
index 582294c6b3..a3bd729156 100644
--- a/src/include/catalog/dependency.h
+++ b/src/include/catalog/dependency.h
@@ -146,7 +146,7 @@ typedef enum ObjectClass
OCLASS_FOREIGN_SERVER, /* pg_foreign_server */
OCLASS_USER_MAPPING, /* pg_user_mapping */
OCLASS_DEFACL, /* pg_default_acl */
- OCLASS_EXTENSION, /* pg_extension */
+ OCLASS_EXTENSION, /* pg_extension */
MAX_OCLASS /* MUST BE LAST */
} ObjectClass;
@@ -204,7 +204,7 @@ extern void recordMultipleDependencies(const ObjectAddress *depender,
extern void recordDependencyOnCurrentExtension(const ObjectAddress *object);
extern long deleteDependencyRecordsFor(Oid classId, Oid objectId,
- bool skipExtensionDeps);
+ bool skipExtensionDeps);
extern long deleteDependencyRecordsForClass(Oid classId, Oid objectId,
Oid refclassId, char deptype);
diff --git a/src/include/catalog/namespace.h b/src/include/catalog/namespace.h
index e72d82eb16..f59beee80d 100644
--- a/src/include/catalog/namespace.h
+++ b/src/include/catalog/namespace.h
@@ -98,7 +98,7 @@ extern Oid get_namespace_oid(const char *nspname, bool missing_ok);
extern Oid LookupCreationNamespace(const char *nspname);
extern void CheckSetNamespace(Oid oldNspOid, Oid nspOid, Oid classid,
- Oid objid);
+ Oid objid);
extern Oid QualifiedNameGetCreationNamespace(List *names, char **objname_p);
extern RangeVar *makeRangeVarFromNameList(List *names);
extern char *NameListToString(List *names);
diff --git a/src/include/catalog/objectaccess.h b/src/include/catalog/objectaccess.h
index f1eace251a..29254758e7 100644
--- a/src/include/catalog/objectaccess.h
+++ b/src/include/catalog/objectaccess.h
@@ -12,7 +12,7 @@
/*
* Object access hooks are intended to be called just before or just after
- * performing certain actions on a SQL object. This is intended as
+ * performing certain actions on a SQL object. This is intended as
* infrastructure for security or logging pluggins.
*
* OAT_POST_CREATE should be invoked just after the the object is created.
@@ -30,10 +30,10 @@ typedef enum ObjectAccessType
* Hook, and a macro to invoke it.
*/
-typedef void (*object_access_hook_type)(ObjectAccessType access,
- Oid classId,
- Oid objectId,
- int subId);
+typedef void (*object_access_hook_type) (ObjectAccessType access,
+ Oid classId,
+ Oid objectId,
+ int subId);
extern PGDLLIMPORT object_access_hook_type object_access_hook;
@@ -43,4 +43,4 @@ extern PGDLLIMPORT object_access_hook_type object_access_hook;
(*object_access_hook)((access),(classId),(objectId),(subId)); \
} while(0)
-#endif /* OBJECTACCESS_H */
+#endif /* OBJECTACCESS_H */
diff --git a/src/include/catalog/pg_am.h b/src/include/catalog/pg_am.h
index 566d4fac5d..feab4201de 100644
--- a/src/include/catalog/pg_am.h
+++ b/src/include/catalog/pg_am.h
@@ -41,7 +41,7 @@ CATALOG(pg_am,2601)
int2 amsupport; /* total number of support functions that this
* AM uses */
bool amcanorder; /* does AM support order by column value? */
- bool amcanorderbyop; /* does AM support order by operator result? */
+ bool amcanorderbyop; /* does AM support order by operator result? */
bool amcanbackward; /* does AM support backward scan? */
bool amcanunique; /* does AM support UNIQUE indexes? */
bool amcanmulticol; /* does AM support multi-column indexes? */
diff --git a/src/include/catalog/pg_amop.h b/src/include/catalog/pg_amop.h
index aabb900ddc..3b88c41599 100644
--- a/src/include/catalog/pg_amop.h
+++ b/src/include/catalog/pg_amop.h
@@ -62,7 +62,7 @@ CATALOG(pg_amop,2602)
char amoppurpose; /* is operator for 's'earch or 'o'rdering? */
Oid amopopr; /* the operator's pg_operator OID */
Oid amopmethod; /* the index access method this entry is for */
- Oid amopsortfamily; /* ordering opfamily OID, or 0 if search op */
+ Oid amopsortfamily; /* ordering opfamily OID, or 0 if search op */
} FormData_pg_amop;
/* allowed values of amoppurpose: */
@@ -581,15 +581,15 @@ DATA(insert ( 627 2277 2277 1 s 1070 405 0 ));
* gist box_ops
*/
-DATA(insert ( 2593 603 603 1 s 493 783 0 ));
-DATA(insert ( 2593 603 603 2 s 494 783 0 ));
-DATA(insert ( 2593 603 603 3 s 500 783 0 ));
-DATA(insert ( 2593 603 603 4 s 495 783 0 ));
-DATA(insert ( 2593 603 603 5 s 496 783 0 ));
-DATA(insert ( 2593 603 603 6 s 499 783 0 ));
-DATA(insert ( 2593 603 603 7 s 498 783 0 ));
-DATA(insert ( 2593 603 603 8 s 497 783 0 ));
-DATA(insert ( 2593 603 603 9 s 2571 783 0 ));
+DATA(insert ( 2593 603 603 1 s 493 783 0 ));
+DATA(insert ( 2593 603 603 2 s 494 783 0 ));
+DATA(insert ( 2593 603 603 3 s 500 783 0 ));
+DATA(insert ( 2593 603 603 4 s 495 783 0 ));
+DATA(insert ( 2593 603 603 5 s 496 783 0 ));
+DATA(insert ( 2593 603 603 6 s 499 783 0 ));
+DATA(insert ( 2593 603 603 7 s 498 783 0 ));
+DATA(insert ( 2593 603 603 8 s 497 783 0 ));
+DATA(insert ( 2593 603 603 9 s 2571 783 0 ));
DATA(insert ( 2593 603 603 10 s 2570 783 0 ));
DATA(insert ( 2593 603 603 11 s 2573 783 0 ));
DATA(insert ( 2593 603 603 12 s 2572 783 0 ));
@@ -600,10 +600,10 @@ DATA(insert ( 2593 603 603 14 s 2862 783 0 ));
* gist point_ops
*/
DATA(insert ( 1029 600 600 11 s 506 783 0 ));
-DATA(insert ( 1029 600 600 1 s 507 783 0 ));
-DATA(insert ( 1029 600 600 5 s 508 783 0 ));
+DATA(insert ( 1029 600 600 1 s 507 783 0 ));
+DATA(insert ( 1029 600 600 5 s 508 783 0 ));
DATA(insert ( 1029 600 600 10 s 509 783 0 ));
-DATA(insert ( 1029 600 600 6 s 510 783 0 ));
+DATA(insert ( 1029 600 600 6 s 510 783 0 ));
DATA(insert ( 1029 600 600 15 o 517 783 1970 ));
DATA(insert ( 1029 603 600 27 s 433 783 0 ));
DATA(insert ( 1029 600 603 28 s 511 783 0 ));
@@ -617,15 +617,15 @@ DATA(insert ( 1029 600 718 68 s 758 783 0 ));
* gist poly_ops (supports polygons)
*/
-DATA(insert ( 2594 604 604 1 s 485 783 0 ));
-DATA(insert ( 2594 604 604 2 s 486 783 0 ));
-DATA(insert ( 2594 604 604 3 s 492 783 0 ));
-DATA(insert ( 2594 604 604 4 s 487 783 0 ));
-DATA(insert ( 2594 604 604 5 s 488 783 0 ));
-DATA(insert ( 2594 604 604 6 s 491 783 0 ));
-DATA(insert ( 2594 604 604 7 s 490 783 0 ));
-DATA(insert ( 2594 604 604 8 s 489 783 0 ));
-DATA(insert ( 2594 604 604 9 s 2575 783 0 ));
+DATA(insert ( 2594 604 604 1 s 485 783 0 ));
+DATA(insert ( 2594 604 604 2 s 486 783 0 ));
+DATA(insert ( 2594 604 604 3 s 492 783 0 ));
+DATA(insert ( 2594 604 604 4 s 487 783 0 ));
+DATA(insert ( 2594 604 604 5 s 488 783 0 ));
+DATA(insert ( 2594 604 604 6 s 491 783 0 ));
+DATA(insert ( 2594 604 604 7 s 490 783 0 ));
+DATA(insert ( 2594 604 604 8 s 489 783 0 ));
+DATA(insert ( 2594 604 604 9 s 2575 783 0 ));
DATA(insert ( 2594 604 604 10 s 2574 783 0 ));
DATA(insert ( 2594 604 604 11 s 2577 783 0 ));
DATA(insert ( 2594 604 604 12 s 2576 783 0 ));
@@ -636,15 +636,15 @@ DATA(insert ( 2594 604 604 14 s 2860 783 0 ));
* gist circle_ops
*/
-DATA(insert ( 2595 718 718 1 s 1506 783 0 ));
-DATA(insert ( 2595 718 718 2 s 1507 783 0 ));
-DATA(insert ( 2595 718 718 3 s 1513 783 0 ));
-DATA(insert ( 2595 718 718 4 s 1508 783 0 ));
-DATA(insert ( 2595 718 718 5 s 1509 783 0 ));
-DATA(insert ( 2595 718 718 6 s 1512 783 0 ));
-DATA(insert ( 2595 718 718 7 s 1511 783 0 ));
-DATA(insert ( 2595 718 718 8 s 1510 783 0 ));
-DATA(insert ( 2595 718 718 9 s 2589 783 0 ));
+DATA(insert ( 2595 718 718 1 s 1506 783 0 ));
+DATA(insert ( 2595 718 718 2 s 1507 783 0 ));
+DATA(insert ( 2595 718 718 3 s 1513 783 0 ));
+DATA(insert ( 2595 718 718 4 s 1508 783 0 ));
+DATA(insert ( 2595 718 718 5 s 1509 783 0 ));
+DATA(insert ( 2595 718 718 6 s 1512 783 0 ));
+DATA(insert ( 2595 718 718 7 s 1511 783 0 ));
+DATA(insert ( 2595 718 718 8 s 1510 783 0 ));
+DATA(insert ( 2595 718 718 9 s 2589 783 0 ));
DATA(insert ( 2595 718 718 10 s 1515 783 0 ));
DATA(insert ( 2595 718 718 11 s 1514 783 0 ));
DATA(insert ( 2595 718 718 12 s 2590 783 0 ));
diff --git a/src/include/catalog/pg_authid.h b/src/include/catalog/pg_authid.h
index 0c5ae443a0..c48d96bcac 100644
--- a/src/include/catalog/pg_authid.h
+++ b/src/include/catalog/pg_authid.h
@@ -51,7 +51,7 @@ CATALOG(pg_authid,1260) BKI_SHARED_RELATION BKI_ROWTYPE_OID(2842) BKI_SCHEMA_MAC
bool rolcreatedb; /* allowed to create databases? */
bool rolcatupdate; /* allowed to alter catalogs manually? */
bool rolcanlogin; /* allowed to log in as session user? */
- bool rolreplication; /* role used for streaming replication */
+ bool rolreplication; /* role used for streaming replication */
int4 rolconnlimit; /* max connections allowed (-1=no limit) */
/* remaining fields may be null; use heap_getattr to read them! */
diff --git a/src/include/catalog/pg_class.h b/src/include/catalog/pg_class.h
index e103530a3f..ffcce3c87c 100644
--- a/src/include/catalog/pg_class.h
+++ b/src/include/catalog/pg_class.h
@@ -49,7 +49,7 @@ CATALOG(pg_class,1259) BKI_BOOTSTRAP BKI_ROWTYPE_OID(83) BKI_SCHEMA_MACRO
Oid reltoastidxid; /* if toast table, OID of chunk_id index */
bool relhasindex; /* T if has (or has had) any indexes */
bool relisshared; /* T if shared across databases */
- char relpersistence; /* see RELPERSISTENCE_xxx constants below */
+ char relpersistence; /* see RELPERSISTENCE_xxx constants below */
char relkind; /* see RELKIND_xxx constants below */
int2 relnatts; /* number of user attributes */
@@ -146,7 +146,7 @@ DESCR("");
#define RELKIND_TOASTVALUE 't' /* for out-of-line values */
#define RELKIND_VIEW 'v' /* view */
#define RELKIND_COMPOSITE_TYPE 'c' /* composite type */
-#define RELKIND_FOREIGN_TABLE 'f' /* foreign table */
+#define RELKIND_FOREIGN_TABLE 'f' /* foreign table */
#define RELKIND_UNCATALOGED 'u' /* not yet cataloged */
#define RELPERSISTENCE_PERMANENT 'p' /* regular table */
diff --git a/src/include/catalog/pg_collation.h b/src/include/catalog/pg_collation.h
index 2ab0c504f6..7d6a544a7d 100644
--- a/src/include/catalog/pg_collation.h
+++ b/src/include/catalog/pg_collation.h
@@ -52,7 +52,7 @@ typedef FormData_pg_collation *Form_pg_collation;
*/
#define Natts_pg_collation 6
#define Anum_pg_collation_collname 1
-#define Anum_pg_collation_collnamespace 2
+#define Anum_pg_collation_collnamespace 2
#define Anum_pg_collation_collowner 3
#define Anum_pg_collation_collencoding 4
#define Anum_pg_collation_collcollate 5
diff --git a/src/include/catalog/pg_collation_fn.h b/src/include/catalog/pg_collation_fn.h
index 63a9cf2d63..df36ee40cb 100644
--- a/src/include/catalog/pg_collation_fn.h
+++ b/src/include/catalog/pg_collation_fn.h
@@ -15,9 +15,9 @@
#define PG_COLLATION_FN_H
extern Oid CollationCreate(const char *collname, Oid collnamespace,
- Oid collowner,
- int32 collencoding,
- const char *collcollate, const char *collctype);
+ Oid collowner,
+ int32 collencoding,
+ const char *collcollate, const char *collctype);
extern void RemoveCollationById(Oid collationOid);
#endif /* PG_COLLATION_FN_H */
diff --git a/src/include/catalog/pg_constraint.h b/src/include/catalog/pg_constraint.h
index a7967ab5c6..1566af2973 100644
--- a/src/include/catalog/pg_constraint.h
+++ b/src/include/catalog/pg_constraint.h
@@ -244,8 +244,8 @@ extern void AlterConstraintNamespaces(Oid ownerId, Oid oldNspId,
extern Oid get_constraint_oid(Oid relid, const char *conname, bool missing_ok);
extern bool check_functional_grouping(Oid relid,
- Index varno, Index varlevelsup,
- List *grouping_columns,
- List **constraintDeps);
+ Index varno, Index varlevelsup,
+ List *grouping_columns,
+ List **constraintDeps);
#endif /* PG_CONSTRAINT_H */
diff --git a/src/include/catalog/pg_control.h b/src/include/catalog/pg_control.h
index fb458acf83..d543ef6e24 100644
--- a/src/include/catalog/pg_control.h
+++ b/src/include/catalog/pg_control.h
@@ -45,8 +45,8 @@ typedef struct CheckPoint
/*
* Oldest XID still running. This is only needed to initialize hot standby
* mode from an online checkpoint, so we only bother calculating this for
- * online checkpoints and only when wal_level is hot_standby. Otherwise it's
- * set to InvalidTransactionId.
+ * online checkpoints and only when wal_level is hot_standby. Otherwise
+ * it's set to InvalidTransactionId.
*/
TransactionId oldestActiveXid;
} CheckPoint;
@@ -59,7 +59,7 @@ typedef struct CheckPoint
#define XLOG_SWITCH 0x40
#define XLOG_BACKUP_END 0x50
#define XLOG_PARAMETER_CHANGE 0x60
-#define XLOG_RESTORE_POINT 0x70
+#define XLOG_RESTORE_POINT 0x70
/*
diff --git a/src/include/catalog/pg_enum.h b/src/include/catalog/pg_enum.h
index a0fca30019..b95e94ad1b 100644
--- a/src/include/catalog/pg_enum.h
+++ b/src/include/catalog/pg_enum.h
@@ -65,6 +65,6 @@ typedef FormData_pg_enum *Form_pg_enum;
extern void EnumValuesCreate(Oid enumTypeOid, List *vals);
extern void EnumValuesDelete(Oid enumTypeOid);
extern void AddEnumLabel(Oid enumTypeOid, const char *newVal,
- const char *neighbor, bool newValIsAfter);
+ const char *neighbor, bool newValIsAfter);
#endif /* PG_ENUM_H */
diff --git a/src/include/catalog/pg_extension.h b/src/include/catalog/pg_extension.h
index 63a1a0711f..064b9991f0 100644
--- a/src/include/catalog/pg_extension.h
+++ b/src/include/catalog/pg_extension.h
@@ -26,22 +26,22 @@
* typedef struct FormData_pg_extension
* ----------------
*/
-#define ExtensionRelationId 3079
+#define ExtensionRelationId 3079
CATALOG(pg_extension,3079)
{
NameData extname; /* extension name */
Oid extowner; /* extension owner */
Oid extnamespace; /* namespace of contained objects */
- bool extrelocatable; /* if true, allow ALTER EXTENSION SET SCHEMA */
+ bool extrelocatable; /* if true, allow ALTER EXTENSION SET SCHEMA */
/*
* VARIABLE LENGTH FIELDS start here.
*
* extversion should never be null, but the others can be.
*/
- text extversion; /* extension version name */
- Oid extconfig[1]; /* dumpable configuration tables */
+ text extversion; /* extension version name */
+ Oid extconfig[1]; /* dumpable configuration tables */
text extcondition[1]; /* WHERE clauses for config tables */
} FormData_pg_extension;
diff --git a/src/include/catalog/pg_index.h b/src/include/catalog/pg_index.h
index d8142e12bc..9f446a5547 100644
--- a/src/include/catalog/pg_index.h
+++ b/src/include/catalog/pg_index.h
@@ -35,7 +35,7 @@ CATALOG(pg_index,2610) BKI_WITHOUT_OIDS BKI_SCHEMA_MACRO
int2 indnatts; /* number of columns in index */
bool indisunique; /* is this a unique index? */
bool indisprimary; /* is this index for primary key? */
- bool indisexclusion; /* is this index for exclusion constraint? */
+ bool indisexclusion; /* is this index for exclusion constraint? */
bool indimmediate; /* is uniqueness enforced immediately? */
bool indisclustered; /* is this the index last clustered by? */
bool indisvalid; /* is this index valid for use by queries? */
diff --git a/src/include/catalog/pg_operator.h b/src/include/catalog/pg_operator.h
index 05a2b0eb07..c9332777c1 100644
--- a/src/include/catalog/pg_operator.h
+++ b/src/include/catalog/pg_operator.h
@@ -718,7 +718,7 @@ DATA(insert OID = 917 ( "*" PGNSP PGUID b f f 23 790 790 912 0 int4_mul_c
DESCR("multiply");
DATA(insert OID = 918 ( "*" PGNSP PGUID b f f 21 790 790 914 0 int2_mul_cash - - ));
DESCR("multiply");
-DATA(insert OID = 3825 ( "/" PGNSP PGUID b f f 790 790 701 0 0 cash_div_cash - - ));
+DATA(insert OID = 3825 ( "/" PGNSP PGUID b f f 790 790 701 0 0 cash_div_cash - - ));
DESCR("divide");
DATA(insert OID = 965 ( "^" PGNSP PGUID b f f 701 701 701 0 0 dpow - - ));
diff --git a/src/include/catalog/pg_proc.h b/src/include/catalog/pg_proc.h
index 7919a40487..3c183ce7b5 100644
--- a/src/include/catalog/pg_proc.h
+++ b/src/include/catalog/pg_proc.h
@@ -57,8 +57,8 @@ CATALOG(pg_proc,1255) BKI_BOOTSTRAP BKI_ROWTYPE_OID(81) BKI_SCHEMA_MACRO
Oid proallargtypes[1]; /* all param types (NULL if IN only) */
char proargmodes[1]; /* parameter modes (NULL if IN only) */
text proargnames[1]; /* parameter names (NULL if no names) */
- pg_node_tree proargdefaults; /* list of expression trees for argument
- * defaults (NULL if none) */
+ pg_node_tree proargdefaults;/* list of expression trees for argument
+ * defaults (NULL if none) */
text prosrc; /* procedure source text */
text probin; /* secondary procedure info (can be NULL) */
text proconfig[1]; /* procedure-local GUC settings */
@@ -544,7 +544,7 @@ DATA(insert OID = 332 ( btbulkdelete PGNSP PGUID 12 1 0 0 f f f t f v 4 0 22
DESCR("btree(internal)");
DATA(insert OID = 972 ( btvacuumcleanup PGNSP PGUID 12 1 0 0 f f f t f v 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ btvacuumcleanup _null_ _null_ _null_ ));
DESCR("btree(internal)");
-DATA(insert OID = 1268 ( btcostestimate PGNSP PGUID 12 1 0 0 f f f t f v 9 0 2278 "2281 2281 2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ btcostestimate _null_ _null_ _null_ ));
+DATA(insert OID = 1268 ( btcostestimate PGNSP PGUID 12 1 0 0 f f f t f v 9 0 2278 "2281 2281 2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ btcostestimate _null_ _null_ _null_ ));
DESCR("btree(internal)");
DATA(insert OID = 2785 ( btoptions PGNSP PGUID 12 1 0 0 f f f t f s 2 0 17 "1009 16" _null_ _null_ _null_ _null_ btoptions _null_ _null_ _null_ ));
DESCR("btree(internal)");
@@ -638,13 +638,13 @@ DATA(insert OID = 447 ( hashrestrpos PGNSP PGUID 12 1 0 0 f f f t f v 1 0 22
DESCR("hash(internal)");
DATA(insert OID = 448 ( hashbuild PGNSP PGUID 12 1 0 0 f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ hashbuild _null_ _null_ _null_ ));
DESCR("hash(internal)");
-DATA(insert OID = 327 ( hashbuildempty PGNSP PGUID 12 1 0 0 f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ hashbuildempty _null_ _null_ _null_ ));
+DATA(insert OID = 327 ( hashbuildempty PGNSP PGUID 12 1 0 0 f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ hashbuildempty _null_ _null_ _null_ ));
DESCR("hash(internal)");
DATA(insert OID = 442 ( hashbulkdelete PGNSP PGUID 12 1 0 0 f f f t f v 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ hashbulkdelete _null_ _null_ _null_ ));
DESCR("hash(internal)");
DATA(insert OID = 425 ( hashvacuumcleanup PGNSP PGUID 12 1 0 0 f f f t f v 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ hashvacuumcleanup _null_ _null_ _null_ ));
DESCR("hash(internal)");
-DATA(insert OID = 438 ( hashcostestimate PGNSP PGUID 12 1 0 0 f f f t f v 9 0 2278 "2281 2281 2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ hashcostestimate _null_ _null_ _null_ ));
+DATA(insert OID = 438 ( hashcostestimate PGNSP PGUID 12 1 0 0 f f f t f v 9 0 2278 "2281 2281 2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ hashcostestimate _null_ _null_ _null_ ));
DESCR("hash(internal)");
DATA(insert OID = 2786 ( hashoptions PGNSP PGUID 12 1 0 0 f f f t f s 2 0 17 "1009 16" _null_ _null_ _null_ _null_ hashoptions _null_ _null_ _null_ ));
DESCR("hash(internal)");
@@ -891,13 +891,13 @@ DATA(insert OID = 781 ( gistrestrpos PGNSP PGUID 12 1 0 0 f f f t f v 1 0 22
DESCR("gist(internal)");
DATA(insert OID = 782 ( gistbuild PGNSP PGUID 12 1 0 0 f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ gistbuild _null_ _null_ _null_ ));
DESCR("gist(internal)");
-DATA(insert OID = 326 ( gistbuildempty PGNSP PGUID 12 1 0 0 f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ gistbuildempty _null_ _null_ _null_ ));
+DATA(insert OID = 326 ( gistbuildempty PGNSP PGUID 12 1 0 0 f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ gistbuildempty _null_ _null_ _null_ ));
DESCR("gist(internal)");
DATA(insert OID = 776 ( gistbulkdelete PGNSP PGUID 12 1 0 0 f f f t f v 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ gistbulkdelete _null_ _null_ _null_ ));
DESCR("gist(internal)");
DATA(insert OID = 2561 ( gistvacuumcleanup PGNSP PGUID 12 1 0 0 f f f t f v 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ gistvacuumcleanup _null_ _null_ _null_ ));
DESCR("gist(internal)");
-DATA(insert OID = 772 ( gistcostestimate PGNSP PGUID 12 1 0 0 f f f t f v 9 0 2278 "2281 2281 2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gistcostestimate _null_ _null_ _null_ ));
+DATA(insert OID = 772 ( gistcostestimate PGNSP PGUID 12 1 0 0 f f f t f v 9 0 2278 "2281 2281 2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gistcostestimate _null_ _null_ _null_ ));
DESCR("gist(internal)");
DATA(insert OID = 2787 ( gistoptions PGNSP PGUID 12 1 0 0 f f f t f s 2 0 17 "1009 16" _null_ _null_ _null_ _null_ gistoptions _null_ _null_ _null_ ));
DESCR("gist(internal)");
@@ -2250,17 +2250,17 @@ DESCR("I/O");
DATA(insert OID = 1799 ( oidout PGNSP PGUID 12 1 0 0 f f f t f i 1 0 2275 "26" _null_ _null_ _null_ _null_ oidout _null_ _null_ _null_ ));
DESCR("I/O");
-DATA(insert OID = 3058 ( concat PGNSP PGUID 12 1 0 2276 f f f f f s 1 0 25 "2276" "{2276}" "{v}" _null_ _null_ text_concat _null_ _null_ _null_ ));
+DATA(insert OID = 3058 ( concat PGNSP PGUID 12 1 0 2276 f f f f f s 1 0 25 "2276" "{2276}" "{v}" _null_ _null_ text_concat _null_ _null_ _null_ ));
DESCR("concatenate values");
-DATA(insert OID = 3059 ( concat_ws PGNSP PGUID 12 1 0 2276 f f f f f s 2 0 25 "25 2276" "{25,2276}" "{i,v}" _null_ _null_ text_concat_ws _null_ _null_ _null_ ));
+DATA(insert OID = 3059 ( concat_ws PGNSP PGUID 12 1 0 2276 f f f f f s 2 0 25 "25 2276" "{25,2276}" "{i,v}" _null_ _null_ text_concat_ws _null_ _null_ _null_ ));
DESCR("concatenate values with separators");
DATA(insert OID = 3060 ( left PGNSP PGUID 12 1 0 0 f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ text_left _null_ _null_ _null_ ));
DESCR("extract the first n characters");
DATA(insert OID = 3061 ( right PGNSP PGUID 12 1 0 0 f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ text_right _null_ _null_ _null_ ));
DESCR("extract the last n characters");
-DATA(insert OID = 3062 ( reverse PGNSP PGUID 12 1 0 0 f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ text_reverse _null_ _null_ _null_ ));
+DATA(insert OID = 3062 ( reverse PGNSP PGUID 12 1 0 0 f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ text_reverse _null_ _null_ _null_ ));
DESCR("reverse text");
-DATA(insert OID = 3539 ( format PGNSP PGUID 12 1 0 2276 f f f f f s 2 0 25 "25 2276" "{25,2276}" "{i,v}" _null_ _null_ text_format _null_ _null_ _null_ ));
+DATA(insert OID = 3539 ( format PGNSP PGUID 12 1 0 2276 f f f f f s 2 0 25 "25 2276" "{25,2276}" "{i,v}" _null_ _null_ text_format _null_ _null_ _null_ ));
DESCR("format text message");
DATA(insert OID = 3540 ( format PGNSP PGUID 12 1 0 0 f f f f f s 1 0 25 "25" _null_ _null_ _null_ _null_ text_format_nv _null_ _null_ _null_ ));
DESCR("format text message");
@@ -2602,7 +2602,7 @@ DATA(insert OID = 3069 ( pg_stat_get_db_conflict_startup_deadlock PGNSP PGUID 1
DESCR("statistics: recovery conflicts in database caused by buffer deadlock");
DATA(insert OID = 3070 ( pg_stat_get_db_conflict_all PGNSP PGUID 12 1 0 0 f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_conflict_all _null_ _null_ _null_ ));
DESCR("statistics: recovery conflicts in database");
-DATA(insert OID = 3074 ( pg_stat_get_db_stat_reset_time PGNSP PGUID 12 1 0 0 f f f t f s 1 0 1184 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_stat_reset_time _null_ _null_ _null_ ));
+DATA(insert OID = 3074 ( pg_stat_get_db_stat_reset_time PGNSP PGUID 12 1 0 0 f f f t f s 1 0 1184 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_stat_reset_time _null_ _null_ _null_ ));
DESCR("statistics: last reset for a database");
DATA(insert OID = 2769 ( pg_stat_get_bgwriter_timed_checkpoints PGNSP PGUID 12 1 0 0 f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ pg_stat_get_bgwriter_timed_checkpoints _null_ _null_ _null_ ));
DESCR("statistics: number of timed checkpoints started by the bgwriter");
@@ -3818,13 +3818,13 @@ DATA(insert OID = 2739 ( ginbulkdelete PGNSP PGUID 12 1 0 0 f f f t f v 4 0
DESCR("gin(internal)");
DATA(insert OID = 2740 ( ginvacuumcleanup PGNSP PGUID 12 1 0 0 f f f t f v 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ ginvacuumcleanup _null_ _null_ _null_ ));
DESCR("gin(internal)");
-DATA(insert OID = 2741 ( gincostestimate PGNSP PGUID 12 1 0 0 f f f t f v 9 0 2278 "2281 2281 2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gincostestimate _null_ _null_ _null_ ));
+DATA(insert OID = 2741 ( gincostestimate PGNSP PGUID 12 1 0 0 f f f t f v 9 0 2278 "2281 2281 2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gincostestimate _null_ _null_ _null_ ));
DESCR("gin(internal)");
DATA(insert OID = 2788 ( ginoptions PGNSP PGUID 12 1 0 0 f f f t f s 2 0 17 "1009 16" _null_ _null_ _null_ _null_ ginoptions _null_ _null_ _null_ ));
DESCR("gin(internal)");
/* GIN array support */
-DATA(insert OID = 2743 ( ginarrayextract PGNSP PGUID 12 1 0 0 f f f t f i 3 0 2281 "2277 2281 2281" _null_ _null_ _null_ _null_ ginarrayextract _null_ _null_ _null_ ));
+DATA(insert OID = 2743 ( ginarrayextract PGNSP PGUID 12 1 0 0 f f f t f i 3 0 2281 "2277 2281 2281" _null_ _null_ _null_ _null_ ginarrayextract _null_ _null_ _null_ ));
DESCR("GIN array support");
DATA(insert OID = 2774 ( ginqueryarrayextract PGNSP PGUID 12 1 0 0 f f f t f i 7 0 2281 "2277 2281 21 2281 2281 2281 2281" _null_ _null_ _null_ _null_ ginqueryarrayextract _null_ _null_ _null_ ));
DESCR("GIN array support");
@@ -3940,7 +3940,7 @@ DESCR("evaluate XPath expression, with namespaces support");
DATA(insert OID = 2932 ( xpath PGNSP PGUID 14 1 0 0 f f f t f i 2 0 143 "25 142" _null_ _null_ _null_ _null_ "select pg_catalog.xpath($1, $2, ''{}''::pg_catalog.text[])" _null_ _null_ _null_ ));
DESCR("evaluate XPath expression");
-DATA(insert OID = 2614 ( xmlexists PGNSP PGUID 12 1 0 0 f f f t f i 2 0 16 "25 142" _null_ _null_ _null_ _null_ xmlexists _null_ _null_ _null_ ));
+DATA(insert OID = 2614 ( xmlexists PGNSP PGUID 12 1 0 0 f f f t f i 2 0 16 "25 142" _null_ _null_ _null_ _null_ xmlexists _null_ _null_ _null_ ));
DESCR("test XML value against XPath expression");
DATA(insert OID = 3049 ( xpath_exists PGNSP PGUID 12 1 0 0 f f f t f i 3 0 16 "25 142 1009" _null_ _null_ _null_ _null_ xpath_exists _null_ _null_ _null_ ));
diff --git a/src/include/catalog/pg_seclabel.h b/src/include/catalog/pg_seclabel.h
index f41b85a368..1f9a6a0432 100644
--- a/src/include/catalog/pg_seclabel.h
+++ b/src/include/catalog/pg_seclabel.h
@@ -1,7 +1,7 @@
/* -------------------------------------------------------------------------
*
* pg_seclabel.h
- * definition of the system "security label" relation (pg_seclabel)
+ * definition of the system "security label" relation (pg_seclabel)
*
* Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
@@ -22,11 +22,11 @@
CATALOG(pg_seclabel,3596) BKI_WITHOUT_OIDS
{
- Oid objoid; /* OID of the object itself */
- Oid classoid; /* OID of table containing the object */
- int4 objsubid; /* column number, or 0 if not used */
- text provider; /* name of label provider */
- text label; /* security label of the object */
+ Oid objoid; /* OID of the object itself */
+ Oid classoid; /* OID of table containing the object */
+ int4 objsubid; /* column number, or 0 if not used */
+ text provider; /* name of label provider */
+ text label; /* security label of the object */
} FormData_pg_seclabel;
/* ----------------
@@ -40,4 +40,4 @@ CATALOG(pg_seclabel,3596) BKI_WITHOUT_OIDS
#define Anum_pg_seclabel_provider 4
#define Anum_pg_seclabel_label 5
-#endif /* PG_SECLABEL_H */
+#endif /* PG_SECLABEL_H */
diff --git a/src/include/catalog/pg_type.h b/src/include/catalog/pg_type.h
index 9baed6c769..d72ca2342f 100644
--- a/src/include/catalog/pg_type.h
+++ b/src/include/catalog/pg_type.h
@@ -194,9 +194,8 @@ CATALOG(pg_type,1247) BKI_BOOTSTRAP BKI_ROWTYPE_OID(71) BKI_SCHEMA_MACRO
int4 typndims;
/*
- * Collation: 0 if type cannot use collations,
- * DEFAULT_COLLATION_OID for collatable base types, possibly other
- * OID for domains
+ * Collation: 0 if type cannot use collations, DEFAULT_COLLATION_OID for
+ * collatable base types, possibly other OID for domains
*/
Oid typcollation;
@@ -205,7 +204,7 @@ CATALOG(pg_type,1247) BKI_BOOTSTRAP BKI_ROWTYPE_OID(71) BKI_SCHEMA_MACRO
* a default expression for the type. Currently this is only used for
* domains.
*/
- pg_node_tree typdefaultbin; /* VARIABLE LENGTH FIELD */
+ pg_node_tree typdefaultbin; /* VARIABLE LENGTH FIELD */
/*
* typdefault is NULL if the type has no associated default value. If
@@ -350,7 +349,7 @@ DESCR("XML content");
#define XMLOID 142
DATA(insert OID = 143 ( _xml PGNSP PGUID -1 f b A f t \054 0 142 0 array_in array_out array_recv array_send - - - i x f 0 -1 0 0 _null_ _null_ ));
-DATA(insert OID = 194 ( pg_node_tree PGNSP PGUID -1 f b S f t \054 0 0 0 pg_node_tree_in pg_node_tree_out pg_node_tree_recv pg_node_tree_send - - - i x f 0 -1 0 100 _null_ _null_ ));
+DATA(insert OID = 194 ( pg_node_tree PGNSP PGUID -1 f b S f t \054 0 0 0 pg_node_tree_in pg_node_tree_out pg_node_tree_recv pg_node_tree_send - - - i x f 0 -1 0 100 _null_ _null_ ));
DESCR("string representing an internal node tree");
#define PGNODETREEOID 194
diff --git a/src/include/catalog/storage.h b/src/include/catalog/storage.h
index 0b93b370bd..8dee8cf225 100644
--- a/src/include/catalog/storage.h
+++ b/src/include/catalog/storage.h
@@ -30,7 +30,7 @@ extern void RelationTruncate(Relation rel, BlockNumber nblocks);
* naming
*/
extern void smgrDoPendingDeletes(bool isCommit);
-extern int smgrGetPendingDeletes(bool forCommit, RelFileNode **ptr);
+extern int smgrGetPendingDeletes(bool forCommit, RelFileNode **ptr);
extern void AtSubCommit_smgr(void);
extern void AtSubAbort_smgr(void);
extern void PostPrepare_smgr(void);
diff --git a/src/include/commands/alter.h b/src/include/commands/alter.h
index 21731685f5..e942b538af 100644
--- a/src/include/commands/alter.h
+++ b/src/include/commands/alter.h
@@ -21,7 +21,7 @@
extern void ExecRenameStmt(RenameStmt *stmt);
extern void ExecAlterObjectSchemaStmt(AlterObjectSchemaStmt *stmt);
extern Oid AlterObjectNamespace_oid(Oid classId, Oid objid, Oid nspOid);
-extern Oid AlterObjectNamespace(Relation rel, int oidCacheId, int nameCacheId,
+extern Oid AlterObjectNamespace(Relation rel, int oidCacheId, int nameCacheId,
Oid objid, Oid nspOid,
int Anum_name, int Anum_namespace, int Anum_owner,
AclObjectKind acl_kind);
diff --git a/src/include/commands/collationcmds.h b/src/include/commands/collationcmds.h
index 60504694a5..6dbeb751aa 100644
--- a/src/include/commands/collationcmds.h
+++ b/src/include/commands/collationcmds.h
@@ -23,6 +23,6 @@ extern void RenameCollation(List *name, const char *newname);
extern void AlterCollationOwner(List *name, Oid newOwnerId);
extern void AlterCollationOwner_oid(Oid collationOid, Oid newOwnerId);
extern void AlterCollationNamespace(List *name, const char *newschema);
-extern Oid AlterCollationNamespace_oid(Oid collOid, Oid newNspOid);
+extern Oid AlterCollationNamespace_oid(Oid collOid, Oid newNspOid);
#endif /* COLLATIONCMDS_H */
diff --git a/src/include/commands/copy.h b/src/include/commands/copy.h
index 7098a70c95..a31479defb 100644
--- a/src/include/commands/copy.h
+++ b/src/include/commands/copy.h
@@ -25,12 +25,12 @@ extern uint64 DoCopy(const CopyStmt *stmt, const char *queryString);
extern void ProcessCopyOptions(CopyState cstate, bool is_from, List *options);
extern CopyState BeginCopyFrom(Relation rel, const char *filename,
- List *attnamelist, List *options);
+ List *attnamelist, List *options);
extern void EndCopyFrom(CopyState cstate);
extern bool NextCopyFrom(CopyState cstate, ExprContext *econtext,
- Datum *values, bool *nulls, Oid *tupleOid);
+ Datum *values, bool *nulls, Oid *tupleOid);
extern bool NextCopyFromRawFields(CopyState cstate,
- char ***fields, int *nfields);
+ char ***fields, int *nfields);
extern void CopyFromErrorCallback(void *arg);
extern DestReceiver *CreateCopyDestReceiver(void);
diff --git a/src/include/commands/dbcommands.h b/src/include/commands/dbcommands.h
index f54c57907a..21dacff39c 100644
--- a/src/include/commands/dbcommands.h
+++ b/src/include/commands/dbcommands.h
@@ -27,14 +27,14 @@ typedef struct xl_dbase_create_rec_old
Oid db_id;
char src_path[1]; /* VARIABLE LENGTH STRING */
/* dst_path follows src_path */
-} xl_dbase_create_rec_old;
+} xl_dbase_create_rec_old;
typedef struct xl_dbase_drop_rec_old
{
/* Records dropping of a single subdirectory incl. contents */
Oid db_id;
char dir_path[1]; /* VARIABLE LENGTH STRING */
-} xl_dbase_drop_rec_old;
+} xl_dbase_drop_rec_old;
typedef struct xl_dbase_create_rec
{
diff --git a/src/include/commands/defrem.h b/src/include/commands/defrem.h
index 157ee39461..bbc024f50c 100644
--- a/src/include/commands/defrem.h
+++ b/src/include/commands/defrem.h
@@ -68,7 +68,7 @@ extern void AlterFunctionNamespace(List *name, List *argtypes, bool isagg,
const char *newschema);
extern Oid AlterFunctionNamespace_oid(Oid procOid, Oid nspOid);
extern void ExecuteDoStmt(DoStmt *stmt);
-extern Oid get_cast_oid(Oid sourcetypeid, Oid targettypeid, bool missing_ok);
+extern Oid get_cast_oid(Oid sourcetypeid, Oid targettypeid, bool missing_ok);
/* commands/operatorcmds.c */
extern void DefineOperator(List *names, List *parameters);
@@ -107,9 +107,9 @@ extern void AlterOpFamilyOwner(List *name, const char *access_method, Oid newOwn
extern void AlterOpFamilyOwner_oid(Oid opfamilyOid, Oid newOwnerId);
extern void AlterOpFamilyNamespace(List *name, char *access_method, const char *newschema);
extern Oid AlterOpFamilyNamespace_oid(Oid opfamilyOid, Oid newNspOid);
-extern Oid get_am_oid(const char *amname, bool missing_ok);
-extern Oid get_opclass_oid(Oid amID, List *opclassname, bool missing_ok);
-extern Oid get_opfamily_oid(Oid amID, List *opfamilyname, bool missing_ok);
+extern Oid get_am_oid(const char *amname, bool missing_ok);
+extern Oid get_opclass_oid(Oid amID, List *opclassname, bool missing_ok);
+extern Oid get_opfamily_oid(Oid amID, List *opfamilyname, bool missing_ok);
/* commands/tsearchcmds.c */
extern void DefineTSParser(List *names, List *parameters);
@@ -164,9 +164,9 @@ extern void RemoveUserMapping(DropUserMappingStmt *stmt);
extern void RemoveUserMappingById(Oid umId);
extern void CreateForeignTable(CreateForeignTableStmt *stmt, Oid relid);
extern Datum transformGenericOptions(Oid catalogId,
- Datum oldOptions,
- List *options,
- Oid fdwvalidator);
+ Datum oldOptions,
+ List *options,
+ Oid fdwvalidator);
/* support routines in commands/define.c */
diff --git a/src/include/commands/explain.h b/src/include/commands/explain.h
index 2c38c92ae5..d7998c3178 100644
--- a/src/include/commands/explain.h
+++ b/src/include/commands/explain.h
@@ -73,14 +73,14 @@ extern void ExplainEndOutput(ExplainState *es);
extern void ExplainSeparatePlans(ExplainState *es);
extern void ExplainPropertyList(const char *qlabel, List *data,
- ExplainState *es);
+ ExplainState *es);
extern void ExplainPropertyText(const char *qlabel, const char *value,
- ExplainState *es);
+ ExplainState *es);
extern void ExplainPropertyInteger(const char *qlabel, int value,
- ExplainState *es);
+ ExplainState *es);
extern void ExplainPropertyLong(const char *qlabel, long value,
- ExplainState *es);
+ ExplainState *es);
extern void ExplainPropertyFloat(const char *qlabel, double value, int ndigits,
- ExplainState *es);
+ ExplainState *es);
#endif /* EXPLAIN_H */
diff --git a/src/include/commands/extension.h b/src/include/commands/extension.h
index c6e69d5fd4..2792c6dd49 100644
--- a/src/include/commands/extension.h
+++ b/src/include/commands/extension.h
@@ -24,7 +24,7 @@
* installation script.
*/
extern bool creating_extension;
-extern Oid CurrentExtensionObject;
+extern Oid CurrentExtensionObject;
extern void CreateExtension(CreateExtensionStmt *stmt);
@@ -32,7 +32,7 @@ extern void CreateExtension(CreateExtensionStmt *stmt);
extern void RemoveExtensions(DropStmt *stmt);
extern void RemoveExtensionById(Oid extId);
-extern Oid InsertExtensionTuple(const char *extName, Oid extOwner,
+extern Oid InsertExtensionTuple(const char *extName, Oid extOwner,
Oid schemaOid, bool relocatable, const char *extVersion,
Datum extConfig, Datum extCondition,
List *requiredExtensions);
diff --git a/src/include/commands/proclang.h b/src/include/commands/proclang.h
index aa1fb34d1a..644c371dcc 100644
--- a/src/include/commands/proclang.h
+++ b/src/include/commands/proclang.h
@@ -21,6 +21,6 @@ extern void RenameLanguage(const char *oldname, const char *newname);
extern void AlterLanguageOwner(const char *name, Oid newOwnerId);
extern void AlterLanguageOwner_oid(Oid oid, Oid newOwnerId);
extern bool PLTemplateExists(const char *languageName);
-extern Oid get_language_oid(const char *langname, bool missing_ok);
+extern Oid get_language_oid(const char *langname, bool missing_ok);
#endif /* PROCLANG_H */
diff --git a/src/include/commands/seclabel.h b/src/include/commands/seclabel.h
index 1ae922b7e9..06ce602d7d 100644
--- a/src/include/commands/seclabel.h
+++ b/src/include/commands/seclabel.h
@@ -19,7 +19,7 @@
extern char *GetSecurityLabel(const ObjectAddress *object,
const char *provider);
extern void SetSecurityLabel(const ObjectAddress *object,
- const char *provider, const char *label);
+ const char *provider, const char *label);
extern void DeleteSecurityLabel(const ObjectAddress *object);
/*
@@ -27,9 +27,9 @@ extern void DeleteSecurityLabel(const ObjectAddress *object);
*/
extern void ExecSecLabelStmt(SecLabelStmt *stmt);
-typedef void (*check_object_relabel_type)(const ObjectAddress *object,
- const char *seclabel);
+typedef void (*check_object_relabel_type) (const ObjectAddress *object,
+ const char *seclabel);
extern void register_label_provider(const char *provider,
- check_object_relabel_type hook);
+ check_object_relabel_type hook);
-#endif /* SECLABEL_H */
+#endif /* SECLABEL_H */
diff --git a/src/include/commands/trigger.h b/src/include/commands/trigger.h
index 80a779ed0b..ad97871d98 100644
--- a/src/include/commands/trigger.h
+++ b/src/include/commands/trigger.h
@@ -115,7 +115,7 @@ extern Oid CreateTrigger(CreateTrigStmt *stmt, const char *queryString,
extern void DropTrigger(Oid relid, const char *trigname,
DropBehavior behavior, bool missing_ok);
extern void RemoveTriggerById(Oid trigOid);
-extern Oid get_trigger_oid(Oid relid, const char *name, bool missing_ok);
+extern Oid get_trigger_oid(Oid relid, const char *name, bool missing_ok);
extern void renametrig(Oid relid, const char *oldname, const char *newname);
diff --git a/src/include/commands/typecmds.h b/src/include/commands/typecmds.h
index 1b20296934..6d9d1ccaa9 100644
--- a/src/include/commands/typecmds.h
+++ b/src/include/commands/typecmds.h
@@ -42,7 +42,7 @@ extern void AlterTypeOwnerInternal(Oid typeOid, Oid newOwnerId,
bool hasDependEntry);
extern void AlterTypeNamespace(List *names, const char *newschema);
extern Oid AlterTypeNamespace_oid(Oid typeOid, Oid nspOid);
-extern Oid AlterTypeNamespaceInternal(Oid typeOid, Oid nspOid,
+extern Oid AlterTypeNamespaceInternal(Oid typeOid, Oid nspOid,
bool isImplicitArray,
bool errorOnTableType);
diff --git a/src/include/commands/vacuum.h b/src/include/commands/vacuum.h
index cc1441372d..79c9f5d90f 100644
--- a/src/include/commands/vacuum.h
+++ b/src/include/commands/vacuum.h
@@ -68,7 +68,7 @@ typedef struct VacAttrStats
* type-specific typanalyze function.
*
* Note: do not assume that the data being analyzed has the same datatype
- * shown in attr, ie do not trust attr->atttypid, attlen, etc. This is
+ * shown in attr, ie do not trust attr->atttypid, attlen, etc. This is
* because some index opclasses store a different type than the underlying
* column/expression. Instead use attrtypid, attrtypmod, and attrtype for
* information about the datatype being fed to the typanalyze function.
diff --git a/src/include/executor/executor.h b/src/include/executor/executor.h
index 3e9df936e5..1d651dd408 100644
--- a/src/include/executor/executor.h
+++ b/src/include/executor/executor.h
@@ -54,7 +54,7 @@
#define EXEC_FLAG_REWIND 0x0002 /* need efficient rescan */
#define EXEC_FLAG_BACKWARD 0x0004 /* need backward scan */
#define EXEC_FLAG_MARK 0x0008 /* need mark/restore */
-#define EXEC_FLAG_SKIP_TRIGGERS 0x0010 /* skip AfterTrigger calls */
+#define EXEC_FLAG_SKIP_TRIGGERS 0x0010 /* skip AfterTrigger calls */
/*
@@ -153,7 +153,7 @@ extern JunkFilter *ExecInitJunkFilterConversion(List *targetList,
extern AttrNumber ExecFindJunkAttribute(JunkFilter *junkfilter,
const char *attrName);
extern AttrNumber ExecFindJunkAttributeInTlist(List *targetlist,
- const char *attrName);
+ const char *attrName);
extern Datum ExecGetJunkAttribute(TupleTableSlot *slot, AttrNumber attno,
bool *isNull);
extern TupleTableSlot *ExecFilterJunk(JunkFilter *junkfilter,
@@ -194,7 +194,7 @@ extern HeapTuple EvalPlanQualFetch(EState *estate, Relation relation,
extern void EvalPlanQualInit(EPQState *epqstate, EState *estate,
Plan *subplan, List *auxrowmarks, int epqParam);
extern void EvalPlanQualSetPlan(EPQState *epqstate,
- Plan *subplan, List *auxrowmarks);
+ Plan *subplan, List *auxrowmarks);
extern void EvalPlanQualSetTuple(EPQState *epqstate, Index rti,
HeapTuple tuple);
extern HeapTuple EvalPlanQualGetTuple(EPQState *epqstate, Index rti);
diff --git a/src/include/executor/functions.h b/src/include/executor/functions.h
index b926e99cbb..aaa36c5826 100644
--- a/src/include/executor/functions.h
+++ b/src/include/executor/functions.h
@@ -27,7 +27,7 @@ extern SQLFunctionParseInfoPtr prepare_sql_fn_parse_info(HeapTuple procedureTupl
Oid inputCollation);
extern void sql_fn_parser_setup(struct ParseState *pstate,
- SQLFunctionParseInfoPtr pinfo);
+ SQLFunctionParseInfoPtr pinfo);
extern bool check_sql_fn_retval(Oid func_id, Oid rettype,
List *queryTreeList,
diff --git a/src/include/executor/hashjoin.h b/src/include/executor/hashjoin.h
index 5ea165434a..0c6e06f8ff 100644
--- a/src/include/executor/hashjoin.h
+++ b/src/include/executor/hashjoin.h
@@ -67,7 +67,7 @@ typedef struct HashJoinTupleData
struct HashJoinTupleData *next; /* link to next tuple in same bucket */
uint32 hashvalue; /* tuple's hash code */
/* Tuple data, in MinimalTuple format, follows on a MAXALIGN boundary */
-} HashJoinTupleData;
+} HashJoinTupleData;
#define HJTUPLE_OVERHEAD MAXALIGN(sizeof(HashJoinTupleData))
#define HJTUPLE_MINTUPLE(hjtup) \
@@ -158,6 +158,6 @@ typedef struct HashJoinTableData
MemoryContext hashCxt; /* context for whole-hash-join storage */
MemoryContext batchCxt; /* context for this-batch-only storage */
-} HashJoinTableData;
+} HashJoinTableData;
#endif /* HASHJOIN_H */
diff --git a/src/include/executor/nodeHash.h b/src/include/executor/nodeHash.h
index 4810f4be5e..2c3c1b534b 100644
--- a/src/include/executor/nodeHash.h
+++ b/src/include/executor/nodeHash.h
@@ -23,7 +23,7 @@ extern void ExecEndHash(HashState *node);
extern void ExecReScanHash(HashState *node);
extern HashJoinTable ExecHashTableCreate(Hash *node, List *hashOperators,
- bool keepNulls);
+ bool keepNulls);
extern void ExecHashTableDestroy(HashJoinTable hashtable);
extern void ExecHashTableInsert(HashJoinTable hashtable,
TupleTableSlot *slot,
@@ -41,7 +41,7 @@ extern void ExecHashGetBucketAndBatch(HashJoinTable hashtable,
extern bool ExecScanHashBucket(HashJoinState *hjstate, ExprContext *econtext);
extern void ExecPrepHashTableForUnmatched(HashJoinState *hjstate);
extern bool ExecScanHashTableForUnmatched(HashJoinState *hjstate,
- ExprContext *econtext);
+ ExprContext *econtext);
extern void ExecHashTableReset(HashJoinTable hashtable);
extern void ExecHashTableResetMatchFlags(HashJoinTable hashtable);
extern void ExecChooseHashTableSize(double ntuples, int tupwidth, bool useskew,
diff --git a/src/include/fmgr.h b/src/include/fmgr.h
index 9e5224d374..e58060f834 100644
--- a/src/include/fmgr.h
+++ b/src/include/fmgr.h
@@ -458,9 +458,9 @@ extern Datum DirectFunctionCall9(PGFunction func, Datum arg1, Datum arg2,
/* The same, but passing a collation to use */
extern Datum DirectFunctionCall1WithCollation(PGFunction func, Oid collation,
- Datum arg1);
+ Datum arg1);
extern Datum DirectFunctionCall2WithCollation(PGFunction func, Oid collation,
- Datum arg1, Datum arg2);
+ Datum arg1, Datum arg2);
/* These are for invocation of a previously-looked-up function with a
* directly-computed parameter list. Note that neither arguments nor result
@@ -573,7 +573,7 @@ extern int AggCheckCallContext(FunctionCallInfo fcinfo,
* We allow plugin modules to hook function entry/exit. This is intended
* as support for loadable security policy modules, which may want to
* perform additional privilege checks on function entry or exit, or to do
- * other internal bookkeeping. To make this possible, such modules must be
+ * other internal bookkeeping. To make this possible, such modules must be
* able not only to support normal function entry and exit, but also to trap
* the case where we bail out due to an error; and they must also be able to
* prevent inlining.
@@ -585,13 +585,13 @@ typedef enum FmgrHookEventType
FHET_ABORT
} FmgrHookEventType;
-typedef bool (*needs_fmgr_hook_type)(Oid fn_oid);
+typedef bool (*needs_fmgr_hook_type) (Oid fn_oid);
-typedef void (*fmgr_hook_type)(FmgrHookEventType event,
- FmgrInfo *flinfo, Datum *arg);
+typedef void (*fmgr_hook_type) (FmgrHookEventType event,
+ FmgrInfo *flinfo, Datum *arg);
-extern PGDLLIMPORT needs_fmgr_hook_type needs_fmgr_hook;
-extern PGDLLIMPORT fmgr_hook_type fmgr_hook;
+extern PGDLLIMPORT needs_fmgr_hook_type needs_fmgr_hook;
+extern PGDLLIMPORT fmgr_hook_type fmgr_hook;
#define FmgrHookIsNeeded(fn_oid) \
(!needs_fmgr_hook ? false : (*needs_fmgr_hook)(fn_oid))
diff --git a/src/include/foreign/fdwapi.h b/src/include/foreign/fdwapi.h
index 2873187388..3378ba9ade 100644
--- a/src/include/foreign/fdwapi.h
+++ b/src/include/foreign/fdwapi.h
@@ -27,11 +27,11 @@ typedef struct FdwPlan
NodeTag type;
/*
- * Cost estimation info. The startup_cost is time before retrieving
- * the first row, so it should include costs of connecting to the remote
- * host, sending over the query, etc. Note that PlanForeignScan also
- * ought to set baserel->rows and baserel->width if it can produce any
- * usable estimates of those values.
+ * Cost estimation info. The startup_cost is time before retrieving the
+ * first row, so it should include costs of connecting to the remote host,
+ * sending over the query, etc. Note that PlanForeignScan also ought to
+ * set baserel->rows and baserel->width if it can produce any usable
+ * estimates of those values.
*/
Cost startup_cost; /* cost expended before fetching any tuples */
Cost total_cost; /* total cost (assuming all tuples fetched) */
@@ -39,10 +39,10 @@ typedef struct FdwPlan
/*
* FDW private data, which will be available at execution time.
*
- * Note that everything in this list must be copiable by copyObject().
- * One way to store an arbitrary blob of bytes is to represent it as a
- * bytea Const. Usually, though, you'll be better off choosing a
- * representation that can be dumped usefully by nodeToString().
+ * Note that everything in this list must be copiable by copyObject(). One
+ * way to store an arbitrary blob of bytes is to represent it as a bytea
+ * Const. Usually, though, you'll be better off choosing a representation
+ * that can be dumped usefully by nodeToString().
*/
List *fdw_private;
} FdwPlan;
@@ -52,17 +52,17 @@ typedef struct FdwPlan
* Callback function signatures --- see fdwhandler.sgml for more info.
*/
-typedef FdwPlan * (*PlanForeignScan_function) (Oid foreigntableid,
- PlannerInfo *root,
- RelOptInfo *baserel);
+typedef FdwPlan *(*PlanForeignScan_function) (Oid foreigntableid,
+ PlannerInfo *root,
+ RelOptInfo *baserel);
typedef void (*ExplainForeignScan_function) (ForeignScanState *node,
- struct ExplainState *es);
+ struct ExplainState *es);
typedef void (*BeginForeignScan_function) (ForeignScanState *node,
- int eflags);
+ int eflags);
-typedef TupleTableSlot * (*IterateForeignScan_function) (ForeignScanState *node);
+typedef TupleTableSlot *(*IterateForeignScan_function) (ForeignScanState *node);
typedef void (*ReScanForeignScan_function) (ForeignScanState *node);
diff --git a/src/include/foreign/foreign.h b/src/include/foreign/foreign.h
index 2fda9e39fe..2c436aef80 100644
--- a/src/include/foreign/foreign.h
+++ b/src/include/foreign/foreign.h
@@ -76,7 +76,7 @@ extern ForeignDataWrapper *GetForeignDataWrapperByName(const char *name,
bool missing_ok);
extern ForeignTable *GetForeignTable(Oid relid);
-extern Oid get_foreign_data_wrapper_oid(const char *fdwname, bool missing_ok);
-extern Oid get_foreign_server_oid(const char *servername, bool missing_ok);
+extern Oid get_foreign_data_wrapper_oid(const char *fdwname, bool missing_ok);
+extern Oid get_foreign_server_oid(const char *servername, bool missing_ok);
#endif /* FOREIGN_H */
diff --git a/src/include/libpq/auth.h b/src/include/libpq/auth.h
index 7d15b73370..884daf59ec 100644
--- a/src/include/libpq/auth.h
+++ b/src/include/libpq/auth.h
@@ -25,7 +25,7 @@ extern char *pg_krb_realm;
extern void ClientAuthentication(Port *port);
/* Hook for plugins to get control in ClientAuthentication() */
-typedef void (*ClientAuthentication_hook_type)(Port *, int);
+typedef void (*ClientAuthentication_hook_type) (Port *, int);
extern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;
#endif /* AUTH_H */
diff --git a/src/include/libpq/libpq-be.h b/src/include/libpq/libpq-be.h
index 4cdb15f064..77e190fd1a 100644
--- a/src/include/libpq/libpq-be.h
+++ b/src/include/libpq/libpq-be.h
@@ -109,10 +109,14 @@ typedef struct Port
SockAddr laddr; /* local addr (postmaster) */
SockAddr raddr; /* remote addr (client) */
char *remote_host; /* name (or ip addr) of remote host */
- char *remote_hostname; /* name (not ip addr) of remote host, if available */
- int remote_hostname_resolv; /* +1 = remote_hostname is known to resolve to client's IP address;
- -1 = remote_hostname is known NOT to resolve to client's IP address;
- 0 = we have not done the forward DNS lookup yet */
+ char *remote_hostname;/* name (not ip addr) of remote host, if
+ * available */
+ int remote_hostname_resolv; /* +1 = remote_hostname is known to
+ * resolve to client's IP address; -1
+ * = remote_hostname is known NOT to
+ * resolve to client's IP address; 0 =
+ * we have not done the forward DNS
+ * lookup yet */
char *remote_port; /* text rep of remote port */
CAC_state canAcceptConnections; /* postmaster connection status */
diff --git a/src/include/libpq/libpq.h b/src/include/libpq/libpq.h
index 2df735f61f..38f96af5cd 100644
--- a/src/include/libpq/libpq.h
+++ b/src/include/libpq/libpq.h
@@ -61,7 +61,7 @@ extern int pq_getbyte_if_available(unsigned char *c);
extern int pq_putbytes(const char *s, size_t len);
extern int pq_flush(void);
extern int pq_flush_if_writable(void);
-extern bool pq_is_send_pending(void);
+extern bool pq_is_send_pending(void);
extern int pq_putmessage(char msgtype, const char *s, size_t len);
extern void pq_putmessage_noblock(char msgtype, const char *s, size_t len);
extern void pq_startcopyout(void);
diff --git a/src/include/nodes/execnodes.h b/src/include/nodes/execnodes.h
index a2dcc68145..9c688c0368 100644
--- a/src/include/nodes/execnodes.h
+++ b/src/include/nodes/execnodes.h
@@ -380,7 +380,7 @@ typedef struct EState
List *es_subplanstates; /* List of PlanState for SubPlans */
- List *es_auxmodifytables; /* List of secondary ModifyTableStates */
+ List *es_auxmodifytables; /* List of secondary ModifyTableStates */
/*
* this ExprContext is for per-output-tuple operations, such as constraint
@@ -489,7 +489,7 @@ typedef struct TupleHashTableData
TupleTableSlot *inputslot; /* current input tuple's slot */
FmgrInfo *in_hash_funcs; /* hash functions for input datatype(s) */
FmgrInfo *cur_eq_funcs; /* equality functions for input vs. table */
-} TupleHashTableData;
+} TupleHashTableData;
typedef HASH_SEQ_STATUS TupleHashIterator;
@@ -718,7 +718,7 @@ typedef struct SubPlanState
TupleHashTable hashnulls; /* hash table for rows with null(s) */
bool havehashrows; /* TRUE if hashtable is not empty */
bool havenullrows; /* TRUE if hashnulls is not empty */
- MemoryContext hashtablecxt; /* memory context containing hash tables */
+ MemoryContext hashtablecxt; /* memory context containing hash tables */
MemoryContext hashtempcxt; /* temp memory context for hash tables */
ExprContext *innerecontext; /* econtext for computing inner tuples */
AttrNumber *keyColIdx; /* control data for hash tables */
@@ -1051,7 +1051,7 @@ typedef struct ModifyTableState
PlanState **mt_plans; /* subplans (one per target rel) */
int mt_nplans; /* number of plans in the array */
int mt_whichplan; /* which one is being executed (0..n-1) */
- ResultRelInfo *resultRelInfo; /* per-subplan target relations */
+ ResultRelInfo *resultRelInfo; /* per-subplan target relations */
List **mt_arowmarks; /* per-subplan ExecAuxRowMark lists */
EPQState mt_epqstate; /* for evaluating EvalPlanQual rechecks */
bool fireBSTriggers; /* do we need to fire stmt triggers? */
@@ -1093,9 +1093,9 @@ typedef struct MergeAppendState
int ms_nkeys;
ScanKey ms_scankeys; /* array of length ms_nkeys */
TupleTableSlot **ms_slots; /* array of length ms_nplans */
- int *ms_heap; /* array of length ms_nplans */
+ int *ms_heap; /* array of length ms_nplans */
int ms_heap_size; /* current active length of ms_heap[] */
- bool ms_initialized; /* are subplans started? */
+ bool ms_initialized; /* are subplans started? */
int ms_last_slot; /* last subplan slot we returned from */
} MergeAppendState;
diff --git a/src/include/nodes/makefuncs.h b/src/include/nodes/makefuncs.h
index 152cb0de2b..61314608f5 100644
--- a/src/include/nodes/makefuncs.h
+++ b/src/include/nodes/makefuncs.h
@@ -31,7 +31,7 @@ extern Var *makeVar(Index varno,
Index varlevelsup);
extern Var *makeVarFromTargetEntry(Index varno,
- TargetEntry *tle);
+ TargetEntry *tle);
extern Var *makeWholeRowVar(RangeTblEntry *rte,
Index varno,
@@ -63,7 +63,7 @@ extern Expr *makeBoolExpr(BoolExprType boolop, List *args, int location);
extern Alias *makeAlias(const char *aliasname, List *colnames);
extern RelabelType *makeRelabelType(Expr *arg, Oid rtype, int32 rtypmod,
- Oid rcollid, CoercionForm rformat);
+ Oid rcollid, CoercionForm rformat);
extern RangeVar *makeRangeVar(char *schemaname, char *relname, int location);
diff --git a/src/include/nodes/params.h b/src/include/nodes/params.h
index 824816e53d..cf9a788019 100644
--- a/src/include/nodes/params.h
+++ b/src/include/nodes/params.h
@@ -72,7 +72,7 @@ typedef struct ParamListInfoData
void *parserSetupArg;
int numParams; /* number of ParamExternDatas following */
ParamExternData params[1]; /* VARIABLE LENGTH ARRAY */
-} ParamListInfoData;
+} ParamListInfoData;
/* ----------------
diff --git a/src/include/nodes/parsenodes.h b/src/include/nodes/parsenodes.h
index d9eac766f0..566cd3af76 100644
--- a/src/include/nodes/parsenodes.h
+++ b/src/include/nodes/parsenodes.h
@@ -148,7 +148,7 @@ typedef struct Query
Node *setOperations; /* set-operation tree if this is top level of
* a UNION/INTERSECT/EXCEPT query */
- List *constraintDeps; /* a list of pg_constraint OIDs that the query
+ List *constraintDeps; /* a list of pg_constraint OIDs that the query
* depends on to be semantically valid */
} Query;
@@ -724,14 +724,14 @@ typedef struct RangeTblEntry
* Fields valid for a function RTE (else NULL):
*
* If the function returns RECORD, funccoltypes lists the column types
- * declared in the RTE's column type specification, funccoltypmods
- * lists their declared typmods, funccolcollations their collations.
- * Otherwise, those fields are NIL.
+ * declared in the RTE's column type specification, funccoltypmods lists
+ * their declared typmods, funccolcollations their collations. Otherwise,
+ * those fields are NIL.
*/
Node *funcexpr; /* expression tree for func call */
List *funccoltypes; /* OID list of column type OIDs */
List *funccoltypmods; /* integer list of column typmods */
- List *funccolcollations; /* OID list of column collation OIDs */
+ List *funccolcollations; /* OID list of column collation OIDs */
/*
* Fields valid for a values RTE (else NIL):
@@ -746,7 +746,7 @@ typedef struct RangeTblEntry
bool self_reference; /* is this a recursive self-reference? */
List *ctecoltypes; /* OID list of column type OIDs */
List *ctecoltypmods; /* integer list of column typmods */
- List *ctecolcollations; /* OID list of column collation OIDs */
+ List *ctecolcollations; /* OID list of column collation OIDs */
/*
* Fields valid in all RTEs:
@@ -789,7 +789,7 @@ typedef struct RangeTblEntry
* here, but it's cheap to get it along with the sortop, and requiring it
* to be valid eases comparisons to grouping items.) Note that this isn't
* actually enough information to determine an ordering: if the sortop is
- * collation-sensitive, a collation OID is needed too. We don't store the
+ * collation-sensitive, a collation OID is needed too. We don't store the
* collation in SortGroupClause because it's not available at the time the
* parser builds the SortGroupClause; instead, consult the exposed collation
* of the referenced targetlist expression to find out what it is.
@@ -914,7 +914,7 @@ typedef struct CommonTableExpr
List *ctecolnames; /* list of output column names */
List *ctecoltypes; /* OID list of output column type OIDs */
List *ctecoltypmods; /* integer list of output column typmods */
- List *ctecolcollations; /* OID list of column collation OIDs */
+ List *ctecolcollations; /* OID list of column collation OIDs */
} CommonTableExpr;
/* Convenience macro to get the output tlist of a CTE's query */
@@ -1102,7 +1102,7 @@ typedef struct SetOperationStmt
typedef enum ObjectType
{
OBJECT_AGGREGATE,
- OBJECT_ATTRIBUTE, /* type's attribute, when distinct from column */
+ OBJECT_ATTRIBUTE, /* type's attribute, when distinct from column */
OBJECT_CAST,
OBJECT_COLUMN,
OBJECT_CONSTRAINT,
@@ -2040,7 +2040,7 @@ typedef struct FetchStmt
*
* This represents creation of an index and/or an associated constraint.
* If indexOid isn't InvalidOid, we are not creating an index, just a
- * UNIQUE/PKEY constraint using an existing index. isconstraint must always
+ * UNIQUE/PKEY constraint using an existing index. isconstraint must always
* be true in this case, and the fields describing the index properties are
* empty.
* ----------------------
@@ -2319,8 +2319,8 @@ typedef struct AlterEnumStmt
NodeTag type;
List *typeName; /* qualified name (list of Value strings) */
char *newVal; /* new enum value's name */
- char *newValNeighbor; /* neighboring enum value, if specified */
- bool newValIsAfter; /* place new enum value after neighbor? */
+ char *newValNeighbor; /* neighboring enum value, if specified */
+ bool newValIsAfter; /* place new enum value after neighbor? */
} AlterEnumStmt;
/* ----------------------
diff --git a/src/include/nodes/pg_list.h b/src/include/nodes/pg_list.h
index e5dd04bd1c..38b94aaa01 100644
--- a/src/include/nodes/pg_list.h
+++ b/src/include/nodes/pg_list.h
@@ -184,7 +184,7 @@ extern int list_length(List *l);
/*
* forthree -
- * the same for three lists
+ * the same for three lists
*/
#define forthree(cell1, list1, cell2, list2, cell3, list3) \
for ((cell1) = list_head(list1), (cell2) = list_head(list2), (cell3) = list_head(list3); \
diff --git a/src/include/nodes/plannodes.h b/src/include/nodes/plannodes.h
index 764fc36521..7c085b3f4f 100644
--- a/src/include/nodes/plannodes.h
+++ b/src/include/nodes/plannodes.h
@@ -171,7 +171,7 @@ typedef struct ModifyTable
CmdType operation; /* INSERT, UPDATE, or DELETE */
bool canSetTag; /* do we set the command tag/es_processed? */
List *resultRelations; /* integer list of RT indexes */
- int resultRelIndex; /* index of first resultRel in plan's list */
+ int resultRelIndex; /* index of first resultRel in plan's list */
List *plans; /* plan(s) producing source data */
List *returningLists; /* per-target-table RETURNING tlists */
List *rowMarks; /* PlanRowMarks (non-locking only) */
@@ -296,7 +296,7 @@ typedef Scan SeqScan;
* that are being implemented by the index, while indexorderby is modified to
* have index column Vars on the left-hand side. Here, multiple expressions
* must appear in exactly the ORDER BY order, and this is not necessarily the
- * index column order. Only the expressions are provided, not the auxiliary
+ * index column order. Only the expressions are provided, not the auxiliary
* sort-order information from the ORDER BY SortGroupClauses; it's assumed
* that the sort ordering is fully determinable from the top-level operators.
* indexorderbyorig is unused at run time, but is needed for EXPLAIN.
@@ -309,8 +309,8 @@ typedef struct IndexScan
Oid indexid; /* OID of index to scan */
List *indexqual; /* list of index quals (usually OpExprs) */
List *indexqualorig; /* the same in original form */
- List *indexorderby; /* list of index ORDER BY exprs */
- List *indexorderbyorig; /* the same in original form */
+ List *indexorderby; /* list of index ORDER BY exprs */
+ List *indexorderbyorig; /* the same in original form */
ScanDirection indexorderdir; /* forward or backward or don't care */
} IndexScan;
@@ -406,7 +406,7 @@ typedef struct FunctionScan
List *funccolnames; /* output column names (string Value nodes) */
List *funccoltypes; /* OID list of column type OIDs */
List *funccoltypmods; /* integer list of column typmods */
- List *funccolcollations; /* OID list of column collation OIDs */
+ List *funccolcollations; /* OID list of column collation OIDs */
} FunctionScan;
/* ----------------
diff --git a/src/include/nodes/primnodes.h b/src/include/nodes/primnodes.h
index 47e5719321..f1e20ef937 100644
--- a/src/include/nodes/primnodes.h
+++ b/src/include/nodes/primnodes.h
@@ -74,7 +74,7 @@ typedef struct RangeVar
char *relname; /* the relation/sequence name */
InhOption inhOpt; /* expand rel by inheritance? recursively act
* on children? */
- char relpersistence; /* see RELPERSISTENCE_* in pg_class.h */
+ char relpersistence; /* see RELPERSISTENCE_* in pg_class.h */
Alias *alias; /* table alias & optional column aliases */
int location; /* token location, or -1 if unknown */
} RangeVar;
@@ -565,7 +565,8 @@ typedef struct SubPlan
/* Extra data useful for determining subplan's output type: */
Oid firstColType; /* Type of first column of subplan result */
int32 firstColTypmod; /* Typmod of first column of subplan result */
- Oid firstColCollation; /* Collation of first column of subplan result */
+ Oid firstColCollation; /* Collation of first column of
+ * subplan result */
/* Information about execution strategy: */
bool useHashTable; /* TRUE to store subselect output in a hash
* table (implies we are doing "IN") */
@@ -909,7 +910,7 @@ typedef struct CoalesceExpr
{
Expr xpr;
Oid coalescetype; /* type of expression result */
- Oid coalescecollid; /* OID of collation, or InvalidOid if none */
+ Oid coalescecollid; /* OID of collation, or InvalidOid if none */
List *args; /* the arguments */
int location; /* token location, or -1 if unknown */
} CoalesceExpr;
@@ -942,7 +943,7 @@ typedef struct MinMaxExpr
* 'args' carries all other arguments.
*
* Note: result type/typmod/collation are not stored, but can be deduced
- * from the XmlExprOp. The type/typmod fields are just used for display
+ * from the XmlExprOp. The type/typmod fields are just used for display
* purposes, and are NOT the true result type of the node.
*/
typedef enum XmlExprOp
diff --git a/src/include/nodes/relation.h b/src/include/nodes/relation.h
index ab7ae2ebbd..78b03e024e 100644
--- a/src/include/nodes/relation.h
+++ b/src/include/nodes/relation.h
@@ -215,8 +215,8 @@ typedef struct PlannerInfo
struct Plan *non_recursive_plan; /* plan for non-recursive term */
/* These fields are workspace for createplan.c */
- Relids curOuterRels; /* outer rels above current node */
- List *curOuterParams; /* not-yet-assigned NestLoopParams */
+ Relids curOuterRels; /* outer rels above current node */
+ List *curOuterParams; /* not-yet-assigned NestLoopParams */
/* optional private data for join_search_hook, e.g., GEQO */
void *join_search_private;
@@ -472,7 +472,7 @@ typedef struct IndexOptInfo
bool predOK; /* true if predicate matches query */
bool unique; /* true if a unique index */
bool hypothetical; /* true if index doesn't really exist */
- bool amcanorderbyop; /* does AM support order by operator result? */
+ bool amcanorderbyop; /* does AM support order by operator result? */
bool amoptionalkey; /* can query omit key for the first column? */
bool amsearchnulls; /* can AM search for NULL/NOT NULL entries? */
bool amhasgettuple; /* does AM have amgettuple interface? */
@@ -492,7 +492,7 @@ typedef struct IndexOptInfo
* equal to each other, where "equal" is according to the rules of the btree
* operator family(s) shown in ec_opfamilies, as well as the collation shown
* by ec_collation. (We restrict an EC to contain only equalities whose
- * operators belong to the same set of opfamilies. This could probably be
+ * operators belong to the same set of opfamilies. This could probably be
* relaxed, but for now it's not worth the trouble, since nearly all equality
* operators belong to only one btree opclass anyway. Similarly, we suppose
* that all or none of the input datatypes are collatable, so that a single
@@ -1436,7 +1436,7 @@ typedef struct MinMaxAggInfo
* to do so for Param slots. Duplicate detection is actually *necessary*
* in the case of NestLoop parameters since it serves to match up the usage
* of a Param (in the inner scan) with the assignment of the value (in the
- * NestLoop node). This might result in the same PARAM_EXEC slot being used
+ * NestLoop node). This might result in the same PARAM_EXEC slot being used
* by multiple NestLoop nodes or SubPlan nodes, but no harm is done since
* the same value would be assigned anyway.
*/
diff --git a/src/include/optimizer/cost.h b/src/include/optimizer/cost.h
index e3cf7464df..08898c13b9 100644
--- a/src/include/optimizer/cost.h
+++ b/src/include/optimizer/cost.h
@@ -34,7 +34,7 @@ typedef enum
CONSTRAINT_EXCLUSION_OFF, /* do not use c_e */
CONSTRAINT_EXCLUSION_ON, /* apply c_e to all rels */
CONSTRAINT_EXCLUSION_PARTITION /* apply c_e to otherrels only */
-} ConstraintExclusionType;
+} ConstraintExclusionType;
/*
diff --git a/src/include/optimizer/pathnode.h b/src/include/optimizer/pathnode.h
index 7a24da2c51..1da2131b09 100644
--- a/src/include/optimizer/pathnode.h
+++ b/src/include/optimizer/pathnode.h
@@ -49,9 +49,9 @@ extern TidPath *create_tidscan_path(PlannerInfo *root, RelOptInfo *rel,
List *tidquals);
extern AppendPath *create_append_path(RelOptInfo *rel, List *subpaths);
extern MergeAppendPath *create_merge_append_path(PlannerInfo *root,
- RelOptInfo *rel,
- List *subpaths,
- List *pathkeys);
+ RelOptInfo *rel,
+ List *subpaths,
+ List *pathkeys);
extern ResultPath *create_result_path(List *quals);
extern MaterialPath *create_material_path(RelOptInfo *rel, Path *subpath);
extern UniquePath *create_unique_path(PlannerInfo *root, RelOptInfo *rel,
diff --git a/src/include/optimizer/paths.h b/src/include/optimizer/paths.h
index 5ff951e67e..7f1353a2a3 100644
--- a/src/include/optimizer/paths.h
+++ b/src/include/optimizer/paths.h
@@ -99,7 +99,7 @@ extern bool have_join_order_restriction(PlannerInfo *root,
extern bool process_equivalence(PlannerInfo *root, RestrictInfo *restrictinfo,
bool below_outer_join);
extern Expr *canonicalize_ec_expression(Expr *expr,
- Oid req_type, Oid req_collation);
+ Oid req_type, Oid req_collation);
extern void reconsider_outer_join_clauses(PlannerInfo *root);
extern EquivalenceClass *get_eclass_for_sort_expr(PlannerInfo *root,
Expr *expr,
@@ -164,9 +164,9 @@ extern List *make_pathkeys_for_sortclauses(PlannerInfo *root,
List *tlist,
bool canonicalize);
extern void initialize_mergeclause_eclasses(PlannerInfo *root,
- RestrictInfo *restrictinfo);
+ RestrictInfo *restrictinfo);
extern void update_mergeclause_eclasses(PlannerInfo *root,
- RestrictInfo *restrictinfo);
+ RestrictInfo *restrictinfo);
extern List *find_mergeclauses_for_pathkeys(PlannerInfo *root,
List *pathkeys,
bool outer_keys,
diff --git a/src/include/optimizer/placeholder.h b/src/include/optimizer/placeholder.h
index 976c5439ca..cce9e1ef1b 100644
--- a/src/include/optimizer/placeholder.h
+++ b/src/include/optimizer/placeholder.h
@@ -23,7 +23,7 @@ extern PlaceHolderInfo *find_placeholder_info(PlannerInfo *root,
PlaceHolderVar *phv);
extern void find_placeholders_in_jointree(PlannerInfo *root);
extern void update_placeholder_eval_levels(PlannerInfo *root,
- SpecialJoinInfo *new_sjinfo);
+ SpecialJoinInfo *new_sjinfo);
extern void fix_placeholder_input_needed_levels(PlannerInfo *root);
extern void add_placeholders_to_base_rels(PlannerInfo *root);
extern void add_placeholders_to_joinrel(PlannerInfo *root,
diff --git a/src/include/optimizer/subselect.h b/src/include/optimizer/subselect.h
index c437412149..ff9e2b7f89 100644
--- a/src/include/optimizer/subselect.h
+++ b/src/include/optimizer/subselect.h
@@ -28,7 +28,7 @@ extern Node *SS_process_sublinks(PlannerInfo *root, Node *expr, bool isQual);
extern void SS_finalize_plan(PlannerInfo *root, Plan *plan,
bool attach_initplans);
extern Param *SS_make_initplan_from_plan(PlannerInfo *root, Plan *plan,
- Oid resulttype, int32 resulttypmod, Oid resultcollation);
+ Oid resulttype, int32 resulttypmod, Oid resultcollation);
extern Param *assign_nestloop_param(PlannerInfo *root, Var *var);
extern int SS_assign_special_param(PlannerInfo *root);
diff --git a/src/include/parser/parse_collate.h b/src/include/parser/parse_collate.h
index 20acb43504..4332ffc2b9 100644
--- a/src/include/parser/parse_collate.h
+++ b/src/include/parser/parse_collate.h
@@ -22,6 +22,6 @@ extern void assign_list_collations(ParseState *pstate, List *exprs);
extern void assign_expr_collations(ParseState *pstate, Node *expr);
-extern Oid select_common_collation(ParseState *pstate, List *exprs, bool none_ok);
+extern Oid select_common_collation(ParseState *pstate, List *exprs, bool none_ok);
#endif /* PARSE_COLLATE_H */
diff --git a/src/include/parser/parse_func.h b/src/include/parser/parse_func.h
index a2011be52f..2fe6f90a2e 100644
--- a/src/include/parser/parse_func.h
+++ b/src/include/parser/parse_func.h
@@ -28,7 +28,7 @@ typedef struct _InhPaths
int nsupers; /* number of superclasses */
Oid self; /* this class */
Oid *supervec; /* vector of superclasses */
-} InhPaths;
+} InhPaths;
/* Result codes for func_get_detail */
typedef enum
diff --git a/src/include/parser/parse_type.h b/src/include/parser/parse_type.h
index 509e3b7f11..373acd8af7 100644
--- a/src/include/parser/parse_type.h
+++ b/src/include/parser/parse_type.h
@@ -23,15 +23,15 @@ extern Type LookupTypeName(ParseState *pstate, const TypeName *typeName,
int32 *typmod_p);
extern Type typenameType(ParseState *pstate, const TypeName *typeName,
int32 *typmod_p);
-extern Oid typenameTypeId(ParseState *pstate, const TypeName *typeName);
+extern Oid typenameTypeId(ParseState *pstate, const TypeName *typeName);
extern void typenameTypeIdAndMod(ParseState *pstate, const TypeName *typeName,
- Oid *typeid_p, int32 *typmod_p);
+ Oid *typeid_p, int32 *typmod_p);
extern char *TypeNameToString(const TypeName *typeName);
extern char *TypeNameListToString(List *typenames);
-extern Oid LookupCollation(ParseState *pstate, List *collnames, int location);
-extern Oid GetColumnDefCollation(ParseState *pstate, ColumnDef *coldef, Oid typeOid);
+extern Oid LookupCollation(ParseState *pstate, List *collnames, int location);
+extern Oid GetColumnDefCollation(ParseState *pstate, ColumnDef *coldef, Oid typeOid);
extern Type typeidType(Oid id);
diff --git a/src/include/parser/parser.h b/src/include/parser/parser.h
index 4d7f648568..21e2b0b126 100644
--- a/src/include/parser/parser.h
+++ b/src/include/parser/parser.h
@@ -23,7 +23,7 @@ typedef enum
BACKSLASH_QUOTE_OFF,
BACKSLASH_QUOTE_ON,
BACKSLASH_QUOTE_SAFE_ENCODING
-} BackslashQuoteType;
+} BackslashQuoteType;
/* GUC variables in scan.l (every one of these is a bad idea :-() */
extern int backslash_quote;
diff --git a/src/include/pgstat.h b/src/include/pgstat.h
index 1ab1ac838f..f04be95b45 100644
--- a/src/include/pgstat.h
+++ b/src/include/pgstat.h
@@ -24,7 +24,7 @@ typedef enum TrackFunctionsLevel
TRACK_FUNC_OFF,
TRACK_FUNC_PL,
TRACK_FUNC_ALL
-} TrackFunctionsLevel;
+} TrackFunctionsLevel;
/* ----------
* The types of backend -> collector messages
@@ -628,7 +628,7 @@ typedef struct PgBackendStatus
Oid st_databaseid;
Oid st_userid;
SockAddr st_clientaddr;
- char *st_clienthostname; /* MUST be null-terminated */
+ char *st_clienthostname; /* MUST be null-terminated */
/* Is backend currently waiting on an lmgr lock? */
bool st_waiting;
diff --git a/src/include/port/win32.h b/src/include/port/win32.h
index f442cca523..4fe7c61c75 100644
--- a/src/include/port/win32.h
+++ b/src/include/port/win32.h
@@ -4,8 +4,8 @@
#define WIN32_ONLY_COMPILER
#endif
-/*
- * Make sure _WIN32_WINNT has the minumum required value.
+/*
+ * Make sure _WIN32_WINNT has the minumum required value.
* Leave a higher value in place.
*/
#if defined(_WIN32_WINNT) && _WIN32_WINNT < 0x0501
@@ -27,7 +27,7 @@
#undef ERROR
-/*
+/*
* The Mingw64 headers choke if this is already defined - they
* define it themselves.
*/
@@ -365,7 +365,7 @@ typedef unsigned short mode_t;
/* see also S_IRGRP etc below */
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
#define S_ISREG(m) (((m) & S_IFMT) == S_IFREG)
-#endif /* __BORLANDC__ */
+#endif /* __BORLANDC__ */
#define F_OK 0
#define W_OK 2
@@ -393,8 +393,7 @@ typedef unsigned short mode_t;
#define _O_SHORT_LIVED O_SHORT_LIVED
#endif /* ifndef O_RANDOM */
#endif /* __BORLANDC__ */
-
-#endif /* WIN32_ONLY_COMPILER */
+#endif /* WIN32_ONLY_COMPILER */
/* These aren't provided by either MingW or MSVC */
#ifndef __BORLANDC__
@@ -406,4 +405,5 @@ typedef unsigned short mode_t;
#define S_IWOTH 0
#define S_IXOTH 0
#define S_IRWXO 0
-#endif /* __BORLANDC__ */
+
+#endif /* __BORLANDC__ */
diff --git a/src/include/replication/replnodes.h b/src/include/replication/replnodes.h
index 6fc037580f..e027f9203b 100644
--- a/src/include/replication/replnodes.h
+++ b/src/include/replication/replnodes.h
@@ -35,7 +35,7 @@ typedef enum ReplNodeTag
typedef struct IdentifySystemCmd
{
NodeTag type;
-} IdentifySystemCmd;
+} IdentifySystemCmd;
/* ----------------------
@@ -46,7 +46,7 @@ typedef struct BaseBackupCmd
{
NodeTag type;
List *options;
-} BaseBackupCmd;
+} BaseBackupCmd;
/* ----------------------
@@ -57,6 +57,6 @@ typedef struct StartReplicationCmd
{
NodeTag type;
XLogRecPtr startpoint;
-} StartReplicationCmd;
+} StartReplicationCmd;
#endif /* REPLNODES_H */
diff --git a/src/include/replication/syncrep.h b/src/include/replication/syncrep.h
index 728e2c8f2d..efbebbcc06 100644
--- a/src/include/replication/syncrep.h
+++ b/src/include/replication/syncrep.h
@@ -44,7 +44,7 @@ extern void SyncRepReleaseWaiters(void);
extern void SyncRepUpdateSyncStandbysDefined(void);
/* called by various procs */
-extern int SyncRepWakeQueue(bool all);
+extern int SyncRepWakeQueue(bool all);
extern bool check_synchronous_standby_names(char **newval, void **extra, GucSource source);
#endif /* _SYNCREP_H */
diff --git a/src/include/replication/walprotocol.h b/src/include/replication/walprotocol.h
index 9baca948a2..94146679fa 100644
--- a/src/include/replication/walprotocol.h
+++ b/src/include/replication/walprotocol.h
@@ -48,9 +48,9 @@ typedef struct
typedef struct
{
/*
- * The xlog locations that have been written, flushed, and applied
- * by standby-side. These may be invalid if the standby-side is unable
- * to or chooses not to report these.
+ * The xlog locations that have been written, flushed, and applied by
+ * standby-side. These may be invalid if the standby-side is unable to or
+ * chooses not to report these.
*/
XLogRecPtr write;
XLogRecPtr flush;
@@ -70,11 +70,11 @@ typedef struct
{
/*
* The current xmin and epoch from the standby, for Hot Standby feedback.
- * This may be invalid if the standby-side does not support feedback,
- * or Hot Standby is not yet available.
+ * This may be invalid if the standby-side does not support feedback, or
+ * Hot Standby is not yet available.
*/
- TransactionId xmin;
- uint32 epoch;
+ TransactionId xmin;
+ uint32 epoch;
/* Sender's system clock at the time of transmission */
TimestampTz sendTime;
diff --git a/src/include/replication/walreceiver.h b/src/include/replication/walreceiver.h
index 775232b6e6..816fa5ba72 100644
--- a/src/include/replication/walreceiver.h
+++ b/src/include/replication/walreceiver.h
@@ -17,7 +17,7 @@
#include "pgtime.h"
extern bool am_walreceiver;
-extern int wal_receiver_status_interval;
+extern int wal_receiver_status_interval;
extern bool hot_standby_feedback;
/*
@@ -52,17 +52,17 @@ typedef struct
pg_time_t startTime;
/*
- * receiveStart is the first byte position that will be received.
- * When startup process starts the walreceiver, it sets receiveStart
- * to the point where it wants the streaming to begin.
+ * receiveStart is the first byte position that will be received. When
+ * startup process starts the walreceiver, it sets receiveStart to the
+ * point where it wants the streaming to begin.
*/
XLogRecPtr receiveStart;
/*
* receivedUpto-1 is the last byte position that has already been
- * received. At the first startup of walreceiver, receivedUpto is
- * set to receiveStart. After that, walreceiver updates this whenever
- * it flushes the received WAL to disk.
+ * received. At the first startup of walreceiver, receivedUpto is set to
+ * receiveStart. After that, walreceiver updates this whenever it flushes
+ * the received WAL to disk.
*/
XLogRecPtr receivedUpto;
diff --git a/src/include/replication/walsender.h b/src/include/replication/walsender.h
index 2670a2e806..6ee8668d0a 100644
--- a/src/include/replication/walsender.h
+++ b/src/include/replication/walsender.h
@@ -25,7 +25,7 @@ typedef enum WalSndState
WALSNDSTATE_BACKUP,
WALSNDSTATE_CATCHUP,
WALSNDSTATE_STREAMING
-} WalSndState;
+} WalSndState;
/*
* Each walsender has a WalSnd struct in shared memory.
@@ -37,9 +37,9 @@ typedef struct WalSnd
XLogRecPtr sentPtr; /* WAL has been sent up to this point */
/*
- * The xlog locations that have been written, flushed, and applied
- * by standby-side. These may be invalid if the standby-side has not
- * offered values yet.
+ * The xlog locations that have been written, flushed, and applied by
+ * standby-side. These may be invalid if the standby-side has not offered
+ * values yet.
*/
XLogRecPtr write;
XLogRecPtr flush;
@@ -49,17 +49,17 @@ typedef struct WalSnd
slock_t mutex;
/*
- * Latch used by backends to wake up this walsender when it has work
- * to do.
+ * Latch used by backends to wake up this walsender when it has work to
+ * do.
*/
Latch latch;
/*
- * The priority order of the standby managed by this WALSender, as
- * listed in synchronous_standby_names, or 0 if not-listed.
- * Protected by SyncRepLock.
+ * The priority order of the standby managed by this WALSender, as listed
+ * in synchronous_standby_names, or 0 if not-listed. Protected by
+ * SyncRepLock.
*/
- int sync_standby_priority;
+ int sync_standby_priority;
} WalSnd;
extern WalSnd *MyWalSnd;
@@ -70,11 +70,11 @@ typedef struct
/*
* Synchronous replication queue. Protected by SyncRepLock.
*/
- SHM_QUEUE SyncRepQueue;
+ SHM_QUEUE SyncRepQueue;
/*
- * Current location of the head of the queue. All waiters should have
- * a waitLSN that follows this value. Protected by SyncRepLock.
+ * Current location of the head of the queue. All waiters should have a
+ * waitLSN that follows this value. Protected by SyncRepLock.
*/
XLogRecPtr lsn;
diff --git a/src/include/rewrite/rewriteSupport.h b/src/include/rewrite/rewriteSupport.h
index 11e8173454..77417ba034 100644
--- a/src/include/rewrite/rewriteSupport.h
+++ b/src/include/rewrite/rewriteSupport.h
@@ -22,7 +22,7 @@ extern bool IsDefinedRewriteRule(Oid owningRel, const char *ruleName);
extern void SetRelationRuleStatus(Oid relationId, bool relHasRules,
bool relIsBecomingView);
-extern Oid get_rewrite_oid(Oid relid, const char *rulename, bool missing_ok);
-extern Oid get_rewrite_oid_without_relid(const char *rulename, Oid *relid);
+extern Oid get_rewrite_oid(Oid relid, const char *rulename, bool missing_ok);
+extern Oid get_rewrite_oid_without_relid(const char *rulename, Oid *relid);
#endif /* REWRITESUPPORT_H */
diff --git a/src/include/storage/backendid.h b/src/include/storage/backendid.h
index b702da2435..ec0ebc6a65 100644
--- a/src/include/storage/backendid.h
+++ b/src/include/storage/backendid.h
@@ -22,6 +22,6 @@ typedef int BackendId; /* unique currently active backend identifier */
#define InvalidBackendId (-1)
-extern PGDLLIMPORT BackendId MyBackendId; /* backend id of this backend */
+extern PGDLLIMPORT BackendId MyBackendId; /* backend id of this backend */
#endif /* BACKENDID_H */
diff --git a/src/include/storage/buf_internals.h b/src/include/storage/buf_internals.h
index 0652bdf711..b7d4ea53a4 100644
--- a/src/include/storage/buf_internals.h
+++ b/src/include/storage/buf_internals.h
@@ -37,7 +37,8 @@
#define BM_JUST_DIRTIED (1 << 5) /* dirtied since write started */
#define BM_PIN_COUNT_WAITER (1 << 6) /* have waiter for sole pin */
#define BM_CHECKPOINT_NEEDED (1 << 7) /* must write for checkpoint */
-#define BM_PERMANENT (1 << 8) /* permanent relation (not unlogged) */
+#define BM_PERMANENT (1 << 8) /* permanent relation (not
+ * unlogged) */
typedef bits16 BufFlags;
diff --git a/src/include/storage/latch.h b/src/include/storage/latch.h
index f64e13bed2..03ec07119b 100644
--- a/src/include/storage/latch.h
+++ b/src/include/storage/latch.h
@@ -23,11 +23,11 @@
*/
typedef struct
{
- sig_atomic_t is_set;
- bool is_shared;
- int owner_pid;
+ sig_atomic_t is_set;
+ bool is_shared;
+ int owner_pid;
#ifdef WIN32
- HANDLE event;
+ HANDLE event;
#endif
} Latch;
@@ -39,10 +39,11 @@ extern void InitSharedLatch(volatile Latch *latch);
extern void OwnLatch(volatile Latch *latch);
extern void DisownLatch(volatile Latch *latch);
extern bool WaitLatch(volatile Latch *latch, long timeout);
-extern int WaitLatchOrSocket(volatile Latch *latch, pgsocket sock,
+extern int WaitLatchOrSocket(volatile Latch *latch, pgsocket sock,
bool forRead, bool forWrite, long timeout);
extern void SetLatch(volatile Latch *latch);
extern void ResetLatch(volatile Latch *latch);
+
#define TestLatch(latch) (((volatile Latch *) latch)->is_set)
/*
diff --git a/src/include/storage/pmsignal.h b/src/include/storage/pmsignal.h
index 0ca8ca0cc7..7606b0961c 100644
--- a/src/include/storage/pmsignal.h
+++ b/src/include/storage/pmsignal.h
@@ -29,7 +29,7 @@ typedef enum
PMSIGNAL_START_AUTOVAC_LAUNCHER, /* start an autovacuum launcher */
PMSIGNAL_START_AUTOVAC_WORKER, /* start an autovacuum worker */
PMSIGNAL_START_WALRECEIVER, /* start a walreceiver */
- PMSIGNAL_ADVANCE_STATE_MACHINE, /* advance postmaster's state machine */
+ PMSIGNAL_ADVANCE_STATE_MACHINE, /* advance postmaster's state machine */
NUM_PMSIGNALS /* Must be last value of enum! */
} PMSignalReason;
diff --git a/src/include/storage/predicate_internals.h b/src/include/storage/predicate_internals.h
index 0556125636..bd42004c2c 100644
--- a/src/include/storage/predicate_internals.h
+++ b/src/include/storage/predicate_internals.h
@@ -114,7 +114,7 @@ typedef struct PredXactListElementData
{
SHM_QUEUE link;
SERIALIZABLEXACT sxact;
-} PredXactListElementData;
+} PredXactListElementData;
typedef struct PredXactListElementData *PredXactListElement;
@@ -152,7 +152,7 @@ typedef struct PredXactListData
SERIALIZABLEXACT *OldCommittedSxact; /* shared copy of dummy sxact */
PredXactListElement element;
-} PredXactListData;
+} PredXactListData;
typedef struct PredXactListData *PredXactList;
@@ -176,7 +176,7 @@ typedef struct RWConflictData
SHM_QUEUE inLink; /* link for list of conflicts in to a sxact */
SERIALIZABLEXACT *sxactOut;
SERIALIZABLEXACT *sxactIn;
-} RWConflictData;
+} RWConflictData;
typedef struct RWConflictData *RWConflict;
@@ -187,7 +187,7 @@ typedef struct RWConflictPoolHeaderData
{
SHM_QUEUE availableList;
RWConflict element;
-} RWConflictPoolHeaderData;
+} RWConflictPoolHeaderData;
typedef struct RWConflictPoolHeaderData *RWConflictPoolHeader;
@@ -266,7 +266,7 @@ typedef struct PREDICATELOCKTARGETTAG
* version, before the reading transaction is obsolete, we need some way to
* prevent errors from reuse of a tuple ID. Rather than attempting to clean
* up the targets as the related tuples are pruned or vacuumed, we check the
- * xmin on access. This should be far less costly.
+ * xmin on access. This should be far less costly.
*/
typedef struct PREDICATELOCKTARGET PREDICATELOCKTARGET;
@@ -353,7 +353,7 @@ typedef enum PredicateLockTargetType
PREDLOCKTAG_PAGE,
PREDLOCKTAG_TUPLE
/* TODO SSI: Other types may be needed for index locking */
-} PredicateLockTargetType;
+} PredicateLockTargetType;
/*
@@ -419,7 +419,7 @@ typedef enum TwoPhasePredicateRecordType
{
TWOPHASEPREDICATERECORD_XACT,
TWOPHASEPREDICATERECORD_LOCK
-} TwoPhasePredicateRecordType;
+} TwoPhasePredicateRecordType;
/*
* Per-transaction information to reconstruct a SERIALIZABLEXACT. Not
diff --git a/src/include/storage/proc.h b/src/include/storage/proc.h
index f2e063c6cb..4819cb8110 100644
--- a/src/include/storage/proc.h
+++ b/src/include/storage/proc.h
@@ -124,10 +124,10 @@ struct PGPROC
* syncRepState must not be touched except by owning process or WALSender.
* syncRepLinks used only while holding SyncRepLock.
*/
- Latch waitLatch; /* allow us to wait for sync rep */
- XLogRecPtr waitLSN; /* waiting for this LSN or higher */
- int syncRepState; /* wait state for sync rep */
- SHM_QUEUE syncRepLinks; /* list link if process is in syncrep queue */
+ Latch waitLatch; /* allow us to wait for sync rep */
+ XLogRecPtr waitLSN; /* waiting for this LSN or higher */
+ int syncRepState; /* wait state for sync rep */
+ SHM_QUEUE syncRepLinks; /* list link if process is in syncrep queue */
/*
* All PROCLOCK objects for locks held or awaited by this backend are
diff --git a/src/include/storage/procarray.h b/src/include/storage/procarray.h
index 334f9a25c1..3c20fc48f6 100644
--- a/src/include/storage/procarray.h
+++ b/src/include/storage/procarray.h
@@ -60,7 +60,7 @@ extern VirtualTransactionId *GetCurrentVirtualXIDs(TransactionId limitXmin,
extern VirtualTransactionId *GetConflictingVirtualXIDs(TransactionId limitXmin, Oid dbOid);
extern pid_t CancelVirtualTransaction(VirtualTransactionId vxid, ProcSignalReason sigmode);
-extern bool MinimumActiveBackends(int min);
+extern bool MinimumActiveBackends(int min);
extern int CountDBBackends(Oid databaseid);
extern void CancelDBBackends(Oid databaseid, ProcSignalReason sigmode, bool conflictPending);
extern int CountUserBackends(Oid roleid);
diff --git a/src/include/storage/relfilenode.h b/src/include/storage/relfilenode.h
index d8eb4c6be9..659a339e61 100644
--- a/src/include/storage/relfilenode.h
+++ b/src/include/storage/relfilenode.h
@@ -28,7 +28,7 @@ typedef enum ForkNumber
MAIN_FORKNUM = 0,
FSM_FORKNUM,
VISIBILITYMAP_FORKNUM,
- INIT_FORKNUM
+ INIT_FORKNUM
/*
* NOTE: if you add a new fork, change MAX_FORKNUM below and update the
@@ -83,7 +83,7 @@ typedef struct RelFileNode
*/
typedef struct RelFileNodeBackend
{
- RelFileNode node;
+ RelFileNode node;
BackendId backend;
} RelFileNodeBackend;
diff --git a/src/include/tsearch/dicts/spell.h b/src/include/tsearch/dicts/spell.h
index 86c7e748e3..f59b30fcab 100644
--- a/src/include/tsearch/dicts/spell.h
+++ b/src/include/tsearch/dicts/spell.h
@@ -152,10 +152,10 @@ typedef struct
bool usecompound;
/*
- * Remaining fields are only used during dictionary construction;
- * they are set up by NIStartBuild and cleared by NIFinishBuild.
+ * Remaining fields are only used during dictionary construction; they are
+ * set up by NIStartBuild and cleared by NIFinishBuild.
*/
- MemoryContext buildCxt; /* temp context for construction */
+ MemoryContext buildCxt; /* temp context for construction */
/* Temporary array of all words in the dict file */
SPELL **Spell;
diff --git a/src/include/utils/acl.h b/src/include/utils/acl.h
index b28b764fd5..75bdaa5343 100644
--- a/src/include/utils/acl.h
+++ b/src/include/utils/acl.h
@@ -227,7 +227,7 @@ extern bool is_member_of_role(Oid member, Oid role);
extern bool is_member_of_role_nosuper(Oid member, Oid role);
extern bool is_admin_of_role(Oid member, Oid role);
extern void check_is_member_of_role(Oid member, Oid role);
-extern Oid get_role_oid(const char *rolname, bool missing_ok);
+extern Oid get_role_oid(const char *rolname, bool missing_ok);
extern void select_best_grantor(Oid roleId, AclMode privileges,
const Acl *acl, Oid ownerId,
diff --git a/src/include/utils/builtins.h b/src/include/utils/builtins.h
index 72b0cdea7f..14215db1b4 100644
--- a/src/include/utils/builtins.h
+++ b/src/include/utils/builtins.h
@@ -441,7 +441,7 @@ extern Datum pg_relation_filepath(PG_FUNCTION_ARGS);
/* genfile.c */
extern bytea *read_binary_file(const char *filename,
- int64 seek_offset, int64 bytes_to_read);
+ int64 seek_offset, int64 bytes_to_read);
extern Datum pg_stat_file(PG_FUNCTION_ARGS);
extern Datum pg_read_file(PG_FUNCTION_ARGS);
extern Datum pg_read_file_all(PG_FUNCTION_ARGS);
diff --git a/src/include/utils/bytea.h b/src/include/utils/bytea.h
index df247c40a9..b64a6fff66 100644
--- a/src/include/utils/bytea.h
+++ b/src/include/utils/bytea.h
@@ -21,7 +21,7 @@ typedef enum
{
BYTEA_OUTPUT_ESCAPE,
BYTEA_OUTPUT_HEX
-} ByteaOutputType;
+} ByteaOutputType;
extern int bytea_output; /* ByteaOutputType, but int for GUC enum */
diff --git a/src/include/utils/datetime.h b/src/include/utils/datetime.h
index 9911d20793..2880304fdb 100644
--- a/src/include/utils/datetime.h
+++ b/src/include/utils/datetime.h
@@ -328,7 +328,7 @@ extern int j2day(int jd);
extern bool CheckDateTokenTables(void);
extern void ConvertTimeZoneAbbrevs(TimeZoneAbbrevTable *tbl,
- struct tzEntry *abbrevs, int n);
+ struct tzEntry *abbrevs, int n);
extern void InstallTimeZoneAbbrevs(TimeZoneAbbrevTable *tbl);
extern Datum pg_timezone_abbrevs(PG_FUNCTION_ARGS);
diff --git a/src/include/utils/elog.h b/src/include/utils/elog.h
index 1f2a9f53c1..fb5ef1620b 100644
--- a/src/include/utils/elog.h
+++ b/src/include/utils/elog.h
@@ -203,7 +203,8 @@ __attribute__((format(printf, 2, 3)));
/* Support for constructing error strings separately from ereport() calls */
extern void pre_format_elog_string(int errnumber, const char *domain);
-extern char *format_elog_string(const char *fmt,...)
+extern char *
+format_elog_string(const char *fmt,...)
/* This extension allows gcc to check the format string for consistency with
the supplied arguments. */
__attribute__((format(printf, 1, 2)));
@@ -335,7 +336,7 @@ typedef enum
PGERROR_TERSE, /* single-line error messages */
PGERROR_DEFAULT, /* recommended style */
PGERROR_VERBOSE /* all the facts, ma'am */
-} PGErrorVerbosity;
+} PGErrorVerbosity;
extern int Log_error_verbosity;
extern char *Log_line_prefix;
diff --git a/src/include/utils/guc.h b/src/include/utils/guc.h
index 452310f2bd..5a42d8cec3 100644
--- a/src/include/utils/guc.h
+++ b/src/include/utils/guc.h
@@ -102,11 +102,11 @@ typedef enum
*/
typedef struct ConfigVariable
{
- char *name;
- char *value;
+ char *name;
+ char *value;
char *filename;
int sourceline;
- struct ConfigVariable *next;
+ struct ConfigVariable *next;
} ConfigVariable;
extern bool ParseConfigFile(const char *config_file, const char *calling_file,
diff --git a/src/include/utils/lsyscache.h b/src/include/utils/lsyscache.h
index b6ceb26c8b..0a419dcf65 100644
--- a/src/include/utils/lsyscache.h
+++ b/src/include/utils/lsyscache.h
@@ -61,7 +61,7 @@ extern AttrNumber get_attnum(Oid relid, const char *attname);
extern Oid get_atttype(Oid relid, AttrNumber attnum);
extern int32 get_atttypmod(Oid relid, AttrNumber attnum);
extern void get_atttypetypmodcoll(Oid relid, AttrNumber attnum,
- Oid *typid, int32 *typmod, Oid *collid);
+ Oid *typid, int32 *typmod, Oid *collid);
extern char *get_collation_name(Oid colloid);
extern char *get_constraint_name(Oid conoid);
extern Oid get_opclass_family(Oid opclass);
@@ -125,7 +125,7 @@ extern void getTypeOutputInfo(Oid type, Oid *typOutput, bool *typIsVarlena);
extern void getTypeBinaryInputInfo(Oid type, Oid *typReceive, Oid *typIOParam);
extern void getTypeBinaryOutputInfo(Oid type, Oid *typSend, bool *typIsVarlena);
extern Oid get_typmodin(Oid typid);
-extern Oid get_typcollation(Oid typid);
+extern Oid get_typcollation(Oid typid);
extern bool type_is_collatable(Oid typid);
extern Oid getBaseType(Oid typid);
extern Oid getBaseTypeAndTypmod(Oid typid, int32 *typmod);
diff --git a/src/include/utils/numeric.h b/src/include/utils/numeric.h
index 6147634817..229c2c0606 100644
--- a/src/include/utils/numeric.h
+++ b/src/include/utils/numeric.h
@@ -56,7 +56,7 @@ typedef struct NumericData *Numeric;
* Utility functions in numeric.c
*/
extern bool numeric_is_nan(Numeric num);
-int32 numeric_maximum_size(int32 typmod);
+int32 numeric_maximum_size(int32 typmod);
extern char *numeric_out_sci(Numeric num, int scale);
#endif /* _PG_NUMERIC_H_ */
diff --git a/src/include/utils/portal.h b/src/include/utils/portal.h
index 3068003caa..6af1cd5b10 100644
--- a/src/include/utils/portal.h
+++ b/src/include/utils/portal.h
@@ -72,7 +72,7 @@
* all the auxiliary queries.)
*
* PORTAL_ONE_MOD_WITH: the portal contains one single SELECT query, but
- * it has data-modifying CTEs. This is currently treated the same as the
+ * it has data-modifying CTEs. This is currently treated the same as the
* PORTAL_ONE_RETURNING case because of the possibility of needing to fire
* triggers. It may act more like PORTAL_ONE_SELECT in future.
*
@@ -174,7 +174,7 @@ typedef struct PortalData
/* Presentation data, primarily used by the pg_cursors system view */
TimestampTz creation_time; /* time at which this portal was defined */
bool visible; /* include this portal in pg_cursors? */
-} PortalData;
+} PortalData;
/*
* PortalIsValid
diff --git a/src/include/utils/rbtree.h b/src/include/utils/rbtree.h
index c506a689e0..c0dc63e463 100644
--- a/src/include/utils/rbtree.h
+++ b/src/include/utils/rbtree.h
@@ -17,13 +17,13 @@
* RBNode is intended to be used as the first field of a larger struct,
* whose additional fields carry whatever payload data the caller needs
* for a tree entry. (The total size of that larger struct is passed to
- * rb_create.) RBNode is declared here to support this usage, but
+ * rb_create.) RBNode is declared here to support this usage, but
* callers must treat it as an opaque struct.
*/
typedef struct RBNode
{
char iteratorState; /* workspace for iterating through tree */
- char color; /* node's current color, red or black */
+ char color; /* node's current color, red or black */
struct RBNode *left; /* left child, or RBNIL if none */
struct RBNode *right; /* right child, or RBNIL if none */
struct RBNode *parent; /* parent, or NULL (not RBNIL!) if none */
@@ -63,4 +63,4 @@ extern void rb_delete(RBTree *rb, RBNode *node);
extern void rb_begin_iterate(RBTree *rb, RBOrderControl ctrl);
extern RBNode *rb_iterate(RBTree *rb);
-#endif /* RBTREE_H */
+#endif /* RBTREE_H */
diff --git a/src/include/utils/rel.h b/src/include/utils/rel.h
index d47c4beaa5..e2c2fa9ae4 100644
--- a/src/include/utils/rel.h
+++ b/src/include/utils/rel.h
@@ -179,9 +179,9 @@ typedef struct RelationData
* index access support info (used only for an index relation)
*
* Note: only default support procs for each opclass are cached, namely
- * those with lefttype and righttype equal to the opclass's opcintype.
- * The arrays are indexed by support function number, which is a
- * sufficient identifier given that restriction.
+ * those with lefttype and righttype equal to the opclass's opcintype. The
+ * arrays are indexed by support function number, which is a sufficient
+ * identifier given that restriction.
*
* Note: rd_amcache is available for index AMs to cache private data about
* an index. This must be just a cache since it may get reset at any time
@@ -203,7 +203,7 @@ typedef struct RelationData
Oid *rd_exclprocs; /* OIDs of exclusion ops' procs, if any */
uint16 *rd_exclstrats; /* exclusion ops' strategy numbers, if any */
void *rd_amcache; /* available for use by index AM */
- Oid *rd_indcollation; /* OIDs of index collations */
+ Oid *rd_indcollation; /* OIDs of index collations */
/*
* Hack for CLUSTER, rewriting ALTER TABLE, etc: when writing a new
diff --git a/src/include/utils/tuplesort.h b/src/include/utils/tuplesort.h
index 59505d4b57..a2085df869 100644
--- a/src/include/utils/tuplesort.h
+++ b/src/include/utils/tuplesort.h
@@ -41,9 +41,9 @@ typedef struct Tuplesortstate Tuplesortstate;
* The "heap" API actually stores/sorts MinimalTuples, which means it doesn't
* preserve the system columns (tuple identity and transaction visibility
* info). The sort keys are specified by column numbers within the tuples
- * and sort operator OIDs. We save some cycles by passing and returning the
+ * and sort operator OIDs. We save some cycles by passing and returning the
* tuples in TupleTableSlots, rather than forming actual HeapTuples (which'd
- * have to be converted to MinimalTuples). This API works well for sorts
+ * have to be converted to MinimalTuples). This API works well for sorts
* executed as parts of plan trees.
*
* The "cluster" API stores/sorts full HeapTuples including all visibility
@@ -52,7 +52,7 @@ typedef struct Tuplesortstate Tuplesortstate;
* go with this API, not the "begin_heap" one!
*
* The "index_btree" API stores/sorts IndexTuples (preserving all their
- * header fields). The sort keys are specified by a btree index definition.
+ * header fields). The sort keys are specified by a btree index definition.
*
* The "index_hash" API is similar to index_btree, but the tuples are
* actually sorted by their hash codes not the raw data.
@@ -60,11 +60,11 @@ typedef struct Tuplesortstate Tuplesortstate;
extern Tuplesortstate *tuplesort_begin_heap(TupleDesc tupDesc,
int nkeys, AttrNumber *attNums,
- Oid *sortOperators, Oid *collations, bool *nullsFirstFlags,
+ Oid *sortOperators, Oid *collations, bool *nullsFirstFlags,
int workMem, bool randomAccess);
extern Tuplesortstate *tuplesort_begin_cluster(TupleDesc tupDesc,
- Relation indexRel,
- int workMem, bool randomAccess);
+ Relation indexRel,
+ int workMem, bool randomAccess);
extern Tuplesortstate *tuplesort_begin_index_btree(Relation indexRel,
bool enforceUnique,
int workMem, bool randomAccess);
@@ -72,7 +72,7 @@ extern Tuplesortstate *tuplesort_begin_index_hash(Relation indexRel,
uint32 hash_mask,
int workMem, bool randomAccess);
extern Tuplesortstate *tuplesort_begin_datum(Oid datumType,
- Oid sortOperator, Oid sortCollation, bool nullsFirstFlag,
+ Oid sortOperator, Oid sortCollation, bool nullsFirstFlag,
int workMem, bool randomAccess);
extern void tuplesort_set_bound(Tuplesortstate *state, int64 bound);
diff --git a/src/include/utils/typcache.h b/src/include/utils/typcache.h
index 2154657d88..e2f8c9ce3c 100644
--- a/src/include/utils/typcache.h
+++ b/src/include/utils/typcache.h
@@ -53,9 +53,9 @@ typedef struct TypeCacheEntry
/*
* Pre-set-up fmgr call info for the equality operator, the btree
- * comparison function, and the hash calculation function. These are kept
+ * comparison function, and the hash calculation function. These are kept
* in the type cache to avoid problems with memory leaks in repeated calls
- * to array_eq, array_cmp, hash_array. There is not currently a need to
+ * to array_eq, array_cmp, hash_array. There is not currently a need to
* maintain call info for the lt_opr or gt_opr.
*/
FmgrInfo eq_opr_finfo;
@@ -70,7 +70,7 @@ typedef struct TypeCacheEntry
TupleDesc tupDesc;
/*
- * Private information about an enum type. NULL if not enum or
+ * Private information about an enum type. NULL if not enum or
* information hasn't been requested.
*/
struct TypeCacheEnumData *enumData;
diff --git a/src/include/utils/varbit.h b/src/include/utils/varbit.h
index 847a1d33e2..e329d52e24 100644
--- a/src/include/utils/varbit.h
+++ b/src/include/utils/varbit.h
@@ -80,6 +80,7 @@ extern Datum bitle(PG_FUNCTION_ARGS);
extern Datum bitgt(PG_FUNCTION_ARGS);
extern Datum bitge(PG_FUNCTION_ARGS);
extern Datum bitcmp(PG_FUNCTION_ARGS);
+
/* avoid the names bitand and bitor, since they are C++ keywords */
extern Datum bit_and(PG_FUNCTION_ARGS);
extern Datum bit_or(PG_FUNCTION_ARGS);
diff --git a/src/include/utils/xml.h b/src/include/utils/xml.h
index 74464e82d6..6359cd6043 100644
--- a/src/include/utils/xml.h
+++ b/src/include/utils/xml.h
@@ -66,7 +66,7 @@ typedef enum
XML_STANDALONE_NO,
XML_STANDALONE_NO_VALUE,
XML_STANDALONE_OMITTED
-} XmlStandaloneType;
+} XmlStandaloneType;
extern void pg_xml_init(void);
extern void xml_ereport(int level, int sqlcode, const char *msg);
@@ -87,7 +87,7 @@ typedef enum
{
XMLBINARY_BASE64,
XMLBINARY_HEX
-} XmlBinaryType;
+} XmlBinaryType;
extern int xmlbinary; /* XmlBinaryType, but int for guc enum */
diff --git a/src/interfaces/ecpg/compatlib/informix.c b/src/interfaces/ecpg/compatlib/informix.c
index af185d533b..3b30864866 100644
--- a/src/interfaces/ecpg/compatlib/informix.c
+++ b/src/interfaces/ecpg/compatlib/informix.c
@@ -179,7 +179,7 @@ static char *
ecpg_strndup(const char *str, size_t len)
{
size_t real_len = strlen(str);
- int use_len = (int) ((real_len > len) ? len : real_len);
+ int use_len = (int) ((real_len > len) ? len : real_len);
char *new = malloc(use_len + 1);
@@ -983,33 +983,33 @@ ldchar(char *src, int len, char *dest)
int
rgetmsg(int msgnum, char *s, int maxsize)
{
- (void) msgnum; /* keep the compiler quiet */
- (void) s; /* keep the compiler quiet */
- (void) maxsize; /* keep the compiler quiet */
+ (void) msgnum; /* keep the compiler quiet */
+ (void) s; /* keep the compiler quiet */
+ (void) maxsize; /* keep the compiler quiet */
return 0;
}
int
rtypalign(int offset, int type)
{
- (void) offset; /* keep the compiler quiet */
- (void) type; /* keep the compiler quiet */
+ (void) offset; /* keep the compiler quiet */
+ (void) type; /* keep the compiler quiet */
return 0;
}
int
rtypmsize(int type, int len)
{
- (void) type; /* keep the compiler quiet */
- (void) len; /* keep the compiler quiet */
+ (void) type; /* keep the compiler quiet */
+ (void) len; /* keep the compiler quiet */
return 0;
}
int
rtypwidth(int sqltype, int sqllen)
{
- (void) sqltype; /* keep the compiler quiet */
- (void) sqllen; /* keep the compiler quiet */
+ (void) sqltype; /* keep the compiler quiet */
+ (void) sqllen; /* keep the compiler quiet */
return 0;
}
diff --git a/src/interfaces/ecpg/ecpglib/connect.c b/src/interfaces/ecpg/ecpglib/connect.c
index 1f91878395..997046b38b 100644
--- a/src/interfaces/ecpg/ecpglib/connect.c
+++ b/src/interfaces/ecpg/ecpglib/connect.c
@@ -216,7 +216,7 @@ ECPGnoticeReceiver(void *arg, const PGresult *result)
struct sqlca_t *sqlca = ECPGget_sqlca();
int sqlcode;
- (void) arg; /* keep the compiler quiet */
+ (void) arg; /* keep the compiler quiet */
if (sqlstate == NULL)
sqlstate = ECPG_SQLSTATE_ECPG_INTERNAL_ERROR;
diff --git a/src/interfaces/ecpg/ecpglib/memory.c b/src/interfaces/ecpg/ecpglib/memory.c
index 542bfc0c7d..a09cd26a54 100644
--- a/src/interfaces/ecpg/ecpglib/memory.c
+++ b/src/interfaces/ecpg/ecpglib/memory.c
@@ -75,7 +75,7 @@ static pthread_once_t auto_mem_once = PTHREAD_ONCE_INIT;
static void
auto_mem_destructor(void *arg)
{
- (void) arg; /* keep the compiler quiet */
+ (void) arg; /* keep the compiler quiet */
ECPGfree_auto_mem();
}
diff --git a/src/interfaces/ecpg/ecpglib/prepare.c b/src/interfaces/ecpg/ecpglib/prepare.c
index 0296d925b9..60c9c50b22 100644
--- a/src/interfaces/ecpg/ecpglib/prepare.c
+++ b/src/interfaces/ecpg/ecpglib/prepare.c
@@ -164,7 +164,7 @@ ECPGprepare(int lineno, const char *connection_name, const bool questionmarks, c
struct prepared_statement *this,
*prev;
- (void) questionmarks; /* quiet the compiler */
+ (void) questionmarks; /* quiet the compiler */
con = ecpg_get_connection(connection_name);
if (!ecpg_init(con, connection_name, lineno))
@@ -305,7 +305,7 @@ ecpg_prepared(const char *name, struct connection * con)
char *
ECPGprepared_statement(const char *connection_name, const char *name, int lineno)
{
- (void)lineno; /* keep the compiler quiet */
+ (void) lineno; /* keep the compiler quiet */
return ecpg_prepared(name, ecpg_get_connection(connection_name));
}
diff --git a/src/interfaces/ecpg/preproc/ecpg.c b/src/interfaces/ecpg/preproc/ecpg.c
index f198035a9a..6f7314875e 100644
--- a/src/interfaces/ecpg/preproc/ecpg.c
+++ b/src/interfaces/ecpg/preproc/ecpg.c
@@ -12,7 +12,7 @@
#include "extern.h"
int ret_value = 0;
-bool autocommit = false,
+bool autocommit = false,
auto_create_c = false,
system_includes = false,
force_indicator = true,
@@ -127,7 +127,7 @@ main(int argc, char *const argv[])
int fnr,
c,
out_option = 0;
- bool verbose = false,
+ bool verbose = false,
header_mode = false;
struct _include_path *ip;
const char *progname;
diff --git a/src/interfaces/ecpg/preproc/extern.h b/src/interfaces/ecpg/preproc/extern.h
index f2072f85d9..05b273cc24 100644
--- a/src/interfaces/ecpg/preproc/extern.h
+++ b/src/interfaces/ecpg/preproc/extern.h
@@ -18,14 +18,14 @@
/* variables */
-extern bool autocommit,
+extern bool autocommit,
auto_create_c,
system_includes,
force_indicator,
questionmarks,
regression_mode,
auto_prepare;
-extern int braces_open,
+extern int braces_open,
ret_value,
struct_level,
ecpg_internal_var;
diff --git a/src/interfaces/libpq/fe-auth.c b/src/interfaces/libpq/fe-auth.c
index 7d2ef51f17..45e39e08e3 100644
--- a/src/interfaces/libpq/fe-auth.c
+++ b/src/interfaces/libpq/fe-auth.c
@@ -246,7 +246,7 @@ pg_krb5_sendauth(PGconn *conn)
}
retval = krb5_sendauth(info.pg_krb5_context, &auth_context,
- (krb5_pointer) & conn->sock, (char *) conn->krbsrvname,
+ (krb5_pointer) &conn->sock, (char *) conn->krbsrvname,
info.pg_krb5_client, server,
AP_OPTS_MUTUAL_REQUIRED,
NULL, 0, /* no creds, use ccache instead */
@@ -892,14 +892,14 @@ pg_fe_sendauth(AuthRequest areq, PGconn *conn)
pgunlock_thread();
}
break;
-#else /* defined(ENABLE_GSS) || defined(ENABLE_SSPI) */
+#else /* defined(ENABLE_GSS) || defined(ENABLE_SSPI) */
/* No GSSAPI *or* SSPI support */
case AUTH_REQ_GSS:
case AUTH_REQ_GSS_CONT:
printfPQExpBuffer(&conn->errorMessage,
libpq_gettext("GSSAPI authentication not supported\n"));
return STATUS_ERROR;
-#endif /* defined(ENABLE_GSS) || defined(ENABLE_SSPI) */
+#endif /* defined(ENABLE_GSS) || defined(ENABLE_SSPI) */
#ifdef ENABLE_SSPI
case AUTH_REQ_SSPI:
@@ -919,19 +919,20 @@ pg_fe_sendauth(AuthRequest areq, PGconn *conn)
pgunlock_thread();
break;
#else
+
/*
* No SSPI support. However, if we have GSSAPI but not SSPI
* support, AUTH_REQ_SSPI will have been handled in the codepath
- * for AUTH_REQ_GSSAPI above, so don't duplicate the case label
- * in that case.
+ * for AUTH_REQ_GSSAPI above, so don't duplicate the case label in
+ * that case.
*/
#if !defined(ENABLE_GSS)
case AUTH_REQ_SSPI:
printfPQExpBuffer(&conn->errorMessage,
libpq_gettext("SSPI authentication not supported\n"));
return STATUS_ERROR;
-#endif /* !define(ENABLE_GSSAPI) */
-#endif /* ENABLE_SSPI */
+#endif /* !define(ENABLE_GSSAPI) */
+#endif /* ENABLE_SSPI */
case AUTH_REQ_CRYPT:
diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c
index aa24c37f9c..729730aa8c 100644
--- a/src/interfaces/libpq/fe-connect.c
+++ b/src/interfaces/libpq/fe-connect.c
@@ -41,7 +41,7 @@
#endif
#define near
#include
-#ifdef WIN32_ONLY_COMPILER /* mstcpip.h is missing on mingw */
+#ifdef WIN32_ONLY_COMPILER /* mstcpip.h is missing on mingw */
#include
#endif
#else
@@ -1011,13 +1011,13 @@ connectFailureMessage(PGconn *conn, int errorno)
else
#endif /* HAVE_UNIX_SOCKETS */
{
- char host_addr[NI_MAXHOST];
- bool display_host_addr;
+ char host_addr[NI_MAXHOST];
+ bool display_host_addr;
struct sockaddr_storage *addr = &conn->raddr.addr;
/*
- * Optionally display the network address with the hostname.
- * This is useful to distinguish between IPv4 and IPv6 connections.
+ * Optionally display the network address with the hostname. This is
+ * useful to distinguish between IPv4 and IPv6 connections.
*/
if (conn->pghostaddr != NULL)
strlcpy(host_addr, conn->pghostaddr, NI_MAXHOST);
@@ -1033,7 +1033,7 @@ connectFailureMessage(PGconn *conn, int errorno)
else if (addr->ss_family == AF_INET6)
{
if (inet_net_ntop(AF_INET6,
- &((struct sockaddr_in6 *) addr)->sin6_addr.s6_addr,
+ &((struct sockaddr_in6 *) addr)->sin6_addr.s6_addr,
128,
host_addr, sizeof(host_addr)) == NULL)
strcpy(host_addr, "???");
@@ -1043,25 +1043,25 @@ connectFailureMessage(PGconn *conn, int errorno)
strcpy(host_addr, "???");
/*
- * If the user did not supply an IP address using 'hostaddr', and
- * 'host' was missing or does not match our lookup, display the
- * looked-up IP address.
+ * If the user did not supply an IP address using 'hostaddr', and
+ * 'host' was missing or does not match our lookup, display the
+ * looked-up IP address.
*/
display_host_addr = (conn->pghostaddr == NULL) &&
- ((conn->pghost == NULL) ||
- (strcmp(conn->pghost, host_addr) != 0));
+ ((conn->pghost == NULL) ||
+ (strcmp(conn->pghost, host_addr) != 0));
appendPQExpBuffer(&conn->errorMessage,
libpq_gettext("could not connect to server: %s\n"
- "\tIs the server running on host \"%s\"%s%s%s and accepting\n"
+ "\tIs the server running on host \"%s\"%s%s%s and accepting\n"
"\tTCP/IP connections on port %s?\n"),
SOCK_STRERROR(errorno, sebuf, sizeof(sebuf)),
(conn->pghostaddr && conn->pghostaddr[0] != '\0')
? conn->pghostaddr
: (conn->pghost && conn->pghost[0] != '\0')
- ? conn->pghost
- : DefaultHost,
- /* display the IP address only if not already output */
+ ? conn->pghost
+ : DefaultHost,
+ /* display the IP address only if not already output */
display_host_addr ? " (" : "",
display_host_addr ? host_addr : "",
display_host_addr ? ")" : "",
@@ -1121,10 +1121,10 @@ setKeepalivesIdle(PGconn *conn)
if (setsockopt(conn->sock, IPPROTO_TCP, TCP_KEEPALIVE,
(char *) &idle, sizeof(idle)) < 0)
{
- char sebuf[256];
+ char sebuf[256];
appendPQExpBuffer(&conn->errorMessage,
- libpq_gettext("setsockopt(TCP_KEEPALIVE) failed: %s\n"),
+ libpq_gettext("setsockopt(TCP_KEEPALIVE) failed: %s\n"),
SOCK_STRERROR(SOCK_ERRNO, sebuf, sizeof(sebuf)));
return 0;
}
@@ -1196,8 +1196,7 @@ setKeepalivesCount(PGconn *conn)
return 1;
}
-
-#else /* Win32 */
+#else /* Win32 */
#ifdef SIO_KEEPALIVE_VALS
/*
* Enable keepalives and set the keepalive values on Win32,
@@ -1206,20 +1205,20 @@ setKeepalivesCount(PGconn *conn)
static int
setKeepalivesWin32(PGconn *conn)
{
- struct tcp_keepalive ka;
- DWORD retsize;
- int idle = 0;
- int interval = 0;
+ struct tcp_keepalive ka;
+ DWORD retsize;
+ int idle = 0;
+ int interval = 0;
if (conn->keepalives_idle)
idle = atoi(conn->keepalives_idle);
if (idle <= 0)
- idle = 2 * 60 * 60; /* 2 hours = default */
+ idle = 2 * 60 * 60; /* 2 hours = default */
if (conn->keepalives_interval)
interval = atoi(conn->keepalives_interval);
if (interval <= 0)
- interval = 1; /* 1 second = default */
+ interval = 1; /* 1 second = default */
ka.onoff = 1;
ka.keepalivetime = idle * 1000;
@@ -1237,14 +1236,14 @@ setKeepalivesWin32(PGconn *conn)
!= 0)
{
appendPQExpBuffer(&conn->errorMessage,
- libpq_gettext("WSAIoctl(SIO_KEEPALIVE_VALS) failed: %ui\n"),
+ libpq_gettext("WSAIoctl(SIO_KEEPALIVE_VALS) failed: %ui\n"),
WSAGetLastError());
return 0;
}
return 1;
}
-#endif /* SIO_KEEPALIVE_VALS */
-#endif /* WIN32 */
+#endif /* SIO_KEEPALIVE_VALS */
+#endif /* WIN32 */
/* ----------
* connectDBStart -
@@ -1661,12 +1660,12 @@ keep_going: /* We will come back to here until there is
|| !setKeepalivesInterval(conn)
|| !setKeepalivesCount(conn))
err = 1;
-#else /* WIN32 */
+#else /* WIN32 */
#ifdef SIO_KEEPALIVE_VALS
else if (!setKeepalivesWin32(conn))
err = 1;
-#endif /* SIO_KEEPALIVE_VALS */
-#endif /* WIN32 */
+#endif /* SIO_KEEPALIVE_VALS */
+#endif /* WIN32 */
if (err)
{
@@ -1864,8 +1863,8 @@ keep_going: /* We will come back to here until there is
if (getpeereid(conn->sock, &uid, &gid) != 0)
{
appendPQExpBuffer(&conn->errorMessage,
- libpq_gettext("could not get peer credentials: %s\n"),
- pqStrerror(errno, sebuf, sizeof(sebuf)));
+ libpq_gettext("could not get peer credentials: %s\n"),
+ pqStrerror(errno, sebuf, sizeof(sebuf)));
goto error_return;
}
#elif defined(SO_PEERCRED)
@@ -1878,20 +1877,20 @@ keep_going: /* We will come back to here until there is
so_len != sizeof(peercred))
{
appendPQExpBuffer(&conn->errorMessage,
- libpq_gettext("could not get peer credentials: %s\n"),
- pqStrerror(errno, sebuf, sizeof(sebuf)));
+ libpq_gettext("could not get peer credentials: %s\n"),
+ pqStrerror(errno, sebuf, sizeof(sebuf)));
goto error_return;
}
uid = peercred.uid;
#elif defined(HAVE_GETPEERUCRED)
ucred_t *ucred;
- ucred = NULL; /* must be initialized to NULL */
+ ucred = NULL; /* must be initialized to NULL */
if (getpeerucred(conn->sock, &ucred) == -1)
{
appendPQExpBuffer(&conn->errorMessage,
- libpq_gettext("could not get peer credentials: %s\n"),
- pqStrerror(errno, sebuf, sizeof(sebuf)));
+ libpq_gettext("could not get peer credentials: %s\n"),
+ pqStrerror(errno, sebuf, sizeof(sebuf)));
goto error_return;
}
@@ -1899,7 +1898,7 @@ keep_going: /* We will come back to here until there is
{
appendPQExpBuffer(&conn->errorMessage,
libpq_gettext("could not get effective UID from peer credentials: %s\n"),
- pqStrerror(errno, sebuf, sizeof(sebuf)));
+ pqStrerror(errno, sebuf, sizeof(sebuf)));
ucred_free(ucred);
goto error_return;
}
@@ -1925,7 +1924,7 @@ keep_going: /* We will come back to here until there is
conn->requirepeer, pass->pw_name);
goto error_return;
}
-#else /* can't support requirepeer */
+#else /* can't support requirepeer */
appendPQExpBuffer(&conn->errorMessage,
libpq_gettext("requirepeer parameter is not supported on this platform\n"));
goto error_return;
@@ -2613,18 +2612,18 @@ internal_ping(PGconn *conn)
* failure in sufficient detail to decide what to return. We do not want
* to report that the server is not up just because we didn't have a valid
* password, for example. In fact, any sort of authentication request
- * implies the server is up. (We need this check since the libpq side
- * of things might have pulled the plug on the connection before getting
- * an error as such from the postmaster.)
+ * implies the server is up. (We need this check since the libpq side of
+ * things might have pulled the plug on the connection before getting an
+ * error as such from the postmaster.)
*/
if (conn->auth_req_received)
return PQPING_OK;
/*
* If we failed to get any ERROR response from the postmaster, report
- * PQPING_NO_RESPONSE. This result could be somewhat misleading for a
+ * PQPING_NO_RESPONSE. This result could be somewhat misleading for a
* pre-7.4 server, since it won't send back a SQLSTATE, but those are long
- * out of support. Another corner case where the server could return a
+ * out of support. Another corner case where the server could return a
* failure without a SQLSTATE is fork failure, but NO_RESPONSE isn't
* totally unreasonable for that anyway. We expect that every other
* failure case in a modern server will produce a report with a SQLSTATE.
@@ -2638,8 +2637,8 @@ internal_ping(PGconn *conn)
return PQPING_NO_RESPONSE;
/*
- * Report PQPING_REJECT if server says it's not accepting connections.
- * (We distinguish this case mainly for the convenience of pg_ctl.)
+ * Report PQPING_REJECT if server says it's not accepting connections. (We
+ * distinguish this case mainly for the convenience of pg_ctl.)
*/
if (strcmp(conn->last_sqlstate, ERRCODE_CANNOT_CONNECT_NOW) == 0)
return PQPING_REJECT;
diff --git a/src/interfaces/libpq/fe-exec.c b/src/interfaces/libpq/fe-exec.c
index 42da1a8f90..83c5ea363f 100644
--- a/src/interfaces/libpq/fe-exec.c
+++ b/src/interfaces/libpq/fe-exec.c
@@ -1787,8 +1787,8 @@ PQexecStart(PGconn *conn)
{
/* We don't allow PQexec during COPY BOTH */
printfPQExpBuffer(&conn->errorMessage,
- libpq_gettext("PQexec not allowed during COPY BOTH\n"));
- return false;
+ libpq_gettext("PQexec not allowed during COPY BOTH\n"));
+ return false;
}
/* check for loss of connection, too */
if (conn->status == CONNECTION_BAD)
@@ -1813,8 +1813,8 @@ PQexecFinish(PGconn *conn)
* than one --- but merge error messages if we get more than one error
* result.
*
- * We have to stop if we see copy in/out/both, however. We will resume parsing
- * after application performs the data transfer.
+ * We have to stop if we see copy in/out/both, however. We will resume
+ * parsing after application performs the data transfer.
*
* Also stop if the connection is lost (else we'll loop infinitely).
*/
@@ -3464,11 +3464,11 @@ PQunescapeBytea(const unsigned char *strtext, size_t *retbuflen)
(ISOCTDIGIT(strtext[i + 1])) &&
(ISOCTDIGIT(strtext[i + 2])))
{
- int byte;
+ int byte;
byte = OCTVAL(strtext[i++]);
- byte = (byte <<3) +OCTVAL(strtext[i++]);
- byte = (byte <<3) +OCTVAL(strtext[i++]);
+ byte = (byte << 3) + OCTVAL(strtext[i++]);
+ byte = (byte << 3) + OCTVAL(strtext[i++]);
buffer[j++] = byte;
}
}
diff --git a/src/interfaces/libpq/fe-protocol2.c b/src/interfaces/libpq/fe-protocol2.c
index 05357de1c7..77c4d5ac57 100644
--- a/src/interfaces/libpq/fe-protocol2.c
+++ b/src/interfaces/libpq/fe-protocol2.c
@@ -100,11 +100,11 @@ pqSetenvPoll(PGconn *conn)
{
switch (conn->setenv_state)
{
- /*
- * The _CLIENT_ENCODING_SEND code is slightly different
- * from _OPTION_SEND below (e.g., no getenv() call), which
- * is why a different state is used.
- */
+ /*
+ * The _CLIENT_ENCODING_SEND code is slightly different from
+ * _OPTION_SEND below (e.g., no getenv() call), which is why a
+ * different state is used.
+ */
case SETENV_STATE_CLIENT_ENCODING_SEND:
{
char setQuery[100]; /* note length limit in
@@ -601,9 +601,10 @@ pqParseInput2(PGconn *conn)
case 'H': /* Start Copy Out */
conn->asyncStatus = PGASYNC_COPY_OUT;
break;
+
/*
- * Don't need to process CopyBothResponse here because
- * it never arrives from the server during protocol 2.0.
+ * Don't need to process CopyBothResponse here because it
+ * never arrives from the server during protocol 2.0.
*/
default:
printfPQExpBuffer(&conn->errorMessage,
diff --git a/src/interfaces/libpq/fe-protocol3.c b/src/interfaces/libpq/fe-protocol3.c
index cf0b91a9bc..45a84d8e55 100644
--- a/src/interfaces/libpq/fe-protocol3.c
+++ b/src/interfaces/libpq/fe-protocol3.c
@@ -1400,8 +1400,8 @@ pqGetCopyData3(PGconn *conn, char **buffer, int async)
/*
* On end-of-copy, exit COPY_OUT or COPY_BOTH mode and let caller
* read status with PQgetResult(). The normal case is that it's
- * Copy Done, but we let parseInput read that. If error, we expect
- * the state was already changed.
+ * Copy Done, but we let parseInput read that. If error, we
+ * expect the state was already changed.
*/
if (msgLength == -1)
conn->asyncStatus = PGASYNC_BUSY;
diff --git a/src/interfaces/libpq/fe-secure.c b/src/interfaces/libpq/fe-secure.c
index 2b7b0341cd..cd1292ccb6 100644
--- a/src/interfaces/libpq/fe-secure.c
+++ b/src/interfaces/libpq/fe-secure.c
@@ -589,8 +589,8 @@ static bool
verify_peer_name_matches_certificate(PGconn *conn)
{
/*
- * If told not to verify the peer name, don't do it. Return true indicating
- * that the verification was successful.
+ * If told not to verify the peer name, don't do it. Return true
+ * indicating that the verification was successful.
*/
if (strcmp(conn->sslmode, "verify-full") != 0)
return true;
@@ -839,7 +839,7 @@ initialize_SSL(PGconn *conn)
!(conn->sslrootcert && strlen(conn->sslrootcert) > 0) ||
!(conn->sslcrl && strlen(conn->sslcrl) > 0))
have_homedir = pqGetHomeDirectory(homedir, sizeof(homedir));
- else /* won't need it */
+ else /* won't need it */
have_homedir = false;
/* Read the client certificate file */
@@ -1135,8 +1135,8 @@ initialize_SSL(PGconn *conn)
"Either provide the file or change sslmode to disable server certificate verification.\n"));
else
printfPQExpBuffer(&conn->errorMessage,
- libpq_gettext("root certificate file \"%s\" does not exist\n"
- "Either provide the file or change sslmode to disable server certificate verification.\n"), fnbuf);
+ libpq_gettext("root certificate file \"%s\" does not exist\n"
+ "Either provide the file or change sslmode to disable server certificate verification.\n"), fnbuf);
return -1;
}
}
diff --git a/src/interfaces/libpq/libpq-fe.h b/src/interfaces/libpq/libpq-fe.h
index de13a03cf0..d7802753ef 100644
--- a/src/interfaces/libpq/libpq-fe.h
+++ b/src/interfaces/libpq/libpq-fe.h
@@ -414,7 +414,7 @@ extern int PQisnonblocking(const PGconn *conn);
extern int PQisthreadsafe(void);
extern PGPing PQping(const char *conninfo);
extern PGPing PQpingParams(const char **keywords,
- const char **values, int expand_dbname);
+ const char **values, int expand_dbname);
/* Force the write buffer to be written (or at least try) */
extern int PQflush(PGconn *conn);
diff --git a/src/interfaces/libpq/libpq-int.h b/src/interfaces/libpq/libpq-int.h
index 25c779acd7..fbd94ebfb8 100644
--- a/src/interfaces/libpq/libpq-int.h
+++ b/src/interfaces/libpq/libpq-int.h
@@ -295,7 +295,7 @@ struct pg_conn
char *pgtty; /* tty on which the backend messages is
* displayed (OBSOLETE, NOT USED) */
char *connect_timeout; /* connection timeout (numeric string) */
- char *client_encoding_initial; /* encoding to use */
+ char *client_encoding_initial; /* encoding to use */
char *pgoptions; /* options to start the backend with */
char *appname; /* application name */
char *fbappname; /* fallback application name */
@@ -337,7 +337,7 @@ struct pg_conn
PGTransactionStatusType xactStatus; /* never changes to ACTIVE */
PGQueryClass queryclass;
char *last_query; /* last SQL command, or NULL if unknown */
- char last_sqlstate[6]; /* last reported SQLSTATE */
+ char last_sqlstate[6]; /* last reported SQLSTATE */
bool options_valid; /* true if OK to attempt connection */
bool nonblocking; /* whether this connection is using nonblock
* sending semantics */
@@ -353,7 +353,8 @@ struct pg_conn
SockAddr raddr; /* Remote address */
ProtocolVersion pversion; /* FE/BE protocol version in use */
int sversion; /* server version, e.g. 70401 for 7.4.1 */
- bool auth_req_received; /* true if any type of auth req received */
+ bool auth_req_received; /* true if any type of auth req
+ * received */
bool password_needed; /* true if server demanded a password */
bool dot_pgpass_used; /* true if used .pgpass */
bool sigpipe_so; /* have we masked SIGPIPE via SO_NOSIGPIPE? */
diff --git a/src/pl/plperl/plperl.c b/src/pl/plperl/plperl.c
index 35bf72ca30..ac9134272c 100644
--- a/src/pl/plperl/plperl.c
+++ b/src/pl/plperl/plperl.c
@@ -1211,7 +1211,7 @@ plperl_sv_to_datum(SV *sv, FmgrInfo *finfo, Oid typid, Oid typioparam,
ereport(ERROR,
(errcode(ERRCODE_DATATYPE_MISMATCH),
- errmsg("PL/Perl function must return reference to hash or array")));
+ errmsg("PL/Perl function must return reference to hash or array")));
return (Datum) 0; /* shut up compiler */
}
else
diff --git a/src/pl/plperl/plperl.h b/src/pl/plperl/plperl.h
index 65b27a344f..5eaec73d2b 100644
--- a/src/pl/plperl/plperl.h
+++ b/src/pl/plperl/plperl.h
@@ -44,9 +44,9 @@
/* supply HeUTF8 if it's missing - ppport.h doesn't supply it, unfortunately */
#ifndef HeUTF8
-#define HeUTF8(he) ((HeKLEN(he) == HEf_SVKEY) ? \
- SvUTF8(HeKEY_sv(he)) : \
- (U32)HeKUTF8(he))
+#define HeUTF8(he) ((HeKLEN(he) == HEf_SVKEY) ? \
+ SvUTF8(HeKEY_sv(he)) : \
+ (U32)HeKUTF8(he))
#endif
/* declare routines from plperl.c for access by .xs files */
@@ -59,7 +59,7 @@ HV *plperl_spi_exec_prepared(char *, HV *, int, SV **);
SV *plperl_spi_query_prepared(char *, int, SV **);
void plperl_spi_freeplan(char *);
void plperl_spi_cursor_close(char *);
-char *plperl_sv_to_literal(SV *, char *);
+char *plperl_sv_to_literal(SV *, char *);
diff --git a/src/pl/plperl/plperl_helpers.h b/src/pl/plperl/plperl_helpers.h
index 4480ce8f5e..81c177b164 100644
--- a/src/pl/plperl/plperl_helpers.h
+++ b/src/pl/plperl/plperl_helpers.h
@@ -7,7 +7,8 @@
static inline char *
utf_u2e(const char *utf8_str, size_t len)
{
- char *ret = (char*)pg_do_encoding_conversion((unsigned char*)utf8_str, len, PG_UTF8, GetDatabaseEncoding());
+ char *ret = (char *) pg_do_encoding_conversion((unsigned char *) utf8_str, len, PG_UTF8, GetDatabaseEncoding());
+
if (ret == utf8_str)
ret = pstrdup(ret);
return ret;
@@ -19,7 +20,8 @@ utf_u2e(const char *utf8_str, size_t len)
static inline char *
utf_e2u(const char *str)
{
- char *ret = (char*)pg_do_encoding_conversion((unsigned char*)str, strlen(str), GetDatabaseEncoding(), PG_UTF8);
+ char *ret = (char *) pg_do_encoding_conversion((unsigned char *) str, strlen(str), GetDatabaseEncoding(), PG_UTF8);
+
if (ret == str)
ret = pstrdup(ret);
return ret;
@@ -32,8 +34,8 @@ utf_e2u(const char *str)
static inline char *
sv2cstr(SV *sv)
{
- char *val;
- STRLEN len;
+ char *val;
+ STRLEN len;
/*
* get a utf8 encoded char * out of perl. *note* it may not be valid utf8!
@@ -55,8 +57,8 @@ sv2cstr(SV *sv)
static inline SV *
cstr2sv(const char *str)
{
- SV *sv;
- char *utf8_str = utf_e2u(str);
+ SV *sv;
+ char *utf8_str = utf_e2u(str);
sv = newSVpv(utf8_str, 0);
SvUTF8_on(sv);
diff --git a/src/pl/plpgsql/src/pl_comp.c b/src/pl/plpgsql/src/pl_comp.c
index 8b963bf818..9f919b88c2 100644
--- a/src/pl/plpgsql/src/pl_comp.c
+++ b/src/pl/plpgsql/src/pl_comp.c
@@ -414,7 +414,7 @@ do_compile(FunctionCallInfo fcinfo,
/* Create datatype info */
argdtype = plpgsql_build_datatype(argtypeid,
-1,
- function->fn_input_collation);
+ function->fn_input_collation);
/* Disallow pseudotype argument */
/* (note we already replaced polymorphic types) */
@@ -561,7 +561,7 @@ do_compile(FunctionCallInfo fcinfo,
(void) plpgsql_build_variable("$0", 0,
build_datatype(typeTup,
-1,
- function->fn_input_collation),
+ function->fn_input_collation),
true);
}
}
@@ -602,7 +602,7 @@ do_compile(FunctionCallInfo fcinfo,
var = plpgsql_build_variable("tg_when", 0,
plpgsql_build_datatype(TEXTOID,
-1,
- function->fn_input_collation),
+ function->fn_input_collation),
true);
function->tg_when_varno = var->dno;
@@ -610,7 +610,7 @@ do_compile(FunctionCallInfo fcinfo,
var = plpgsql_build_variable("tg_level", 0,
plpgsql_build_datatype(TEXTOID,
-1,
- function->fn_input_collation),
+ function->fn_input_collation),
true);
function->tg_level_varno = var->dno;
@@ -618,7 +618,7 @@ do_compile(FunctionCallInfo fcinfo,
var = plpgsql_build_variable("tg_op", 0,
plpgsql_build_datatype(TEXTOID,
-1,
- function->fn_input_collation),
+ function->fn_input_collation),
true);
function->tg_op_varno = var->dno;
@@ -666,7 +666,7 @@ do_compile(FunctionCallInfo fcinfo,
var = plpgsql_build_variable("tg_argv", 0,
plpgsql_build_datatype(TEXTARRAYOID,
-1,
- function->fn_input_collation),
+ function->fn_input_collation),
true);
function->tg_argv_varno = var->dno;
@@ -998,13 +998,13 @@ plpgsql_post_column_ref(ParseState *pstate, ColumnRef *cref, Node *var)
/*
* If we find a record/row variable but can't match a field name, throw
- * error if there was no core resolution for the ColumnRef either. In
+ * error if there was no core resolution for the ColumnRef either. In
* that situation, the reference is inevitably going to fail, and
- * complaining about the record/row variable is likely to be more
- * on-point than the core parser's error message. (It's too bad we
- * don't have access to transformColumnRef's internal crerr state here,
- * as in case of a conflict with a table name this could still be less
- * than the most helpful error message possible.)
+ * complaining about the record/row variable is likely to be more on-point
+ * than the core parser's error message. (It's too bad we don't have
+ * access to transformColumnRef's internal crerr state here, as in case of
+ * a conflict with a table name this could still be less than the most
+ * helpful error message possible.)
*/
myvar = resolve_column_ref(pstate, expr, cref, (var == NULL));
@@ -1970,7 +1970,7 @@ build_row_from_class(Oid classOid)
var = plpgsql_build_variable(refname, 0,
plpgsql_build_datatype(attrStruct->atttypid,
attrStruct->atttypmod,
- attrStruct->attcollation),
+ attrStruct->attcollation),
false);
/* Add the variable to the row */
diff --git a/src/pl/plpgsql/src/pl_exec.c b/src/pl/plpgsql/src/pl_exec.c
index f793991209..5fccf096de 100644
--- a/src/pl/plpgsql/src/pl_exec.c
+++ b/src/pl/plpgsql/src/pl_exec.c
@@ -108,7 +108,7 @@ static int exec_stmt_fors(PLpgSQL_execstate *estate,
static int exec_stmt_forc(PLpgSQL_execstate *estate,
PLpgSQL_stmt_forc *stmt);
static int exec_stmt_foreach_a(PLpgSQL_execstate *estate,
- PLpgSQL_stmt_foreach_a *stmt);
+ PLpgSQL_stmt_foreach_a *stmt);
static int exec_stmt_open(PLpgSQL_execstate *estate,
PLpgSQL_stmt_open *stmt);
static int exec_stmt_fetch(PLpgSQL_execstate *estate,
@@ -1016,7 +1016,7 @@ exec_stmt_block(PLpgSQL_execstate *estate, PLpgSQL_stmt_block *block)
MemoryContext oldcontext = CurrentMemoryContext;
ResourceOwner oldowner = CurrentResourceOwner;
ExprContext *old_eval_econtext = estate->eval_econtext;
- ErrorData *save_cur_error = estate->cur_error;
+ ErrorData *save_cur_error = estate->cur_error;
estate->err_text = gettext_noop("during statement block entry");
@@ -1518,7 +1518,7 @@ exec_stmt_case(PLpgSQL_execstate *estate, PLpgSQL_stmt_case *stmt)
if (t_var->datatype->typoid != t_oid)
t_var->datatype = plpgsql_build_datatype(t_oid,
-1,
- estate->func->fn_input_collation);
+ estate->func->fn_input_collation);
/* now we can assign to the variable */
exec_assign_value(estate,
@@ -2046,16 +2046,16 @@ exec_stmt_forc(PLpgSQL_execstate *estate, PLpgSQL_stmt_forc *stmt)
static int
exec_stmt_foreach_a(PLpgSQL_execstate *estate, PLpgSQL_stmt_foreach_a *stmt)
{
- ArrayType *arr;
- Oid arrtype;
- PLpgSQL_datum *loop_var;
- Oid loop_var_elem_type;
- bool found = false;
- int rc = PLPGSQL_RC_OK;
- ArrayIterator array_iterator;
- Oid iterator_result_type;
- Datum value;
- bool isnull;
+ ArrayType *arr;
+ Oid arrtype;
+ PLpgSQL_datum *loop_var;
+ Oid loop_var_elem_type;
+ bool found = false;
+ int rc = PLPGSQL_RC_OK;
+ ArrayIterator array_iterator;
+ Oid iterator_result_type;
+ Datum value;
+ bool isnull;
/* get the value of the array expression */
value = exec_eval_expr(estate, stmt->expr, &isnull, &arrtype);
@@ -2085,8 +2085,8 @@ exec_stmt_foreach_a(PLpgSQL_execstate *estate, PLpgSQL_stmt_foreach_a *stmt)
if (stmt->slice < 0 || stmt->slice > ARR_NDIM(arr))
ereport(ERROR,
(errcode(ERRCODE_ARRAY_SUBSCRIPT_ERROR),
- errmsg("slice dimension (%d) is out of the valid range 0..%d",
- stmt->slice, ARR_NDIM(arr))));
+ errmsg("slice dimension (%d) is out of the valid range 0..%d",
+ stmt->slice, ARR_NDIM(arr))));
/* Set up the loop variable and see if it is of an array type */
loop_var = estate->datums[stmt->varno];
@@ -2104,19 +2104,19 @@ exec_stmt_foreach_a(PLpgSQL_execstate *estate, PLpgSQL_stmt_foreach_a *stmt)
loop_var));
/*
- * Sanity-check the loop variable type. We don't try very hard here,
- * and should not be too picky since it's possible that exec_assign_value
- * can coerce values of different types. But it seems worthwhile to
- * complain if the array-ness of the loop variable is not right.
+ * Sanity-check the loop variable type. We don't try very hard here, and
+ * should not be too picky since it's possible that exec_assign_value can
+ * coerce values of different types. But it seems worthwhile to complain
+ * if the array-ness of the loop variable is not right.
*/
if (stmt->slice > 0 && loop_var_elem_type == InvalidOid)
ereport(ERROR,
(errcode(ERRCODE_DATATYPE_MISMATCH),
- errmsg("FOREACH ... SLICE loop variable must be of an array type")));
+ errmsg("FOREACH ... SLICE loop variable must be of an array type")));
if (stmt->slice == 0 && loop_var_elem_type != InvalidOid)
ereport(ERROR,
(errcode(ERRCODE_DATATYPE_MISMATCH),
- errmsg("FOREACH loop variable must not be of an array type")));
+ errmsg("FOREACH loop variable must not be of an array type")));
/* Create an iterator to step through the array */
array_iterator = array_create_iterator(arr, stmt->slice);
@@ -3949,9 +3949,9 @@ exec_assign_value(PLpgSQL_execstate *estate,
/*
* We need to do subscript evaluation, which might require
* evaluating general expressions; and the caller might have
- * done that too in order to prepare the input Datum. We
- * have to save and restore the caller's SPI_execute result,
- * if any.
+ * done that too in order to prepare the input Datum. We have
+ * to save and restore the caller's SPI_execute result, if
+ * any.
*/
save_eval_tuptable = estate->eval_tuptable;
estate->eval_tuptable = NULL;
@@ -4017,11 +4017,11 @@ exec_assign_value(PLpgSQL_execstate *estate,
errmsg("array subscript in assignment must not be null")));
/*
- * Clean up in case the subscript expression wasn't simple.
- * We can't do exec_eval_cleanup, but we can do this much
- * (which is safe because the integer subscript value is
- * surely pass-by-value), and we must do it in case the
- * next subscript expression isn't simple either.
+ * Clean up in case the subscript expression wasn't
+ * simple. We can't do exec_eval_cleanup, but we can do
+ * this much (which is safe because the integer subscript
+ * value is surely pass-by-value), and we must do it in
+ * case the next subscript expression isn't simple either.
*/
if (estate->eval_tuptable != NULL)
SPI_freetuptable(estate->eval_tuptable);
@@ -4355,7 +4355,7 @@ exec_get_datum_collation(PLpgSQL_execstate *estate,
/* XXX there's no SPI_getcollid, as yet */
if (fno > 0)
collid = rec->tupdesc->attrs[fno - 1]->attcollation;
- else /* no system column types have collation */
+ else /* no system column types have collation */
collid = InvalidOid;
break;
}
@@ -4726,7 +4726,7 @@ loop_exit:
* Because we only store one execution tree for a simple expression, we
* can't handle recursion cases. So, if we see the tree is already busy
* with an evaluation in the current xact, we just return FALSE and let the
- * caller run the expression the hard way. (Other alternatives such as
+ * caller run the expression the hard way. (Other alternatives such as
* creating a new tree for a recursive call either introduce memory leaks,
* or add enough bookkeeping to be doubtful wins anyway.) Another case that
* is covered by the expr_simple_in_use test is where a previous execution
@@ -4907,7 +4907,7 @@ setup_param_list(PLpgSQL_execstate *estate, PLpgSQL_expr *expr)
/* sizeof(ParamListInfoData) includes the first array element */
paramLI = (ParamListInfo)
palloc0(sizeof(ParamListInfoData) +
- (estate->ndatums - 1) *sizeof(ParamExternData));
+ (estate->ndatums - 1) * sizeof(ParamExternData));
paramLI->paramFetch = plpgsql_param_fetch;
paramLI->paramFetchArg = (void *) estate;
paramLI->parserSetup = (ParserSetupHook) plpgsql_parser_setup;
diff --git a/src/pl/plpgsql/src/plpgsql.h b/src/pl/plpgsql/src/plpgsql.h
index 0429f68d4c..e50d7eb45f 100644
--- a/src/pl/plpgsql/src/plpgsql.h
+++ b/src/pl/plpgsql/src/plpgsql.h
@@ -870,7 +870,7 @@ extern PLpgSQL_type *plpgsql_parse_cwordtype(List *idents);
extern PLpgSQL_type *plpgsql_parse_wordrowtype(char *ident);
extern PLpgSQL_type *plpgsql_parse_cwordrowtype(List *idents);
extern PLpgSQL_type *plpgsql_build_datatype(Oid typeOid, int32 typmod,
- Oid collation);
+ Oid collation);
extern PLpgSQL_variable *plpgsql_build_variable(const char *refname, int lineno,
PLpgSQL_type *dtype,
bool add2namespace);
@@ -906,7 +906,7 @@ extern void plpgsql_subxact_cb(SubXactEvent event, SubTransactionId mySubid,
extern Oid exec_get_datum_type(PLpgSQL_execstate *estate,
PLpgSQL_datum *datum);
extern Oid exec_get_datum_collation(PLpgSQL_execstate *estate,
- PLpgSQL_datum *datum);
+ PLpgSQL_datum *datum);
/* ----------
* Functions for namespace handling in pl_funcs.c
diff --git a/src/pl/plpython/plpython.c b/src/pl/plpython/plpython.c
index 47d898a976..5e600daa96 100644
--- a/src/pl/plpython/plpython.c
+++ b/src/pl/plpython/plpython.c
@@ -159,7 +159,7 @@ typedef union PLyTypeInput
struct PLyObToDatum;
typedef Datum (*PLyObToDatumFunc) (struct PLyObToDatum *, int32 typmod,
- PyObject *);
+ PyObject *);
typedef struct PLyObToDatum
{
@@ -288,8 +288,8 @@ static HTAB *PLy_spi_exceptions;
typedef struct PLyExceptionEntry
{
- int sqlstate; /* hash key, must be first */
- PyObject *exc; /* corresponding exception */
+ int sqlstate; /* hash key, must be first */
+ PyObject *exc; /* corresponding exception */
} PLyExceptionEntry;
@@ -315,7 +315,7 @@ PG_FUNCTION_INFO_V1(plpython_inline_handler);
/* most of the remaining of the declarations, all static */
/*
- * These should only be called once from _PG_init. Initialize the
+ * These should only be called once from _PG_init. Initialize the
* Python interpreter and global data.
*/
static void PLy_init_interp(void);
@@ -374,7 +374,7 @@ static PyObject *PLy_procedure_call(PLyProcedure *, char *, PyObject *);
static PLyProcedure *PLy_procedure_get(Oid fn_oid, bool is_trigger);
static PLyProcedure *PLy_procedure_create(HeapTuple procTup,
- Oid fn_oid, bool is_trigger);
+ Oid fn_oid, bool is_trigger);
static void PLy_procedure_compile(PLyProcedure *, const char *);
static char *PLy_procedure_munge_source(const char *, const char *);
@@ -660,17 +660,16 @@ PLy_trigger_handler(FunctionCallInfo fcinfo, PLyProcedure *proc)
HeapTuple rv = NULL;
PyObject *volatile plargs = NULL;
PyObject *volatile plrv = NULL;
- TriggerData *tdata;
+ TriggerData *tdata;
Assert(CALLED_AS_TRIGGER(fcinfo));
/*
- * Input/output conversion for trigger tuples. Use the result
- * TypeInfo variable to store the tuple conversion info. We do
- * this over again on each call to cover the possibility that the
- * relation's tupdesc changed since the trigger was last called.
- * PLy_input_tuple_funcs and PLy_output_tuple_funcs are
- * responsible for not doing repetitive work.
+ * Input/output conversion for trigger tuples. Use the result TypeInfo
+ * variable to store the tuple conversion info. We do this over again on
+ * each call to cover the possibility that the relation's tupdesc changed
+ * since the trigger was last called. PLy_input_tuple_funcs and
+ * PLy_output_tuple_funcs are responsible for not doing repetitive work.
*/
tdata = (TriggerData *) fcinfo->context;
@@ -1086,8 +1085,8 @@ PLy_function_handler(FunctionCallInfo fcinfo, PLyProcedure *proc)
if (!proc->is_setof || proc->setof == NULL)
{
/*
- * Simple type returning function or first time for SETOF function:
- * actually execute the function.
+ * Simple type returning function or first time for SETOF
+ * function: actually execute the function.
*/
plargs = PLy_function_build_args(fcinfo, proc);
plrv = PLy_procedure_call(proc, "args", plargs);
@@ -1304,26 +1303,26 @@ static PyObject *
PLy_procedure_call(PLyProcedure *proc, char *kargs, PyObject *vargs)
{
PyObject *rv;
- int volatile save_subxact_level = list_length(explicit_subtransactions);
+ int volatile save_subxact_level = list_length(explicit_subtransactions);
PyDict_SetItemString(proc->globals, kargs, vargs);
PG_TRY();
{
#if PY_VERSION_HEX >= 0x03020000
- rv = PyEval_EvalCode(proc->code,
- proc->globals, proc->globals);
+ rv = PyEval_EvalCode(proc->code,
+ proc->globals, proc->globals);
#else
- rv = PyEval_EvalCode((PyCodeObject *) proc->code,
- proc->globals, proc->globals);
+ rv = PyEval_EvalCode((PyCodeObject *) proc->code,
+ proc->globals, proc->globals);
#endif
- /*
- * Since plpy will only let you close subtransactions that
- * you started, you cannot *unnest* subtransactions, only
- * *nest* them without closing.
- */
- Assert(list_length(explicit_subtransactions) >= save_subxact_level);
+ /*
+ * Since plpy will only let you close subtransactions that you
+ * started, you cannot *unnest* subtransactions, only *nest* them
+ * without closing.
+ */
+ Assert(list_length(explicit_subtransactions) >= save_subxact_level);
}
PG_CATCH();
{
@@ -1470,8 +1469,8 @@ PLy_procedure_valid(PLyProcedure *proc, HeapTuple procTup)
/* If there are composite input arguments, they might have changed */
for (i = 0; i < proc->nargs; i++)
{
- Oid relid;
- HeapTuple relTup;
+ Oid relid;
+ HeapTuple relTup;
/* Short-circuit on first changed argument */
if (!valid)
@@ -1516,7 +1515,7 @@ static PLyProcedure *
PLy_procedure_get(Oid fn_oid, bool is_trigger)
{
HeapTuple procTup;
- PLyProcedureEntry * volatile entry;
+ PLyProcedureEntry *volatile entry;
bool found;
procTup = SearchSysCache1(PROCOID, ObjectIdGetDatum(fn_oid));
@@ -1636,8 +1635,8 @@ PLy_procedure_create(HeapTuple procTup, Oid fn_oid, bool is_trigger)
procStruct->prorettype != RECORDOID)
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("PL/Python functions cannot return type %s",
- format_type_be(procStruct->prorettype))));
+ errmsg("PL/Python functions cannot return type %s",
+ format_type_be(procStruct->prorettype))));
}
if (rvTypeStruct->typtype == TYPTYPE_COMPOSITE ||
@@ -1986,8 +1985,11 @@ PLy_output_record_funcs(PLyTypeInfo *arg, TupleDesc desc)
arg->out.d.typmod = desc->tdtypmod;
/* proceed with normal I/O function caching */
PLy_output_tuple_funcs(arg, desc);
- /* it should change is_rowtype to 1, so we won't go through this again
- * unless the the output record description changes */
+
+ /*
+ * it should change is_rowtype to 1, so we won't go through this again
+ * unless the the output record description changes
+ */
Assert(arg->is_rowtype == 1);
}
@@ -2373,9 +2375,9 @@ PLyDict_FromTuple(PLyTypeInfo *info, HeapTuple tuple, TupleDesc desc)
}
/*
- * Convert a Python object to a PostgreSQL tuple, using all supported
- * conversion methods: tuple as a sequence, as a mapping or as an object that
- * has __getattr__ support.
+ * Convert a Python object to a PostgreSQL tuple, using all supported
+ * conversion methods: tuple as a sequence, as a mapping or as an object that
+ * has __getattr__ support.
*/
static HeapTuple
PLyObject_ToTuple(PLyTypeInfo *info, TupleDesc desc, PyObject *plrv)
@@ -2469,7 +2471,7 @@ PLyObject_ToComposite(PLyObToDatum *arg, int32 typmod, PyObject *plrv)
{
HeapTuple tuple = NULL;
Datum rv;
- PLyTypeInfo info;
+ PLyTypeInfo info;
TupleDesc desc;
if (typmod != -1)
@@ -2977,7 +2979,7 @@ static PyTypeObject PLy_SubtransactionType = {
/*
* methods
*/
- PLy_subtransaction_dealloc, /* tp_dealloc */
+ PLy_subtransaction_dealloc, /* tp_dealloc */
0, /* tp_print */
0, /* tp_getattr */
0, /* tp_setattr */
@@ -3000,7 +3002,7 @@ static PyTypeObject PLy_SubtransactionType = {
0, /* tp_weaklistoffset */
0, /* tp_iter */
0, /* tp_iternext */
- PLy_subtransaction_methods, /* tp_tpmethods */
+ PLy_subtransaction_methods, /* tp_tpmethods */
};
static PyMethodDef PLy_methods[] = {
@@ -3264,12 +3266,11 @@ PLy_spi_prepare(PyObject *self, PyObject *args)
PG_TRY();
{
- int i;
+ int i;
/*
- * the other loop might throw an exception, if PLyTypeInfo
- * member isn't properly initialized the Py_DECREF(plan) will
- * go boom
+ * the other loop might throw an exception, if PLyTypeInfo member
+ * isn't properly initialized the Py_DECREF(plan) will go boom
*/
for (i = 0; i < nargs; i++)
{
@@ -3311,9 +3312,10 @@ PLy_spi_prepare(PyObject *self, PyObject *args)
elog(ERROR, "cache lookup failed for type %u", typeId);
Py_DECREF(optr);
+
/*
- * set optr to NULL, so we won't try to unref it again in
- * case of an error
+ * set optr to NULL, so we won't try to unref it again in case of
+ * an error
*/
optr = NULL;
@@ -3324,7 +3326,7 @@ PLy_spi_prepare(PyObject *self, PyObject *args)
else
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("plpy.prepare does not support composite types")));
+ errmsg("plpy.prepare does not support composite types")));
ReleaseSysCache(typeTup);
}
@@ -3355,9 +3357,9 @@ PLy_spi_prepare(PyObject *self, PyObject *args)
}
PG_CATCH();
{
- ErrorData *edata;
+ ErrorData *edata;
PLyExceptionEntry *entry;
- PyObject *exc;
+ PyObject *exc;
/* Save error info */
MemoryContextSwitchTo(oldcontext);
@@ -3372,9 +3374,9 @@ PLy_spi_prepare(PyObject *self, PyObject *args)
CurrentResourceOwner = oldowner;
/*
- * If AtEOSubXact_SPI() popped any SPI context of the subxact, it
- * will have left us in a disconnected state. We need this hack to
- * return to connected state.
+ * If AtEOSubXact_SPI() popped any SPI context of the subxact, it will
+ * have left us in a disconnected state. We need this hack to return
+ * to connected state.
*/
SPI_restore_connection();
@@ -3470,7 +3472,7 @@ PLy_spi_execute_plan(PyObject *ob, PyObject *list, long limit)
PG_TRY();
{
- char * volatile nulls;
+ char *volatile nulls;
volatile int j;
if (nargs > 0)
@@ -3535,9 +3537,9 @@ PLy_spi_execute_plan(PyObject *ob, PyObject *list, long limit)
PG_CATCH();
{
int k;
- ErrorData *edata;
+ ErrorData *edata;
PLyExceptionEntry *entry;
- PyObject *exc;
+ PyObject *exc;
/* Save error info */
MemoryContextSwitchTo(oldcontext);
@@ -3563,9 +3565,9 @@ PLy_spi_execute_plan(PyObject *ob, PyObject *list, long limit)
CurrentResourceOwner = oldowner;
/*
- * If AtEOSubXact_SPI() popped any SPI context of the subxact, it
- * will have left us in a disconnected state. We need this hack to
- * return to connected state.
+ * If AtEOSubXact_SPI() popped any SPI context of the subxact, it will
+ * have left us in a disconnected state. We need this hack to return
+ * to connected state.
*/
SPI_restore_connection();
@@ -3636,9 +3638,9 @@ PLy_spi_execute_query(char *query, long limit)
}
PG_CATCH();
{
- ErrorData *edata;
- PLyExceptionEntry *entry;
- PyObject *exc;
+ ErrorData *edata;
+ PLyExceptionEntry *entry;
+ PyObject *exc;
/* Save error info */
MemoryContextSwitchTo(oldcontext);
@@ -3651,9 +3653,9 @@ PLy_spi_execute_query(char *query, long limit)
CurrentResourceOwner = oldowner;
/*
- * If AtEOSubXact_SPI() popped any SPI context of the subxact, it
- * will have left us in a disconnected state. We need this hack to
- * return to connected state.
+ * If AtEOSubXact_SPI() popped any SPI context of the subxact, it will
+ * have left us in a disconnected state. We need this hack to return
+ * to connected state.
*/
SPI_restore_connection();
@@ -3877,8 +3879,8 @@ PLy_subtransaction_exit(PyObject *self, PyObject *args)
PLy_free(subxactdata);
/*
- * AtEOSubXact_SPI() should not have popped any SPI context, but
- * just in case it did, make sure we remain connected.
+ * AtEOSubXact_SPI() should not have popped any SPI context, but just in
+ * case it did, make sure we remain connected.
*/
SPI_restore_connection();
@@ -3937,11 +3939,11 @@ PLy_add_exceptions(PyObject *plpy)
if (PyModule_AddObject(plpy, "spiexceptions", excmod) < 0)
PLy_elog(ERROR, "failed to add the spiexceptions module");
-/*
+/*
* XXX it appears that in some circumstances the reference count of the
* spiexceptions module drops to zero causing a Python assert failure when
* the garbage collector visits the module. This has been observed on the
- * buildfarm. To fix this, add an additional ref for the module here.
+ * buildfarm. To fix this, add an additional ref for the module here.
*
* This shouldn't cause a memory leak - we don't want this garbage collected,
* and this function shouldn't be called more than once per backend.
@@ -4329,9 +4331,9 @@ PLy_exception_set_plural(PyObject *exc,
static void
PLy_spi_exception_set(PyObject *excclass, ErrorData *edata)
{
- PyObject *args = NULL;
- PyObject *spierror = NULL;
- PyObject *spidata = NULL;
+ PyObject *args = NULL;
+ PyObject *spierror = NULL;
+ PyObject *spidata = NULL;
args = Py_BuildValue("(s)", edata->message);
if (!args)
@@ -4378,11 +4380,13 @@ PLy_elog(int elevel, const char *fmt,...)
char *tbmsg;
int tb_depth;
StringInfoData emsg;
- PyObject *exc, *val, *tb;
- const char *primary = NULL;
- char *detail = NULL;
- char *hint = NULL;
- char *query = NULL;
+ PyObject *exc,
+ *val,
+ *tb;
+ const char *primary = NULL;
+ char *detail = NULL;
+ char *hint = NULL;
+ char *query = NULL;
int position = 0;
PyErr_Fetch(&exc, &val, &tb);
@@ -4463,7 +4467,7 @@ PLy_elog(int elevel, const char *fmt,...)
static void
PLy_get_spi_error_data(PyObject *exc, char **detail, char **hint, char **query, int *position)
{
- PyObject *spidata = NULL;
+ PyObject *spidata = NULL;
spidata = PyObject_GetAttrString(exc, "spidata");
if (!spidata)
@@ -4484,9 +4488,9 @@ cleanup:
static char *
get_source_line(const char *src, int lineno)
{
- const char *s = NULL;
- const char *next = src;
- int current = 0;
+ const char *s = NULL;
+ const char *next = src;
+ int current = 0;
while (current < lineno)
{
@@ -4597,11 +4601,11 @@ PLy_traceback(char **xmsg, char **tbmsg, int *tb_depth)
appendStringInfoString(&tbstr, "Traceback (most recent call last):");
while (tb != NULL && tb != Py_None)
{
- PyObject *volatile tb_prev = NULL;
- PyObject *volatile frame = NULL;
- PyObject *volatile code = NULL;
- PyObject *volatile name = NULL;
- PyObject *volatile lineno = NULL;
+ PyObject *volatile tb_prev = NULL;
+ PyObject *volatile frame = NULL;
+ PyObject *volatile code = NULL;
+ PyObject *volatile name = NULL;
+ PyObject *volatile lineno = NULL;
PG_TRY();
{
@@ -4634,15 +4638,14 @@ PLy_traceback(char **xmsg, char **tbmsg, int *tb_depth)
/* The first frame always points at , skip it. */
if (*tb_depth > 0)
{
- char *proname;
- char *fname;
- char *line;
- long plain_lineno;
+ char *proname;
+ char *fname;
+ char *line;
+ long plain_lineno;
/*
- * The second frame points at the internal function, but
- * to mimick Python error reporting we want to say
- * .
+ * The second frame points at the internal function, but to mimick
+ * Python error reporting we want to say .
*/
if (*tb_depth == 1)
fname = "";
@@ -4654,22 +4657,22 @@ PLy_traceback(char **xmsg, char **tbmsg, int *tb_depth)
if (proname == NULL)
appendStringInfo(
- &tbstr, "\n PL/Python anonymous code block, line %ld, in %s",
- plain_lineno - 1, fname);
+ &tbstr, "\n PL/Python anonymous code block, line %ld, in %s",
+ plain_lineno - 1, fname);
else
appendStringInfo(
&tbstr, "\n PL/Python function \"%s\", line %ld, in %s",
- proname, plain_lineno - 1, fname);
+ proname, plain_lineno - 1, fname);
if (PLy_curr_procedure)
{
/*
- * If we know the current procedure, append the exact
- * line from the source, again mimicking Python's
- * traceback.py module behavior. We could store the
- * already line-split source to avoid splitting it
- * every time, but producing a traceback is not the
- * most important scenario to optimize for.
+ * If we know the current procedure, append the exact line
+ * from the source, again mimicking Python's traceback.py
+ * module behavior. We could store the already line-split
+ * source to avoid splitting it every time, but producing a
+ * traceback is not the most important scenario to optimize
+ * for.
*/
line = get_source_line(PLy_curr_procedure->src, plain_lineno);
if (line)
@@ -4813,7 +4816,6 @@ PLyUnicode_FromString(const char *s)
return o;
}
-
#endif /* PY_MAJOR_VERSION >= 3 */
#if PY_MAJOR_VERSION < 3
diff --git a/src/pl/tcl/pltcl.c b/src/pl/tcl/pltcl.c
index 6e8c5c05b5..7b952b27e1 100644
--- a/src/pl/tcl/pltcl.c
+++ b/src/pl/tcl/pltcl.c
@@ -95,9 +95,9 @@ PG_MODULE_MAGIC;
**********************************************************************/
typedef struct pltcl_interp_desc
{
- Oid user_id; /* Hash key (must be first!) */
- Tcl_Interp *interp; /* The interpreter */
- Tcl_HashTable query_hash; /* pltcl_query_desc structs */
+ Oid user_id; /* Hash key (must be first!) */
+ Tcl_Interp *interp; /* The interpreter */
+ Tcl_HashTable query_hash; /* pltcl_query_desc structs */
} pltcl_interp_desc;
@@ -148,18 +148,19 @@ typedef struct pltcl_query_desc
**********************************************************************/
typedef struct pltcl_proc_key
{
- Oid proc_id; /* Function OID */
+ Oid proc_id; /* Function OID */
+
/*
* is_trigger is really a bool, but declare as Oid to ensure this struct
* contains no padding
*/
- Oid is_trigger; /* is it a trigger function? */
- Oid user_id; /* User calling the function, or 0 */
+ Oid is_trigger; /* is it a trigger function? */
+ Oid user_id; /* User calling the function, or 0 */
} pltcl_proc_key;
typedef struct pltcl_proc_ptr
{
- pltcl_proc_key proc_key; /* Hash key (must be first!) */
+ pltcl_proc_key proc_key; /* Hash key (must be first!) */
pltcl_proc_desc *proc_ptr;
} pltcl_proc_ptr;
@@ -196,7 +197,7 @@ static HeapTuple pltcl_trigger_handler(PG_FUNCTION_ARGS, bool pltrusted);
static void throw_tcl_error(Tcl_Interp *interp, const char *proname);
static pltcl_proc_desc *compile_pltcl_function(Oid fn_oid, Oid tgreloid,
- bool pltrusted);
+ bool pltrusted);
static int pltcl_elog(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[]);
diff --git a/src/port/chklocale.c b/src/port/chklocale.c
index 62932c2005..e4f3dc99e0 100644
--- a/src/port/chklocale.c
+++ b/src/port/chklocale.c
@@ -333,7 +333,7 @@ pg_get_encoding_from_locale(const char *ctype, bool write_message)
ereport(WARNING,
(errmsg("could not determine encoding for locale \"%s\": codeset is \"%s\"",
ctype, sys),
- errdetail("Please report this to .")));
+ errdetail("Please report this to .")));
#endif
}
diff --git a/src/port/crypt.c b/src/port/crypt.c
index 7f18e1d2a7..9347d3b47c 100644
--- a/src/port/crypt.c
+++ b/src/port/crypt.c
@@ -236,7 +236,7 @@ typedef union
#if defined(B64)
B64 b64;
#endif
-} C_block;
+} C_block;
/*
* Convert twenty-four-bit long in host-order
diff --git a/src/port/dirmod.c b/src/port/dirmod.c
index b6a5564c2c..17fd96573d 100644
--- a/src/port/dirmod.c
+++ b/src/port/dirmod.c
@@ -211,7 +211,7 @@ typedef struct
WORD PrintNameOffset;
WORD PrintNameLength;
WCHAR PathBuffer[1];
-} REPARSE_JUNCTION_DATA_BUFFER;
+} REPARSE_JUNCTION_DATA_BUFFER;
#define REPARSE_JUNCTION_DATA_BUFFER_HEADER_SIZE \
FIELD_OFFSET(REPARSE_JUNCTION_DATA_BUFFER, SubstituteNameOffset)
diff --git a/src/port/exec.c b/src/port/exec.c
index 6027917b57..21a951c424 100644
--- a/src/port/exec.c
+++ b/src/port/exec.c
@@ -358,7 +358,7 @@ pipe_read_line(char *cmd, char *line, int maxsize)
if (fgets(line, maxsize, pgver) == NULL)
{
perror("fgets failure");
- pclose(pgver); /* no error checking */
+ pclose(pgver); /* no error checking */
return NULL;
}
diff --git a/src/port/getaddrinfo.c b/src/port/getaddrinfo.c
index fabd50dddb..db19878ae1 100644
--- a/src/port/getaddrinfo.c
+++ b/src/port/getaddrinfo.c
@@ -329,7 +329,7 @@ gai_strerror(int errcode)
return "Not enough memory";
#endif
#ifdef EAI_NODATA
-#if !defined(WIN64) && !defined(WIN32_ONLY_COMPILER) /* MSVC/WIN64 duplicate */
+#if !defined(WIN64) && !defined(WIN32_ONLY_COMPILER) /* MSVC/WIN64 duplicate */
case EAI_NODATA:
return "No host data of that type was found";
#endif
@@ -390,9 +390,9 @@ getnameinfo(const struct sockaddr * sa, int salen,
if (sa->sa_family == AF_INET)
{
if (inet_net_ntop(AF_INET, &((struct sockaddr_in *) sa)->sin_addr,
- sa->sa_family == AF_INET ? 32 : 128,
- node, nodelen) == NULL)
- return EAI_MEMORY;
+ sa->sa_family == AF_INET ? 32 : 128,
+ node, nodelen) == NULL)
+ return EAI_MEMORY;
}
else
return EAI_MEMORY;
diff --git a/src/port/inet_net_ntop.c b/src/port/inet_net_ntop.c
index 7ed3867c05..9c3c93b8ec 100644
--- a/src/port/inet_net_ntop.c
+++ b/src/port/inet_net_ntop.c
@@ -78,11 +78,11 @@ char *
inet_net_ntop(int af, const void *src, int bits, char *dst, size_t size)
{
/*
- * We need to cover both the address family constants used by the PG
- * inet type (PGSQL_AF_INET and PGSQL_AF_INET6) and those used by the
- * system libraries (AF_INET and AF_INET6). We can safely assume
- * PGSQL_AF_INET == AF_INET, but the INET6 constants are very likely
- * to be different. If AF_INET6 isn't defined, silently ignore it.
+ * We need to cover both the address family constants used by the PG inet
+ * type (PGSQL_AF_INET and PGSQL_AF_INET6) and those used by the system
+ * libraries (AF_INET and AF_INET6). We can safely assume PGSQL_AF_INET
+ * == AF_INET, but the INET6 constants are very likely to be different.
+ * If AF_INET6 isn't defined, silently ignore it.
*/
switch (af)
{
diff --git a/src/port/path.c b/src/port/path.c
index df2c4e7be6..0d40a0bb9c 100644
--- a/src/port/path.c
+++ b/src/port/path.c
@@ -374,21 +374,22 @@ path_is_relative_and_below_cwd(const char *path)
else if (path_contains_parent_reference(path))
return false;
#ifdef WIN32
+
/*
- * On Win32, a drive letter _not_ followed by a slash, e.g. 'E:abc', is
- * relative to the cwd on that drive, or the drive's root directory
- * if that drive has no cwd. Because the path itself cannot tell us
- * which is the case, we have to assume the worst, i.e. that it is not
- * below the cwd. We could use GetFullPathName() to find the full path
- * but that could change if the current directory for the drive changes
- * underneath us, so we just disallow it.
+ * On Win32, a drive letter _not_ followed by a slash, e.g. 'E:abc', is
+ * relative to the cwd on that drive, or the drive's root directory if
+ * that drive has no cwd. Because the path itself cannot tell us which is
+ * the case, we have to assume the worst, i.e. that it is not below the
+ * cwd. We could use GetFullPathName() to find the full path but that
+ * could change if the current directory for the drive changes underneath
+ * us, so we just disallow it.
*/
else if (isalpha((unsigned char) path[0]) && path[1] == ':' &&
- !IS_DIR_SEP(path[2]))
+ !IS_DIR_SEP(path[2]))
return false;
#endif
else
- return true;
+ return true;
}
/*
diff --git a/src/port/pgmkdirp.c b/src/port/pgmkdirp.c
index b65db5e969..84367f7c9b 100644
--- a/src/port/pgmkdirp.c
+++ b/src/port/pgmkdirp.c
@@ -9,18 +9,18 @@
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
+ * notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
* 4. Neither the name of the University nor the names of its contributors
- * may be used to endorse or promote products derived from this software
- * without specific prior written permission.
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
diff --git a/src/port/snprintf.c b/src/port/snprintf.c
index 88cb4d4c2b..9f719505f4 100644
--- a/src/port/snprintf.c
+++ b/src/port/snprintf.c
@@ -108,7 +108,7 @@ typedef struct
/* bufend == NULL is for sprintf, where we assume buf is big enough */
FILE *stream; /* eventual output destination, or NULL */
int nchars; /* # chars already sent to stream */
-} PrintfTarget;
+} PrintfTarget;
/*
* Info about the type and value of a formatting parameter. Note that we
@@ -124,7 +124,7 @@ typedef enum
ATYPE_LONGLONG,
ATYPE_DOUBLE,
ATYPE_CHARPTR
-} PrintfArgType;
+} PrintfArgType;
typedef union
{
@@ -133,11 +133,11 @@ typedef union
int64 ll;
double d;
char *cptr;
-} PrintfArgValue;
+} PrintfArgValue;
-static void flushbuffer(PrintfTarget * target);
-static int dopr(PrintfTarget * target, const char *format, va_list args);
+static void flushbuffer(PrintfTarget *target);
+static int dopr(PrintfTarget *target, const char *format, va_list args);
int
@@ -257,7 +257,7 @@ pg_printf(const char *fmt,...)
/* call this only when stream is defined */
static void
-flushbuffer(PrintfTarget * target)
+flushbuffer(PrintfTarget *target)
{
size_t nc = target->bufptr - target->bufstart;
@@ -268,29 +268,29 @@ flushbuffer(PrintfTarget * target)
static void fmtstr(char *value, int leftjust, int minlen, int maxwidth,
- int pointflag, PrintfTarget * target);
-static void fmtptr(void *value, PrintfTarget * target);
+ int pointflag, PrintfTarget *target);
+static void fmtptr(void *value, PrintfTarget *target);
static void fmtint(int64 value, char type, int forcesign,
int leftjust, int minlen, int zpad, int precision, int pointflag,
- PrintfTarget * target);
-static void fmtchar(int value, int leftjust, int minlen, PrintfTarget * target);
+ PrintfTarget *target);
+static void fmtchar(int value, int leftjust, int minlen, PrintfTarget *target);
static void fmtfloat(double value, char type, int forcesign,
int leftjust, int minlen, int zpad, int precision, int pointflag,
- PrintfTarget * target);
-static void dostr(const char *str, int slen, PrintfTarget * target);
-static void dopr_outch(int c, PrintfTarget * target);
+ PrintfTarget *target);
+static void dostr(const char *str, int slen, PrintfTarget *target);
+static void dopr_outch(int c, PrintfTarget *target);
static int adjust_sign(int is_negative, int forcesign, int *signvalue);
static void adjust_padlen(int minlen, int vallen, int leftjust, int *padlen);
static void leading_pad(int zpad, int *signvalue, int *padlen,
- PrintfTarget * target);
-static void trailing_pad(int *padlen, PrintfTarget * target);
+ PrintfTarget *target);
+static void trailing_pad(int *padlen, PrintfTarget *target);
/*
* dopr(): poor man's version of doprintf
*/
static int
-dopr(PrintfTarget * target, const char *format, va_list args)
+dopr(PrintfTarget *target, const char *format, va_list args)
{
const char *format_start = format;
int ch;
@@ -764,7 +764,7 @@ pg_strnlen(const char *str, size_t maxlen)
static void
fmtstr(char *value, int leftjust, int minlen, int maxwidth,
- int pointflag, PrintfTarget * target)
+ int pointflag, PrintfTarget *target)
{
int padlen,
vallen; /* amount to pad */
@@ -792,7 +792,7 @@ fmtstr(char *value, int leftjust, int minlen, int maxwidth,
}
static void
-fmtptr(void *value, PrintfTarget * target)
+fmtptr(void *value, PrintfTarget *target)
{
int vallen;
char convert[64];
@@ -806,7 +806,7 @@ fmtptr(void *value, PrintfTarget * target)
static void
fmtint(int64 value, char type, int forcesign, int leftjust,
int minlen, int zpad, int precision, int pointflag,
- PrintfTarget * target)
+ PrintfTarget *target)
{
uint64 base;
int dosign;
@@ -883,7 +883,7 @@ fmtint(int64 value, char type, int forcesign, int leftjust,
}
static void
-fmtchar(int value, int leftjust, int minlen, PrintfTarget * target)
+fmtchar(int value, int leftjust, int minlen, PrintfTarget *target)
{
int padlen = 0; /* amount to pad */
@@ -903,7 +903,7 @@ fmtchar(int value, int leftjust, int minlen, PrintfTarget * target)
static void
fmtfloat(double value, char type, int forcesign, int leftjust,
int minlen, int zpad, int precision, int pointflag,
- PrintfTarget * target)
+ PrintfTarget *target)
{
int signvalue = 0;
int vallen;
@@ -932,7 +932,7 @@ fmtfloat(double value, char type, int forcesign, int leftjust,
}
static void
-dostr(const char *str, int slen, PrintfTarget * target)
+dostr(const char *str, int slen, PrintfTarget *target)
{
while (slen > 0)
{
@@ -959,7 +959,7 @@ dostr(const char *str, int slen, PrintfTarget * target)
}
static void
-dopr_outch(int c, PrintfTarget * target)
+dopr_outch(int c, PrintfTarget *target)
{
if (target->bufend != NULL && target->bufptr >= target->bufend)
{
@@ -998,7 +998,7 @@ adjust_padlen(int minlen, int vallen, int leftjust, int *padlen)
static void
-leading_pad(int zpad, int *signvalue, int *padlen, PrintfTarget * target)
+leading_pad(int zpad, int *signvalue, int *padlen, PrintfTarget *target)
{
if (*padlen > 0 && zpad)
{
@@ -1031,7 +1031,7 @@ leading_pad(int zpad, int *signvalue, int *padlen, PrintfTarget * target)
static void
-trailing_pad(int *padlen, PrintfTarget * target)
+trailing_pad(int *padlen, PrintfTarget *target)
{
while (*padlen < 0)
{
diff --git a/src/port/unsetenv.c b/src/port/unsetenv.c
index 248cead79d..339e172593 100644
--- a/src/port/unsetenv.c
+++ b/src/port/unsetenv.c
@@ -31,8 +31,8 @@ unsetenv(const char *name)
* that we zap the actual environ member. However, there are some libc
* implementations (notably recent BSDs) that do not obey SUS but copy the
* presented string. This method fails on such platforms. Hopefully all
- * such platforms have unsetenv() and thus won't be using this hack.
- * See: http://www.greenend.org.uk/rjk/2008/putenv.html
+ * such platforms have unsetenv() and thus won't be using this hack. See:
+ * http://www.greenend.org.uk/rjk/2008/putenv.html
*
* Note that repeatedly setting and unsetting a var using this code will
* leak memory.
diff --git a/src/test/isolation/isolation_main.c b/src/test/isolation/isolation_main.c
index 7d2cfa2ea8..2df12f879e 100644
--- a/src/test/isolation/isolation_main.c
+++ b/src/test/isolation/isolation_main.c
@@ -18,9 +18,9 @@
*/
static PID_TYPE
isolation_start_test(const char *testname,
- _stringlist ** resultfiles,
- _stringlist ** expectfiles,
- _stringlist ** tags)
+ _stringlist ** resultfiles,
+ _stringlist ** expectfiles,
+ _stringlist ** tags)
{
PID_TYPE pid;
char infile[MAXPGPATH];
diff --git a/src/test/isolation/isolationtester.c b/src/test/isolation/isolationtester.c
index 9946051945..44a4858c96 100644
--- a/src/test/isolation/isolationtester.c
+++ b/src/test/isolation/isolationtester.c
@@ -17,16 +17,16 @@
#include "isolationtester.h"
-static PGconn **conns = NULL;
-static int nconns = 0;
+static PGconn **conns = NULL;
+static int nconns = 0;
-static void run_all_permutations(TestSpec *testspec);
-static void run_all_permutations_recurse(TestSpec *testspec, int nsteps, Step **steps);
-static void run_named_permutations(TestSpec *testspec);
-static void run_permutation(TestSpec *testspec, int nsteps, Step **steps);
+static void run_all_permutations(TestSpec * testspec);
+static void run_all_permutations_recurse(TestSpec * testspec, int nsteps, Step ** steps);
+static void run_named_permutations(TestSpec * testspec);
+static void run_permutation(TestSpec * testspec, int nsteps, Step ** steps);
-static int step_qsort_cmp(const void *a, const void *b);
-static int step_bsearch_cmp(const void *a, const void *b);
+static int step_qsort_cmp(const void *a, const void *b);
+static int step_bsearch_cmp(const void *a, const void *b);
static void printResultSet(PGresult *res);
@@ -35,6 +35,7 @@ static void
exit_nicely(void)
{
int i;
+
for (i = 0; i < nconns; i++)
PQfinish(conns[i]);
exit(1);
@@ -49,9 +50,8 @@ main(int argc, char **argv)
/*
* If the user supplies a parameter on the command line, use it as the
- * conninfo string; otherwise default to setting dbname=postgres and
- * using environment variables or defaults for all other connection
- * parameters.
+ * conninfo string; otherwise default to setting dbname=postgres and using
+ * environment variables or defaults for all other connection parameters.
*/
if (argc > 1)
conninfo = argv[1];
@@ -68,7 +68,7 @@ main(int argc, char **argv)
conns = calloc(nconns, sizeof(PGconn *));
for (i = 0; i < testspec->nsessions; i++)
{
- PGresult *res;
+ PGresult *res;
conns[i] = PQconnectdb(conninfo);
if (PQstatus(conns[i]) != CONNECTION_OK)
@@ -94,8 +94,9 @@ main(int argc, char **argv)
/* Set the session index fields in steps. */
for (i = 0; i < testspec->nsessions; i++)
{
- Session *session = testspec->sessions[i];
- int stepindex;
+ Session *session = testspec->sessions[i];
+ int stepindex;
+
for (stepindex = 0; stepindex < session->nsteps; stepindex++)
session->steps[stepindex]->session = i;
}
@@ -121,7 +122,7 @@ static int *piles;
* Run all permutations of the steps and sessions.
*/
static void
-run_all_permutations(TestSpec *testspec)
+run_all_permutations(TestSpec * testspec)
{
int nsteps;
int i;
@@ -135,13 +136,13 @@ run_all_permutations(TestSpec *testspec)
steps = malloc(sizeof(Step *) * nsteps);
/*
- * To generate the permutations, we conceptually put the steps of
- * each session on a pile. To generate a permuation, we pick steps
- * from the piles until all piles are empty. By picking steps from
- * piles in different order, we get different permutations.
+ * To generate the permutations, we conceptually put the steps of each
+ * session on a pile. To generate a permuation, we pick steps from the
+ * piles until all piles are empty. By picking steps from piles in
+ * different order, we get different permutations.
*
- * A pile is actually just an integer which tells how many steps
- * we've already picked from this pile.
+ * A pile is actually just an integer which tells how many steps we've
+ * already picked from this pile.
*/
piles = malloc(sizeof(int) * testspec->nsessions);
for (i = 0; i < testspec->nsessions; i++)
@@ -151,10 +152,10 @@ run_all_permutations(TestSpec *testspec)
}
static void
-run_all_permutations_recurse(TestSpec *testspec, int nsteps, Step **steps)
+run_all_permutations_recurse(TestSpec * testspec, int nsteps, Step ** steps)
{
- int i;
- int found = 0;
+ int i;
+ int found = 0;
for (i = 0; i < testspec->nsessions; i++)
{
@@ -181,12 +182,13 @@ run_all_permutations_recurse(TestSpec *testspec, int nsteps, Step **steps)
* Run permutations given in the test spec
*/
static void
-run_named_permutations(TestSpec *testspec)
+run_named_permutations(TestSpec * testspec)
{
- int i, j;
- int n;
- int nallsteps;
- Step **allsteps;
+ int i,
+ j;
+ int n;
+ int nallsteps;
+ Step **allsteps;
/* First create a lookup table of all steps */
nallsteps = 0;
@@ -207,7 +209,7 @@ run_named_permutations(TestSpec *testspec)
for (i = 0; i < testspec->npermutations; i++)
{
Permutation *p = testspec->permutations[i];
- Step **steps;
+ Step **steps;
steps = malloc(p->nsteps * sizeof(Step *));
@@ -215,7 +217,7 @@ run_named_permutations(TestSpec *testspec)
for (j = 0; j < p->nsteps; j++)
{
steps[j] = *((Step **) bsearch(p->stepnames[j], allsteps, nallsteps,
- sizeof(Step *), &step_bsearch_cmp));
+ sizeof(Step *), &step_bsearch_cmp));
if (steps[j] == NULL)
{
fprintf(stderr, "undefined step \"%s\" specified in permutation\n", p->stepnames[j]);
@@ -231,8 +233,8 @@ run_named_permutations(TestSpec *testspec)
static int
step_qsort_cmp(const void *a, const void *b)
{
- Step *stepa = *((Step **) a);
- Step *stepb = *((Step **) b);
+ Step *stepa = *((Step **) a);
+ Step *stepb = *((Step **) b);
return strcmp(stepa->name, stepb->name);
}
@@ -240,8 +242,8 @@ step_qsort_cmp(const void *a, const void *b)
static int
step_bsearch_cmp(const void *a, const void *b)
{
- char *stepname = (char *) a;
- Step *step = *((Step **) b);
+ char *stepname = (char *) a;
+ Step *step = *((Step **) b);
return strcmp(stepname, step->name);
}
@@ -250,10 +252,10 @@ step_bsearch_cmp(const void *a, const void *b)
* Run one permutation
*/
static void
-run_permutation(TestSpec *testspec, int nsteps, Step **steps)
+run_permutation(TestSpec * testspec, int nsteps, Step ** steps)
{
- PGresult *res;
- int i;
+ PGresult *res;
+ int i;
printf("\nstarting permutation:");
for (i = 0; i < nsteps; i++)
@@ -292,11 +294,12 @@ run_permutation(TestSpec *testspec, int nsteps, Step **steps)
/* Perform steps */
for (i = 0; i < nsteps; i++)
{
- Step *step = steps[i];
+ Step *step = steps[i];
+
printf("step %s: %s\n", step->name, step->sql);
res = PQexec(conns[step->session], step->sql);
- switch(PQresultStatus(res))
+ switch (PQresultStatus(res))
{
case PGRES_COMMAND_OK:
break;
@@ -353,20 +356,21 @@ run_permutation(TestSpec *testspec, int nsteps, Step **steps)
static void
printResultSet(PGresult *res)
{
- int nFields;
- int i, j;
-
- /* first, print out the attribute names */
- nFields = PQnfields(res);
- for (i = 0; i < nFields; i++)
- printf("%-15s", PQfname(res, i));
- printf("\n\n");
-
- /* next, print out the rows */
- for (i = 0; i < PQntuples(res); i++)
- {
- for (j = 0; j < nFields; j++)
- printf("%-15s", PQgetvalue(res, i, j));
- printf("\n");
- }
+ int nFields;
+ int i,
+ j;
+
+ /* first, print out the attribute names */
+ nFields = PQnfields(res);
+ for (i = 0; i < nFields; i++)
+ printf("%-15s", PQfname(res, i));
+ printf("\n\n");
+
+ /* next, print out the rows */
+ for (i = 0; i < PQntuples(res); i++)
+ {
+ for (j = 0; j < nFields; j++)
+ printf("%-15s", PQgetvalue(res, i, j));
+ printf("\n");
+ }
}
diff --git a/src/test/isolation/isolationtester.h b/src/test/isolation/isolationtester.h
index 1f86db8727..377c10c393 100644
--- a/src/test/isolation/isolationtester.h
+++ b/src/test/isolation/isolationtester.h
@@ -28,7 +28,7 @@ struct Session
struct Step
{
- int session;
+ int session;
char *name;
char *sql;
};
@@ -37,19 +37,19 @@ typedef struct
{
int nsteps;
char **stepnames;
-} Permutation;
+} Permutation;
typedef struct
{
char *setupsql;
char *teardownsql;
- Session **sessions;
+ Session **sessions;
int nsessions;
Permutation **permutations;
int npermutations;
-} TestSpec;
+} TestSpec;
-extern TestSpec parseresult;
+extern TestSpec parseresult;
extern int spec_yyparse(void);
diff --git a/src/test/regress/pg_regress.c b/src/test/regress/pg_regress.c
index fd7068dcc6..c639c479e4 100644
--- a/src/test/regress/pg_regress.c
+++ b/src/test/regress/pg_regress.c
@@ -1805,8 +1805,8 @@ create_database(const char *dbname)
}
/*
- * Install any requested extensions. We use CREATE IF NOT EXISTS
- * so that this will work whether or not the extension is preinstalled.
+ * Install any requested extensions. We use CREATE IF NOT EXISTS so that
+ * this will work whether or not the extension is preinstalled.
*/
for (sl = loadextension; sl != NULL; sl = sl->next)
{
--
cgit v1.2.3
From c13dc6402b6e99af9a8b7794e44d62deecafc745 Mon Sep 17 00:00:00 2001
From: Peter Eisentraut
Date: Thu, 19 May 2011 01:14:45 +0300
Subject: Spell checking and markup refinement
---
doc/src/sgml/backup.sgml | 4 ++--
doc/src/sgml/btree-gist.sgml | 4 ++--
doc/src/sgml/catalogs.sgml | 4 ++--
doc/src/sgml/config.sgml | 6 +++---
doc/src/sgml/ecpg.sgml | 36 ++++++++++++++++----------------
doc/src/sgml/extend.sgml | 2 +-
doc/src/sgml/file-fdw.sgml | 2 +-
doc/src/sgml/func.sgml | 18 ++++++++--------
doc/src/sgml/high-availability.sgml | 2 +-
doc/src/sgml/installation.sgml | 4 ++--
doc/src/sgml/libpq.sgml | 4 ++--
doc/src/sgml/monitoring.sgml | 12 +++++------
doc/src/sgml/mvcc.sgml | 2 +-
doc/src/sgml/perform.sgml | 4 ++--
doc/src/sgml/pgtestfsync.sgml | 2 +-
doc/src/sgml/plperl.sgml | 6 +++---
doc/src/sgml/plpgsql.sgml | 2 +-
doc/src/sgml/plpython.sgml | 6 +++---
doc/src/sgml/queries.sgml | 2 +-
doc/src/sgml/ref/alter_opfamily.sgml | 2 +-
doc/src/sgml/ref/cluster.sgml | 6 +++---
doc/src/sgml/ref/create_opclass.sgml | 2 +-
doc/src/sgml/ref/create_type.sgml | 2 +-
doc/src/sgml/ref/ecpg-ref.sgml | 6 +++---
doc/src/sgml/ref/pg_basebackup.sgml | 6 +++---
doc/src/sgml/ref/pg_dump.sgml | 2 +-
doc/src/sgml/release-9.1.sgml | 14 ++++++-------
doc/src/sgml/runtime.sgml | 2 +-
doc/src/sgml/sepgsql.sgml | 4 ++--
doc/src/sgml/xml2.sgml | 2 +-
src/backend/access/gist/gist.c | 4 ++--
src/backend/access/gist/gistget.c | 2 +-
src/backend/access/gist/gistxlog.c | 2 +-
src/backend/catalog/sql_features.txt | 2 +-
src/backend/commands/indexcmds.c | 2 +-
src/test/regress/expected/opr_sanity.out | 6 +++---
src/test/regress/sql/opr_sanity.sql | 6 +++---
37 files changed, 97 insertions(+), 97 deletions(-)
(limited to 'src/backend/access/gist/gistxlog.c')
diff --git a/doc/src/sgml/backup.sgml b/doc/src/sgml/backup.sgml
index 2a1c2939e2..03180cf108 100644
--- a/doc/src/sgml/backup.sgml
+++ b/doc/src/sgml/backup.sgml
@@ -818,8 +818,8 @@ SELECT pg_stop_backup();
the equivalent of pg_start_backup()>, copy and
pg_stop_backup()> steps automatically, and transfers the
backup over a regular PostgreSQL connection
- using the replication protocol, instead of requiring filesystem level
- access. pg_basebackup does not interfere with filesystem level backups
+ using the replication protocol, instead of requiring file system level
+ access. pg_basebackup does not interfere with file system level backups
taken using pg_start_backup()>/pg_stop_backup()>.
diff --git a/doc/src/sgml/btree-gist.sgml b/doc/src/sgml/btree-gist.sgml
index e52971f3d9..2275a997ba 100644
--- a/doc/src/sgml/btree-gist.sgml
+++ b/doc/src/sgml/btree-gist.sgml
@@ -25,7 +25,7 @@
standard B-tree code: the ability to enforce uniqueness. However,
they provide some other features that are not available with a B-tree
index, as described below. Also, these operator classes are useful
- when a multi-column GiST index is needed, wherein some of the columns
+ when a multicolumn GiST index is needed, wherein some of the columns
are of data types that are only indexable with GiST but other columns
are just simple data types. Lastly, these operator classes are useful for
GiST testing and as a base for developing other GiST operator classes.
@@ -55,7 +55,7 @@
Example Usage
- Simple example using btree_gist instead of btree:
+ Simple example using btree_gist instead of btree:
diff --git a/doc/src/sgml/catalogs.sgml b/doc/src/sgml/catalogs.sgml
index 7b62818ce4..8504555bac 100644
--- a/doc/src/sgml/catalogs.sgml
+++ b/doc/src/sgml/catalogs.sgml
@@ -1129,7 +1129,7 @@
pg_collation.oid
The defined collation of the column, or zero if the column is
- not of a collatable datatype.
+ not of a collatable data type.
@@ -1294,7 +1294,7 @@
Password (possibly encrypted); null if none. If the password
is encrypted, this column will begin with the string md5>
followed by a 32-character hexadecimal MD5 hash. The MD5 hash
- will be of the user's password concatenated to their username.
+ will be of the user's password concatenated to their user name.
For example, if user joe> has password xyzzy>,
PostgreSQL> will store the md5 hash of
xyzzyjoe>. A password that does not follow that
diff --git a/doc/src/sgml/config.sgml b/doc/src/sgml/config.sgml
index 5d37065626..e367c29bd5 100644
--- a/doc/src/sgml/config.sgml
+++ b/doc/src/sgml/config.sgml
@@ -3892,7 +3892,7 @@ FROM pg_stat_activity;
This option emits log lines in comma-separated-values
(CSV>) format,
with these columns:
- timestamp with milliseconds,
+ time stamp with milliseconds,
user name,
database name,
process ID,
@@ -4936,7 +4936,7 @@ SET XML OPTION { DOCUMENT | CONTENT };
Sets the collection of time zone abbreviations that will be accepted
by the server for datetime input. The default is 'Default'>,
which is a collection that works in most of the world; there are
- also 'Australia' and 'India', and other collections can be defined
+ also 'Australia' and 'India', and other collections can be defined
for a particular installation. See for more information.
@@ -6284,7 +6284,7 @@ LOG: CleanUpLock: deleting: lock(0xb7acd844) id(24688,24696,0,0,0,1)
be present in the table. It is useful for recovering data if
corruption has occurred due to a hardware or software error. You should
generally not set this on until you have given up hope of recovering
- data from the damaged pages of a table. Zerod-out pages are not
+ data from the damaged pages of a table. Zeroed-out pages are not
forced to disk so it is recommended to recreate the table or
the index before turning this parameter off again. The
default setting is off>, and it can only be changed
diff --git a/doc/src/sgml/ecpg.sgml b/doc/src/sgml/ecpg.sgml
index 751de9a2ae..9c6ca4c519 100644
--- a/doc/src/sgml/ecpg.sgml
+++ b/doc/src/sgml/ecpg.sgml
@@ -407,7 +407,7 @@ EXEC SQL SELECT foo INTO :FooBar FROM table1 WHERE ascii = 'doodad';
- Also, a configuration parameter can be retreived with the
+ Also, a configuration parameter can be retrieved with the
SHOW command:
EXEC SQL SHOW search_path INTO :var;
@@ -983,7 +983,7 @@ VARCHAR v2[128];
the pgtypes library. The pgtypes library, described in detail
in contains basic functions to deal
with those types, such that you do not need to send a query to
- the SQL server just for adding an interval to a timestamp for
+ the SQL server just for adding an interval to a time stamp for
example.
@@ -1038,9 +1038,9 @@ ts = 2010-06-27 18:03:56.949343
In addition, the DATE type can be handled in the same way. The
- program has to include pg_types_date.h, declare a host variable
+ program has to include pg_types_date.h, declare a host variable
as the date type and convert a DATE value into a text form using
- PGTYPESdate_to_asc() function. For more details about the
+ PGTYPESdate_to_asc() function. For more details about the
pgtypes library functions, see .
@@ -1173,12 +1173,12 @@ EXEC SQL END DECLARE SECTION;
is a way to store some text string in char[]
or VARCHAR[], as
explained . The second use case is to
- retreive multiple rows from a query result without using a
+ retrieve multiple rows from a query result without using a
cursor. Without an array, to process a query result consisting
of multiple rows, it is required to use a cursor and
the FETCH command. But with array host
variables, multiple rows can be received at once. The length of
- the array has to be defined to be able to accomodate all rows,
+ the array has to be defined to be able to accommodate all rows,
otherwise a buffer overflow will likely occur.
@@ -1239,7 +1239,7 @@ oid=0, dbname=
The following example retrieves OIDs, names, and sizes of the
- avilable databases from the pg_database
+ available databases from the pg_database
system table and using
the pg_database_size() function. In this
example, a structure variable dbinfo_t with
@@ -3006,7 +3006,7 @@ int PGTYPEStimestamp_fmt_asc(timestamp *ts, char *output, int str_len, char *fmt
%p - is replaced by national representation of
- either "ante meridiem" or "post meridiem" as appropriate.
+ either ante meridiem
or post meridiem
as appropriate.
@@ -3852,7 +3852,7 @@ EXEC SQL DESCRIBE prepared_statement INTO mysqlda;
- SQLDA Datac Structure
+ SQLDA Data Structure
SQLDA uses three data structure
@@ -4080,7 +4080,7 @@ struct sqlname
- Retreiving a Result Set Using an SQLDA
+ Retrieving a Result Set Using an SQLDA
@@ -4265,9 +4265,9 @@ free(sqlda2);
This application joins two system tables, pg_database and
- pg_stat_database on the database oid, and also fetches and shows
- the database statistics which are retreived by two input
- parameters (a database "postgres", and oid "1").
+ pg_stat_database on the database OID, and also fetches and shows
+ the database statistics which are retrieved by two input
+ parameters (a database postgres, and OID 1).
@@ -5832,7 +5832,7 @@ ECPG = ecpg
Large object functions have to be called in a transaction block, so
when autocommit is off, BEGIN commands have to
- be isssued explicitly.
+ be issued explicitly.
@@ -6616,7 +6616,7 @@ DECLARE cursor_name [ BINARY ] [ IN
prepared_name
- The name of a prepared query, either as an SQL identfier or a
+ The name of a prepared query, either as an SQL identifier or a
host variable.
@@ -7477,7 +7477,7 @@ SET DESCRIPTOR descriptor_name VALU
descriptor_item
- A token identifiying which item of information to set in the
+ A token identifying which item of information to set in the
descriptor. See for a
list of supported items.
@@ -8461,7 +8461,7 @@ int dectoasc(decimal *np, char *cp, int len, int right)
right> to -1 indicates that all available decimal digits
should be included in the output. If the length of the output buffer,
which is indicated by len> is not sufficient to hold the
- textual representation including the trailing NUL character, only a
+ textual representation including the trailing zero byte, only a
single *> character is stored in the result and -1 is
returned.
@@ -8556,7 +8556,7 @@ int rdatestr(date d, char *str);
The function receives two arguments, the first one is the date to
convert (d> and the second one is a pointer to the target
string. The output format is always yyyy-mm-dd>, so you need
- to allocate at least 11 bytes (including the NUL-terminator) for the
+ to allocate at least 11 bytes (including the zero-byte terminator) for the
string.
diff --git a/doc/src/sgml/extend.sgml b/doc/src/sgml/extend.sgml
index 4ca17ef1a4..5ff6d16a41 100644
--- a/doc/src/sgml/extend.sgml
+++ b/doc/src/sgml/extend.sgml
@@ -288,7 +288,7 @@
A useful extension to PostgreSQL> typically includes
- multiple SQL objects; for example, a new datatype will require new
+ multiple SQL objects; for example, a new data type will require new
functions, new operators, and probably new index operator classes.
It is helpful to collect all these objects into a single package
to simplify database management. PostgreSQL> calls
diff --git a/doc/src/sgml/file-fdw.sgml b/doc/src/sgml/file-fdw.sgml
index e6ccdada2c..8497d9a45f 100644
--- a/doc/src/sgml/file-fdw.sgml
+++ b/doc/src/sgml/file-fdw.sgml
@@ -10,7 +10,7 @@
The file_fdw> module provides the foreign-data wrapper
file_fdw, which can be used to access data
- files in the server's filesystem. Data files must be in a format
+ files in the server's file system. Data files must be in a format
that can be read by COPY FROM;
see for details.
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml
index c1a34fb169..8f223d6891 100644
--- a/doc/src/sgml/func.sgml
+++ b/doc/src/sgml/func.sgml
@@ -9103,7 +9103,7 @@ SELECT xmlagg(x) FROM (SELECT * FROM test ORDER BY y DESC) AS tab;
- IS DOCUMENT
+ IS DOCUMENT
IS DOCUMENT
@@ -9123,7 +9123,7 @@ SELECT xmlagg(x) FROM (SELECT * FROM test ORDER BY y DESC) AS tab;
- XMLEXISTS
+ XMLEXISTS
XMLEXISTS
@@ -9165,7 +9165,7 @@ SELECT xmlexists('//town[text() = ''Toronto'']' PASSING BY REF 'Tor
- xml_is_well_formed
+ xml_is_well_formed
xml_is_well_formed
@@ -9187,7 +9187,7 @@ SELECT xmlexists('//town[text() = ''Toronto'']' PASSING BY REF 'Tor
These functions check whether a text> string is well-formed XML,
- returning a boolean result.
+ returning a Boolean result.
xml_is_well_formed_document checks for a well-formed
document, while xml_is_well_formed_content checks
for well-formed content. xml_is_well_formed does
@@ -9324,7 +9324,7 @@ SELECT xpath('//mydefns:b/text()', 'testxpath_exists is a specialized form
of the xpath function. Instead of returning the
individual XML values that satisfy the XPath, this function returns a
- boolean indicating whether the query was satisfied or not. This
+ Boolean indicating whether the query was satisfied or not. This
function is equivalent to the standard XMLEXISTS> predicate,
except that it also offers support for a namespace mapping argument.
@@ -13685,12 +13685,12 @@ SELECT typlen FROM pg_type WHERE oid = pg_typeof(33);
txid_snapshot_xmax(txid_snapshot)
bigint
- get xmax of snapshot
+ get xmax of snapshot
txid_snapshot_xmin(txid_snapshot)
bigint
- get xmin of snapshot
+ get xmin of snapshot
txid_visible_in_snapshot(bigint, txid_snapshot)
@@ -14218,7 +14218,7 @@ postgres=# SELECT * FROM pg_xlogfile_name_offset(pg_stop_backup());
pg_last_xact_replay_timestamp()
timestamp with time zone
- Get timestamp of last transaction replayed during recovery.
+ Get time stamp of last transaction replayed during recovery.
This is the time at which the commit or abort WAL record for that
transaction was generated on the primary.
If no transactions have been replayed during recovery, this function
@@ -14638,7 +14638,7 @@ postgres=# SELECT * FROM pg_xlogfile_name_offset(pg_stop_backup());
pg_read_binary_file> is similar to
- pg_read_file>, except that the result is a bytea value;
+ pg_read_file>, except that the result is a bytea value;
accordingly, no encoding checks are performed.
In combination with the convert_from> function, this function
can be used to read a file in a specified encoding:
diff --git a/doc/src/sgml/high-availability.sgml b/doc/src/sgml/high-availability.sgml
index 0283a1c867..80665a5cb2 100644
--- a/doc/src/sgml/high-availability.sgml
+++ b/doc/src/sgml/high-availability.sgml
@@ -1144,7 +1144,7 @@ primary_conninfo = 'host=192.168.1.50 port=5432 user=foo password=foopass'
To trigger failover of a log-shipping standby server,
run pg_ctl promote> or create a trigger
- file with the filename and path specified by the trigger_file>
+ file with the file name and path specified by the trigger_file>
setting in recovery.conf>. If you're planning to use
pg_ctl promote> to fail over, trigger_file> is
not required. If you're setting up the reporting servers that are
diff --git a/doc/src/sgml/installation.sgml b/doc/src/sgml/installation.sgml
index 96387bd610..61e34126c0 100644
--- a/doc/src/sgml/installation.sgml
+++ b/doc/src/sgml/installation.sgml
@@ -1989,7 +1989,7 @@ kill `cat /usr/local/pgsql/data/postmaster.pid`
PostgreSQL works on AIX, but getting it installed properly can be
challenging. AIX versions from 4.3.3 to 6.1 are considered supported.
- You can use GCC or the native IBM compiler xlc. In
+ You can use GCC or the native IBM compiler xlc. In
general, using recent versions of AIX and PostgreSQL helps. Check
the build farm for up to date information about which versions of
AIX are known to work.
@@ -2817,7 +2817,7 @@ MANPATH=/usr/lib/scohelp/%L/man:/usr/dt/man:/usr/man:/usr/share/man:scohelp:/usr
You can build with either GCC or Sun's compiler suite. For
better code optimization, Sun's compiler is strongly recommended
on the SPARC architecture. We have heard reports of problems
- when using GCC 2.95.1; gcc 2.95.3 or later is recommended. If
+ when using GCC 2.95.1; GCC 2.95.3 or later is recommended. If
you are using Sun's compiler, be careful not to select
/usr/ucb/cc;
use /opt/SUNWspro/bin/cc.
diff --git a/doc/src/sgml/libpq.sgml b/doc/src/sgml/libpq.sgml
index ba0cfc99cd..8e19a6e525 100644
--- a/doc/src/sgml/libpq.sgml
+++ b/doc/src/sgml/libpq.sgml
@@ -556,7 +556,7 @@ PGconn *PQconnectdbParams(const char **keywords, const char **values, int expand
parameter can be used to achieve the kind of server
authentication that SSL certificates achieve on TCP/IP
connections. (Note that if the Unix-domain socket is
- in /tmp or another publically writable
+ in /tmp or another publicly writable
location, any user could start a server there. Use this
parameter to ensure that you are connected to a server run
by a trusted user,
@@ -5410,7 +5410,7 @@ int PQlibVersion(void);
The result of this function can be used to determine, at
- runtime, if specific functionality is available in the currently
+ run time, if specific functionality is available in the currently
loaded version of libpq. The function can be used, for example,
to determine which connection options are available for
PQconnectdb> or if the hex> bytea>
diff --git a/doc/src/sgml/monitoring.sgml b/doc/src/sgml/monitoring.sgml
index 7d8b77e27e..553c16873f 100644
--- a/doc/src/sgml/monitoring.sgml
+++ b/doc/src/sgml/monitoring.sgml
@@ -245,15 +245,15 @@ postgres: user> database> host> pg_stat_activity>pg_stat_activity
One row per server process, showing database OID, database
name, process ID>, user OID, user name, application name,
- client's address, hostname (if available), and port number, times at
+ client's address, host name (if available), and port number, times at
which the server process, current transaction, and current query began
execution, process's waiting status, and text of the current query.
The columns that report data on the current query are available unless
the parameter track_activities has been turned off.
Furthermore, these columns are only visible if the user examining
the view is a superuser or the same as the user owning the process
- being reported on. The client's hostname will be available only if
- is set or if the user's hostname
+ being reported on. The client's host name will be available only if
+ is set or if the user's host name
needed to be looked up during pg_hba.conf
processing.
@@ -300,7 +300,7 @@ postgres: user> database> host>
pg_stat_replication>pg_stat_replication
One row per WAL sender process, showing process ID>,
- user OID, user name, application name, client's address, hostname
+ user OID, user name, application name, client's address, host name
(if available) and port number, time at which the server process began
execution, and the current WAL sender state and transaction log
location. In addition, the standby reports the last transaction log
@@ -311,8 +311,8 @@ postgres: user> database> host> is set or if the user's hostname
+ The client's host name will be available only if
+ is set or if the user's host name
needed to be looked up during pg_hba.conf
processing.
diff --git a/doc/src/sgml/mvcc.sgml b/doc/src/sgml/mvcc.sgml
index 180d6e82e4..e688176acb 100644
--- a/doc/src/sgml/mvcc.sgml
+++ b/doc/src/sgml/mvcc.sgml
@@ -613,7 +613,7 @@ ERROR: could not serialize access due to read/write dependencies among transact
with a SQLSTATE value of '40001'), because it will be very hard to
predict exactly which transactions might contribute to the read/write
dependencies and need to be rolled back to prevent serialization
- anomalies. The monitoring of read/write dependences has a cost, as does
+ anomalies. The monitoring of read/write dependencies has a cost, as does
the restart of transactions which are terminated with a serialization
failure, but balanced against the cost and blocking involved in use of
explicit locks and SELECT FOR UPDATE> or SELECT FOR
diff --git a/doc/src/sgml/perform.sgml b/doc/src/sgml/perform.sgml
index 9d5b709aec..2d115fa26e 100644
--- a/doc/src/sgml/perform.sgml
+++ b/doc/src/sgml/perform.sgml
@@ -440,14 +440,14 @@ WHERE t1.unique1 < 100 AND t1.unique2 = t2.unique2;
the related Insert, Update, or Delete node, although time spent executing
AFTER> triggers is not. The time spent in each trigger
(either BEFORE> or AFTER>) is also shown separately
- and is included in total runtime.
+ and is included in total run time.
Note, however, that deferred constraint triggers will not be executed
until end of transaction and are thus not shown by
EXPLAIN ANALYZE.
- There are two significant ways in which runtimes measured by
+ There are two significant ways in which run times measured by
EXPLAIN ANALYZE can deviate from normal execution of
the same query. First, since no output rows are delivered to the client,
network transmission costs and I/O formatting costs are not included.
diff --git a/doc/src/sgml/pgtestfsync.sgml b/doc/src/sgml/pgtestfsync.sgml
index 4015eb51d8..2889059c82 100644
--- a/doc/src/sgml/pgtestfsync.sgml
+++ b/doc/src/sgml/pgtestfsync.sgml
@@ -36,7 +36,7 @@ pg_test_fsync [options]
- Specifies the filename to write test data in.
+ Specifies the file name to write test data in.
This file should be in the same file system that the
pg_xlog> directory is or will be placed in.
(pg_xlog> contains the WAL> files.)
diff --git a/doc/src/sgml/plperl.sgml b/doc/src/sgml/plperl.sgml
index 0aab10bbd6..b957757da6 100644
--- a/doc/src/sgml/plperl.sgml
+++ b/doc/src/sgml/plperl.sgml
@@ -129,7 +129,7 @@ $$ LANGUAGE plperl;
Arguments will be converted from the database's encoding to UTF-8
- for use inside plperl, and then converted from UTF-8 back to the
+ for use inside PL/Perl, and then converted from UTF-8 back to the
database encoding upon return.
@@ -786,7 +786,7 @@ SELECT release_hosts_query();
encode_typed_literal(value, typename)
- Converts a Perl variable to the value of the datatype passed as a
+ Converts a Perl variable to the value of the data type passed as a
second argument and returns a string representation of this value.
Correctly handles nested arrays and values of composite types.
@@ -1277,7 +1277,7 @@ DO 'elog(WARNING, join ", ", sort keys %INC)' language plperl;
child processes.
- This parameter can only be set in the postgresql.conf file or on the server command line.
+ This parameter can only be set in the postgresql.conf file or on the server command line.
diff --git a/doc/src/sgml/plpgsql.sgml b/doc/src/sgml/plpgsql.sgml
index 1866e43e0e..eea6ec58e3 100644
--- a/doc/src/sgml/plpgsql.sgml
+++ b/doc/src/sgml/plpgsql.sgml
@@ -3586,7 +3586,7 @@ AFTER INSERT OR UPDATE OR DELETE ON emp
This example uses a trigger on the view to make it updatable, and
ensure that any insert, update or delete of a row in the view is
- recorded (i.e., audited) in the emp_audit table. The current time
+ recorded (i.e., audited) in the emp_audit table. The current time
and user name are recorded, together with the type of operation
performed, and the view displays the last modified time of each row.
diff --git a/doc/src/sgml/plpython.sgml b/doc/src/sgml/plpython.sgml
index 14f00d8236..ffc1d3ab3d 100644
--- a/doc/src/sgml/plpython.sgml
+++ b/doc/src/sgml/plpython.sgml
@@ -356,7 +356,7 @@ $$ LANGUAGE plpythonu;
When the PostgreSQL return type is bytea, the
return value will be converted to a string (Python 2) or bytes
- (Python 3) using the respective Python builtins, with the
+ (Python 3) using the respective Python built-ins, with the
result being converted bytea.
@@ -365,7 +365,7 @@ $$ LANGUAGE plpythonu;
For all other PostgreSQL return types, the returned Python
value is converted to a string using the Python
- builtin str, and the result is passed to the
+ built-in str, and the result is passed to the
input function of the PostgreSQL data type.
@@ -1101,7 +1101,7 @@ $$ LANGUAGE plpythonu;
inserted into it. The subtransaction context manager does not
trap errors, it only assures that all database operations executed
inside its scope will be atomically committed or rolled back. A
- rollback of the subtransaction block occurrs on any kind of
+ rollback of the subtransaction block occurs on any kind of
exception exit, not only ones caused by errors originating from
database access. A regular Python exception raised inside an
explicit subtransaction block would also cause the subtransaction
diff --git a/doc/src/sgml/queries.sgml b/doc/src/sgml/queries.sgml
index 99c4e4e698..b3cf39a39b 100644
--- a/doc/src/sgml/queries.sgml
+++ b/doc/src/sgml/queries.sgml
@@ -1586,7 +1586,7 @@ GROUP BY region, product;
top_regions> and the output of top_regions>
is used in the primary SELECT> query.
This example could have been written without WITH>,
- but we'd have needed two levels of nested sub-SELECTs. It's a bit
+ but we'd have needed two levels of nested sub-SELECTs. It's a bit
easier to follow this way.
diff --git a/doc/src/sgml/ref/alter_opfamily.sgml b/doc/src/sgml/ref/alter_opfamily.sgml
index e22b4728d9..7d9c7560ac 100644
--- a/doc/src/sgml/ref/alter_opfamily.sgml
+++ b/doc/src/sgml/ref/alter_opfamily.sgml
@@ -159,7 +159,7 @@ ALTER OPERATOR FAMILY name USING sort_family_name
- The name (optionally schema-qualified) of an existing btree operator
+ The name (optionally schema-qualified) of an existing btree operator
family that describes the sort ordering associated with an ordering
operator.
diff --git a/doc/src/sgml/ref/cluster.sgml b/doc/src/sgml/ref/cluster.sgml
index adba267863..addf652065 100644
--- a/doc/src/sgml/ref/cluster.sgml
+++ b/doc/src/sgml/ref/cluster.sgml
@@ -128,7 +128,7 @@ CLUSTER [VERBOSE]
- CLUSTER> can re-sort the table using either an indexscan
+ CLUSTER> can re-sort the table using either an index scan
on the specified index, or (if the index is a b-tree) a sequential
scan followed by sorting. It will attempt to choose the method that
will be faster, based on planner cost parameters and available statistical
@@ -136,7 +136,7 @@ CLUSTER [VERBOSE]
- When an indexscan is used, a temporary copy of the table is created that
+ When an index scan is used, a temporary copy of the table is created that
contains the table data in the index order. Temporary copies of each
index on the table are created as well. Therefore, you need free space on
disk at least equal to the sum of the table size and the index sizes.
@@ -146,7 +146,7 @@ CLUSTER [VERBOSE]
When a sequential scan and sort is used, a temporary sort file is
also created, so that the peak temporary space requirement is as much
as double the table size, plus the index sizes. This method is often
- faster than the indexscan method, but if the disk space requirement is
+ faster than the index scan method, but if the disk space requirement is
intolerable, you can disable this choice by temporarily setting to off>.
diff --git a/doc/src/sgml/ref/create_opclass.sgml b/doc/src/sgml/ref/create_opclass.sgml
index 158740b667..02ff2d7f9b 100644
--- a/doc/src/sgml/ref/create_opclass.sgml
+++ b/doc/src/sgml/ref/create_opclass.sgml
@@ -184,7 +184,7 @@ CREATE OPERATOR CLASS name [ DEFAUL
sort_family_name
- The name (optionally schema-qualified) of an existing btree operator
+ The name (optionally schema-qualified) of an existing btree operator
family that describes the sort ordering associated with an ordering
operator.
diff --git a/doc/src/sgml/ref/create_type.sgml b/doc/src/sgml/ref/create_type.sgml
index 70b0325f0e..ea45fadae6 100644
--- a/doc/src/sgml/ref/create_type.sgml
+++ b/doc/src/sgml/ref/create_type.sgml
@@ -355,7 +355,7 @@ CREATE TYPE name
- If the optional boolean
+ If the optional Boolean
parameter collatable
is true, column definitions and expressions of the type may carry
collation information through use of
diff --git a/doc/src/sgml/ref/ecpg-ref.sgml b/doc/src/sgml/ref/ecpg-ref.sgml
index 20f8c9d0ad..2bbd476158 100644
--- a/doc/src/sgml/ref/ecpg-ref.sgml
+++ b/doc/src/sgml/ref/ecpg-ref.sgml
@@ -143,7 +143,7 @@ PostgreSQL documentation
Do not use indicators but instead use special values to represent
- NULLs. Historically there have been databases using this approach.
+ null values. Historically there have been databases using this approach.
@@ -152,7 +152,7 @@ PostgreSQL documentation
Prepare all statements before using them. Libecpg will keep a cache of
- prepared statments and reuse a statement if it gets executed again. If the
+ prepared statements and reuse a statement if it gets executed again. If the
cache runs full, libecpg will free the least used statement.
@@ -161,7 +161,7 @@ PostgreSQL documentation
- Allow questionmark as placeholder for compatibility reasons.
+ Allow question mark as placeholder for compatibility reasons.
This used to be the default long ago.
diff --git a/doc/src/sgml/ref/pg_basebackup.sgml b/doc/src/sgml/ref/pg_basebackup.sgml
index 29c885e93d..8a7b833f0f 100644
--- a/doc/src/sgml/ref/pg_basebackup.sgml
+++ b/doc/src/sgml/ref/pg_basebackup.sgml
@@ -59,7 +59,7 @@ PostgreSQL documentation
- There can be multiple pg_basebackups running at the same time, but it is
+ There can be multiple pg_basebackups running at the same time, but it is
better from a performance point of view to take only one backup, and copy
the result.
@@ -127,7 +127,7 @@ PostgreSQL documentation
Write the output as tar files in the target directory. The main
data directory will be written to a file named
base.tar, and all other tablespaces will
- be named after the tablespace oid.
+ be named after the tablespace OID.
If the value - (dash) is specified as
@@ -235,7 +235,7 @@ PostgreSQL documentation
Enables verbose mode. Will output some extra steps during startup and
- shutdown, as well as show the exact filename that is currently being
+ shutdown, as well as show the exact file name that is currently being
processed if progress reporting is also enabled.
diff --git a/doc/src/sgml/ref/pg_dump.sgml b/doc/src/sgml/ref/pg_dump.sgml
index 7f12460426..cb1773eeaa 100644
--- a/doc/src/sgml/ref/pg_dump.sgml
+++ b/doc/src/sgml/ref/pg_dump.sgml
@@ -142,7 +142,7 @@ PostgreSQL documentation
Output commands to clean (drop)
- database objects prior to outputing the commands for creating them.
+ database objects prior to outputting the commands for creating them.
(Restore might generate some harmless errors.)
diff --git a/doc/src/sgml/release-9.1.sgml b/doc/src/sgml/release-9.1.sgml
index 713e89bee5..299cf9d721 100644
--- a/doc/src/sgml/release-9.1.sgml
+++ b/doc/src/sgml/release-9.1.sgml
@@ -491,7 +491,7 @@
- Add client_hostname field to client_hostname field to pg_stat_activity>
(Peter Eisentraut)
@@ -1227,7 +1227,7 @@
Make EXPLAIN VERBOSE> show the function call expression
- in a FunctionScan node (Tom Lane)
+ in a FunctionScan node (Tom Lane)
@@ -1428,7 +1428,7 @@
- These are used for xpath matching.
+ These are used for XPath matching.
@@ -2046,7 +2046,7 @@
- Allow ecpg to accept dynamic cursor names even in
+ Allow ECPG to accept dynamic cursor names even in
WHERE CURRENT OF clauses
@@ -2139,7 +2139,7 @@
- Enable building with the Mingw64 compiler (Andrew Dunstan)
+ Enable building with the MinGW64 compiler (Andrew Dunstan)
@@ -2175,7 +2175,7 @@
- Add missing get_{object}_oid() functions, for consistency
+ Add missing get_object>_oid() functions, for consistency
(Robert Haas)
@@ -2316,7 +2316,7 @@
Allow contrib/fuzzystrmatch>'s
- levenshtein()> function handle multi-byte characters
+ levenshtein()> function handle multibyte characters
(Alexander Korotkov)
diff --git a/doc/src/sgml/runtime.sgml b/doc/src/sgml/runtime.sgml
index d18ba79f40..ef83206bbc 100644
--- a/doc/src/sgml/runtime.sgml
+++ b/doc/src/sgml/runtime.sgml
@@ -1662,7 +1662,7 @@ $ kill -INT `head -1 /usr/local/pgsql/data/postmaster.pid`/etc/rc.d/init.d/postgresql stop
See for details about starting and
- stoping the server.
+ stopping the server.
diff --git a/doc/src/sgml/sepgsql.sgml b/doc/src/sgml/sepgsql.sgml
index f35ab97be1..db9b64cc88 100644
--- a/doc/src/sgml/sepgsql.sgml
+++ b/doc/src/sgml/sepgsql.sgml
@@ -26,7 +26,7 @@
This module integrates with SELinux> to provide an
- additional layer of security checking above and beyond what is normaly
+ additional layer of security checking above and beyond what is normally
provided by PostgreSQL. From the perspective of
SELinux>, this module allows
PostgreSQL to function as a user-space object
@@ -97,7 +97,7 @@ Policy from config file: targeted
The following instructions that assume your installation is under the
/usr/local/pgsql> directory. Adjust the paths shown below as
- appropriate for your installaton.
+ appropriate for your installation.
diff --git a/doc/src/sgml/xml2.sgml b/doc/src/sgml/xml2.sgml
index 90b5ac0785..47bac31f0c 100644
--- a/doc/src/sgml/xml2.sgml
+++ b/doc/src/sgml/xml2.sgml
@@ -343,7 +343,7 @@ WHERE t.author_id = p.person_id;
The xpath_table> function assumes that the results of each XPath query
- might be multi-valued, so the number of rows returned by the function
+ might be multivalued, so the number of rows returned by the function
may not be the same as the number of input documents. The first row
returned contains the first result from each query, the second row the
second result from each query. If one of the queries has fewer values
diff --git a/src/backend/access/gist/gist.c b/src/backend/access/gist/gist.c
index 4881a7dd48..0e779e09d7 100644
--- a/src/backend/access/gist/gist.c
+++ b/src/backend/access/gist/gist.c
@@ -227,7 +227,7 @@ gistbuildempty(PG_FUNCTION_ARGS)
{
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("unlogged GIST indexes are not supported")));
+ errmsg("unlogged GiST indexes are not supported")));
PG_RETURN_VOID();
}
@@ -1405,7 +1405,7 @@ initGISTstate(GISTSTATE *giststate, Relation index)
* functions don't care about collation, so we just do it
* unconditionally. (We could alternatively call get_typcollation,
* but that seems like expensive overkill --- there aren't going to be
- * any cases where a GIST storage type has a nondefault collation.)
+ * any cases where a GiST storage type has a nondefault collation.)
*/
if (OidIsValid(index->rd_indcollation[i]))
giststate->supportCollation[i] = index->rd_indcollation[i];
diff --git a/src/backend/access/gist/gistget.c b/src/backend/access/gist/gistget.c
index 4eb31318ff..1aba686844 100644
--- a/src/backend/access/gist/gistget.c
+++ b/src/backend/access/gist/gistget.c
@@ -71,7 +71,7 @@ gistindex_keytest(IndexScanDesc scan,
int i;
if (GistPageIsLeaf(page)) /* shouldn't happen */
- elog(ERROR, "invalid GIST tuple found on leaf page");
+ elog(ERROR, "invalid GiST tuple found on leaf page");
for (i = 0; i < scan->numberOfOrderBys; i++)
so->distances[i] = -get_float8_infinity();
return true;
diff --git a/src/backend/access/gist/gistxlog.c b/src/backend/access/gist/gistxlog.c
index 51354c1c18..02c4ec3a6f 100644
--- a/src/backend/access/gist/gistxlog.c
+++ b/src/backend/access/gist/gistxlog.c
@@ -306,7 +306,7 @@ gist_redo(XLogRecPtr lsn, XLogRecord *record)
MemoryContext oldCxt;
/*
- * GIST indexes do not require any conflict processing. NB: If we ever
+ * GiST indexes do not require any conflict processing. NB: If we ever
* implement a similar optimization we have in b-tree, and remove killed
* tuples outside VACUUM, we'll need to handle that here.
*/
diff --git a/src/backend/catalog/sql_features.txt b/src/backend/catalog/sql_features.txt
index 3a40c456e1..71597f90a3 100644
--- a/src/backend/catalog/sql_features.txt
+++ b/src/backend/catalog/sql_features.txt
@@ -397,7 +397,7 @@ T052 MAX and MIN for row types NO
T053 Explicit aliases for all-fields reference NO
T061 UCS support NO
T071 BIGINT data type YES
-T101 Enhanced nullability determiniation NO
+T101 Enhanced nullability determination NO
T111 Updatable joins, unions, and columns NO
T121 WITH (excluding RECURSIVE) in query expression YES
T122 WITH (excluding RECURSIVE) in subquery YES
diff --git a/src/backend/commands/indexcmds.c b/src/backend/commands/indexcmds.c
index b91e4a4bd2..479db2c3f1 100644
--- a/src/backend/commands/indexcmds.c
+++ b/src/backend/commands/indexcmds.c
@@ -287,7 +287,7 @@ DefineIndex(RangeVar *heapRelation,
{
/*
* Hack to provide more-or-less-transparent updating of old RTREE
- * indexes to GIST: if RTREE is requested and not found, use GIST.
+ * indexes to GiST: if RTREE is requested and not found, use GIST.
*/
if (strcmp(accessMethodName, "rtree") == 0)
{
diff --git a/src/test/regress/expected/opr_sanity.out b/src/test/regress/expected/opr_sanity.out
index a83608ade5..a25f90cbfd 100644
--- a/src/test/regress/expected/opr_sanity.out
+++ b/src/test/regress/expected/opr_sanity.out
@@ -1177,7 +1177,7 @@ WHERE p1.amprocfamily = p3.oid AND p3.opfmethod = p2.oid AND
-- Detect missing pg_amproc entries: should have as many support functions
-- as AM expects for each datatype combination supported by the opfamily.
--- GIST/GIN are special cases because each has an optional support function.
+-- GiST/GIN are special cases because each has an optional support function.
SELECT p1.amname, p2.opfname, p3.amproclefttype, p3.amprocrighttype
FROM pg_am AS p1, pg_opfamily AS p2, pg_amproc AS p3
WHERE p2.opfmethod = p1.oid AND p3.amprocfamily = p2.oid AND
@@ -1190,7 +1190,7 @@ WHERE p2.opfmethod = p1.oid AND p3.amprocfamily = p2.oid AND
--------+---------+----------------+-----------------
(0 rows)
--- Similar check for GIST/GIN, allowing one optional proc
+-- Similar check for GiST/GIN, allowing one optional proc
SELECT p1.amname, p2.opfname, p3.amproclefttype, p3.amprocrighttype
FROM pg_am AS p1, pg_opfamily AS p2, pg_amproc AS p3
WHERE p2.opfmethod = p1.oid AND p3.amprocfamily = p2.oid AND
@@ -1205,7 +1205,7 @@ WHERE p2.opfmethod = p1.oid AND p3.amprocfamily = p2.oid AND
(0 rows)
-- Also, check if there are any pg_opclass entries that don't seem to have
--- pg_amproc support. Again, GIST/GIN have to be checked specially.
+-- pg_amproc support. Again, GiST/GIN have to be checked specially.
SELECT amname, opcname, count(*)
FROM pg_am am JOIN pg_opclass op ON opcmethod = am.oid
LEFT JOIN pg_amproc p ON amprocfamily = opcfamily AND
diff --git a/src/test/regress/sql/opr_sanity.sql b/src/test/regress/sql/opr_sanity.sql
index 217192139c..65ae868d98 100644
--- a/src/test/regress/sql/opr_sanity.sql
+++ b/src/test/regress/sql/opr_sanity.sql
@@ -920,7 +920,7 @@ WHERE p1.amprocfamily = p3.oid AND p3.opfmethod = p2.oid AND
-- Detect missing pg_amproc entries: should have as many support functions
-- as AM expects for each datatype combination supported by the opfamily.
--- GIST/GIN are special cases because each has an optional support function.
+-- GiST/GIN are special cases because each has an optional support function.
SELECT p1.amname, p2.opfname, p3.amproclefttype, p3.amprocrighttype
FROM pg_am AS p1, pg_opfamily AS p2, pg_amproc AS p3
@@ -931,7 +931,7 @@ WHERE p2.opfmethod = p1.oid AND p3.amprocfamily = p2.oid AND
p4.amproclefttype = p3.amproclefttype AND
p4.amprocrighttype = p3.amprocrighttype);
--- Similar check for GIST/GIN, allowing one optional proc
+-- Similar check for GiST/GIN, allowing one optional proc
SELECT p1.amname, p2.opfname, p3.amproclefttype, p3.amprocrighttype
FROM pg_am AS p1, pg_opfamily AS p2, pg_amproc AS p3
@@ -944,7 +944,7 @@ WHERE p2.opfmethod = p1.oid AND p3.amprocfamily = p2.oid AND
NOT IN (p1.amsupport, p1.amsupport - 1);
-- Also, check if there are any pg_opclass entries that don't seem to have
--- pg_amproc support. Again, GIST/GIN have to be checked specially.
+-- pg_amproc support. Again, GiST/GIN have to be checked specially.
SELECT amname, opcname, count(*)
FROM pg_am am JOIN pg_opclass op ON opcmethod = am.oid
--
cgit v1.2.3