Program: 70645
Project: 70645
Buggy source:
public SplitResult split(int height,boolean force) throws BirtException {
  assert(height < this.height);
  LineArea result=null;
  Iterator iter=children.iterator();
  while (iter.hasNext()) {
    ContainerArea child=(ContainerArea)iter.next();
    if (iter.hasNext()) {
      if (child.getX() < height) {
        continue;
      }
 else {
        if (child.getMinYPosition() <= height) {
          iter.remove();
          if (result == null) {
            result=cloneArea();
          }
          result.addChild(child);
          child.setParent(result);
        }
 else {
          SplitResult splitChild=child.split(height - child.getY(),force);
          ContainerArea splitChildArea=splitChild.getResult();
          if (splitChildArea != null) {
            if (result == null) {
              result=cloneArea();
            }
            result.addChild(splitChildArea);
            splitChildArea.setParent(result);
          }
        }
      }
    }
 else {
      break;
    }
  }
  if (result != null) {
    int h=0;
    iter=result.getChildren();
    while (iter.hasNext()) {
      ContainerArea child=(ContainerArea)iter.next();
      h=Math.max(h,child.getAllocatedHeight());
    }
    result.setHeight(h);
  }
  if (children.size() > 0) {
    int h=0;
    iter=getChildren();
    while (iter.hasNext()) {
      ContainerArea child=(ContainerArea)iter.next();
      h=Math.max(h,child.getAllocatedHeight());
    }
    result.setHeight(h);
  }
  if (result != null) {
    return new SplitResult(result,SplitResult.SPLIT_SUCCEED_WITH_PART);
  }
 else {
    return SplitResult.SUCCEED_WITH_NULL;
  }
}

Fixed version (ground truth):
public SplitResult split(int height,boolean force) throws BirtException {
  assert(height < this.height);
  LineArea result=null;
  Iterator iter=children.iterator();
  while (iter.hasNext()) {
    ContainerArea child=(ContainerArea)iter.next();
    if (iter.hasNext()) {
      if (child.getX() < height) {
        continue;
      }
 else {
        if (child.getMinYPosition() <= height) {
          iter.remove();
          if (result == null) {
            result=cloneArea();
          }
          result.addChild(child);
          child.setParent(result);
        }
 else {
          SplitResult splitChild=child.split(height - child.getY(),force);
          ContainerArea splitChildArea=splitChild.getResult();
          if (splitChildArea != null) {
            if (result == null) {
              result=cloneArea();
            }
            result.addChild(splitChildArea);
            splitChildArea.setParent(result);
          }
        }
      }
    }
 else {
      break;
    }
  }
  if (result != null) {
    int h=0;
    iter=result.getChildren();
    while (iter.hasNext()) {
      ContainerArea child=(ContainerArea)iter.next();
      h=Math.max(h,child.getAllocatedHeight());
    }
    result.setHeight(h);
  }
  if (children.size() > 0) {
    int h=0;
    iter=getChildren();
    while (iter.hasNext()) {
      ContainerArea child=(ContainerArea)iter.next();
      h=Math.max(h,child.getAllocatedHeight());
    }
    setHeight(h);
  }
  if (result != null) {
    return new SplitResult(result,SplitResult.SPLIT_SUCCEED_WITH_PART);
  }
 else {
    return SplitResult.SUCCEED_WITH_NULL;
  }
}