This is an automated email from the ASF dual-hosted git repository. starocean999 pushed a commit to branch branch-2.0 in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/branch-2.0 by this push: new a793ca825b9 [fix](nereids)prevent null pointer access if translate expression fails (#34055) a793ca825b9 is described below commit a793ca825b946db31606d55a14fc60a656dc98fa Author: starocean999 <40539150+starocean...@users.noreply.github.com> AuthorDate: Fri Apr 26 09:26:55 2024 +0800 [fix](nereids)prevent null pointer access if translate expression fails (#34055) --- .../doris/nereids/rules/expression/rules/FoldConstantRuleOnBE.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/expression/rules/FoldConstantRuleOnBE.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/expression/rules/FoldConstantRuleOnBE.java index e334eb8425e..89955dc4950 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/expression/rules/FoldConstantRuleOnBE.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/expression/rules/FoldConstantRuleOnBE.java @@ -136,6 +136,11 @@ public class FoldConstantRuleOnBE extends AbstractExpressionRewriteRule { LOG.warn("expression {} translate to legacy expr failed. ", expr, e); return; } + if (staleExpr == null) { + // just return, it's a fail-safe + LOG.warn("expression {} translate to legacy expr failed. ", expr); + return; + } tExprMap.put(id, staleExpr.treeToThrift()); } else { for (int i = 0; i < expr.children().size(); i++) { --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org