Program: 153340
Project: 153340
Buggy source:
/** 
 * Called when the activity is first created. 
 */
@Override public void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  setContentView(R.layout.dashboard);
  this.baseDirectory=getFilesDir();
  this.flipper=(ViewFlipper)findViewById(R.id.subject_views);
  Button subjectCreateButton=(Button)findViewById(R.id.subject_create_button);
  subjectCreateButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_CREATE_VIEW);
    }
  }
);
  Button subjectListButton=(Button)findViewById(R.id.subject_list_button);
  subjectListButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_LIST_VIEW);
    }
  }
);
  Button subjectCreateSaveButton=(Button)findViewById(R.id.subject_create_save_button);
  subjectCreateSaveButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      EditText newSubjectField=(EditText)findViewById(R.id.subject_create_name);
      String currentSubjectName=newSubjectField.getText().toString();
      String subjectDirectory=baseDirectory.getAbsolutePath() + File.separator + currentSubjectName;
      currentSubjectDirectory=new File(subjectDirectory);
      if (currentSubjectDirectory.exists()) {
        Toast.makeText(getApplicationContext(),"String_Node_Str",Toast.LENGTH_SHORT).show();
        return;
      }
      currentSubjectDirectory.mkdirs();
      String message="String_Node_Str" + currentSubjectName + "String_Node_Str";
      Toast.makeText(getApplicationContext(),message,Toast.LENGTH_SHORT).show();
      flipper.setDisplayedChild(Interview.SUBJECT_DETAILS_VIEW);
    }
  }
);
  Button subjectCreateBackButton=(Button)findViewById(R.id.subject_create_back_button);
  subjectCreateBackButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_DASHBOARD_VIEW);
    }
  }
);
  ArrayAdapter<String> subjectListAdapter=new ArrayAdapter<String>(this,android.R.layout.simple_spinner_dropdown_item,this.baseDirectory.list());
  Spinner spinner=(Spinner)findViewById(R.id.subject_list_dropdown);
  spinner.setAdapter(subjectListAdapter);
  spinner.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener(){
    public void onItemSelected(    AdapterView<?> parent,    View view,    int position,    long id){
      String subjectName=parent.getItemAtPosition(position).toString();
      currentSubjectDirectory=new File(baseDirectory.getAbsolutePath() + File.separator + subjectName);
    }
    public void onNothingSelected(    AdapterView parent){
    }
  }
);
  Button subjectListViewButton=(Button)findViewById(R.id.subject_list_view_button);
  subjectListViewButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_DETAILS_VIEW);
    }
  }
);
  Button subjectListBackButton=(Button)findViewById(R.id.subject_list_back_button);
  subjectListBackButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_DASHBOARD_VIEW);
    }
  }
);
  Button subjectViewBackButton=(Button)findViewById(R.id.subject_dashboard_button);
  subjectViewBackButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_DASHBOARD_VIEW);
    }
  }
);
}

Fixed version (ground truth):
/** 
 * Called when the activity is first created. 
 */
@Override public void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  setContentView(R.layout.dashboard);
  this.baseDirectory=getFilesDir();
  this.flipper=(ViewFlipper)findViewById(R.id.subject_views);
  Button subjectCreateButton=(Button)findViewById(R.id.subject_create_button);
  subjectCreateButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_CREATE_VIEW);
    }
  }
);
  Button subjectListButton=(Button)findViewById(R.id.subject_list_button);
  subjectListButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_LIST_VIEW);
    }
  }
);
  Button subjectCreateSaveButton=(Button)findViewById(R.id.subject_create_save_button);
  subjectCreateSaveButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      EditText newSubjectField=(EditText)findViewById(R.id.subject_create_name);
      String currentSubjectName=newSubjectField.getText().toString();
      createSubject(currentSubjectName);
      Spinner spinner=(Spinner)findViewById(R.id.subject_list_dropdown);
      populateSpinner(spinner);
      flipper.setDisplayedChild(Interview.SUBJECT_DETAILS_VIEW);
    }
  }
);
  Button subjectCreateBackButton=(Button)findViewById(R.id.subject_create_back_button);
  subjectCreateBackButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_DASHBOARD_VIEW);
    }
  }
);
  Spinner spinner=(Spinner)findViewById(R.id.subject_list_dropdown);
  populateSpinner(spinner);
  spinner.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener(){
    public void onItemSelected(    AdapterView<?> parent,    View view,    int position,    long id){
      String subjectName=parent.getItemAtPosition(position).toString();
      currentSubjectDirectory=new File(baseDirectory.getAbsolutePath() + File.separator + subjectName);
    }
    public void onNothingSelected(    AdapterView parent){
    }
  }
);
  Button subjectListViewButton=(Button)findViewById(R.id.subject_list_view_button);
  subjectListViewButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_DETAILS_VIEW);
    }
  }
);
  Button subjectListBackButton=(Button)findViewById(R.id.subject_list_back_button);
  subjectListBackButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_DASHBOARD_VIEW);
    }
  }
);
  Button subjectViewBackButton=(Button)findViewById(R.id.subject_dashboard_button);
  subjectViewBackButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(    View view){
      flipper.setDisplayedChild(Interview.SUBJECT_DASHBOARD_VIEW);
    }
  }
);
}