Program: 184298
Project: 184298
Buggy source:
public void onClick(View v){
  if (v.getId() == R.id.btnAdd) {
    txtMinutes.requestFocus();
    if (txtName.getText().toString().compareTo("String_Node_Str") == 0) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
 else     if ((Integer.parseInt(txtHours.getText().toString()) == 0) && (Integer.parseInt(txtMinutes.getText().toString()) == 0)) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
    String brother=getId(txtName.getText().toString());
    if (brother == null) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
    boolean driver;
    if (chkDriver.isChecked())     driver=true;
 else     driver=false;
    Brother bro=new Brother(txtName.getText().toString(),getId(txtName.getText().toString()),Integer.parseInt(txtHours.getText().toString()),Integer.parseInt(txtMinutes.getText().toString()),driver);
    brothers.add(bro);
    loadBrothers();
  }
 else   if (v.getId() == R.id.btnSubmit) {
    if (txtProjName.getText().toString().compareTo("String_Node_Str") == 0) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
 else     if (txtProjLoc.getText().toString().compareTo("String_Node_Str") == 0) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
 else     if (brothers.size() == 0) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
    try {
      JSONObject json=new JSONObject();
      for (int x=0; x < brothers.size(); x++) {
        JSONObject jsonBro=new JSONObject();
        jsonBro.put("String_Node_Str",brothers.get(x).id);
        jsonBro.put("String_Node_Str",brothers.get(x).hours);
        jsonBro.put("String_Node_Str",brothers.get(x).minutes);
        if (brothers.get(x).driver)         jsonBro.put("String_Node_Str",1);
 else         jsonBro.put("String_Node_Str",0);
        jsonBro.put("String_Node_Str",brothers.get(x).minutes);
        if (brothers.get(x).driver)         jsonBro.put("String_Node_Str",1);
 else         jsonBro.put("String_Node_Str",0);
        json.put(x + "String_Node_Str",jsonBro);
      }
      String[] params=new String[9];
      String month, day;
      if (datePicker.getMonth() < 10)       month="String_Node_Str" + datePicker.getMonth();
 else       month="String_Node_Str" + datePicker.getMonth();
      if (datePicker.getDayOfMonth() < 10)       day="String_Node_Str" + datePicker.getDayOfMonth();
 else       day="String_Node_Str" + datePicker.getDayOfMonth();
      params[0]=datePicker.getYear() + "String_Node_Str" + month+ "String_Node_Str"+ day;
      params[1]=txtProjName.getText().toString();
      params[2]=txtProjLoc.getText().toString();
      if (radIn.isChecked())       params[3]="String_Node_Str";
 else       params[3]="String_Node_Str";
      if (radOn.isChecked())       params[4]="String_Node_Str";
 else       params[4]="String_Node_Str";
      if (radService1.isChecked())       params[5]="String_Node_Str";
 else       if (radService2.isChecked())       params[5]="String_Node_Str";
 else       if (radService3.isChecked())       params[5]="String_Node_Str";
 else       params[5]="String_Node_Str";
      if (txtTravelTime.getText().toString().compareTo("String_Node_Str") == 0)       params[6]="String_Node_Str";
 else       params[6]="String_Node_Str" + Integer.parseInt(txtTravelTime.getText().toString());
      params[7]=txtComments.getText().toString();
      params[8]="String_Node_Str" + brothers.size();
      API api=new API(this);
      if (!api.callMethod(Methods.serviceReport,this,json,params)) {
        Toast msg=Toast.makeText(getApplicationContext(),"String_Node_Str",Toast.LENGTH_LONG);
        msg.show();
      }
    }
 catch (    JSONException e) {
      e.printStackTrace();
    }
  }
 else {
    Button remove=(Button)v;
    if (remove.getText().toString().compareTo("String_Node_Str") != 0)     return;
    LinearLayout row=(LinearLayout)remove.getParent();
    int count=layoutBrothers.getChildCount();
    int match=-1;
    for (int x=1; x <= count; x++) {
      if (layoutBrothers.getChildAt(x) == row) {
        match=x;
        break;
      }
    }
    if (match == -1)     return;
 else {
      brothers.remove(match - 1);
      loadBrothers();
    }
  }
}

