Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 4e1ee79

Browse filesBrowse files
committed
Fix typalign in rangetypes statistics
6df7a96 introduces multirange types, whose typanalyze function shares infrastructure with range types typanalyze function. Since 6df7a96, information about type gathered by statistics is filled from typcache. But typalign is mistakenly always set to double. This commit fixes this oversight.
1 parent eea1e08 commit 4e1ee79
Copy full SHA for 4e1ee79

File tree

Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed

‎src/backend/utils/adt/rangetypes_typanalyze.c

Copy file name to clipboardExpand all lines: src/backend/utils/adt/rangetypes_typanalyze.c
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ compute_range_stats(VacAttrStats *stats, AnalyzeAttrFetchFunc fetchfunc,
330330
stats->statypid[slot_idx] = typcache->type_id;
331331
stats->statyplen[slot_idx] = typcache->typlen;
332332
stats->statypbyval[slot_idx] = typcache->typbyval;
333-
stats->statypalign[slot_idx] = 'd';
333+
stats->statypalign[slot_idx] = typcache->typalign;
334334

335335
slot_idx++;
336336
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.