Program: 74847
Project: 74847
Buggy source:
public void resolveAll(){
  if (rows.size() == 0 || !hasDropCell) {
    return;
  }
  Row row=(Row)rows.getCurrent();
  int rowHeight=row.getArea().getHeight();
  int height=rowHeight;
  boolean hasDropCell=false;
  for (int i=startCol; i <= endCol; i++) {
    CellArea cell=row.getCell(i);
    if (cell != null) {
      if (isDropCell(cell) || cell.getRowSpan() > 1) {
        height=Math.max(height,cell.getHeight());
        hasDropCell=true;
      }
    }
  }
  if (hasDropCell) {
    HashSet dropCells=new HashSet();
    int delta=height - rowHeight;
    if (delta > 0) {
      row.getArea().setHeight(height);
    }
    for (int i=startCol; i <= endCol; i++) {
      CellArea cell=row.getCell(i);
      if (cell == null) {
        continue;
      }
      int rowSpan=cell.getRowSpan();
      if (rowSpan < 0 || rowSpan > 1) {
        if (cell instanceof DummyCell) {
          CellArea ref=((DummyCell)cell).getCell();
          int cellHeight=cell.getHeight();
          int refHeight=ref.getHeight();
          if (!dropCells.contains(ref)) {
            ref.setHeight(refHeight - cellHeight + delta);
            verticalAlign(ref);
            dropCells.add(ref);
          }
        }
 else {
          cell.setHeight(height);
          verticalAlign(cell);
        }
      }
 else       if (rowSpan == 1) {
        if (cell instanceof DummyCell) {
          CellArea ref=((DummyCell)cell).getCell();
          if (!dropCells.contains(ref)) {
            ref.setHeight(ref.getHeight() + delta);
            if (delta > 0) {
              verticalAlign(ref);
            }
            dropCells.add(ref);
          }
        }
 else {
          cell.setHeight(height);
          verticalAlign(cell);
        }
      }
    }
  }
  if (hasDropCell || (row != null && !row.finished)) {
    unresolvedRow=row;
  }
}

Fixed version (ground truth):
public int resolveAll(){
  if (rows.size() == 0 || !hasDropCell) {
    return 0;
  }
  Row row=(Row)rows.getCurrent();
  int rowHeight=row.getArea().getHeight();
  int height=rowHeight;
  boolean hasDropCell=false;
  for (int i=startCol; i <= endCol; i++) {
    CellArea cell=row.getCell(i);
    if (cell != null) {
      if (isDropCell(cell) || cell.getRowSpan() > 1) {
        if (cell instanceof DummyCell) {
          height=Math.max(height,cell.getHeight() + rowHeight);
        }
 else {
          height=Math.max(height,cell.getHeight());
        }
        hasDropCell=true;
      }
    }
  }
  int delta=height - rowHeight;
  if (hasDropCell) {
    HashSet dropCells=new HashSet();
    if (delta > 0) {
      row.getArea().setHeight(height);
    }
    for (int i=startCol; i <= endCol; i++) {
      CellArea cell=row.getCell(i);
      if (cell == null) {
        continue;
      }
      int rowSpan=cell.getRowSpan();
      if (rowSpan < 0 || rowSpan > 1) {
        if (cell instanceof DummyCell) {
          CellArea ref=((DummyCell)cell).getCell();
          int cellHeight=cell.getHeight();
          int refHeight=ref.getHeight();
          if (!dropCells.contains(ref)) {
            ref.setHeight(refHeight - cellHeight + delta);
            verticalAlign(ref);
            dropCells.add(ref);
          }
        }
 else {
          cell.setHeight(height);
          verticalAlign(cell);
        }
      }
 else       if (rowSpan == 1) {
        if (cell instanceof DummyCell) {
          CellArea ref=((DummyCell)cell).getCell();
          if (!dropCells.contains(ref)) {
            ref.setHeight(ref.getHeight() + delta);
            if (delta > 0) {
              verticalAlign(ref);
            }
            dropCells.add(ref);
          }
        }
 else {
          cell.setHeight(height);
          verticalAlign(cell);
        }
      }
    }
  }
  if (hasDropCell || (row != null && !row.finished)) {
    unresolvedRow=row;
  }
  return delta;
}