Program: 21256
Project: 21256
Buggy source:
@Override public void paint(Graphics g,JComponent c){
  int vRowHeight=c.getFont().getSize() + 6;
  Rectangle clip=g.getClipBounds();
  int x=clip.x;
  int y=clip.y;
  int w=clip.width;
  int h=clip.height;
  int row=0;
  int y2=y + h;
  if (y != 0) {
    int diff=y % vRowHeight;
    row=y / vRowHeight;
    y-=diff;
  }
  TreePath path;
  Color color;
  DownloadLink dLink;
  while (y < y2) {
    path=((DownloadTreeTable)c).getPathForRow(row);
    color=row % 2 == 0 ? EVEN_ROW_COLOR : ODD_ROW_COLOR;
    if (((DownloadTreeTable)c).isRowSelected(row)) {
      color=SELECTED_ROW_COLOR;
    }
 else {
      if (path != null && path.getLastPathComponent() instanceof FilePackage) {
        if (((FilePackage)path.getLastPathComponent()).isFinished()) {
          color=COLOR_DONE;
        }
 else {
          color=PACKAGE_ROW_COLOR;
        }
        g.setColor(Color.BLACK);
        g.drawLine(x,y,w,y);
      }
 else       if (path != null && path.getLastPathComponent() instanceof DownloadLink) {
        dLink=(DownloadLink)path.getLastPathComponent();
        if (!dLink.isEnabled()) {
          color=COLOR_DISABLED;
        }
 else         if (dLink.getLinkStatus().hasStatus(LinkStatus.FINISHED)) {
          color=COLOR_DONE;
        }
 else         if (dLink.getLinkStatus().isFailed()) {
          color=COLOR_ERROR;
        }
 else         if (dLink.getLinkStatus().getRemainingWaittime() > 0 || dLink.getPlugin() == null || dLink.getPlugin().getRemainingHosterWaittime() > 0) {
          color=COLOR_WAIT;
        }
      }
    }
    if (((DownloadTreeTable)c).mouseOverRow == row) {
      if (((JTable)c).isRowSelected(row)) {
        g.setColor(color.darker());
        g.fillRect(x,y + 1,w,vRowHeight - 2);
        g.setColor(SELECTED_ROW_BORDER_COLOR);
        g.draw3DRect(x,y,w,vRowHeight - 1,true);
      }
 else {
        g.setColor(color.darker());
        g.fillRect(x,y + 1,w,vRowHeight - 1);
      }
    }
 else {
      if (((JTable)c).isRowSelected(row)) {
        g.setColor(color);
        g.fillRect(x,y + 1,w,vRowHeight - 2);
        g.setColor(SELECTED_ROW_BORDER_COLOR);
        g.draw3DRect(x,y,w,vRowHeight - 1,false);
      }
 else {
        g.setColor(color);
        g.fillRect(x,y + 1,w,vRowHeight - 1);
      }
    }
    y+=vRowHeight;
    row++;
  }
  super.paint(g,c);
  x=0;
  g.setColor(GRID_COLOR);
  TableColumnModel vModel=table.getColumnModel();
  for (int i=0; i < vModel.getColumnCount(); i++) {
    TableColumn vColumn=vModel.getColumn(i);
    x+=vColumn.getWidth();
    if (x >= clip.x && x <= clip.x + clip.width) {
      g.drawLine(x - 1,clip.y,x - 1,clip.y + clip.height);
    }
  }
}

Fixed version (ground truth):
@Override public void paint(Graphics g,JComponent c){
  int vRowHeight=c.getFont().getSize() + 6;
  Rectangle clip=g.getClipBounds();
  int x=clip.x;
  int y=clip.y;
  int w=clip.width;
  int h=clip.height;
  int row=0;
  int y2=y + h;
  if (y != 0) {
    int diff=y % vRowHeight;
    row=y / vRowHeight;
    y-=diff;
  }
  TreePath path;
  Color color;
  DownloadLink dLink;
  while (y < y2) {
    path=((DownloadTreeTable)c).getPathForRow(row);
    color=row % 2 == 0 ? EVEN_ROW_COLOR : ODD_ROW_COLOR;
    if (((DownloadTreeTable)c).isRowSelected(row)) {
      color=SELECTED_ROW_COLOR;
    }
 else {
      if (path != null && path.getLastPathComponent() instanceof FilePackage) {
        if (((FilePackage)path.getLastPathComponent()).isFinished()) {
          color=COLOR_DONE_Package;
        }
 else         if ((((FilePackage)path.getLastPathComponent()).getLinksInProgress() > 0)) {
          color=COLOR_Progress;
        }
 else {
          color=PACKAGE_ROW_COLOR;
        }
        g.setColor(Color.BLACK);
        g.drawLine(x,y,w,y);
      }
 else       if (path != null && path.getLastPathComponent() instanceof DownloadLink) {
        dLink=(DownloadLink)path.getLastPathComponent();
        if (!dLink.isEnabled()) {
          color=COLOR_DISABLED;
        }
 else         if (dLink.getLinkStatus().hasStatus(LinkStatus.PLUGIN_IN_PROGRESS)) {
          color=COLOR_Progress;
        }
 else         if (dLink.getLinkStatus().hasStatus(LinkStatus.FINISHED)) {
          color=COLOR_DONE;
        }
 else         if (dLink.getLinkStatus().isFailed()) {
          color=COLOR_ERROR;
        }
 else         if (dLink.getLinkStatus().getRemainingWaittime() > 0 || dLink.getPlugin() == null || dLink.getPlugin().getRemainingHosterWaittime() > 0) {
          color=COLOR_WAIT;
        }
      }
    }
    if (((DownloadTreeTable)c).mouseOverRow == row) {
      if (((JTable)c).isRowSelected(row)) {
        g.setColor(color.darker());
        g.fillRect(x,y + 1,w,vRowHeight - 2);
        g.setColor(SELECTED_ROW_BORDER_COLOR);
        g.draw3DRect(x,y,w,vRowHeight - 1,true);
      }
 else {
        g.setColor(color.darker());
        g.fillRect(x,y + 1,w,vRowHeight - 1);
      }
    }
 else {
      if (((JTable)c).isRowSelected(row)) {
        g.setColor(color);
        g.fillRect(x,y + 1,w,vRowHeight - 2);
        g.setColor(SELECTED_ROW_BORDER_COLOR);
        g.draw3DRect(x,y,w,vRowHeight - 1,false);
      }
 else {
        g.setColor(color);
        g.fillRect(x,y + 1,w,vRowHeight - 1);
      }
    }
    y+=vRowHeight;
    row++;
  }
  super.paint(g,c);
  x=0;
  g.setColor(GRID_COLOR);
  TableColumnModel vModel=table.getColumnModel();
  for (int i=0; i < vModel.getColumnCount(); i++) {
    TableColumn vColumn=vModel.getColumn(i);
    x+=vColumn.getWidth();
    if (x >= clip.x && x <= clip.x + clip.width) {
      g.drawLine(x - 1,clip.y,x - 1,clip.y + clip.height);
    }
  }
}