aboutsummaryrefslogtreecommitdiff
path: root/src/backend/parser/parse_clause.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2000-02-15 23:09:08 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2000-02-15 23:09:08 +0000
commit90e160befff0d0e693ea3aca4173827281255200 (patch)
treea7f83e08cdaa8df0587af39b90a55de627f5c96d /src/backend/parser/parse_clause.c
parentb1577a7c78d2d8880b3c0f94689fb75bd074c897 (diff)
downloadpostgresql-90e160befff0d0e693ea3aca4173827281255200.tar.gz
postgresql-90e160befff0d0e693ea3aca4173827281255200.zip
Fix missing lfirst() in ListTableAsAttrs(). This code
doesn't seem to be used at the moment, but as long as I'm looking at it...
Diffstat (limited to 'src/backend/parser/parse_clause.c')
-rw-r--r--src/backend/parser/parse_clause.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/backend/parser/parse_clause.c b/src/backend/parser/parse_clause.c
index d6ccbeaa5c6..a6549015af9 100644
--- a/src/backend/parser/parse_clause.c
+++ b/src/backend/parser/parse_clause.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_clause.c,v 1.53 2000/02/15 07:47:37 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_clause.c,v 1.54 2000/02/15 23:09:08 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -172,14 +172,13 @@ ListTableAsAttrs(ParseState *pstate, char *table);
List *
ListTableAsAttrs(ParseState *pstate, char *table)
{
- List *rlist = NULL;
+ Attr *attr = expandTable(pstate, table, TRUE);
+ List *rlist = NIL;
List *col;
- Attr *attr = expandTable(pstate, table, TRUE);
foreach(col, attr->attrs)
{
- Attr *a;
- a = makeAttr(table, strVal((Value *) col));
+ Attr *a = makeAttr(table, strVal((Value *) lfirst(col)));
rlist = lappend(rlist, a);
}