=== Applying patches on top of PostgreSQL commit ID f20a347e1a613cfc9053e7bc3d254608ae968386 === /etc/rc.d/jail: WARNING: Per-jail configuration via jail_* variables is obsolete. Please consider migrating to /etc/jail.conf. Mon Jun 30 15:07:18 UTC 2025 On branch cf/5867 nothing to commit, working tree clean === using 'git am' to apply patch ./v3-0001-fix-bug-18953-some-more.patch === Patch format detection failed. === using patch(1) to apply patch ./v3-0001-fix-bug-18953-some-more.patch === patching file src/backend/optimizer/plan/createplan.c Hunk #1 succeeded at 4496 with fuzz 2 (offset 152 lines). Hunk #2 FAILED at 4375. Hunk #3 FAILED at 4416. Hunk #4 FAILED at 4424. 3 out of 4 hunks FAILED -- saving rejects to file src/backend/optimizer/plan/createplan.c.rej patching file src/backend/optimizer/util/paramassign.c Hunk #1 FAILED at 599. Hunk #2 FAILED at 661. 2 out of 2 hunks FAILED -- saving rejects to file src/backend/optimizer/util/paramassign.c.rej patching file src/backend/optimizer/util/placeholder.c Hunk #1 succeeded at 585 with fuzz 2 (offset 40 lines). patching file src/include/optimizer/paramassign.h Hunk #1 FAILED at 30. 1 out of 1 hunk FAILED -- saving rejects to file src/include/optimizer/paramassign.h.rej patching file src/include/optimizer/placeholder.h Hunk #1 FAILED at 30. 1 out of 1 hunk FAILED -- saving rejects to file src/include/optimizer/placeholder.h.rej patching file src/test/regress/expected/join.out Hunk #1 FAILED at 4119. 1 out of 1 hunk FAILED -- saving rejects to file src/test/regress/expected/join.out.rej patching file src/test/regress/sql/join.sql Hunk #1 succeeded at 1407 with fuzz 2 (offset 46 lines). Unstaged changes after reset: M src/backend/optimizer/plan/createplan.c M src/backend/optimizer/util/placeholder.c M src/test/regress/sql/join.sql Removing src/backend/optimizer/plan/createplan.c.rej Removing src/backend/optimizer/util/paramassign.c.rej Removing src/include/optimizer/paramassign.h.rej Removing src/include/optimizer/placeholder.h.rej Removing src/test/regress/expected/join.out.rej === using 'git apply' to apply patch ./v3-0001-fix-bug-18953-some-more.patch === Applied patch to 'src/backend/optimizer/plan/createplan.c' with conflicts. Applied patch to 'src/backend/optimizer/util/paramassign.c' cleanly. Applied patch to 'src/backend/optimizer/util/placeholder.c' cleanly. Applied patch to 'src/include/optimizer/paramassign.h' cleanly. Applied patch to 'src/include/optimizer/placeholder.h' cleanly. Applied patch to 'src/test/regress/expected/join.out' cleanly. Applied patch to 'src/test/regress/sql/join.sql' cleanly. U src/backend/optimizer/plan/createplan.c diff --cc src/backend/optimizer/plan/createplan.c index 0b61aef962c,4d059eba3f0..00000000000 --- a/src/backend/optimizer/plan/createplan.c +++ b/src/backend/optimizer/plan/createplan.c @@@ -4451,11 -4451,18 +4451,26 @@@ create_nestloop_plan(PlannerInfo *root * here contain references to surviving root->curOuterParams items * (that is, they reference values that will be supplied by some * higher-level nestloop). Those need to be converted to Params now. ++<<<<<<< ours + * Note: it's safe to do this after the tlist_member() check, because + * equal() won't pay attention to phv->phexpr. + */ + phv->phexpr = (Expr *) replace_nestloop_params(root, + (Node *) phv->phexpr); ++======= + */ + phv = (PlaceHolderVar *) replace_nestloop_params(root, (Node *) phv); + + /* + * It's not actually necessary to update the NestLoopParam entry, + * because the two PHVs would be equal() anyway and thus setrefs.c + * would still replace the NestLoopParam's PHV with an outer-plan + * reference Var. (This is also why we needn't run + * replace_nestloop_params before checking tlist_member.) But we + * might as well do it for cleanliness. + */ + nlp->paramval = (Var *) phv; ++>>>>>>> theirs /* Make a shallow copy of outer_tlist, if we didn't already */ if (outer_tlist == outer_plan->targetlist)