Program: 168212
Project: 168212
Buggy source:
private void addButtonsToToolBar(){
  IToolBarManager mgr=form.getToolBarManager();
  mgr.add(new Action(){
    @Override public ImageDescriptor getImageDescriptor(){
      return (NaiveBayesClassifierViewImageRegistry.getImageIconFactory().getImageDescriptor(IMAGE_LRUN_OBJ));
    }
    @Override public String getToolTipText(){
      return "String_Node_Str";
    }
    public void run(){
      ArrayList<String> trainingDataPaths=new ArrayList<String>();
      TreeItem trainingDataset=trainingClassPathTree.getItem(0);
      for (      TreeItem ti : trainingDataset.getItems()) {
        trainingDataPaths.add(ti.getData().toString());
      }
      ArrayList<String> testingDataPaths=new ArrayList<String>();
      TreeItem testingDataset=trainingClassPathTree.getItem(0);
      for (      TreeItem ti : testingDataset.getItems()) {
        testingDataPaths.add(ti.getData().toString());
      }
      for (      String s : trainingDataPaths) {
        System.out.println("String_Node_Str" + s);
      }
      String classificationInputDir=classifyInputText.getText();
      String classificationOutputDir=classifyOutputText.getText();
      Job job=new Job("String_Node_Str"){
        @Override protected IStatus run(        IProgressMonitor monitor){
          monitor.beginTask("String_Node_Str",100);
          NaiveBayesClassifier nbc=new NaiveBayesClassifier();
          try {
            nbc.classify(trainingDataPaths,classificationInputDir,classificationOutputDir,false,false);
          }
 catch (          FileNotFoundException e1) {
            e1.printStackTrace();
          }
catch (          IOException e1) {
            e1.printStackTrace();
          }
catch (          EvalError e1) {
            e1.printStackTrace();
          }
          int i=0;
          while (i < 1000000000) {
            try {
              Thread.sleep(1000);
            }
 catch (            InterruptedException e) {
              e.printStackTrace();
            }
            if (monitor.isCanceled()) {
              throw new OperationCanceledException();
            }
            i++;
            monitor.worked(1);
          }
          monitor.done();
          return Status.OK_STATUS;
        }
      }
;
      job.setUser(true);
      job.schedule();
    }
  }
);
  mgr.add(new Action(){
    @Override public ImageDescriptor getImageDescriptor(){
      return (NaiveBayesClassifierViewImageRegistry.getImageIconFactory().getImageDescriptor(IMAGE_HELP_CO));
    }
    @Override public String getToolTipText(){
      return "String_Node_Str";
    }
    public void run(){
    }
  }
);
  form.getToolBarManager().update(true);
}

Fixed version (ground truth):
private void addButtonsToToolBar(){
  IToolBarManager mgr=form.getToolBarManager();
  mgr.add(new Action(){
    @Override public ImageDescriptor getImageDescriptor(){
      return (NaiveBayesClassifierViewImageRegistry.getImageIconFactory().getImageDescriptor(IMAGE_LRUN_OBJ));
    }
    @Override public String getToolTipText(){
      return "String_Node_Str";
    }
    public void run(){
      ArrayList<String> trainingDataPaths=new ArrayList<String>();
      TreeItem trainingDataset=trainingClassPathTree.getItem(0);
      for (      TreeItem ti : trainingDataset.getItems()) {
        trainingDataPaths.add(ti.getData().toString());
      }
      String classificationInputDir=classifyInputText.getText();
      String classificationOutputDir=classifyOutputText.getText();
      Job job=new Job("String_Node_Str"){
        @Override protected IStatus run(        IProgressMonitor monitor){
          if (monitor.isCanceled()) {
            return Status.CANCEL_STATUS;
          }
          NaiveBayesClassifier nbc=new NaiveBayesClassifier();
          try {
            nbc.classify(trainingDataPaths,classificationInputDir,classificationOutputDir,false,false);
          }
 catch (          FileNotFoundException e1) {
            e1.printStackTrace();
          }
catch (          IOException e1) {
            e1.printStackTrace();
          }
catch (          EvalError e1) {
            e1.printStackTrace();
          }
          System.out.println("String_Node_Str");
          monitor.done();
          return Status.OK_STATUS;
        }
      }
;
      job.setUser(true);
      job.schedule();
    }
  }
);
  mgr.add(new Action(){
    @Override public ImageDescriptor getImageDescriptor(){
      return (NaiveBayesClassifierViewImageRegistry.getImageIconFactory().getImageDescriptor(IMAGE_HELP_CO));
    }
    @Override public String getToolTipText(){
      return "String_Node_Str";
    }
    public void run(){
    }
  }
);
  form.getToolBarManager().update(true);
}