Program: 92021
Project: 92021
Buggy source:
@Override protected void okPressed(){
  fSessionName=fSessionNameText.getText();
  fSessionPath=fSessionPathText.getText();
  if (!"String_Node_Str".equals(fSessionPath)) {
    if (!fIsStreamedTrace) {
      TargetNodeComponent node=(TargetNodeComponent)fParent.getParent();
      IRemoteSystemProxy proxy=node.getRemoteSystemProxy();
      IFileServiceSubSystem fsss=proxy.getFileServiceSubSystem();
      if (fsss != null) {
        try {
          IRemoteFile remoteFolder=fsss.getRemoteFileObject(fSessionPath,new NullProgressMonitor());
          if (remoteFolder.exists()) {
            MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,Messages.TraceControl_SessionPathAlreadyExistsError + "String_Node_Str" + fSessionPath+ "String_Node_Str");
            return;
          }
        }
 catch (        SystemMessageException e) {
          MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,Messages.TraceControl_FileSubSystemError + "String_Node_Str" + e);
          return;
        }
      }
    }
    fIsDefaultPath=false;
  }
  fNetworkUrl=null;
  fControlUrl=null;
  fDataUrl=null;
  if (fIsStreamedTrace) {
    fTracePath=fTracePathText.getText();
    if (fControlProtocolCombo.getSelectionIndex() < 0) {
      MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,"String_Node_Str");
      return;
    }
    if ("String_Node_Str".equals(fControlHostAddressText.getText())) {
      MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,"String_Node_Str");
      return;
    }
    if (!fLinkDataWithControlButton.getSelection()) {
      if (fDataProtocolCombo.getSelectionIndex() < 0) {
        MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,"String_Node_Str");
        return;
      }
      if ("String_Node_Str".equals(fDataHostAddressText.getText())) {
        MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,"String_Node_Str");
        return;
      }
      fControlUrl=getUrlString(fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()),fControlHostAddressText.getText(),fControlPortText.getText(),null,fTracePath);
      fDataUrl=getUrlString(fControlProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()),fDataHostAddressText.getText(),null,fDataPortText.getText(),fTracePath);
    }
 else {
      fNetworkUrl=getUrlString(fControlProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()),fControlHostAddressText.getText(),fControlPortText.getText(),fDataPortText.getText(),fTracePath);
    }
  }
  if (!"String_Node_Str".equals(fSessionName) && !fSessionName.matches("String_Node_Str")) {
    MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,Messages.TraceControl_InvalidSessionNameError + "String_Node_Str" + fSessionName+ "String_Node_Str");
    return;
  }
  if (fParent.containsChild(fSessionName)) {
    MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,Messages.TraceControl_SessionAlreadyExistsError + "String_Node_Str" + fSessionName+ "String_Node_Str");
    return;
  }
  super.okPressed();
}

Fixed version (ground truth):
@Override protected void okPressed(){
  fSessionName=fSessionNameText.getText();
  fSessionPath=fSessionPathText.getText();
  if (!"String_Node_Str".equals(fSessionPath)) {
    if (!fIsStreamedTrace) {
      TargetNodeComponent node=(TargetNodeComponent)fParent.getParent();
      IRemoteSystemProxy proxy=node.getRemoteSystemProxy();
      IFileServiceSubSystem fsss=proxy.getFileServiceSubSystem();
      if (fsss != null) {
        try {
          IRemoteFile remoteFolder=fsss.getRemoteFileObject(fSessionPath,new NullProgressMonitor());
          if (remoteFolder == null) {
            MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,Messages.TraceControl_InvalidSessionPathError + "String_Node_Str" + fSessionPath+ "String_Node_Str");
            return;
          }
          if (remoteFolder.exists()) {
            MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,Messages.TraceControl_SessionPathAlreadyExistsError + "String_Node_Str" + fSessionPath+ "String_Node_Str");
            return;
          }
        }
 catch (        SystemMessageException e) {
          MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,Messages.TraceControl_FileSubSystemError + "String_Node_Str" + e);
          return;
        }
      }
    }
    fIsDefaultPath=false;
  }
  fNetworkUrl=null;
  fControlUrl=null;
  fDataUrl=null;
  if (fIsStreamedTrace) {
    fTracePath=fTracePathText.getText();
    if (fControlProtocolCombo.getSelectionIndex() < 0) {
      MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,"String_Node_Str");
      return;
    }
    if ("String_Node_Str".equals(fControlHostAddressText.getText())) {
      MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,"String_Node_Str");
      return;
    }
    if (!fLinkDataWithControlButton.getSelection()) {
      if (fDataProtocolCombo.getSelectionIndex() < 0) {
        MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,"String_Node_Str");
        return;
      }
      if ("String_Node_Str".equals(fDataHostAddressText.getText())) {
        MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,"String_Node_Str");
        return;
      }
      fControlUrl=getUrlString(fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()),fControlHostAddressText.getText(),fControlPortText.getText(),null,fTracePath);
      fDataUrl=getUrlString(fControlProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()),fDataHostAddressText.getText(),null,fDataPortText.getText(),fTracePath);
    }
 else {
      fNetworkUrl=getUrlString(fControlProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()),fControlHostAddressText.getText(),fControlPortText.getText(),fDataPortText.getText(),fTracePath);
    }
  }
  if (!"String_Node_Str".equals(fSessionName) && !fSessionName.matches("String_Node_Str")) {
    MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,Messages.TraceControl_InvalidSessionNameError + "String_Node_Str" + fSessionName+ "String_Node_Str");
    return;
  }
  if (fParent.containsChild(fSessionName)) {
    MessageDialog.openError(getShell(),Messages.TraceControl_CreateSessionDialogTitle,Messages.TraceControl_SessionAlreadyExistsError + "String_Node_Str" + fSessionName+ "String_Node_Str");
    return;
  }
  super.okPressed();
}