Fix inconsistencies and typos in the tree

This is numbered take 8, and addresses again a set of issues with code
comments, variable names and unreferenced variables.

Author: Alexander Lakhin
Discussion: https://postgr.es/m/b137b5eb-9c95-9c2f-586e-38aba7d59788@gmail.com
This commit is contained in:
Michael Paquier 2019-07-29 12:28:30 +09:00
parent 7cce159349
commit eb43f3d193
42 changed files with 58 additions and 75 deletions

View File

@ -355,7 +355,7 @@ mdc_finish(PGP_Context *ctx, PullFilter *src, int len)
if (len != 20) if (len != 20)
return PXE_PGP_CORRUPT_DATA; return PXE_PGP_CORRUPT_DATA;
/* mdc_read should not call md_update */ /* mdc_read should not call px_md_update */
ctx->in_mdc_pkt = 1; ctx->in_mdc_pkt = 1;
/* read data */ /* read data */

View File

@ -83,10 +83,7 @@ typedef struct CustomPath
by <literal>nodeToString</literal>, so that debugging routines that attempt to by <literal>nodeToString</literal>, so that debugging routines that attempt to
print the custom path will work as designed. <structfield>methods</structfield> must print the custom path will work as designed. <structfield>methods</structfield> must
point to a (usually statically allocated) object implementing the required point to a (usually statically allocated) object implementing the required
custom path methods, of which there is currently only one. The custom path methods, of which there is currently only one.
<structfield>LibraryName</structfield> and <structfield>SymbolName</structfield> fields must also
be initialized so that the dynamic loader can resolve them to locate the
method table.
</para> </para>
<para> <para>

View File

@ -211,7 +211,7 @@ CREATE [ OR REPLACE ] AGGREGATE <replaceable class="parameter">name</replaceable
as described in <xref linkend="xaggr-moving-aggregates"/>. This requires as described in <xref linkend="xaggr-moving-aggregates"/>. This requires
specifying the <literal>MSFUNC</literal>, <literal>MINVFUNC</literal>, specifying the <literal>MSFUNC</literal>, <literal>MINVFUNC</literal>,
and <literal>MSTYPE</literal> parameters, and optionally and <literal>MSTYPE</literal> parameters, and optionally
the <literal>MSPACE</literal>, <literal>MFINALFUNC</literal>, the <literal>MSSPACE</literal>, <literal>MFINALFUNC</literal>,
<literal>MFINALFUNC_EXTRA</literal>, <literal>MFINALFUNC_MODIFY</literal>, <literal>MFINALFUNC_EXTRA</literal>, <literal>MFINALFUNC_MODIFY</literal>,
and <literal>MINITCOND</literal> parameters. Except for <literal>MINVFUNC</literal>, and <literal>MINITCOND</literal> parameters. Except for <literal>MINVFUNC</literal>,
these parameters work like the corresponding simple-aggregate parameters these parameters work like the corresponding simple-aggregate parameters

View File

@ -137,7 +137,7 @@ CREATE FUNCTION <replaceable>validator_function_name</replaceable>(oid)
<para> <para>
Finally, the PL must be declared with the command Finally, the PL must be declared with the command
<synopsis> <synopsis>
CREATE <optional>TRUSTED</optional> LANGUAGE <replaceable>language-name</replaceable> CREATE <optional>TRUSTED</optional> LANGUAGE <replaceable>language_name</replaceable>
HANDLER <replaceable>handler_function_name</replaceable> HANDLER <replaceable>handler_function_name</replaceable>
<optional>INLINE <replaceable>inline_function_name</replaceable></optional> <optional>INLINE <replaceable>inline_function_name</replaceable></optional>
<optional>VALIDATOR <replaceable>validator_function_name</replaceable></optional> ; <optional>VALIDATOR <replaceable>validator_function_name</replaceable></optional> ;

View File

@ -23,7 +23,7 @@ standard_targets = all install installdirs uninstall distprep clean distclean ma
# these targets should recurse even into subdirectories not being built: # these targets should recurse even into subdirectories not being built:
standard_always_targets = distprep clean distclean maintainer-clean standard_always_targets = distprep clean distclean maintainer-clean
.PHONY: $(standard_targets) install-strip html man installcheck-parallel maintainer-check .PHONY: $(standard_targets) install-strip html man installcheck-parallel
# make `all' the default target # make `all' the default target
all: all:

