impala-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Attila Jeges (Code Review)" <ger...@cloudera.org>
Subject [Impala-ASF-CR] IMPALA-5246: UDF's Close() should handle Expr's preparation failure
Date Wed, 03 May 2017 16:21:11 GMT
Attila Jeges has posted comments on this change.

Change subject: IMPALA-5246: UDF's Close() should handle Expr's preparation failure
......................................................................


Patch Set 1:

(5 comments)

http://gerrit.cloudera.org:8080/#/c/6757/1/be/src/exprs/case-expr.cc
File be/src/exprs/case-expr.cc:

PS1, Line 82: fn_ctx->Free(reinterpret_cast<uint8_t*>(case_state))
I could be wrong, but shouldn't we call
fn_ctx->SetFunctionState(FunctionContext::THREAD_LOCAL, nullptr)
after fn_ctx->Free(case_state) to avoid double-free problems ?
(just like we do in Close functions in be/src/testutil/test-udfs.cc)


http://gerrit.cloudera.org:8080/#/c/6757/1/be/src/exprs/math-functions-ir.cc
File be/src/exprs/math-functions-ir.cc:

PS1, Line 182: ctx->Free(seed);
same here


http://gerrit.cloudera.org:8080/#/c/6757/1/be/src/exprs/string-functions-ir.cc
File be/src/exprs/string-functions-ir.cc:

PS1, Line 614: delete re;
same here


http://gerrit.cloudera.org:8080/#/c/6757/1/be/src/exprs/timestamp-functions.cc
File be/src/exprs/timestamp-functions.cc:

PS1, Line 195: delete dt_ctx
same here


http://gerrit.cloudera.org:8080/#/c/6757/1/be/src/exprs/utility-functions.cc
File be/src/exprs/utility-functions.cc:

PS1, Line 59: delete uuid_gen;
same here


-- 
To view, visit http://gerrit.cloudera.org:8080/6757
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Id2c689246ed4f8dd38f104fa35904f3926a7039c
Gerrit-PatchSet: 1
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-Owner: Michael Ho <kwho@cloudera.com>
Gerrit-Reviewer: Attila Jeges <attilaj@cloudera.com>
Gerrit-Reviewer: Dan Hecht <dhecht@cloudera.com>
Gerrit-Reviewer: Taras Bobrovytsky <tbobrovytsky@cloudera.com>
Gerrit-HasComments: Yes

Mime
View raw message