Movatterモバイル変換


[0]ホーム

URL:


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

Sign up
Appearance settings

Commit8d29d45

Browse files
committed
Fix assert failure in expand_grouping_sets
linitial_node() fails in assert enabled builds if the given pointer isnot of the specified type. Here the type is IntList. The code thoughtit should be expecting List, but it was wrong.In the existing tests which run this code the initial list element isalways NIL. Since linitial_node() allows NULL, we didn't trigger anyassert failures in the existing regression tests.There is still some discussion as to whether we need a few more tests inthis area, but for now, since beta2 is looming, fix the bug first.Bug: #17067Discussion:https://postgr.es/m/17067-665d50fa321f79e0@postgresql.orgReported-by: Yaoguang Chen
1 parenta7bb0ce commit8d29d45

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/backend/parser/parse_agg.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1855,7 +1855,7 @@ expand_grouping_sets(List *groupingSets, bool groupDistinct, int limit)
18551855
list_sort(result,cmp_list_len_contents_asc);
18561856

18571857
/* Finally, remove duplicates */
1858-
prev=linitial_node(List,result);
1858+
prev=linitial(result);
18591859
for_each_from(cell,result,1)
18601860
{
18611861
if (equal(lfirst(cell),prev))

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp