Buggy code:
public final class DataCleanerHome { private static final Logger logger ; private static final FileObject _dataCleanerHome ; private static FileObject findDataCleanerHome ( ) throws FileSystemException { final FileSystemManager manager = VFSUtils . getFileSystemManager ( ) ; FileObject candidate = null ; final String env = System . getenv ( "DATACLEANER_HOME" ) ; if ( ! ( StringUtils . isNullOrEmpty ( env ) ) ) { candidate = manager . resolveFile ( env ) ; DataCleanerHome . logger . info ( "Resolved<seq2seq4repair_space>env.<seq2seq4repair_space>variable<seq2seq4repair_space>DATACLEANER_HOME<seq2seq4repair_space>({})<seq2seq4repair_space>to:<seq2seq4repair_space>{}" , env , candidate ) ; } else { final String sysProp = System . getProperty ( "DATACLEANER_HOME" ) ; if ( ! ( StringUtils . isNullOrEmpty ( sysProp ) ) ) { candidate = manager . resolveFile ( sysProp ) ; DataCleanerHome . logger . info ( "Resolved<seq2seq4repair_space>system<seq2seq4repair_space>property<seq2seq4repair_space>DATACLEANER_HOME<seq2seq4repair_space>({})<seq2seq4repair_space>to:<seq2seq4repair_space>{}" , sysProp , candidate ) ; } } if ( DataCleanerHome . isUsable ( candidate ) ) { return candidate ; } if ( ClassLoaderUtils . IS_WEB_START ) { final String path = DataCleanerHome . getUserHomeCandidatePath ( ) ; candidate = manager . resolveFile ( path ) ; DataCleanerHome . logger . info ( "Running<seq2seq4repair_space>in<seq2seq4repair_space>WebStart<seq2seq4repair_space>mode.<seq2seq4repair_space>Attempting<seq2seq4repair_space>to<seq2seq4repair_space>build<seq2seq4repair_space>DATACLEANER_HOME<seq2seq4repair_space>in<seq2seq4repair_space>user.home:<seq2seq4repair_space>{}<seq2seq4repair_space>-><seq2seq4repair_space>{}" , path , candidate ) ; } else { <START_BUG> if ( candidate == null ) { <END_BUG> candidate = manager . resolveFile ( "." ) ; } if ( DataCleanerHome . isWriteable ( candidate ) ) { DataCleanerHome . logger . info ( "Running<seq2seq4repair_space>in<seq2seq4repair_space>standard<seq2seq4repair_space>mode.<seq2seq4repair_space>Attempting<seq2seq4repair_space>to<seq2seq4repair_space>build<seq2seq4repair_space>DATACLEANER_HOME<seq2seq4repair_space>in<seq2seq4repair_space>'.'<seq2seq4repair_space>-><seq2seq4repair_space>{}" , candidate ) ; } else { final String path = DataCleanerHome . getUserHomeCandidatePath ( ) ; candidate = manager . resolveFile ( path ) ; DataCleanerHome . logger . info ( "Application<seq2seq4repair_space>directory<seq2seq4repair_space>is<seq2seq4repair_space>not<seq2seq4repair_space>writeable.<seq2seq4repair_space>Attempting<seq2seq4repair_space>to<seq2seq4repair_space>build<seq2seq4repair_space>DATACLEANER_HOME<seq2seq4repair_space>in<seq2seq4repair_space>user.home:<seq2seq4repair_space>{}<seq2seq4repair_space>-><seq2seq4repair_space>{}" , path , candidate ) ; } } if ( "true" . equalsIgnoreCase ( System . getProperty ( SANDBOX ) ) ) { DataCleanerHome . logger . info ( "Running<seq2seq4repair_space>in<seq2seq4repair_space>sandbox<seq2seq4repair_space>mode<seq2seq4repair_space>({}),<seq2seq4repair_space>setting<seq2seq4repair_space>{}<seq2seq4repair_space>as<seq2seq4repair_space>DATACLEANER_HOME" , SANDBOX , candidate ) ; if ( ! ( candidate . exists ( ) ) ) { candidate . createFolder ( ) ; } return candidate ; } if ( ! ( DataCleanerHome . isUsable ( candidate ) ) ) { if ( ! ( candidate . exists ( ) ) ) { DataCleanerHome . logger . debug ( "DATACLEANER_HOME<seq2seq4repair_space>directory<seq2seq4repair_space>does<seq2seq4repair_space>not<seq2seq4repair_space>exist,<seq2seq4repair_space>creating:<seq2seq4repair_space>{}" , candidate ) ; candidate . createFolder ( ) ; } if ( DataCleanerHome . isWriteable ( candidate ) ) { DataCleanerHome . logger . debug ( "Copying<seq2seq4repair_space>default<seq2seq4repair_space>configuration<seq2seq4repair_space>and<seq2seq4repair_space>examples<seq2seq4repair_space>to<seq2seq4repair_space>DATACLEANER_HOME<seq2seq4repair_space>directory:<seq2seq4repair_space>{}" , candidate ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , "conf.xml" ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , DATASTORE_FILE_CONTACTDATA ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_EXPORT_ORDERS_DATA ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_CUSTOMER_PROFILING ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_ADDRESS_CLEANSING ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_PHONE_CLEANSING ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_SFDC_DUPLICATE_DETECTION ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_SFDC_DUPLICATE_TRAINING ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , OTHER_DEDUP_MODEL_SFDC_USERS ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_ORDERDB_DUPLICATE_DETECTION ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_ORDERDB_DUPLICATE_TRAINING ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , OTHER_DEDUP_MODEL_ORDERDB_CUSTOMERS ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , OTHER_DEDUP_REFERENCE_ORDERDB_CUSTOMERS ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_COPY_EMPLOYEES_TO_CUSTOMERS ) ; DataCleanerHome . copyIfNonExisting ( candidate , manager , JOB_US_CUSTOMER_STATE_ANALYSIS ) ; } } return candidate ; } private static boolean isWriteable ( FileObject candidate ) throws FileSystemException { } public static FileObject get ( ) { } private static FileObject copyIfNonExisting ( FileObject candidate , FileSystemManager manager , String filename ) throws FileSystemException { } private static String getUserHomeCandidatePath ( ) { } private static boolean isUsable ( FileObject candidate ) throws FileSystemException { } }

Fix:
if ( ! ( DataCleanerHome . isUsable ( candidate ) ) ) {