Program: 163625
Project: 163625
Buggy source:
@Override protected void arcImpl(float x,float y,float w,float h,float start,float stop,int mode){
  if (stop - start >= TWO_PI) {
    ellipseImpl(x,y,w,h);
  }
 else {
    start=start * RAD_TO_DEG;
    stop=stop * RAD_TO_DEG;
    while (start < 0) {
      start+=360;
      stop+=360;
    }
    if (start > stop) {
      float temp=start;
      start=stop;
      stop=temp;
    }
    float sweep=stop - start;
    rect.set(x,y,x + w,y + h);
    if (mode == 0) {
      if (fill) {
        canvas.drawArc(rect,start,sweep,true,fillPaint);
      }
      if (stroke) {
        canvas.drawArc(rect,start,sweep,false,strokePaint);
      }
    }
 else     if (mode == OPEN) {
      if (fill) {
        showMissingWarning("String_Node_Str");
      }
      if (stroke) {
        canvas.drawArc(rect,start,sweep,false,strokePaint);
      }
    }
 else     if (mode == CHORD) {
      showMissingWarning("String_Node_Str");
    }
 else     if (mode == PIE) {
      if (fill) {
        canvas.drawArc(rect,start,sweep,true,fillPaint);
      }
      if (stroke) {
        canvas.drawArc(rect,start,sweep,true,strokePaint);
      }
    }
  }
}

Fixed version (ground truth):
@Override protected void arcImpl(float x,float y,float w,float h,float start,float stop,int mode){
  if (stop - start >= TWO_PI) {
    ellipseImpl(x,y,w,h);
  }
 else {
    start=start * RAD_TO_DEG;
    stop=stop * RAD_TO_DEG;
    while (start < 0) {
      start+=360;
      stop+=360;
    }
    if (start > stop) {
      float temp=start;
      start=stop;
      stop=temp;
    }
    float sweep=stop - start;
    rect.set(x,y,x + w,y + h);
    if (mode == 0) {
      if (fill) {
        canvas.drawArc(rect,start,sweep,true,fillPaint);
      }
      if (stroke) {
        canvas.drawArc(rect,start,sweep,false,strokePaint);
      }
    }
 else     if (mode == OPEN) {
      if (fill) {
        canvas.drawArc(rect,start,sweep,false,fillPaint);
        canvas.drawArc(rect,start,sweep,false,strokePaint);
      }
      if (stroke) {
        canvas.drawArc(rect,start,sweep,false,strokePaint);
      }
    }
 else     if (mode == CHORD) {
      float endAngle=start + sweep;
      float halfRectWidth=rect.width() / 2;
      float halfRectHeight=rect.height() / 2;
      float centerX=rect.centerX();
      float centerY=rect.cenerY();
      float startX=(float)(halfRectWidth * Math.cos(Math.toRadians(start))) + centerX;
      float startY=(float)(halfRectHeight * Math.sin(Math.toRadians(start))) + centerY;
      float endX=(float)(halfRectWidth * Math.cos(Math.toRadians(endAngle))) + centerX;
      float endY=(float)(halfRectHeight * Math.sin(Math.toRadians(endAngle))) + centerY;
      if (fill) {
        canvas.drawArc(rect,start,sweep,false,fillPaint);
        canvas.drawArc(rect,start,sweep,false,strokePaint);
        canvas.drawLine(startX,startY,endX,endY,strokePaint);
      }
      if (stroke) {
        canvas.drawArc(rect,start,sweep,false,strokePaint);
        canvas.drawLine(startX,startY,endX,endY,strokePaint);
      }
    }
 else     if (mode == PIE) {
      if (fill) {
        canvas.drawArc(rect,start,sweep,true,fillPaint);
      }
      if (stroke) {
        canvas.drawArc(rect,start,sweep,true,strokePaint);
      }
    }
  }
}