Program: 72911
Project: 72911
Buggy source:
private String getOutputFromCursor(CubeCursor cursor,List columnEdgeBindingNames,List rowEdgeBindingNames,String measureBindingNames,String columnAggr,String rowAggr,String overallAggr) throws OLAPException {
  EdgeCursor edge1=(EdgeCursor)(cursor.getOrdinateEdge().get(0));
  EdgeCursor edge2=(EdgeCursor)(cursor.getOrdinateEdge().get(1));
  String[] lines=new String[columnEdgeBindingNames.size()];
  for (int i=0; i < columnEdgeBindingNames.size(); i++) {
    lines[i]="String_Node_Str";
  }
  while (edge1.next()) {
    for (int i=0; i < columnEdgeBindingNames.size(); i++) {
      lines[i]+=cursor.getObject(columnEdgeBindingNames.get(i).toString()) + "String_Node_Str";
    }
  }
  if (rowAggr != null)   lines[lines.length - 1]+="String_Node_Str";
  String output="String_Node_Str";
  for (int i=0; i < lines.length; i++) {
    output+="String_Node_Str" + lines[i];
  }
  while (edge2.next()) {
    String line="String_Node_Str";
    for (int i=0; i < rowEdgeBindingNames.size(); i++) {
      line+=cursor.getObject(rowEdgeBindingNames.get(i).toString()).toString() + "String_Node_Str";
    }
    edge1.beforeFirst();
    while (edge1.next()) {
      line+=cursor.getObject(measureBindingNames) + "String_Node_Str";
    }
    if (rowAggr != null)     line+=cursor.getObject(rowAggr);
    output+="String_Node_Str" + line;
  }
  if (columnAggr != null) {
    String line="String_Node_Str" + "String_Node_Str";
    edge1.beforeFirst();
    while (edge1.next()) {
      line+=cursor.getObject(columnAggr) + "String_Node_Str";
    }
    if (overallAggr != null)     line+=cursor.getObject(overallAggr);
    output+="String_Node_Str" + line;
  }
  return output;
}

Fixed version (ground truth):
private String getOutputFromCursor(CubeCursor cursor,List columnEdgeBindingNames,List rowEdgeBindingNames,String measureBindingName,String[] columnAggrs) throws OLAPException {
  EdgeCursor edge1=(EdgeCursor)(cursor.getOrdinateEdge().get(0));
  EdgeCursor edge2=(EdgeCursor)(cursor.getOrdinateEdge().get(1));
  String[] lines=new String[columnEdgeBindingNames.size()];
  for (int i=0; i < columnEdgeBindingNames.size(); i++) {
    lines[i]="String_Node_Str";
  }
  while (edge1.next()) {
    for (int i=0; i < columnEdgeBindingNames.size(); i++) {
      lines[i]+=cursor.getObject(columnEdgeBindingNames.get(i).toString()) + "String_Node_Str";
    }
  }
  String output="String_Node_Str";
  for (int i=0; i < lines.length; i++) {
    output+="String_Node_Str" + lines[i];
  }
  while (edge2.next()) {
    String line="String_Node_Str";
    for (int i=0; i < rowEdgeBindingNames.size(); i++) {
      line+=cursor.getObject(rowEdgeBindingNames.get(i).toString()).toString() + "String_Node_Str";
    }
    edge1.beforeFirst();
    while (edge1.next()) {
      line+=cursor.getObject(measureBindingName) + "String_Node_Str";
    }
    output+="String_Node_Str" + line;
  }
  String line="String_Node_Str" + "String_Node_Str";
  edge1.beforeFirst();
  edge2.first();
  while (edge1.next()) {
    line+=cursor.getObject("String_Node_Str") + "String_Node_Str";
  }
  output+="String_Node_Str" + line;
  line="String_Node_Str" + "String_Node_Str";
  edge1.beforeFirst();
  edge2.first();
  while (edge1.next()) {
    line+=cursor.getObject("String_Node_Str") + "String_Node_Str";
  }
  output+="String_Node_Str" + line;
  line="String_Node_Str" + "String_Node_Str";
  edge1.beforeFirst();
  edge2.first();
  while (edge1.next()) {
    line+=cursor.getObject("String_Node_Str") + "String_Node_Str";
  }
  output+="String_Node_Str" + line;
  line="String_Node_Str" + "String_Node_Str";
  edge1.beforeFirst();
  edge2.first();
  while (edge1.next()) {
    line+=cursor.getObject("String_Node_Str") + "String_Node_Str";
  }
  output+="String_Node_Str" + line + "String_Node_Str";
  return output;
}