[
https://issues.apache.org/jira/browse/TAJO-1512?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14394127#comment-14394127
]
Tajo QA commented on TAJO-1512:
-------------------------------
{color:green}*+1 overall.*{color} Here are the results of testing the latest
attachment
http://issues.apache.org/jira/secure/attachment/12709184/TAJO-1512.Hyun.150403.0.patch
against master revision release-0.9.0-rc0-236-g70d5fdf.
{color:green}+1 @author.{color} The patch does not contain any @author
tags.
{color:green}+1 tests included.{color} The patch appears to include 1 new
or modified test files.
{color:green}+1 javac.{color} The applied patch does not increase the
total number of javac compiler warnings.
{color:green}+1 javadoc.{color} The applied patch does not increase the
total number of javadoc warnings.
{color:green}+1 checkstyle.{color} The patch generated 0 code style errors.
{color:green}+1 findbugs.{color} The patch does not introduce any new
Findbugs (version 2.0.3) warnings.
{color:green}+1 release audit.{color} The applied patch does not increase
the total number of release audit warnings.
{color:green}+1 core tests.{color} The patch passed unit tests in
tajo-algebra.
Test results:
https://builds.apache.org/job/PreCommit-TAJO-Build/694//testReport/
Console output: https://builds.apache.org/job/PreCommit-TAJO-Build/694//console
This message is automatically generated.
> Fix Aggregation.clone NPE bug
> -----------------------------
>
> Key: TAJO-1512
> URL: https://issues.apache.org/jira/browse/TAJO-1512
> Project: Tajo
> Issue Type: Bug
> Affects Versions: 0.10.0
> Reporter: Dongjoon Hyun
> Assignee: Dongjoon Hyun
> Priority: Critical
> Fix For: 0.10.1
>
> Attachments: TAJO-1512.Hyun.150403.0.patch
>
>
> When `Expr.clone()` is called, NPE is raised because `Aggregation.clone()`
> does not check its `null` array. This issue should be solved for others
> issues reusing `Expr`. Please refer the following code.
> {code:java}
> - aggregation.namedExprs = new NamedExpr[namedExprs.length];
> - for (int i = 0; i < namedExprs.length; i++) {
> - aggregation.namedExprs[i] = (NamedExpr) namedExprs[i].clone();
> + if (namedExprs != null) {
> + aggregation.namedExprs = new NamedExpr[namedExprs.length];
> + for (int i = 0; i < namedExprs.length; i++) {
> + aggregation.namedExprs[i] = (NamedExpr) namedExprs[i].clone();
> + }
> }
>
> - aggregation.groups = new GroupElement[groups.length];
> - for (int i = 0; i < groups.length; i++) {
> - aggregation.groups[i] = (GroupElement) groups[i].clone();
> + if (groups != null) {
> + aggregation.groups = new GroupElement[groups.length];
> + for (int i = 0; i < groups.length; i++) {
> + aggregation.groups[i] = (GroupElement) groups[i].clone();
> + }
> }
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)