Fixed version (ground truth):
public void onClick(View v){
  if (v.getId() == R.id.btnAdd) {
    txtMinutes.requestFocus();
    if (txtName.getText().toString().compareTo("String_Node_Str") == 0) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
 else     if ((Integer.parseInt(txtHours.getText().toString()) == 0) && (Integer.parseInt(txtMinutes.getText().toString()) == 0)) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
    String brother=getId(txtName.getText().toString());
    if (brother == null) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
    boolean driver;
    if (chkDriver.isChecked())     driver=true;
 else     driver=false;
    Brother bro=new Brother(txtName.getText().toString(),getId(txtName.getText().toString()),Integer.parseInt(txtHours.getText().toString()),Integer.parseInt(txtMinutes.getText().toString()),driver);
    brothers.add(bro);
    loadBrothers();
  }
 else   if (v.getId() == R.id.btnSubmit) {
    if (txtProjName.getText().toString().compareTo("String_Node_Str") == 0) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
 else     if (txtProjLoc.getText().toString().compareTo("String_Node_Str") == 0) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
 else     if (brothers.size() == 0) {
      Toast.makeText(this,"String_Node_Str",Toast.LENGTH_SHORT).show();
      return;
    }
    try {
      JSONObject json=new JSONObject();
      for (int x=0; x < brothers.size(); x++) {
        JSONObject jsonBro=new JSONObject();
        jsonBro.put("String_Node_Str",brothers.get(x).id);
        jsonBro.put("String_Node_Str",brothers.get(x).hours);
        jsonBro.put("String_Node_Str",brothers.get(x).minutes);
        if (brothers.get(x).driver)         jsonBro.put("String_Node_Str",1);
 else         jsonBro.put("String_Node_Str",0);
        jsonBro.put("String_Node_Str",brothers.get(x).minutes);
        if (brothers.get(x).driver)         jsonBro.put("String_Node_Str",1);
 else         jsonBro.put("String_Node_Str",0);
        json.put(x + "String_Node_Str",jsonBro);
      }
      String[] params=new String[9];
      String month, day;
      if (datePicker.getMonth() < 9)       month="String_Node_Str" + (datePicker.getMonth() + 1);
 else       month="String_Node_Str" + (datePicker.getMonth() + 1);
      if (datePicker.getDayOfMonth() < 10)       day="String_Node_Str" + datePicker.getDayOfMonth();
 else       day="String_Node_Str" + datePicker.getDayOfMonth();
      params[0]=datePicker.getYear() + "String_Node_Str" + month+ "String_Node_Str"+ day;
      params[1]=txtProjName.getText().toString();
      params[2]=txtProjLoc.getText().toString();
      if (radIn.isChecked())       params[3]="String_Node_Str";
 else       params[3]="String_Node_Str";
      if (radOn.isChecked())       params[4]="String_Node_Str";
 else       params[4]="String_Node_Str";
      if (radService1.isChecked())       params[5]="String_Node_Str";
 else       if (radService2.isChecked())       params[5]="String_Node_Str";
 else       if (radService3.isChecked())       params[5]="String_Node_Str";
 else       params[5]="String_Node_Str";
      if (txtTravelTime.getText().toString().compareTo("String_Node_Str") == 0)       params[6]="String_Node_Str";
 else       params[6]="String_Node_Str" + Integer.parseInt(txtTravelTime.getText().toString());
      params[7]=txtComments.getText().toString() + "String_Node_Str";
      params[8]="String_Node_Str" + brothers.size();
      API api=new API(this);
      if (!api.callMethod(Methods.serviceReport,this,json,params)) {
        Toast msg=Toast.makeText(getApplicationContext(),"String_Node_Str",Toast.LENGTH_LONG);
        msg.show();
      }
    }
 catch (    JSONException e) {
      e.printStackTrace();
    }
  }
 else {
    Button remove=(Button)v;
    if (remove.getText().toString().compareTo("String_Node_Str") != 0)     return;
    LinearLayout row=(LinearLayout)remove.getParent();
    int count=layoutBrothers.getChildCount();
    int match=-1;
    for (int x=1; x <= count; x++) {
      if (layoutBrothers.getChildAt(x) == row) {
        match=x;
        break;
      }
    }
    if (match == -1)     return;
 else {
      brothers.remove(match - 1);
      loadBrothers();
    }
  }
}