Buggy code:
public class WorkflowDesignerSessionController extends AbstractComponentSessionController { public static final String TYPE_USER = "user" ; public static final String FORMS = "forms" ; public static final String DATA_FOLDER = "dataFolder" ; public static final String USER_INFOS = "userInfos" ; public static final String ACTIONS = "actions" ; public static final String INPUTS = "inputs" ; public static final String STATES = "states" ; public static final String PARAMETERS = "parameters" ; public static final String PARTICIPANTS = "participants" ; public static final String PRESENTATION = "presentation" ; public static final String ROLES = "roles" ; public static final String RELATED_USER = "relatedUser" ; public static final String WORKING_USERS = "workingUsers" ; public static final String INTERESTED_USERS = "interestedUsers" ; public static final String NOTIFIED_USERS = "notifiedUsers" ; public static final String ALLOWED_USERS = "allowedUsers" ; public static final String CONSEQUENCES = "consequences" ; public static final String FORM_TYPE_PRESENTATION = "presentationForm" ; public static final String FORM_TYPE_PRINT = "printForm" ; public static final String FORM_TYPE_ACTION = "action" ; public static final String NEW_ELEMENT_NAME = "New" ; public static final String TITLES = "titles" ; public static final String ACTIVITIES = "activities" ; public static final String DESCRIPTIONS = "descriptions" ; public static final String LABELS = "labels" ; private static final String CONTEXT_DELIMS = "//[]" ; private ProcessModel processModel ; private String processModelFileName ; private String referencedInComponent ; public WorkflowDesignerSessionController ( MainSessionController mainSessionCtrl , ComponentContext componentContext ) { } public List < String > listProcessModels ( ) throws WorkflowDesignerException { } public ProcessModel createProcessModel ( ) throws WorkflowDesignerException { } public ProcessModel loadProcessModel ( String strProcessFileName ) throws WorkflowDesignerException { } public void saveProcessModel ( String strProcessModelFileName ) throws WorkflowDesignerException { } public void removeProcessModel ( String strProcessModelFileName ) throws WorkflowDesignerException { } public ProcessModel getProcessModel ( ) { } public Boolean isNewProcessModel ( ) { } public String getProcessFileName ( ) { } public String getComponentDescriptorName ( ) { } public void updateProcessModelHeader ( ProcessModel processModel ) { } public Columns addColumns ( ) { } public void updateColumns ( Columns source , String strRoleOriginal ) throws WorkflowDesignerException { Columns check = processModel . getPresentation ( ) . getColumnsByRole ( source . getRoleName ( ) ) ; if ( WorkflowDesignerSessionController . NEW_ELEMENT_NAME . equals ( strRoleOriginal ) ) { <START_BUG> if ( check != null ) { <END_BUG> throw new WorkflowDesignerException ( "WorkflowDesignerSessionController.updateColumns" , SilverpeasException . ERROR , "workflowDesigner.EX_COLUMNS_ALREADY_EXISTS" ) ; } } else { if ( ( check != null ) && ( ! ( strRoleOriginal . equals ( source . getRoleName ( ) ) ) ) ) { throw new WorkflowDesignerException ( "WorkflowDesignerSessionController.updateColumns" , SilverpeasException . ERROR , "workflowDesigner.EX_COLUMNS_ALREADY_EXISTS" ) ; } try { processModel . getPresentation ( ) . deleteColumns ( strRoleOriginal ) ; } catch ( WorkflowException e ) { throw new WorkflowDesignerException ( "WorkflowDesignerSessionController.updateColumns" , SilverpeasException . ERROR , "workflowDesigner.EX_UPDATING_COLUMNS_FAILED" , e ) ; } } processModel . getPresentation ( ) . addColumns ( source ) ; } public void deleteColumns ( String strRoleName ) throws WorkflowDesignerException { } public Role createRole ( ) { } public void updateRole ( Role source , String strNameOriginal ) throws WorkflowDesignerException { } public void removeRole ( String strRoleName ) throws WorkflowDesignerException { } public Participant createParticipant ( ) { } public void updateParticipant ( Participant source , String strNameOriginal ) throws WorkflowDesignerException { } public void removeParticipant ( String strParticipantName ) throws WorkflowDesignerException { } public State createState ( ) { } public void updateState ( State source , String strNameOriginal ) throws WorkflowDesignerException { } public void removeState ( String strStateName ) throws WorkflowDesignerException { } public void updateQualifiedUsers ( QualifiedUsers source , String strContext ) throws WorkflowException , WorkflowDesignerException { } public RelatedUser findRelatedUser ( String strContext , String strParticipant , String strFolderItem , String strRelation , String strRole ) throws WorkflowException { } public void updateRelatedUser ( RelatedUser source , String strContext , String strParticipantOriginal , String strFolderItemOriginal , String strRelationOriginal , String strRoleOriginal ) throws WorkflowException , WorkflowDesignerException { } public void removeRelatedUser ( RelatedUser reference , String strContext ) throws WorkflowException { } public Action createAction ( ) { } public void updateAction ( Action source , String strNameOriginal ) throws WorkflowException , WorkflowDesignerException { } public void removeAction ( String strActionName ) throws WorkflowException , WorkflowDesignerException { } public void updateConsequence ( Consequence source , String strContext ) throws WorkflowException , WorkflowDesignerException { } public void moveConsequence ( String strContext , int iConsequence , int nDirection ) throws WorkflowDesignerException { } public void removeConsequence ( String strContext ) throws WorkflowDesignerException { } public Form createForm ( ) { } public Form findForm ( String strContext ) { } public void updateForm ( Form source , String strContext , String strNameOriginal , String strRoleOriginal ) throws WorkflowDesignerException { } public void removeForm ( String strContext ) throws WorkflowException , WorkflowDesignerException { } public Input findInput ( String strContext ) { } public void updateInput ( Input source , String strContext ) throws WorkflowDesignerException { } public void removeInput ( String strContext ) throws WorkflowException , WorkflowDesignerException { } public ContextualDesignation createDesignation ( ) { } public void updateContextualDesignations ( String strContext , ContextualDesignation source , String strLangOriginal , String strRoleOriginal ) throws WorkflowDesignerException { } public ContextualDesignation findContextualDesignation ( String strContext , String strRole , String strLanguage ) throws WorkflowDesignerException { } public void removeContextualDesignation ( String strContext , ContextualDesignation contextualDesignation ) throws WorkflowDesignerException { } private ContextualDesignations findContextualDesignations ( String strContext ) throws WorkflowDesignerException { } private Map < ContextualDesignations , String > collectContextualDesignations ( ) { } public Item createItem ( String strContext ) { } public Item findItem ( String strContext ) { } public void updateItem ( Item source , String strContext , String strNameOriginal ) throws WorkflowDesignerException { } public void removeItem ( String strContext ) throws WorkflowException , WorkflowDesignerException { } public void updateParameter ( Parameter source , String strContext , String strNameOriginal ) throws WorkflowDesignerException { }

Fix:
if ( ( check != null ) && ( check . getRoleName ( ) . equals ( strRoleOriginal ) ) ) {