Repository: incubator-hawq Updated Branches: refs/heads/master 1e5e996ec -> 56e21fce3
HAWQ-1135. MADlib: Raising exception leads to database connection termination. Project: http://git-wip-us.apache.org/repos/asf/incubator-hawq/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-hawq/commit/56e21fce Tree: http://git-wip-us.apache.org/repos/asf/incubator-hawq/tree/56e21fce Diff: http://git-wip-us.apache.org/repos/asf/incubator-hawq/diff/56e21fce Branch: refs/heads/master Commit: 56e21fce3d3e0c65d7988cb8b0fbdbc6f1975a60 Parents: 1e5e996 Author: hzhang2 <[email protected]> Authored: Wed Nov 2 10:24:04 2016 +0800 Committer: hzhang2 <[email protected]> Committed: Wed Nov 2 10:38:25 2016 +0800 ---------------------------------------------------------------------- src/backend/access/transam/xact.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/56e21fce/src/backend/access/transam/xact.c ---------------------------------------------------------------------- diff --git a/src/backend/access/transam/xact.c b/src/backend/access/transam/xact.c index cfb5351..440b2ca 100644 --- a/src/backend/access/transam/xact.c +++ b/src/backend/access/transam/xact.c @@ -4822,7 +4822,11 @@ AbortSubTransaction(void) AtSubAbort_Memory(); AtSubAbort_ResourceOwner(); AtAbort_AppendOnly(true); - AtSubAbort_ActiveQueryResource(); + /* In sub transaction, ActiveQueryResource should not be set NULL + * sub transaction inherits resource from parent. + * parent transaction may still use ActiveQueryResource to reference the original resource. + */ + // AtSubAbort_ActiveQueryResource(); /* * Release any LW locks we might be holding as quickly as possible.
