Buggy code:
public class SplashScreen extends ApplicationWindow { private ProgressBar bar ; private Label label ; private Display display ; private enum ReturnType { NO_ERROR , MKDIR_READ_ERROR , WRITE_ERROR , READ_ERROR , OPENGL_ERROR ; } public SplashScreen ( ) { } public void run ( ) { final File configGzFile = new File ( "config.gz" ) ; if ( configGzFile . exists ( ) ) { WorkbenchManager . loadWorkbench ( ) ; <START_BUG> if ( WorkbenchManager . getUserSettingState ( ) . isResetOnStart ( ) ) { <END_BUG> configGzFile . delete ( ) ; } } if ( ! ( configGzFile . exists ( ) ) ) { WorkbenchManager . createDefaultWorkbench ( ) ; if ( ( new org . nschmidt . ldparteditor . dialogs . startup . StartupDialog ( Display . getDefault ( ) . getActiveShell ( ) ) . open ( ) ) == ( IDialogConstants . OK_ID ) ) { WorkbenchManager . saveWorkbench ( ) ; } else { configGzFile . delete ( ) ; ResourceManager . dispose ( ) ; Display . getCurrent ( ) . dispose ( ) ; return ; } } try { Locale . setDefault ( WorkbenchManager . getUserSettingState ( ) . getLocale ( ) ) ; } catch ( SecurityException se ) { } this . setShellStyle ( ON_TOP ) ; this . create ( ) ; final Shell sh = this . getShell ( ) ; sh . setText ( SPLASH_Title ) ; sh . setBounds ( 0 , 0 , 390 , 240 ) ; ShellHelper . centerShellOnPrimaryScreen ( sh ) ; this . open ( ) ; final boolean [ ] openGLerror = new boolean [ 1 ] ; try { Shell sh2 = new Shell ( ) ; Composite comp = new Composite ( sh2 , SWT . NONE ) ; GLData data = new GLData ( ) ; data . doubleBuffer = true ; data . depthSize = 24 ; data . alphaSize = 8 ; data . blueSize = 8 ; data . redSize = 8 ; data . greenSize = 8 ; data . stencilSize = 8 ; final GLCanvas canvas = new GLCanvas ( comp , SWT . NONE , data ) ; canvas . setCurrent ( ) ; GLContext . useContext ( canvas ) ; String glVersion = GL11 . glGetString ( GL_VERSION ) ; int major = Integer . parseInt ( glVersion . substring ( 0 , 1 ) ) ; openGLerror [ 0 ] = major < 2 ; } catch ( Exception e ) { openGLerror [ 0 ] = true ; } display = Display . getCurrent ( ) ; final SplashScreen . ReturnType [ ] threadReturn = new SplashScreen . ReturnType [ 1 ] ; new Thread ( ) { @ Override public void run ( ) { if ( openGLerror [ 0 ] ) { threadReturn [ 0 ] = SplashScreen . ReturnType . OPENGL_ERROR ; return ; } ProgressHelper . queueTask ( SPLASH_CheckPlugIn ) ; ProgressHelper . queueTask ( SPLASH_LoadWorkbench ) ; dequeueTask ( ) ; try { File plugInFolder = new File ( "plugin" ) ; if ( ! ( plugInFolder . exists ( ) ) ) { plugInFolder . mkdir ( ) ; } } catch ( SecurityException s ) { threadReturn [ 0 ] = SplashScreen . ReturnType . MKDIR_READ_ERROR ; return ; } dequeueTask ( ) ; try { if ( ! ( configGzFile . exists ( ) ) ) { threadReturn [ 0 ] = SplashScreen . ReturnType . WRITE_ERROR ; return ; } } catch ( SecurityException s ) { threadReturn [ 0 ] = SplashScreen . ReturnType . READ_ERROR ; return ; } UTF8BufferedReader reader ; String line = null ; try { ArrayList < ToolItemState > states = WorkbenchManager . getUserSettingState ( ) . getToolItemConfig3D ( ) ; if ( states == null ) { states = new ArrayList < ToolItemState > ( ) ; WorkbenchManager . getUserSettingState ( ) . setToolItemConfig3D ( states ) ; } reader = new UTF8BufferedReader ( "layout_3D_editor.cfg" ) ; states . clear ( ) ; while ( true ) { line = reader . readLine ( ) ; if ( line == null ) { break ; } final String [ ] data_segments = Pattern . compile ( ";" ) . split ( line . trim ( ) ) ; if ( ( data_segments . length ) > 3 ) { for ( int i = 0 ; i < 4 ; i ++ ) { data_segments [ i ] = data_segments [ i ] . trim ( ) ; } ToolItemDrawMode mode = ToolItemDrawMode . HORIZONTAL ; ToolItemDrawLocation location = ToolItemDrawLocation . NORTH ; if ( "EAST" . equals ( data_segments [ 1 ] ) ) { location = ToolItemDrawLocation . EAST ; } else if ( "WEST" . equals ( data_segments [ 1 ] ) ) { location = ToolItemDrawLocation . WEST ; } if ( "VERTICAL" . equals ( data_segments [ 2 ] ) ) { mode = ToolItemDrawMode . VERTICAL ; } else if ( "DROPDWNMNU" . equals ( data_segments [ 2 ] ) ) { mode = ToolItemDrawMode . DROP_DOWN ; } if ( "NO_LABEL" . equals ( data_segments [ 3 ] ) ) { data_segments [ 3 ] = "" ; } states . add ( new ToolItemState ( data_segments [ 0 ] , location , mode , data_segments [ 3 ] ) ) ; } } reader . close ( ) ; } catch ( FileNotFoundException consumed ) { } catch ( LDParsingException e1 ) { NLogger . error ( getClass ( ) , e1 ) ; } catch ( UnsupportedEncodingException e1 ) { NLogger . error ( getClass ( ) , e1 ) ; } display . syncExec ( new Runnable ( ) { @ Override public void run ( ) { ProgressHelper . finishQueue ( bar , label ) ; } } ) ; threadReturn [ 0 ] = SplashScreen . ReturnType . NO_ERROR ;

Fix:
if ( ( ( WorkbenchManager . getUserSettingState ( ) ) == null ) || ( WorkbenchManager . getUserSettingState ( ) . isResetOnStart ( ) ) ) {