Program: 75226
Project: 75226
Buggy source:
public Object execute(ExecutionEvent event) throws ExecutionException {
  super.execute(event);
  boolean retBoolean=true;
  if (Policy.TRACING_ACTIONS) {
    System.out.println("String_Node_Str");
  }
  CommandStack stack=getActiveCommandStack();
  stack.startTrans(STACK_MSG_ADD_STYLE);
  IEvaluationContext context=(IEvaluationContext)event.getApplicationContext();
  Object obj=context.getVariable(ICommandParameterNameContants.NEW_STYLE_THEME_HANDLE_NAME);
  if (obj instanceof ThemeHandle) {
    themeHandle=(ThemeHandle)obj;
  }
 else {
    themeHandle=null;
  }
  ModuleHandle reportDesignHandle=SessionHandleAdapter.getInstance().getReportDesignHandle();
  StyleHandle styleHandle=themeHandle != null ? DesignElementFactory.getInstance(reportDesignHandle).newStyle(themeHandle,null) : DesignElementFactory.getInstance(reportDesignHandle).newStyle(null);
  try {
    StyleBuilder dialog=new StyleBuilder(PlatformUI.getWorkbench().getDisplay().getActiveShell(),styleHandle,StyleBuilder.DLG_TITLE_NEW);
    if (dialog.open() == Window.OK) {
      if (themeHandle != null) {
        themeHandle.getStyles().add(styleHandle);
      }
 else {
        reportDesignHandle.getStyles().add(styleHandle);
        if (!styleHandle.isPredefined()) {
          applyStyle((SharedStyleHandle)styleHandle);
        }
      }
      stack.commit();
    }
 else {
      stack.rollbackAll();
      retBoolean=false;
    }
  }
 catch (  Exception e) {
    stack.rollbackAll();
    ExceptionHandler.handle(e);
    retBoolean=false;
  }
  return new Boolean(retBoolean);
}

Fixed version (ground truth):
public Object execute(ExecutionEvent event) throws ExecutionException {
  super.execute(event);
  boolean retBoolean=true;
  if (Policy.TRACING_ACTIONS) {
    System.out.println("String_Node_Str");
  }
  CommandStack stack=getActiveCommandStack();
  stack.startTrans(STACK_MSG_ADD_STYLE);
  IEvaluationContext context=(IEvaluationContext)event.getApplicationContext();
  Object obj=context.getVariable(ICommandParameterNameContants.NEW_STYLE_THEME_HANDLE_NAME);
  if (obj instanceof ThemeHandle) {
    themeHandle=(ThemeHandle)obj;
  }
 else {
    themeHandle=null;
  }
  ModuleHandle reportDesignHandle=SessionHandleAdapter.getInstance().getReportDesignHandle();
  StyleHandle styleHandle=themeHandle != null ? DesignElementFactory.getInstance(reportDesignHandle).newStyle(themeHandle,null) : DesignElementFactory.getInstance(reportDesignHandle).newStyle(null);
  try {
    StyleBuilder dialog=new StyleBuilder(PlatformUI.getWorkbench().getDisplay().getActiveShell(),styleHandle,themeHandle,StyleBuilder.DLG_TITLE_NEW);
    if (dialog.open() == Window.OK) {
      if (themeHandle != null) {
        themeHandle.getStyles().add(styleHandle);
      }
 else {
        reportDesignHandle.getStyles().add(styleHandle);
        if (!styleHandle.isPredefined()) {
          applyStyle((SharedStyleHandle)styleHandle);
        }
      }
      stack.commit();
    }
 else {
      stack.rollbackAll();
      retBoolean=false;
    }
  }
 catch (  Exception e) {
    stack.rollbackAll();
    ExceptionHandler.handle(e);
    retBoolean=false;
  }
  return new Boolean(retBoolean);
}