Program: 137626
Project: 137626
Buggy source:
/** 
 * add contextual menu for job generation.
 * @param menu
 * @param analysis
 * @param currentIndicator
 */
public static void addJobGenerationMenu(final Menu menu,final Analysis analysis,final Indicator currentIndicator){
  final Connection tdDataProvider=(Connection)analysis.getContext().getConnection();
  final boolean isMDMAnalysis=ConnectionUtils.isMdmConnection(tdDataProvider);
  final boolean isDelimitedFileAnalysis=ConnectionUtils.isDelimitedFileConnection(tdDataProvider);
  final boolean isHiveConnection=ConnectionHelper.isHive(tdDataProvider);
  if (PluginChecker.isTDCPLoaded() && !(isMDMAnalysis || isDelimitedFileAnalysis || isHiveConnection)) {
    final IDatabaseJobService service=(IDatabaseJobService)GlobalServiceRegister.getDefault().getService(IJobService.class);
    if (service != null) {
      service.setIndicator(currentIndicator);
      service.setAnalysis(analysis);
      MenuItem item=null;
      if (ChartTableFactory.isDUDIndicator(currentIndicator) && AnalysisType.COLUMN_SET != analysis.getParameters().getAnalysisType()) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
 else       if (ChartTableFactory.isPatternMatchingIndicator(currentIndicator)) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
 else       if (ChartTableFactory.isAllMatchIndicator(currentIndicator)) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
 else       if (ChartTableFactory.isPhonseNumberIndicator(currentIndicator)) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
 else       if (ChartTableFactory.isDqRule(currentIndicator)) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
      if (item != null) {
        item.setImage(ImageLib.getImage(ImageLib.ICON_PROCESS));
        item.addSelectionListener(new SelectionAdapter(){
          @Override public void widgetSelected(          SelectionEvent e){
            service.executeJob();
          }
        }
);
      }
    }
  }
}

Fixed version (ground truth):
/** 
 * add contextual menu for job generation.
 * @param menu
 * @param analysis
 * @param currentIndicator
 */
public static void addJobGenerationMenu(final Menu menu,final Analysis analysis,final Indicator currentIndicator){
  final Connection tdDataProvider=(Connection)analysis.getContext().getConnection();
  final boolean isMDMAnalysis=ConnectionUtils.isMdmConnection(tdDataProvider);
  final boolean isDelimitedFileAnalysis=ConnectionUtils.isDelimitedFileConnection(tdDataProvider);
  final boolean isHiveConnection=ConnectionHelper.isHive(tdDataProvider);
  final boolean isVertica=ConnectionHelper.isVertica(tdDataProvider);
  if (PluginChecker.isTDCPLoaded() && !(isMDMAnalysis || isDelimitedFileAnalysis || isHiveConnection)) {
    final IDatabaseJobService service=(IDatabaseJobService)GlobalServiceRegister.getDefault().getService(IJobService.class);
    if (service != null) {
      service.setIndicator(currentIndicator);
      service.setAnalysis(analysis);
      MenuItem item=null;
      if (ChartTableFactory.isDUDIndicator(currentIndicator) && AnalysisType.COLUMN_SET != analysis.getParameters().getAnalysisType()) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
 else       if (ChartTableFactory.isPatternMatchingIndicator(currentIndicator) && !isVertica) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
 else       if (ChartTableFactory.isAllMatchIndicator(currentIndicator)) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
 else       if (ChartTableFactory.isPhonseNumberIndicator(currentIndicator)) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
 else       if (ChartTableFactory.isDqRule(currentIndicator)) {
        item=new MenuItem(menu,SWT.PUSH);
        item.setText(DefaultMessagesImpl.getString("String_Node_Str"));
      }
      if (item != null) {
        item.setImage(ImageLib.getImage(ImageLib.ICON_PROCESS));
        item.addSelectionListener(new SelectionAdapter(){
          @Override public void widgetSelected(          SelectionEvent e){
            service.executeJob();
          }
        }
);
      }
    }
  }
}