Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 66decbf

Browse files
committed
Macro for btree runtime fix.
1 parent 6b52dc7 commit 66decbf

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/include/access/nbtree.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
88
* Portions Copyright (c) 1994, Regents of the University of California
99
*
10-
* $Id: nbtree.h,v 1.50 2001/01/24 19:43:19 momjian Exp $
10+
* $Id: nbtree.h,v 1.51 2001/02/07 23:34:18 vadim Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -50,6 +50,10 @@ typedef BTPageOpaqueData *BTPageOpaque;
5050
#define BTREE_METAPAGE 0 /* first page is meta */
5151
#define BTREE_MAGIC 0x053162
5252

53+
#define BTreeInvalidParent(opaque) \
54+
(opaque->btpo_parent == InvalidBlockNumber || \
55+
opaque->btpo_parent == BTREE_METAPAGE)
56+
5357
#define BTREE_VERSION 1
5458

5559
typedef struct BTMetaPageData

0 commit comments

Comments
 (0)