Program: 31882
Project: 31882
Buggy source:
private void drawTimeAxis(Canvas c,float labelBeginX,float labelBeginY,float nt){
  float axisMin=(float)timeWatch;
  float axisMax=0;
  float canvasMin=0;
  float canvasMax=labelBeginY;
  updateGridLabels(axisMin,axisMax,nt,GridScaleType.TIME);
  float yPos;
  float labelLargeLen=0.03f * canvasWidth;
  float labelSmallLen=0.02f * canvasWidth;
  float textHeigh=labelPaint.getFontMetrics(null);
  for (int i=0; i < gridPoints2T[0].length; i++) {
    yPos=((float)gridPoints2T[0][i] - axisMin) / (axisMax - axisMin) * (canvasMax - canvasMin) + canvasMin;
    c.drawLine(labelBeginX - labelLargeLen,yPos,labelBeginX,yPos,gridPaint);
  }
  for (int i=0; i < gridPoints2T[1].length; i++) {
    yPos=((float)gridPoints2T[1][i] - axisMin) / (axisMax - axisMin) * (canvasMax - canvasMin) + canvasMin;
    c.drawLine(labelBeginX - labelSmallLen,yPos,labelBeginX,yPos,gridPaint);
  }
  c.drawLine(labelBeginX,canvasMin,labelBeginX,canvasMax,labelPaint);
  float widthDigit=labelPaint.measureText("String_Node_Str");
  yPos=labelBeginY + 0.5f * labelLargeLen + textHeigh;
  for (int i=0; i < gridPoints2StrT.length; i++) {
    yPos=((float)gridPoints2T[0][i] - axisMin) / (axisMax - axisMin) * (canvasMax - canvasMin) + canvasMin;
    if (yPos > canvasMax - 1.3f * textHeigh) {
      continue;
    }
    c.drawText(gridPoints2stT[i],0,gridPoints2StrT[i].length(),labelBeginX - widthDigit * gridPoints2StrT[i].length() - 0.5f * labelLargeLen,yPos,labelPaint);
  }
  c.drawText("String_Node_Str",labelBeginX - widthDigit * 3 - 0.5f * labelLargeLen,canvasMax,labelPaint);
}

Fixed version (ground truth):
private void drawTimeAxis(Canvas c,float labelBeginX,float labelBeginY,float nt){
  float axisMin=(float)timeWatch * timeMultiplier;
  float axisMax=0;
  float canvasMin=0;
  float canvasMax=labelBeginY;
  updateGridLabels(axisMin,axisMax,nt,GridScaleType.TIME);
  float yPos;
  float labelLargeLen=0.03f * canvasWidth;
  float labelSmallLen=0.02f * canvasWidth;
  float textHeigh=labelPaint.getFontMetrics(null);
  for (int i=0; i < gridPoints2T[0].length; i++) {
    yPos=((float)gridPoints2T[0][i] - axisMin) / (axisMax - axisMin) * (canvasMax - canvasMin) + canvasMin;
    c.drawLine(labelBeginX - labelLargeLen,yPos,labelBeginX,yPos,gridPaint);
  }
  for (int i=0; i < gridPoints2T[1].length; i++) {
    yPos=((float)gridPoints2T[1][i] - axisMin) / (axisMax - axisMin) * (canvasMax - canvasMin) + canvasMin;
    c.drawLine(labelBeginX - labelSmallLen,yPos,labelBeginX,yPos,gridPaint);
  }
  c.drawLine(labelBeginX,canvasMin,labelBeginX,canvasMax,labelPaint);
  float widthDigit=labelPaint.measureText("String_Node_Str");
  yPos=labelBeginY + 0.5f * labelLargeLen + textHeigh;
  for (int i=0; i < gridPoints2StrT.length; i++) {
    yPos=((float)gridPoints2T[0][i] - axisMin) / (axisMax - axisMin) * (canvasMax - canvasMin) + canvasMin;
    if (yPos > canvasMax - 1.3f * textHeigh) {
      continue;
    }
    c.drawText(gridPoints2stT[i],0,gridPoints2StrT[i].length(),labelBeginX - widthDigit * gridPoints2StrT[i].length() - 0.5f * labelLargeLen,yPos,labelPaint);
  }
  c.drawText("String_Node_Str",labelBeginX - widthDigit * 3 - 0.5f * labelLargeLen,canvasMax,labelPaint);
}