Skip to content

Commit 14ee357

Browse files
committed
Fix portability bug in gin_page_opaque_info().
Somebody apparently thought that "if Int32GetDatum is good, Int64GetDatum must be better". Per buildfarm failures now that Peter has added some regression tests here.
1 parent f7c9a6e commit 14ee357

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

contrib/pageinspect/ginfuncs.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ gin_page_opaque_info(PG_FUNCTION_ARGS)
100100
GinPageOpaque opaq;
101101
HeapTuple resultTuple;
102102
Datum values[3];
103-
bool nulls[10];
103+
bool nulls[3];
104104
Datum flags[16];
105105
int nflags = 0;
106106
uint16 flagbits;
@@ -152,9 +152,9 @@ gin_page_opaque_info(PG_FUNCTION_ARGS)
152152
memset(nulls, 0, sizeof(nulls));
153153

154154
values[0] = Int64GetDatum(opaq->rightlink);
155-
values[1] = Int64GetDatum(opaq->maxoff);
156-
values[2] = PointerGetDatum(
157-
construct_array(flags, nflags, TEXTOID, -1, false, 'i'));
155+
values[1] = Int32GetDatum(opaq->maxoff);
156+
values[2] = PointerGetDatum(construct_array(flags, nflags,
157+
TEXTOID, -1, false, 'i'));
158158

159159
/* Build and return the result tuple. */
160160
resultTuple = heap_form_tuple(tupdesc, values, nulls);

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