aboutsummaryrefslogtreecommitdiff
path: root/src/backend/optimizer/path/pathkeys.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/optimizer/path/pathkeys.c')
-rw-r--r--src/backend/optimizer/path/pathkeys.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/backend/optimizer/path/pathkeys.c b/src/backend/optimizer/path/pathkeys.c
index 985b5d8de9b..b5d6c977eef 100644
--- a/src/backend/optimizer/path/pathkeys.c
+++ b/src/backend/optimizer/path/pathkeys.c
@@ -2464,7 +2464,7 @@ truncate_useless_pathkeys(PlannerInfo *root,
else if (nuseful == list_length(pathkeys))
return pathkeys;
else
- return list_truncate(list_copy(pathkeys), nuseful);
+ return list_copy_head(pathkeys, nuseful);
}
/*