Program: 67377
Project: 67377
Buggy source:
private Map getCurrentValueOnEdge(String aggrName) throws OLAPException {
  EdgeCursor rowEdgeCursor=null, columnEdgeCursor=null, pageEdgeCursor=null;
  List columnDimList=null, rowDimList=null, pageDimList=null;
  if (this.view.getRowEdgeView() != null) {
    rowEdgeCursor=(EdgeCursor)((BirtEdgeView)this.view.getRowEdgeView()).getEdgeCursor();
    if (rowEdgeCursor != null)     rowDimList=rowEdgeCursor.getDimensionCursor();
  }
  if (this.view.getColumnEdgeView() != null) {
    columnEdgeCursor=(EdgeCursor)((BirtEdgeView)this.view.getColumnEdgeView()).getEdgeCursor();
    if (columnEdgeCursor != null)     columnDimList=columnEdgeCursor.getDimensionCursor();
  }
  if (this.view.getPageEdgeView() != null) {
    pageEdgeCursor=(EdgeCursor)((BirtEdgeView)this.view.getPageEdgeView()).getEdgeCursor();
    if (pageEdgeCursor != null)     pageDimList=pageEdgeCursor.getDimensionCursor();
  }
  Relationship relation=(Relationship)this.relationMap.get(aggrName);
  List pageLevelList=relation.getLevelListOnPage();
  List columnLevelList=relation.getLevelListOnColumn();
  List rowLevelList=relation.getLevelListOnRow();
  Map valueMap=new HashMap();
  if (columnLevelList.isEmpty() && rowLevelList.isEmpty() && pageLevelList.isEmpty())   return null;
  for (int index=0; index < pageLevelList.size(); index++) {
    DimLevel level=(DimLevel)pageLevelList.get(index);
    DimensionCursor cursor=(DimensionCursor)pageDimList.get(index);
    Object value=cursor.getObject(level.getLevelName());
    valueMap.put(level,value);
  }
  for (int i=0; i < columnLevelList.size(); i++) {
    DimLevel level=(DimLevel)columnLevelList.get(i);
    DimensionCursor cursor=(DimensionCursor)columnDimList.get(i);
    Object value=cursor.getObject(level.getLevelName());
    valueMap.put(level,value);
  }
  for (int i=0; i < rowLevelList.size(); i++) {
    DimLevel level=(DimLevel)rowLevelList.get(i);
    DimensionCursor cursor=(DimensionCursor)rowDimList.get(i);
    Object value=cursor.getObject(level.getLevelName());
    valueMap.put(level,value);
  }
  return valueMap;
}

Fixed version (ground truth):
private Map getCurrentValueOnEdge(String aggrName) throws OLAPException {
  if (!this.dimensionPrepared) {
    this.prepareDimensionCursor();
    this.dimensionPrepared=true;
  }
  Relationship relation=(Relationship)this.relationMap.get(aggrName);
  List pageLevelList=relation.getLevelListOnPage();
  List columnLevelList=relation.getLevelListOnColumn();
  List rowLevelList=relation.getLevelListOnRow();
  Map valueMap=new HashMap();
  if (columnLevelList.isEmpty() && rowLevelList.isEmpty() && pageLevelList.isEmpty())   return null;
  for (int index=0; index < pageLevelList.size(); index++) {
    DimLevel level=(DimLevel)pageLevelList.get(index);
    DimensionCursor cursor=(DimensionCursor)dimensionCursorMap.get(UniqueNamingUtil.getUniqueName(level.getDimensionName(),level.getLevelName()));
    Object value=cursor.getObject(level.getLevelName());
    valueMap.put(level,value);
  }
  for (int i=0; i < columnLevelList.size(); i++) {
    DimLevel level=(DimLevel)columnLevelList.get(i);
    DimensionCursor cursor=(DimensionCursor)dimensionCursorMap.get(UniqueNamingUtil.getUniqueName(level.getDimensionName(),level.getLevelName()));
    Object value=cursor.getObject(level.getLevelName());
    valueMap.put(level,value);
  }
  for (int i=0; i < rowLevelList.size(); i++) {
    DimLevel level=(DimLevel)rowLevelList.get(i);
    DimensionCursor cursor=(DimensionCursor)dimensionCursorMap.get(UniqueNamingUtil.getUniqueName(level.getDimensionName(),level.getLevelName()));
    Object value=cursor.getObject(level.getLevelName());
    valueMap.put(level,value);
  }
  return valueMap;
}