aboutsummaryrefslogtreecommitdiff
path: root/contrib/postgres_fdw/postgres_fdw.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/postgres_fdw/postgres_fdw.c')
-rw-r--r--contrib/postgres_fdw/postgres_fdw.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/contrib/postgres_fdw/postgres_fdw.c b/contrib/postgres_fdw/postgres_fdw.c
index 465f43cd7c9..d79e4ccbe3d 100644
--- a/contrib/postgres_fdw/postgres_fdw.c
+++ b/contrib/postgres_fdw/postgres_fdw.c
@@ -3488,30 +3488,30 @@ foreign_join_ok(PlannerInfo *root, RelOptInfo *joinrel, JoinType jointype,
{
case JOIN_INNER:
fpinfo->remote_conds = list_concat(fpinfo->remote_conds,
- fpinfo_i->remote_conds);
+ list_copy(fpinfo_i->remote_conds));
fpinfo->remote_conds = list_concat(fpinfo->remote_conds,
- fpinfo_o->remote_conds);
+ list_copy(fpinfo_o->remote_conds));
break;
case JOIN_LEFT:
fpinfo->joinclauses = list_concat(fpinfo->joinclauses,
- fpinfo_i->remote_conds);
+ list_copy(fpinfo_i->remote_conds));
fpinfo->remote_conds = list_concat(fpinfo->remote_conds,
- fpinfo_o->remote_conds);
+ list_copy(fpinfo_o->remote_conds));
break;
case JOIN_RIGHT:
fpinfo->joinclauses = list_concat(fpinfo->joinclauses,
- fpinfo_o->remote_conds);
+ list_copy(fpinfo_o->remote_conds));
fpinfo->remote_conds = list_concat(fpinfo->remote_conds,
- fpinfo_i->remote_conds);
+ list_copy(fpinfo_i->remote_conds));
break;
case JOIN_FULL:
fpinfo->joinclauses = list_concat(fpinfo->joinclauses,
- fpinfo_i->remote_conds);
+ list_copy(fpinfo_i->remote_conds));
fpinfo->joinclauses = list_concat(fpinfo->joinclauses,
- fpinfo_o->remote_conds);
+ list_copy(fpinfo_o->remote_conds));
break;
default: