Program: 147995
Project: 147995
Buggy source:
protected WSRoutingOrderV2[] getResults(){
  Cursor waitCursor=null;
  try {
    Display display=getEditor().getSite().getPage().getWorkbenchWindow().getWorkbench().getDisplay();
    waitCursor=new Cursor(display,SWT.CURSOR_WAIT);
    this.getSite().getShell().setCursor(waitCursor);
    XtentisPort port=Util.getPort(getXObject());
    long from=-1;
    long to=-1;
    SimpleDateFormat sdf=new SimpleDateFormat("String_Node_Str");
    Pattern pattern=Pattern.compile("String_Node_Str");
    if (!"String_Node_Str".equals(fromText.getText())) {
      String dateTimeText=fromText.getText().trim();
      Matcher matcher=pattern.matcher(dateTimeText);
      if (!matcher.matches()) {
        MessageDialog.openWarning(this.getSite().getShell(),"String_Node_Str","String_Node_Str");
        return new WSRoutingOrderV2[0];
      }
      try {
        Date d=sdf.parse(fromText.getText());
        from=d.getTime();
      }
 catch (      ParseException pe) {
      }
    }
    if (!"String_Node_Str".equals(toText.getText())) {
      String dateTimeText=toText.getText().trim();
      Matcher matcher=pattern.matcher(dateTimeText);
      if (!matcher.matches()) {
        MessageDialog.openWarning(this.getSite().getShell(),"String_Node_Str","String_Node_Str");
        return new WSRoutingOrderV2[0];
      }
      try {
        Date d=sdf.parse(toText.getText());
        to=d.getTime();
      }
 catch (      ParseException pe) {
      }
    }
    long timeCreatedMin=-1;
    long timeCreatedMax=-1;
    long timeScheduledMin=-1;
    long timeScheduledMax=-1;
    long timeLastRunStartedMin=-1;
    long timeLastRunStartedMax=-1;
    long timeLastRunCompletedMin=-1;
    long timeLastRunCompletedMax=-1;
    WSRoutingOrderV2Status status=null;
    String statusText=statusCombo.getItem(statusCombo.getSelectionIndex());
    if ("String_Node_Str".equals(statusText)) {
      timeCreatedMin=from;
      timeCreatedMax=to;
      status=WSRoutingOrderV2Status.ACTIVE;
    }
 else     if ("String_Node_Str".equals(statusText)) {
      timeLastRunCompletedMin=from;
      timeLastRunCompletedMax=to;
      status=WSRoutingOrderV2Status.COMPLETED;
    }
 else     if ("String_Node_Str".equals(statusText)) {
      timeLastRunCompletedMin=from;
      timeLastRunCompletedMax=to;
      status=WSRoutingOrderV2Status.FAILED;
    }
 else {
      throw new XtentisException("String_Node_Str" + statusText + "String_Node_Str");
    }
    String serviceJNDI=serviceCombo.getItem(serviceCombo.getSelectionIndex());
    if ("String_Node_Str".equals(serviceJNDI))     serviceJNDI=null;
    WSRoutingOrderV2[] results=port.getRoutingOrderV2SByCriteria(new WSGetRoutingOrderV2SByCriteria(new WSRoutingOrderV2SearchCriteria(status,"String_Node_Str".equals(anyFieldText.getText()) || "String_Node_Str".equals(anyFieldText.getText()) ? null : anyFieldText.getText(),null,timeCreatedMin,timeCreatedMax,timeScheduledMin,timeScheduledMax,timeLastRunStartedMin,timeLastRunStartedMax,timeLastRunCompletedMin,timeLastRunCompletedMax,"String_Node_Str".equals(documentTypeText.getText()) || "String_Node_Str".equals(documentTypeText.getText()) ? null : documentTypeText.getText(),"String_Node_Str".equals(idText.getText()) || "String_Node_Str".equals(idText.getText()) ? null : idText.getText(),serviceJNDI,null,null))).getWsRoutingOrder();
    if (results == null) {
      MessageDialog.openInformation(this.getSite().getShell(),"String_Node_Str","String_Node_Str");
      return new WSRoutingOrderV2[0];
    }
    return results;
  }
 catch (  Exception e) {
    log.error(e.getMessage(),e);
    if ((e.getLocalizedMessage() != null) && e.getLocalizedMessage().contains("String_Node_Str"))     MessageDialog.openError(this.getSite().getShell(),"String_Node_Str","String_Node_Str");
 else     MessageDialog.openError(this.getSite().getShell(),"String_Node_Str",e.getLocalizedMessage());
    return null;
  }
 finally {
    try {
      this.getSite().getShell().setCursor(null);
      waitCursor.dispose();
    }
 catch (    Exception e) {
    }
  }
}

