diff options
Diffstat (limited to 'src/backend/executor/execExpr.c')
-rw-r--r-- | src/backend/executor/execExpr.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/backend/executor/execExpr.c b/src/backend/executor/execExpr.c index 60f9eb28cd4..ca0d38b3095 100644 --- a/src/backend/executor/execExpr.c +++ b/src/backend/executor/execExpr.c @@ -1171,6 +1171,14 @@ ExecInitExprRec(Expr *node, ExprState *state, state); /* + * If first argument is of varlena type, we'll need to ensure + * that the value passed to the comparison function is a + * read-only pointer. + */ + scratch.d.func.make_ro = + (get_typlen(exprType((Node *) linitial(op->args))) == -1); + + /* * Change opcode of call instruction to EEOP_NULLIF. * * XXX: historically we've not called the function usage |