Program: 68495
Project: 68495
Buggy source:
protected Bounds computeBounds() throws ChartException {
  final Bounds originalBounds=cm.getBlock().getBounds();
  Bounds bounds=originalBounds.copyInstance();
  try {
    AggregationCellHandle xtabCell=ChartCubeUtil.getXtabContainerCell(modelHandle);
    if (xtabCell != null) {
      if (xtabCell.getSpanOverOnColumn() != null) {
        double dWidth=getColumnCellWidth(xtabCell.getCrosstab(),dpi);
        if (ChartUtil.mathEqual(dWidth,0)) {
          dWidth=ChartCubeUtil.DEFAULT_COLUMN_WIDTH.getMeasure();
        }
        StyleHandle style=xtabCell.getModelHandle().getPrivateStyle();
        double dLeftBorder=ChartItemUtil.convertToPoints(style.getBorderLeftWidth(),dpi);
        double dRightBorder=ChartItemUtil.convertToPoints(style.getBorderRightWidth(),dpi);
        bounds.setWidth(-roundPointsWithPixels(dWidth + (dLeftBorder + dRightBorder) / 2));
        double dHeight=getRowCellHeight(xtabCell.getCrosstab(),dpi);
        if (!ChartUtil.mathEqual(dHeight,0) && !ChartUtil.mathEqual(dHeight,ChartCubeUtil.DEFAULT_ROW_HEIGHT.getMeasure())) {
          bounds.setHeight(dHeight);
        }
      }
 else       if (xtabCell.getSpanOverOnRow() != null) {
        double dHeight=getRowCellHeight(xtabCell.getCrosstab(),dpi);
        if (ChartUtil.mathEqual(dHeight,0)) {
          dHeight=ChartCubeUtil.DEFAULT_ROW_HEIGHT.getMeasure();
        }
        StyleHandle style=xtabCell.getModelHandle().getPrivateStyle();
        double dTopBorder=ChartItemUtil.convertToPoints(style.getBorderTopWidth(),dpi);
        double dBottomBorder=ChartItemUtil.convertToPoints(style.getBorderBottomWidth(),dpi);
        bounds.setHeight(-roundPointsWithPixels(dHeight + (dTopBorder + dBottomBorder) / 2));
        double dWidth=getColumnCellWidth(xtabCell.getCrosstab(),dpi);
        if (!ChartUtil.mathEqual(dWidth,0) && !ChartUtil.mathEqual(dWidth,ChartCubeUtil.DEFAULT_COLUMN_WIDTH.getMeasure())) {
          bounds.setWidth(dWidth);
        }
      }
    }
  }
 catch (  BirtException e) {
    throw new ChartException(ChartReportItemConstants.ID,ChartException.GENERATION,e);
  }
  return bounds;
}

Fixed version (ground truth):
protected Bounds computeBounds() throws ChartException {
  final Bounds originalBounds=cm.getBlock().getBounds();
  Bounds bounds=originalBounds.copyInstance();
  try {
    AggregationCellHandle xtabCell=ChartCubeUtil.getXtabContainerCell(modelHandle);
    if (xtabCell != null) {
      if (xtabCell.getSpanOverOnColumn() != null) {
        double dWidth=getColumnCellWidth(xtabCell.getCrosstab(),dpi);
        if (ChartUtil.mathEqual(dWidth,0)) {
          dWidth=ChartCubeUtil.DEFAULT_COLUMN_WIDTH.getMeasure();
        }
        StyleHandle style=xtabCell.getModelHandle().getPrivateStyle();
        double dLeftBorder=ChartItemUtil.convertToPoints(style.getBorderLeftWidth(),dpi);
        double dRightBorder=ChartItemUtil.convertToPoints(style.getBorderRightWidth(),dpi);
        bounds.setWidth(-roundPointsWithPixels(dWidth + (dLeftBorder + dRightBorder) / 2));
        double dHeight=getRowCellHeight(xtabCell.getCrosstab(),dpi);
        if (!ChartUtil.mathEqual(dHeight,0) && !ChartUtil.mathEqual(dHeight,ChartCubeUtil.DEFAULT_ROW_HEIGHT.getMeasure())) {
          bounds.setHeight(dHeight);
        }
 else         if (!bounds.isSetHeight() || ChartUtil.mathEqual(bounds.getHeight(),0)) {
          bounds.setHeight(ChartCubeUtil.DEFAULT_ROW_HEIGHT.getMeasure());
        }
      }
 else       if (xtabCell.getSpanOverOnRow() != null) {
        double dHeight=getRowCellHeight(xtabCell.getCrosstab(),dpi);
        if (ChartUtil.mathEqual(dHeight,0)) {
          dHeight=ChartCubeUtil.DEFAULT_ROW_HEIGHT.getMeasure();
        }
        StyleHandle style=xtabCell.getModelHandle().getPrivateStyle();
        double dTopBorder=ChartItemUtil.convertToPoints(style.getBorderTopWidth(),dpi);
        double dBottomBorder=ChartItemUtil.convertToPoints(style.getBorderBottomWidth(),dpi);
        bounds.setHeight(-roundPointsWithPixels(dHeight + (dTopBorder + dBottomBorder) / 2));
        double dWidth=getColumnCellWidth(xtabCell.getCrosstab(),dpi);
        if (!ChartUtil.mathEqual(dWidth,0) && !ChartUtil.mathEqual(dWidth,ChartCubeUtil.DEFAULT_COLUMN_WIDTH.getMeasure())) {
          bounds.setWidth(dWidth);
        }
 else         if (!bounds.isSetWidth() || ChartUtil.mathEqual(bounds.getWidth(),0)) {
          bounds.setWidth(ChartCubeUtil.DEFAULT_COLUMN_WIDTH.getMeasure());
        }
      }
    }
  }
 catch (  BirtException e) {
    throw new ChartException(ChartReportItemConstants.ID,ChartException.GENERATION,e);
  }
  return bounds;
}