Fixed version (ground truth):
protected WSRoutingOrderV2[] getResults(){
  Cursor waitCursor=null;
  try {
    Display display=getEditor().getSite().getPage().getWorkbenchWindow().getWorkbench().getDisplay();
    waitCursor=new Cursor(display,SWT.CURSOR_WAIT);
    this.getSite().getShell().setCursor(waitCursor);
    XtentisPort port=getPort();
    long from=-1;
    long to=-1;
    SimpleDateFormat sdf=new SimpleDateFormat("String_Node_Str");
    Pattern pattern=Pattern.compile("String_Node_Str");
    if (!"String_Node_Str".equals(fromText.getText())) {
      String dateTimeText=fromText.getText().trim();
      Matcher matcher=pattern.matcher(dateTimeText);
      if (!matcher.matches()) {
        MessageDialog.openWarning(this.getSite().getShell(),"String_Node_Str","String_Node_Str");
        return new WSRoutingOrderV2[0];
      }
      try {
        Date d=sdf.parse(fromText.getText());
        from=d.getTime();
      }
 catch (      ParseException pe) {
      }
    }
    if (!"String_Node_Str".equals(toText.getText())) {
      String dateTimeText=toText.getText().trim();
      Matcher matcher=pattern.matcher(dateTimeText);
      if (!matcher.matches()) {
        MessageDialog.openWarning(this.getSite().getShell(),"String_Node_Str","String_Node_Str");
        return new WSRoutingOrderV2[0];
      }
      try {
        Date d=sdf.parse(toText.getText());
        to=d.getTime();
      }
 catch (      ParseException pe) {
      }
    }
    long timeCreatedMin=-1;
    long timeCreatedMax=-1;
    long timeScheduledMin=-1;
    long timeScheduledMax=-1;
    long timeLastRunStartedMin=-1;
    long timeLastRunStartedMax=-1;
    long timeLastRunCompletedMin=-1;
    long timeLastRunCompletedMax=-1;
    WSRoutingOrderV2Status status=null;
    String statusText=statusCombo.getItem(statusCombo.getSelectionIndex());
    if ("String_Node_Str".equals(statusText)) {
      timeCreatedMin=from;
      timeCreatedMax=to;
      status=WSRoutingOrderV2Status.ACTIVE;
    }
 else     if ("String_Node_Str".equals(statusText)) {
      timeLastRunCompletedMin=from;
      timeLastRunCompletedMax=to;
      status=WSRoutingOrderV2Status.COMPLETED;
    }
 else     if ("String_Node_Str".equals(statusText)) {
      timeLastRunCompletedMin=from;
      timeLastRunCompletedMax=to;
      status=WSRoutingOrderV2Status.FAILED;
    }
 else {
      throw new XtentisException("String_Node_Str" + statusText + "String_Node_Str");
    }
    String serviceJNDI=serviceCombo.getItem(serviceCombo.getSelectionIndex());
    if ("String_Node_Str".equals(serviceJNDI))     serviceJNDI=null;
    WSRoutingOrderV2[] results=port.getRoutingOrderV2SByCriteria(new WSGetRoutingOrderV2SByCriteria(new WSRoutingOrderV2SearchCriteria(status,"String_Node_Str".equals(anyFieldText.getText()) || "String_Node_Str".equals(anyFieldText.getText()) ? null : anyFieldText.getText(),null,timeCreatedMin,timeCreatedMax,timeScheduledMin,timeScheduledMax,timeLastRunStartedMin,timeLastRunStartedMax,timeLastRunCompletedMin,timeLastRunCompletedMax,"String_Node_Str".equals(documentTypeText.getText()) || "String_Node_Str".equals(documentTypeText.getText()) ? null : documentTypeText.getText(),"String_Node_Str".equals(idText.getText()) || "String_Node_Str".equals(idText.getText()) ? null : idText.getText(),serviceJNDI,null,null))).getWsRoutingOrder();
    if (results == null) {
      MessageDialog.openInformation(this.getSite().getShell(),"String_Node_Str","String_Node_Str");
      return new WSRoutingOrderV2[0];
    }
    return results;
  }
 catch (  Exception e) {
    log.error(e.getMessage(),e);
    if ((e.getLocalizedMessage() != null) && e.getLocalizedMessage().contains("String_Node_Str"))     MessageDialog.openError(this.getSite().getShell(),"String_Node_Str","String_Node_Str");
 else     MessageDialog.openError(this.getSite().getShell(),"String_Node_Str",e.getLocalizedMessage());
    return null;
  }
 finally {
    try {
      this.getSite().getShell().setCursor(null);
      waitCursor.dispose();
    }
 catch (    Exception e) {
    }
  }
}