View File

@ -20,7 +20,7 @@
#include "access/bufmask.h" #include "access/bufmask.h"
/* /*
* mask_page_lsn * mask_page_lsn_and_checksum
* *
* In consistency checks, the LSN of the two pages compared will likely be * In consistency checks, the LSN of the two pages compared will likely be
* different because of concurrent operations when the WAL is generated and * different because of concurrent operations when the WAL is generated and

View File

@ -1371,7 +1371,7 @@ disassembleLeaf(Page page)
if (GinPageIsCompressed(page)) if (GinPageIsCompressed(page))
{ {
/* /*
* Create a leafSegment entry for each segment. * Create a leafSegmentInfo entry for each segment.
*/ */
seg = GinDataLeafPageGetPostingList(page); seg = GinDataLeafPageGetPostingList(page);
segbegin = (Pointer) seg; segbegin = (Pointer) seg;

View File

@ -237,7 +237,7 @@ static void logical_end_heap_rewrite(RewriteState state);
* new_heap new, locked heap relation to insert tuples to * new_heap new, locked heap relation to insert tuples to
* oldest_xmin xid used by the caller to determine which tuples are dead * oldest_xmin xid used by the caller to determine which tuples are dead
* freeze_xid xid before which tuples will be frozen * freeze_xid xid before which tuples will be frozen
* min_multi multixact before which multis will be removed * cutoff_multi multixact before which multis will be removed
* use_wal should the inserts to the new heap be WAL-logged? * use_wal should the inserts to the new heap be WAL-logged?
* *
* Returns an opaque RewriteState, allocated in current memory context, * Returns an opaque RewriteState, allocated in current memory context,
@ -787,7 +787,7 @@ raw_heap_insert(RewriteState state, HeapTuple tup)
* Instead we simply write the mapping files out to disk, *before* the * Instead we simply write the mapping files out to disk, *before* the
* XLogInsert() is performed. That guarantees that either the XLogInsert() is * XLogInsert() is performed. That guarantees that either the XLogInsert() is
* inserted after the checkpoint's redo pointer or that the checkpoint (via * inserted after the checkpoint's redo pointer or that the checkpoint (via
* LogicalRewriteHeapCheckpoint()) has flushed the (partial) mapping file to * CheckPointLogicalRewriteHeap()) has flushed the (partial) mapping file to
* disk. That leaves the tail end that has not yet been flushed open to * disk. That leaves the tail end that has not yet been flushed open to
* corruption, which is solved by including the current offset in the * corruption, which is solved by including the current offset in the
* xl_heap_rewrite_mapping records and truncating the mapping file to it * xl_heap_rewrite_mapping records and truncating the mapping file to it

View File

@ -842,7 +842,7 @@ spgvacuumscan(spgBulkDeleteState *bds)
} }
} }
/* Propagate local lastUsedPage cache to metablock */ /* Propagate local lastUsedPages cache to metablock */
SpGistUpdateMetaPage(index); SpGistUpdateMetaPage(index);
/* /*

View File

@ -1988,7 +1988,7 @@ StartTransaction(void)
/* /*
* Advertise it in the proc array. We assume assignment of * Advertise it in the proc array. We assume assignment of
* LocalTransactionID is atomic, and the backendId should be set already. * localTransactionId is atomic, and the backendId should be set already.
*/ */
Assert(MyProc->backendId == vxid.backendId); Assert(MyProc->backendId == vxid.backendId);
MyProc->lxid = vxid.localTransactionId; MyProc->lxid = vxid.localTransactionId;

View File

@ -1796,11 +1796,11 @@ WaitXLogInsertionsToFinish(XLogRecPtr upto)
do do
{ {
/* /*
* See if this insertion is in progress. LWLockWait will wait for * See if this insertion is in progress. LWLockWaitForVar will
* the lock to be released, or for the 'value' to be set by a * wait for the lock to be released, or for the 'value' to be set
* LWLockUpdateVar call. When a lock is initially acquired, its * by a LWLockUpdateVar call. When a lock is initially acquired,
* value is 0 (InvalidXLogRecPtr), which means that we don't know * its value is 0 (InvalidXLogRecPtr), which means that we don't
* where it's inserting yet. We will have to wait for it. If * know where it's inserting yet. We will have to wait for it. If
* it's a small insertion, the record will most likely fit on the * it's a small insertion, the record will most likely fit on the
* same page and the inserter will release the lock without ever * same page and the inserter will release the lock without ever
* calling LWLockUpdateVar. But if it has to sleep, it will * calling LWLockUpdateVar. But if it has to sleep, it will
@ -6024,7 +6024,10 @@ recoveryApplyDelay(XLogReaderState *record)
TimestampDifference(GetCurrentTimestamp(), recoveryDelayUntilTime, TimestampDifference(GetCurrentTimestamp(), recoveryDelayUntilTime,
&secs, &microsecs); &secs, &microsecs);
/* NB: We're ignoring waits below min_apply_delay's resolution. */ /*
* NB: We're ignoring waits below recovery_min_apply_delay's
* resolution.
*/
if (secs <= 0 && microsecs / 1000 <= 0) if (secs <= 0 && microsecs / 1000 <= 0)
break; break;

View File

@ -733,7 +733,7 @@ AggregateCreate(const char *aggName,
* Create dependencies for the aggregate (above and beyond those already * Create dependencies for the aggregate (above and beyond those already
* made by ProcedureCreate). Note: we don't need an explicit dependency * made by ProcedureCreate). Note: we don't need an explicit dependency
* on aggTransType since we depend on it indirectly through transfn. * on aggTransType since we depend on it indirectly through transfn.
* Likewise for aggmTransType using the mtransfunc, if it exists. * Likewise for aggmTransType using the mtransfn, if it exists.
* *
* If we're replacing an existing definition, ProcedureCreate deleted all * If we're replacing an existing definition, ProcedureCreate deleted all
* our existing dependencies, so we have to do the same things here either * our existing dependencies, so we have to do the same things here either

View File

@ -1854,7 +1854,7 @@ get_db_info(const char *name, LOCKMODE lockmode,
/* limit of frozen XIDs */ /* limit of frozen XIDs */
if (dbFrozenXidP) if (dbFrozenXidP)
*dbFrozenXidP = dbform->datfrozenxid; *dbFrozenXidP = dbform->datfrozenxid;
/* minimum MultixactId */ /* minimum MultiXactId */
if (dbMinMultiP) if (dbMinMultiP)
*dbMinMultiP = dbform->datminmxid; *dbMinMultiP = dbform->datminmxid;
/* default tablespace for this database */ /* default tablespace for this database */

View File

@ -27,9 +27,6 @@
* "create operator": * "create operator":
* operators * operators
* *
* Most of the parse-tree manipulation routines are defined in
* commands/manip.c.
*
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h" #include "postgres.h"

View File

@ -1796,14 +1796,9 @@ interpret_ident_response(const char *ident_response,
/* /*
* Talk to the ident server on host "remote_ip_addr" and find out who * Talk to the ident server on "remote_addr" and find out who
* owns the tcp connection from his port "remote_port" to port * owns the tcp connection to "local_addr"
* "local_port_addr" on host "local_ip_addr". Return the user name the * It the username successfully retrieved, check the usermap.
* ident server gives as "*ident_user".
*
* IP addresses and port numbers are in network byte order.
*
* But iff we're unable to get the information from ident, return false.
* *
* XXX: Using WaitLatchOrSocket() and doing a CHECK_FOR_INTERRUPTS() if the * XXX: Using WaitLatchOrSocket() and doing a CHECK_FOR_INTERRUPTS() if the
* latch was set would improve the responsiveness to timeouts/cancellations. * latch was set would improve the responsiveness to timeouts/cancellations.

View File

@ -291,10 +291,10 @@ BackgroundWriterMain(void)
* significantly bigger than BgWriterDelay, so we don't complicate the * significantly bigger than BgWriterDelay, so we don't complicate the
* overall timeout handling but just assume we're going to get called * overall timeout handling but just assume we're going to get called
* often enough even if hibernation mode is active. It's not that * often enough even if hibernation mode is active. It's not that
* important that log_snap_interval_ms is met strictly. To make sure * important that LOG_SNAPSHOT_INTERVAL_MS is met strictly. To make
* we're not waking the disk up unnecessarily on an idle system we * sure we're not waking the disk up unnecessarily on an idle system
* check whether there has been any WAL inserted since the last time * we check whether there has been any WAL inserted since the last
* we've logged a running xacts. * time we've logged a running xacts.
* *
* We do this logging in the bgwriter as it is the only process that * We do this logging in the bgwriter as it is the only process that
* is run regularly and returns to its mainloop all the time. E.g. * is run regularly and returns to its mainloop all the time. E.g.

View File

@ -2259,7 +2259,7 @@ WalSndLoop(WalSndSendDataCallback send_data)
WL_SOCKET_READABLE; WL_SOCKET_READABLE;
/* /*
* Use fresh timestamp, not last_processed, to reduce the chance * Use fresh timestamp, not last_processing, to reduce the chance
* of reaching wal_sender_timeout before sending a keepalive. * of reaching wal_sender_timeout before sending a keepalive.
*/ */
sleeptime = WalSndComputeSleeptime(GetCurrentTimestamp()); sleeptime = WalSndComputeSleeptime(GetCurrentTimestamp());
@ -2666,7 +2666,7 @@ XLogSendPhysical(void)
* very close to together here so that we'll get a later position if it is * very close to together here so that we'll get a later position if it is
* still moving. * still moving.
* *
* Because LagTrackerWriter ignores samples when the LSN hasn't advanced, * Because LagTrackerWrite ignores samples when the LSN hasn't advanced,
* this gives us a cheap approximation for the WAL flush time for this * this gives us a cheap approximation for the WAL flush time for this
* LSN. * LSN.
* *

View File

@ -3169,7 +3169,7 @@ DisplayXidCache(void)
* *
* When we throw away subXIDs from KnownAssignedXids, we need to keep track of * When we throw away subXIDs from KnownAssignedXids, we need to keep track of
* that, similarly to tracking overflow of a PGPROC's subxids array. We do * that, similarly to tracking overflow of a PGPROC's subxids array. We do
* that by remembering the lastOverflowedXID, ie the last thrown-away subXID. * that by remembering the lastOverflowedXid, ie the last thrown-away subXID.
* As long as that is within the range of interesting XIDs, we have to assume * As long as that is within the range of interesting XIDs, we have to assume
* that subXIDs are missing from snapshots. (Note that subXID overflow occurs * that subXIDs are missing from snapshots. (Note that subXID overflow occurs
* on primary when 65th subXID arrives, whereas on standby it occurs when 64th * on primary when 65th subXID arrives, whereas on standby it occurs when 64th

View File

@ -99,7 +99,7 @@ InitRecoveryTransactionEnvironment(void)
* Lock a virtual transaction id for Startup process. * Lock a virtual transaction id for Startup process.
* *
* We need to do GetNextLocalTransactionId() because * We need to do GetNextLocalTransactionId() because
* SharedInvalBackendInit() leaves localTransactionid invalid and the lock * SharedInvalBackendInit() leaves localTransactionId invalid and the lock
* manager doesn't like that at all. * manager doesn't like that at all.
* *
* Note that we don't need to run XactLockTableInsert() because nobody * Note that we don't need to run XactLockTableInsert() because nobody

View File

@ -232,7 +232,7 @@ LOG_LWDEBUG(const char *where, LWLock *lock, const char *msg)
static void init_lwlock_stats(void); static void init_lwlock_stats(void);
static void print_lwlock_stats(int code, Datum arg); static void print_lwlock_stats(int code, Datum arg);
static lwlock_stats * get_lwlock_stats_entry(LWLock *lockid); static lwlock_stats * get_lwlock_stats_entry(LWLock *lock);
static void static void
init_lwlock_stats(void) init_lwlock_stats(void)

View File

@ -731,7 +731,7 @@ mdwrite(SMgrRelation reln, ForkNumber forknum, BlockNumber blocknum,
* mdnblocks() -- Get the number of blocks stored in a relation. * mdnblocks() -- Get the number of blocks stored in a relation.
* *
* Important side effect: all active segments of the relation are opened * Important side effect: all active segments of the relation are opened
* and added to the mdfd_seg_fds array. If this routine has not been * and added to the md_seg_fds array. If this routine has not been
* called, then only segments up to the last one actually touched * called, then only segments up to the last one actually touched
* are present in the array. * are present in the array.
*/ */

View File

@ -1023,8 +1023,8 @@ FillPortalStore(Portal portal, bool isTopLevel)
/* /*
* Run the portal to completion just as for the default * Run the portal to completion just as for the default
* MULTI_QUERY case, but send the primary query's output to the * PORTAL_MULTI_QUERY case, but send the primary query's output to
* tuplestore. Auxiliary query outputs are discarded. Set the * the tuplestore. Auxiliary query outputs are discarded. Set the
* portal's holdSnapshot to the snapshot used (or a copy of it). * portal's holdSnapshot to the snapshot used (or a copy of it).
*/ */
PortalRunMulti(portal, isTopLevel, true, PortalRunMulti(portal, isTopLevel, true,

View File

@ -139,7 +139,7 @@ static void array_insert_slice(ArrayType *destArray, ArrayType *origArray,
int *st, int *endp, int *st, int *endp,
int typlen, bool typbyval, char typalign); int typlen, bool typbyval, char typalign);
static int array_cmp(FunctionCallInfo fcinfo); static int array_cmp(FunctionCallInfo fcinfo);
static ArrayType *create_array_envelope(int ndims, int *dimv, int *lbv, int nbytes, static ArrayType *create_array_envelope(int ndims, int *dimv, int *lbsv, int nbytes,
Oid elmtype, int dataoffset); Oid elmtype, int dataoffset);
static ArrayType *array_fill_internal(ArrayType *dims, ArrayType *lbs, static ArrayType *array_fill_internal(ArrayType *dims, ArrayType *lbs,
Datum value, bool isnull, Oid elmtype, Datum value, bool isnull, Oid elmtype,

View File

@ -27,7 +27,8 @@
/* /*
* Originally written by Rich $alz, mirror!rs, Wed Nov 26 19:03:17 EST 1986. * Originally written by Rich $alz, mirror!rs, Wed Nov 26 19:03:17 EST 1986.
* Rich $alz is now <rsalz@bbn.com>. * Rich $alz is now <rsalz@bbn.com>.
* Special thanks to Lars Mathiesen <thorinn@diku.dk> for the LABORT code. * Special thanks to Lars Mathiesen <thorinn@diku.dk> for the
* LIKE_ABORT code.
* *
* This code was shamelessly stolen from the "pql" code by myself and * This code was shamelessly stolen from the "pql" code by myself and
* slightly modified :) * slightly modified :)

View File

@ -915,7 +915,7 @@ AllocSetAlloc(MemoryContext context, Size size)
/* /*
* We could be asking for pretty big blocks here, so cope if malloc * We could be asking for pretty big blocks here, so cope if malloc
* fails. But give up if there's less than a meg or so available... * fails. But give up if there's less than 1 MB or so available...
*/ */
while (block == NULL && blksize > 1024 * 1024) while (block == NULL && blksize > 1024 * 1024)
{ {

View File

@ -2024,7 +2024,7 @@ make_template0(FILE *cmdfd)
"CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;\n\n", "CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;\n\n",
/* /*
* We use the OID of template0 to determine lastsysoid * We use the OID of template0 to determine datlastsysoid
*/ */
"UPDATE pg_database SET datlastsysoid = " "UPDATE pg_database SET datlastsysoid = "
" (SELECT oid FROM pg_database " " (SELECT oid FROM pg_database "

View File

@ -4,7 +4,7 @@
* reads the data from $PGDATA/global/pg_control * reads the data from $PGDATA/global/pg_control
* *
* copyright (c) Oliver Elphick <olly@lfix.co.uk>, 2001; * copyright (c) Oliver Elphick <olly@lfix.co.uk>, 2001;
* licence: BSD * license: BSD
* *
* src/bin/pg_controldata/pg_controldata.c * src/bin/pg_controldata/pg_controldata.c
*/ */

View File

@ -1725,7 +1725,7 @@ pgwin32_doRunAsService(void)
/* /*
* Mingw headers are incomplete, and so are the libraries. So we have to load * Mingw headers are incomplete, and so are the libraries. So we have to load
* a whole lot of API functions dynamically. Since we have to do this anyway, * a whole lot of API functions dynamically. Since we have to do this anyway,
* also load the couple of functions that *do* exist in minwg headers but not * also load the couple of functions that *do* exist in mingw headers but not
* on NT4. That way, we don't break on NT4. * on NT4. That way, we don't break on NT4.
*/ */
typedef BOOL (WINAPI * __CreateRestrictedToken) (HANDLE, DWORD, DWORD, PSID_AND_ATTRIBUTES, DWORD, PLUID_AND_ATTRIBUTES, DWORD, PSID_AND_ATTRIBUTES, PHANDLE); typedef BOOL (WINAPI * __CreateRestrictedToken) (HANDLE, DWORD, DWORD, PSID_AND_ATTRIBUTES, DWORD, PLUID_AND_ATTRIBUTES, DWORD, PSID_AND_ATTRIBUTES, PHANDLE);

View File

@ -19,11 +19,8 @@
#define USER_NAME_SIZE 128 #define USER_NAME_SIZE 128
#define MAX_STRING 1024 #define MAX_STRING 1024
#define LINE_ALLOC 4096
#define QUERY_ALLOC 8192 #define QUERY_ALLOC 8192
#define MIGRATOR_API_VERSION 1
#define MESSAGE_WIDTH 60 #define MESSAGE_WIDTH 60
#define GET_MAJOR_VERSION(v) ((v) / 100) #define GET_MAJOR_VERSION(v) ((v) / 100)

View File

@ -3,7 +3,7 @@ src/bin/pgevent/README
pgevent pgevent
======= =======
MSG000001.bin is a binary file, result of Microsoft MC compiler. MC compiler MSG00001.bin is a binary file, result of Microsoft MC compiler. MC compiler
can be downloaded for free with MS Core SDK but it is not included with MSYS can be downloaded for free with MS Core SDK but it is not included with MSYS
tools and I didn't find an alternative way to compile MC file. tools and I didn't find an alternative way to compile MC file.

View File

@ -178,7 +178,7 @@ recompose_code(uint32 start, uint32 code, uint32 *result)
((start - SBASE) % TCOUNT) == 0 && ((start - SBASE) % TCOUNT) == 0 &&
code >= TBASE && code < (TBASE + TCOUNT)) code >= TBASE && code < (TBASE + TCOUNT))
{ {
/* make syllable of from LVT */ /* make syllable of form LVT */
uint32 tindex = code - TBASE; uint32 tindex = code - TBASE;
*result = start + tindex; *result = start + tindex;

View File

@ -417,7 +417,7 @@ extern bool gistplacetopage(Relation rel, Size freespace, GISTSTATE *giststate,
OffsetNumber oldoffnum, BlockNumber *newblkno, OffsetNumber oldoffnum, BlockNumber *newblkno,
Buffer leftchildbuf, Buffer leftchildbuf,
List **splitinfo, List **splitinfo,
bool markleftchild, bool markfollowright,
Relation heapRel, Relation heapRel,
bool is_build); bool is_build);

View File

@ -26,7 +26,7 @@ extern Oid AlterDatabase(ParseState *pstate, AlterDatabaseStmt *stmt, bool isTop
extern Oid AlterDatabaseSet(AlterDatabaseSetStmt *stmt); extern Oid AlterDatabaseSet(AlterDatabaseSetStmt *stmt);
extern ObjectAddress AlterDatabaseOwner(const char *dbname, Oid newOwnerId); extern ObjectAddress AlterDatabaseOwner(const char *dbname, Oid newOwnerId);
extern Oid get_database_oid(const char *dbname, bool missingok); extern Oid get_database_oid(const char *dbname, bool missing_ok);
extern char *get_database_name(Oid dbid); extern char *get_database_name(Oid dbid);
extern void check_encoding_locale_matches(int encoding, const char *collate, const char *ctype); extern void check_encoding_locale_matches(int encoding, const char *collate, const char *ctype);

View File

@ -19,8 +19,8 @@
/* /*
* Protocol capabilities * Protocol capabilities
* *
* LOGICAL_PROTO_VERSION_NUM is our native protocol and the greatest version * LOGICALREP_PROTO_VERSION_NUM is our native protocol and the greatest version
* we can support. PGLOGICAL_PROTO_MIN_VERSION_NUM is the oldest version we * we can support. LOGICALREP_PROTO_MIN_VERSION_NUM is the oldest version we
* have backwards compatibility for. The client requests protocol version at * have backwards compatibility for. The client requests protocol version at
* connect time. * connect time.
*/ */
@ -106,4 +106,4 @@ extern LogicalRepRelation *logicalrep_read_rel(StringInfo in);
extern void logicalrep_write_typ(StringInfo out, Oid typoid); extern void logicalrep_write_typ(StringInfo out, Oid typoid);
extern void logicalrep_read_typ(StringInfo out, LogicalRepTyp *ltyp); extern void logicalrep_read_typ(StringInfo out, LogicalRepTyp *ltyp);
#endif /* LOGICALREP_PROTO_H */ #endif /* LOGICAL_PROTO_H */

View File

@ -22,7 +22,7 @@
#define STATS_NDISTINCT_MAGIC 0xA352BFA4 /* struct identifier */ #define STATS_NDISTINCT_MAGIC 0xA352BFA4 /* struct identifier */
#define STATS_NDISTINCT_TYPE_BASIC 1 /* struct version */ #define STATS_NDISTINCT_TYPE_BASIC 1 /* struct version */
/* MVDistinctItem represents a single combination of columns */ /* MVNDistinctItem represents a single combination of columns */
typedef struct MVNDistinctItem typedef struct MVNDistinctItem
{ {
double ndistinct; /* ndistinct value for this combination */ double ndistinct; /* ndistinct value for this combination */

View File

@ -306,7 +306,7 @@ typedef PageHeaderData *PageHeader;
* This is intended to catch use of the pointer before page initialization. * This is intended to catch use of the pointer before page initialization.
* It is implemented as a function due to the limitations of the MSVC * It is implemented as a function due to the limitations of the MSVC
* compiler, which choked on doing all these tests within another macro. We * compiler, which choked on doing all these tests within another macro. We
* return true so that MacroAssert() can be used while still getting the * return true so that AssertMacro() can be used while still getting the
* specifics from the macro failure within this function. * specifics from the macro failure within this function.
*/ */
static inline bool static inline bool

View File

@ -594,4 +594,4 @@ extern void VirtualXactLockTableInsert(VirtualTransactionId vxid);
extern void VirtualXactLockTableCleanup(void); extern void VirtualXactLockTableCleanup(void);
extern bool VirtualXactLock(VirtualTransactionId vxid, bool wait); extern bool VirtualXactLock(VirtualTransactionId vxid, bool wait);
#endif /* LOCK_H */ #endif /* LOCK_H_ */

View File

@ -56,4 +56,4 @@ typedef struct xl_standby_lock
Oid relOid; /* OID of table */ Oid relOid; /* OID of table */
} xl_standby_lock; } xl_standby_lock;
#endif /* LOCKDEF_H_ */ #endif /* LOCKDEFS_H_ */

View File

@ -133,7 +133,7 @@ typedef enum LWLockMode
{ {
LW_EXCLUSIVE, LW_EXCLUSIVE,
LW_SHARED, LW_SHARED,
LW_WAIT_UNTIL_FREE /* A special mode used in PGPROC->lwlockMode, LW_WAIT_UNTIL_FREE /* A special mode used in PGPROC->lwWaitMode,
* when waiting for lock to become free. Not * when waiting for lock to become free. Not
* to be used as LWLockAcquire argument */ * to be used as LWLockAcquire argument */
} LWLockMode; } LWLockMode;

View File

@ -2250,7 +2250,7 @@ PQsendDescribe(PGconn *conn, char desc_type, const char *desc_target)
/* remember we are doing a Describe */ /* remember we are doing a Describe */
conn->queryclass = PGQUERY_DESCRIBE; conn->queryclass = PGQUERY_DESCRIBE;
/* reset last-query string (not relevant now) */ /* reset last_query string (not relevant now) */
if (conn->last_query) if (conn->last_query)
{ {
free(conn->last_query); free(conn->last_query);

View File

@ -2091,7 +2091,7 @@ plperlu_validator(PG_FUNCTION_ARGS)
/* /*
* Uses mksafefunc/mkunsafefunc to create a subroutine whose text is * Uses mkfunc to create a subroutine whose text is
* supplied in s, and returns a reference to it * supplied in s, and returns a reference to it
*/ */
static void static void

View File

@ -1,7 +0,0 @@
#!/bin/sh
# src/tools/FAQ2txt:
# Converts doc/src/FAQ/FAQ.html to text file doc/FAQ
lynx -force_html -dont_wrap_pre -dump -hiddenlinks=ignore -nolist "$@"