Buggy code:
public class CodeFormatterApplication implements IPlatformRunnable { private static final class Messages extends NLS { private static final String BUNDLE_NAME = "org.eclipse.jdt.core.formatter.messages" ; public static String CommandLineConfigFile ; public static String CommandLineDone ; public static String CommandLineErrorConfig ; public static String CommandLineErrorFile ; public static String CommandLineErrorFileDir ; public static String CommandLineErrorQuietVerbose ; public static String CommandLineErrorNoConfigFile ; public static String CommandLineFormatting ; public static String CommandLineStart ; public static String CommandLineUsage ; public static String ConfigFileReadingError ; public static String FormatProblem ; public static String CaughtException ; public static String ExceptionSkip ; public static String bind ( String message ) { } public static String bind ( String message , Object binding ) { } public static String bind ( String message , Object binding1 , Object binding2 ) { } public static String bind ( String message , Object [ ] bindings ) { } } private final String ARG_CONFIG = "-config" ; private final String ARG_HELP = "-help" ; private final String ARG_QUIET = "-quiet" ; private final String ARG_VERBOSE = "-verbose" ; private String configName ; private Properties options = null ; private final String PDE_LAUNCH = "-pdelaunch" ; private boolean quiet = false ; private boolean verbose = false ; private void displayHelp ( ) { } private void displayHelp ( String message ) { } private void formatDirTree ( File dir , CodeFormatter codeFormatter ) { } private void formatFile ( File file , CodeFormatter codeFormatter ) { } private File [ ] processCommandLine ( String [ ] argsArray ) { ArrayList args = new ArrayList ( ) ; for ( int i = 0 ; i < ( argsArray . length ) ; i ++ ) { args . add ( argsArray [ i ] ) ; } int index = 0 ; final int argCount = argsArray . length ; final int DEFAULT_MODE = 0 ; final int CONFIG_MODE = 1 ; int mode = DEFAULT_MODE ; final int INITIAL_SIZE = 1 ; int fileCounter = 0 ; File [ ] filesToFormat = new File [ INITIAL_SIZE ] ; loop : while ( index < argCount ) { String currentArg = argsArray [ ( index ++ ) ] ; switch ( mode ) { case DEFAULT_MODE : if ( PDE_LAUNCH . equals ( currentArg ) ) { continue loop ; } if ( ARG_HELP . equals ( currentArg ) ) { displayHelp ( ) ; return null ; } if ( ARG_VERBOSE . equals ( currentArg ) ) { this . verbose = true ; continue loop ; } if ( ARG_QUIET . equals ( currentArg ) ) { this . quiet = true ; continue loop ; } if ( ARG_CONFIG . equals ( currentArg ) ) { mode = CONFIG_MODE ; continue loop ; } File file = new File ( currentArg ) ; if ( file . exists ( ) ) { if ( ( filesToFormat . length ) == fileCounter ) { System . arraycopy ( filesToFormat , 0 , ( filesToFormat = new File [ fileCounter * 2 ] ) , 0 , fileCounter ) ; } filesToFormat [ ( fileCounter ++ ) ] = file ; } else { displayHelp ( CodeFormatterApplication . Messages . bind ( CodeFormatterApplication . Messages . CommandLineErrorFile , currentArg ) ) ; return null ; } break ; case CONFIG_MODE : this . configName = currentArg ; this . options = readConfig ( currentArg ) ; if ( ( this . options ) == null ) { displayHelp ( CodeFormatterApplication . Messages . bind ( CodeFormatterApplication . Messages . CommandLineErrorConfig , currentArg ) ) ; return null ; } mode = DEFAULT_MODE ; continue loop ; } } <START_BUG> if ( mode == CONFIG_MODE ) { <END_BUG> displayHelp ( CodeFormatterApplication . Messages . bind ( CodeFormatterApplication . Messages . CommandLineErrorNoConfigFile ) ) ; return null ; } if ( ( this . quiet ) && ( this . verbose ) ) { displayHelp ( CodeFormatterApplication . Messages . bind ( CodeFormatterApplication . Messages . CommandLineErrorQuietVerbose , new String [ ] { ARG_QUIET , ARG_VERBOSE } ) ) ; return null ; } if ( fileCounter == 0 ) { displayHelp ( CodeFormatterApplication . Messages . bind ( CodeFormatterApplication . Messages . CommandLineErrorFileDir ) ) ; return null ; } if ( ( filesToFormat . length ) != fileCounter ) { System . arraycopy ( filesToFormat , 0 , ( filesToFormat = new File [ fileCounter ] ) , 0 , fileCounter ) ; } return filesToFormat ; } private Properties readConfig ( String filename ) { } public Object run ( Object args ) throws Exception { } }

Fix:
if ( ( mode == CONFIG_MODE ) || ( ( this . options ) == null ) ) {