Skip to content

Commit 245e14e

Browse files
committed
Fix inconsistent comments for some function declarations in headers
Some of the headers list a couple of function prototypes located in a different file than what is referred to. This fixes a couple of places where this inconsistency exists. Author: Richard Guo Discussion: https://postgr.es/m/CAMbWs4__RdcSNXPa7L62Ozvo_Q4LvT60o3Bnp8yrQ_m9y5CKvg@mail.gmail.com
1 parent 56f2c7b commit 245e14e

File tree

3 files changed

+14
-7
lines changed

3 files changed

+14
-7
lines changed

src/include/access/nbtxlog.h

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -342,10 +342,14 @@ typedef struct xl_btree_newroot
342342
* prototypes for functions in nbtxlog.c
343343
*/
344344
extern void btree_redo(XLogReaderState *record);
345-
extern void btree_desc(StringInfo buf, XLogReaderState *record);
346-
extern const char *btree_identify(uint8 info);
347345
extern void btree_xlog_startup(void);
348346
extern void btree_xlog_cleanup(void);
349347
extern void btree_mask(char *pagedata, BlockNumber blkno);
350348

349+
/*
350+
* prototypes for functions in nbtdesc.c
351+
*/
352+
extern void btree_desc(StringInfo buf, XLogReaderState *record);
353+
extern const char *btree_identify(uint8 info);
354+
351355
#endif /* NBTXLOG_H */

src/include/replication/walreceiver.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -455,6 +455,7 @@ walrcv_clear_result(WalRcvExecResult *walres)
455455
/* prototypes for functions in walreceiver.c */
456456
extern void WalReceiverMain(void) pg_attribute_noreturn();
457457
extern void ProcessWalRcvInterrupts(void);
458+
extern void WalRcvForceReply(void);
458459

459460
/* prototypes for functions in walreceiverfuncs.c */
460461
extern Size WalRcvShmemSize(void);
@@ -469,6 +470,5 @@ extern XLogRecPtr GetWalRcvFlushRecPtr(XLogRecPtr *latestChunkStart, TimeLineID
469470
extern XLogRecPtr GetWalRcvWriteRecPtr(void);
470471
extern int GetReplicationApplyDelay(void);
471472
extern int GetReplicationTransferLatency(void);
472-
extern void WalRcvForceReply(void);
473473

474474
#endif /* _WALRECEIVER_H */

src/include/storage/bufmgr.h

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,6 @@ extern void IncrBufferRefCount(Buffer buffer);
123123
extern Buffer ReleaseAndReadBuffer(Buffer buffer, Relation relation,
124124
BlockNumber blockNum);
125125

126-
extern void InitBufferPool(void);
127126
extern void InitBufferPoolAccess(void);
128127
extern void AtEOXact_Buffers(bool isCommit);
129128
extern void PrintBufferLeakWarning(Buffer buffer);
@@ -154,7 +153,6 @@ extern XLogRecPtr BufferGetLSNAtomic(Buffer buffer);
154153
#ifdef NOT_USED
155154
extern void PrintPinnedBufs(void);
156155
#endif
157-
extern Size BufferShmemSize(void);
158156
extern void BufferGetTag(Buffer buffer, RelFileLocator *rlocator,
159157
ForkNumber *forknum, BlockNumber *blknum);
160158

@@ -173,10 +171,15 @@ extern void AbortBufferIO(void);
173171
extern void BufmgrCommit(void);
174172
extern bool BgBufferSync(struct WritebackContext *wb_context);
175173

176-
extern void AtProcExit_LocalBuffers(void);
177-
178174
extern void TestForOldSnapshot_impl(Snapshot snapshot, Relation relation);
179175

176+
/* in buf_init.c */
177+
extern void InitBufferPool(void);
178+
extern Size BufferShmemSize(void);
179+
180+
/* in localbuf.c */
181+
extern void AtProcExit_LocalBuffers(void);
182+
180183
/* in freelist.c */
181184
extern BufferAccessStrategy GetAccessStrategy(BufferAccessStrategyType btype);
182185
extern void FreeAccessStrategy(BufferAccessStrategy strategy);

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy