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

Commit18bdefa

Browse files
author
Thomas G. Lockhart
committed
Fix reference to null pointer when no aggregate function candidates
are available. Problem reported by David Sauer <davids@iol.cz>.Modify information in resulting error message to indicate both agg name and data type.
1 parent5afe8d3 commit18bdefa

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

‎src/backend/parser/parse_func.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/parser/parse_func.c,v 1.35 1998/12/15 12:46:14 vadim Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/parser/parse_func.c,v 1.36 1998/12/23 14:38:40 thomas Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -225,7 +225,7 @@ agg_select_candidate(Oid typeid, CandidateList candidates)
225225
}
226226
}
227227
/* otherwise, don't bother keeping this one around... */
228-
else
228+
elseif (last_candidate!=NULL)
229229
{
230230
last_candidate->next=NULL;
231231
}
@@ -399,8 +399,8 @@ ParseFuncOrColumn(ParseState *pstate, char *funcname, List *fargs,
399399
}
400400
else
401401
{
402-
elog(ERROR,"Unable to select an aggregate functionfor type '%s'",
403-
typeidTypeName(basetype));
402+
elog(ERROR,"Unable to select an aggregate function%s(%s)",
403+
funcname,typeidTypeName(basetype));
404404
}
405405
}
406406

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp