Buggy code:
charFeatScreenScroll . setContent ( charFeatScreen ) ; charFeatScreen . setSize ( charFeatScreen . computeSize ( DEFAULT , DEFAULT ) ) ; charFeatScreen . setLayout ( featLayout ) ; List featsList = new List ( featListScreen , SWT . NONE ) ; for ( int i = 0 ; i < ( feats . size ( ) ) ; i ++ ) { featsList . add ( feats . get ( i ) . getName ( ) ) ; } featsList . pack ( ) ; featScreenScroll . setMinHeight ( featsList . getBounds ( ) . height ) ; charFeatsList = new List ( charFeatScreen , SWT . NONE ) ; for ( int i = 0 ; i < ( charFeats . size ( ) ) ; i ++ ) charFeatsList . add ( charFeats . get ( i ) . getName ( ) ) ; charFeatsList . pack ( ) ; Label errorMsg = new Label ( wiz6 , SWT . NONE ) ; errorMsg . setLocation ( ( ( ( WIDTH ) // 2 ) - 150 ) , ( ( HEIGHT ) - 75 ) ) ; errorMsg . setForeground ( new org . eclipse . swt . graphics . Color ( dev , 255 , 0 , 0 ) ) ; errorMsg . setText ( "You<seq2seq4repair_space>cannot<seq2seq4repair_space>remove<seq2seq4repair_space>a<seq2seq4repair_space>class<seq2seq4repair_space>bonus<seq2seq4repair_space>feat!" ) ; errorMsg . setVisible ( false ) ; errorMsg . pack ( ) ; Button addButton = new Button ( wiz6 , SWT . PUSH ) ; addButton . setText ( "Add<seq2seq4repair_space>>" ) ; addButton . setLocation ( ( ( ( WIDTH ) // 2 ) - 25 ) , ( ( ( HEIGHT ) // 2 ) - 50 ) ) ; addButton . pack ( ) ; addButton . addListener ( Selection , new Listener ( ) { public void handleEvent ( Event e ) { errorMsg . setVisible ( false ) ; boolean error = false ; if ( ( numFeats ) == 0 ) error = true ; int index = featsList . getSelectionIndex ( ) ; if ( index == ( - 1 ) ) error = true ; else { for ( int i = 0 ; i < ( charFeats . size ( ) ) ; i ++ ) { if ( charFeats . get ( i ) . getName ( ) . equals ( featsList . getItem ( index ) ) ) error = true ; } } if ( error ) return ; charFeatsList . add ( featsList . getItem ( index ) ) ; charFeats . add ( feats . get ( index ) ) ; ( numFeats ) -- ; numFeatsLabel . setText ( Integer . toString ( numFeats ) ) ; numFeatsLabel . setBackground ( null ) ; numFeatsLabel . pack ( ) ; charFeatsList . pack ( ) ; charFeatScreenScroll . setMinHeight ( charFeatsList . getBounds ( ) . height ) ; charFeatScreen . layout ( ) ; charFeatScreenScroll . layout ( ) ; } } ) ; Button removeButton = new Button ( wiz6 , SWT . PUSH ) ; removeButton . setText ( "<<seq2seq4repair_space>Remove" ) ; removeButton . setLocation ( ( ( ( WIDTH ) // 2 ) - 38 ) , ( ( HEIGHT ) // 2 ) ) ; removeButton . pack ( ) ; removeButton . addListener ( Selection , new Listener ( ) { public void handleEvent ( Event e ) { errorMsg . setVisible ( false ) ; if ( charFeats . isEmpty ( ) ) return ; int index = charFeatsList . getSelectionIndex ( ) ; if ( index == ( - 1 ) ) return ; if ( ( ( ( ( charClass . equalsIgnoreCase ( "Fighter" ) ) | ( charClass . equalsIgnoreCase ( "Monk" ) ) ) | ( charClass . equalsIgnoreCase ( "Ranger" ) ) ) | ( charClass . equalsIgnoreCase ( "Wizard" ) ) ) && ( ( charFeatsList . getSelectionIndex ( ) ) == 0 ) ) { errorMsg . setVisible ( true ) ; return ; } charFeatsList . remove ( index ) ; charFeats . remove ( index ) ; ( numFeats ) ++ ; numFeatsLabel . setText ( Integer . toString ( numFeats ) ) ; numFeatsLabel . setBackground ( null ) ; numFeatsLabel . pack ( ) ; charFeatsList . pack ( ) ; charFeatScreenScroll . setMinHeight ( charFeatsList . getBounds ( ) . height ) ; charFeatScreen . layout ( ) ; charFeatScreenScroll . layout ( ) ; } } ) ; featListScreen . pack ( ) ; charFeatScreen . pack ( ) ; Button wiz6NextButton = CharacterWizard . createNextButton ( wiz6 ) ; wiz6NextButton . addListener ( Selection , new Listener ( ) { public void handleEvent ( Event event ) { if ( ( numFeats ) > 0 ) { numFeatsLabel . setBackground ( new org . eclipse . swt . graphics . Color ( dev , 255 , 100 , 100 ) ) ; return ; } for ( int i = 0 ; i < ( charFeats . size ( ) ) ; i ++ ) character . addFeat ( charFeats . get ( i ) ) ; if ( ( CharacterWizard . wizPageNum ) < ( ( wizPagesSize ) - 1 ) ) ( CharacterWizard . wizPageNum ) ++ ; <START_BUG> if ( ! ( CharacterWizard . wizPageCreated [ 5 ] ) ) <END_BUG> createNextPage ( ) ; layout . topControl = nextPage ; panel . layout ( ) ; } } ) ; Button wiz6CancelButton = CharacterWizard . createCancelButton ( wiz6 , home , homePanel , homeLayout ) ; wiz6CancelButton . addListener ( Selection , new Listener ( ) { public void handleEvent ( Event event ) { if ( CharacterWizard . cancel ) CharacterWizard . reset ( ) ; } } ) ; } void createBonusPopUp ( ) { } private void createNextPage ( ) { } public Composite getWiz6 ( ) { } }

Fix:
if ( ! ( CharacterWizard . wizPageCreated [ 6 ] ) )