Program: 52607
Project: 52607
Buggy source:
@Override protected void paintTabBackground(final Graphics g,final int tabPlacement,final int tabIndex,final int x,final int y,final int w,final int h,final boolean isSelected){
  final Graphics2D g2d=(Graphics2D)g;
  final Object aa=GraphicsUtils.setupAntialias(g2d);
  final GeneralPath borderShape=createTabShape(TabShapeType.border,tabPlacement,x,y,w,h,isSelected);
  if (tabbedPaneStyle.equals(TabbedPaneStyle.standalone)) {
    final GeneralPath shadeShape=createTabShape(TabShapeType.shade,tabPlacement,x,y,w,h,isSelected);
    GraphicsUtils.drawShade(g2d,shadeShape,StyleConstants.shadeColor,shadeWidth,new Rectangle2D.Double(0,0,tabPane.getWidth(),y + h),round > 0);
  }
  final GeneralPath bgShape=createTabShape(TabShapeType.background,tabPlacement,x,y,w,h,isSelected);
  if (backgroundPainterAt.containsKey(tabIndex) && isSelected) {
    final Shape old=GraphicsUtils.intersectClip(g2d,bgShape);
    final Painter bp=backgroundPainterAt.get(tabIndex);
    bp.paint(g2d,new Rectangle(x,y,w,h),tabPane);
    GraphicsUtils.restoreClip(g2d,old);
  }
 else {
    final Point topPoint=getTopTabBgPoint(tabPlacement,x,y,w,h);
    final Point bottomPoint=getBottomTabBgPoint(tabPlacement,x,y,w,h);
    if (isSelected) {
      if (forceUseSelectedTabBgColors) {
        g2d.setPaint(new GradientPaint(topPoint.x,topPoint.y,selectedTopBg,bottomPoint.x,bottomPoint.y,selectedTopBg));
      }
 else {
        Color bg=tabPane.getBackgroundAt(tabIndex);
        bg=bg != null ? bg : tabPane.getBackground();
        g2d.setPaint(new GradientPaint(topPoint.x,topPoint.y,selectedTopBg,bottomPoint.x,bottomPoint.y,bg));
      }
    }
 else {
      g2d.setPaint(new GradientPaint(topPoint.x,topPoint.y,topBg,bottomPoint.x,bottomPoint.y,bottomBg));
    }
    g2d.fill(isSelected ? borderShape : bgShape);
  }
  g2d.setPaint(tabBorderColor);
  g2d.draw(borderShape);
  final boolean drawFocus=isSelected && tabPane.isFocusOwner();
  if (tabbedPaneStyle.equals(TabbedPaneStyle.standalone)) {
    LafUtils.drawCustomWebFocus(g2d,null,StyleConstants.focusType,borderShape,null,drawFocus);
  }
  GraphicsUtils.restoreAntialias(g2d,aa);
}

Fixed version (ground truth):
@Override protected void paintTabBackground(final Graphics g,final int tabPlacement,final int tabIndex,final int x,final int y,final int w,final int h,final boolean isSelected){
  final Graphics2D g2d=(Graphics2D)g;
  final Object aa=GraphicsUtils.setupAntialias(g2d);
  final GeneralPath borderShape=createTabShape(TabShapeType.border,tabPlacement,x,y,w,h,isSelected);
  if (tabbedPaneStyle.equals(TabbedPaneStyle.standalone)) {
    final GeneralPath shadeShape=createTabShape(TabShapeType.shade,tabPlacement,x,y,w,h,isSelected);
    GraphicsUtils.drawShade(g2d,shadeShape,StyleConstants.shadeColor,shadeWidth,new Rectangle2D.Double(0,0,tabPane.getWidth(),y + h),round > 0);
  }
  final GeneralPath bgShape=createTabShape(TabShapeType.background,tabPlacement,x,y,w,h,isSelected);
  if (backgroundPainterAt.containsKey(tabIndex) && isSelected) {
    final Shape old=GraphicsUtils.intersectClip(g2d,bgShape);
    final Painter bp=backgroundPainterAt.get(tabIndex);
    bp.paint(g2d,new Rectangle(x,y,w,h),tabPane);
    GraphicsUtils.restoreClip(g2d,old);
  }
 else {
    final Point topPoint=getTopTabBgPoint(tabPlacement,x,y,w,h);
    final Point bottomPoint=getBottomTabBgPoint(tabPlacement,x,y,w,h);
    if (isSelected) {
      if (forceUseSelectedTabBgColors) {
        g2d.setPaint(new GradientPaint(topPoint.x,topPoint.y,selectedTopBg,bottomPoint.x,bottomPoint.y,selectedBottomBg));
      }
 else {
        Color bg=tabPane.getBackgroundAt(tabIndex);
        bg=bg != null ? bg : tabPane.getBackground();
        g2d.setPaint(new GradientPaint(topPoint.x,topPoint.y,selectedTopBg,bottomPoint.x,bottomPoint.y,bg));
      }
    }
 else {
      g2d.setPaint(new GradientPaint(topPoint.x,topPoint.y,topBg,bottomPoint.x,bottomPoint.y,bottomBg));
    }
    g2d.fill(isSelected ? borderShape : bgShape);
  }
  g2d.setPaint(tabBorderColor);
  g2d.draw(borderShape);
  final boolean drawFocus=isSelected && tabPane.isFocusOwner();
  if (tabbedPaneStyle.equals(TabbedPaneStyle.standalone)) {
    LafUtils.drawCustomWebFocus(g2d,null,StyleConstants.focusType,borderShape,null,drawFocus);
  }
  GraphicsUtils.restoreAntialias(g2d,aa);
}