Buggy code:
public class Execute { public static final int INVALID = Integer . MAX_VALUE ; private static final FileUtils FILE_UTILS = FileUtils . getFileUtils ( ) ; private String [ ] cmdl = null ; private String [ ] env = null ; private int exitValue = Execute . INVALID ; private ExecuteStreamHandler streamHandler ; private ExecuteWatchdog watchdog ; private File workingDirectory = null ; private Project project = null ; private boolean newEnvironment = false ; private boolean spawn = false ; private boolean useVMLauncher = true ; private static String antWorkingDirectory = System . getProperty ( "user.dir" ) ; private static Execute . CommandLauncher vmLauncher = null ; private static Execute . CommandLauncher shellLauncher = null ; private static Vector procEnvironment = null ; private static ProcessDestroyer processDestroyer = new ProcessDestroyer ( ) ; public void setSpawn ( boolean spawn ) { } public static synchronized Vector getProcEnvironment ( ) { } private static String [ ] getProcEnvCommand ( ) { } public static String toString ( ByteArrayOutputStream bos ) { } public Execute ( ) { } public Execute ( ExecuteStreamHandler streamHandler ) { } public Execute ( ExecuteStreamHandler streamHandler , ExecuteWatchdog watchdog ) { } public void setStreamHandler ( ExecuteStreamHandler streamHandler ) { } public String [ ] getCommandline ( ) { } public void setCommandline ( String [ ] commandline ) { } public void setNewenvironment ( boolean newenv ) { } public String [ ] getEnvironment ( ) { } public void setEnvironment ( String [ ] env ) { } public void setWorkingDirectory ( File wd ) { } public File getWorkingDirectory ( ) { } public void setAntRun ( Project project ) throws BuildException { } public void setVMLauncher ( boolean useVMLauncher ) { } public static Process launch ( Project project , String [ ] command , String [ ] env , File dir , boolean useVM ) throws IOException { } public int execute ( ) throws IOException { } public void spawn ( ) throws IOException { } protected void waitFor ( Process process ) { } protected void setExitValue ( int value ) { } public int getExitValue ( ) { } public static boolean isFailure ( int exitValue ) { } public boolean killedProcess ( ) { } private String [ ] patchEnvironment ( ) { } public static void runCommand ( Task task , String [ ] cmdline ) throws BuildException { } public static void closeStreams ( Process process ) { } private static Vector addVMSLogicals ( Vector environment , BufferedReader in ) throws IOException { } private static class CommandLauncher { public Process exec ( Project project , String [ ] cmd , String [ ] env ) throws IOException { } public Process exec ( Project project , String [ ] cmd , String [ ] env , File workingDir ) throws IOException { } } private static class Java13CommandLauncher extends Execute . CommandLauncher { private Method myExecWithCWD ; public Java13CommandLauncher ( ) throws NoSuchMethodException { } public Process exec ( Project project , String [ ] cmd , String [ ] env , File workingDir ) throws IOException { } } private static class CommandLauncherProxy extends Execute . CommandLauncher { private Execute . CommandLauncher myLauncher ; CommandLauncherProxy ( Execute . CommandLauncher launcher ) { } public Process exec ( Project project , String [ ] cmd , String [ ] env ) throws IOException { } } private static class OS2CommandLauncher extends Execute . CommandLauncherProxy { OS2CommandLauncher ( Execute . CommandLauncher launcher ) { } public Process exec ( Project project , String [ ] cmd , String [ ] env , File workingDir ) throws IOException { } } private static class WinNTCommandLauncher extends Execute . CommandLauncherProxy { WinNTCommandLauncher ( Execute . CommandLauncher launcher ) { } public Process exec ( Project project , String [ ] cmd , String [ ] env , File workingDir ) throws IOException { } } private static class MacCommandLauncher extends Execute . CommandLauncherProxy { MacCommandLauncher ( Execute . CommandLauncher launcher ) { } public Process exec ( Project project , String [ ] cmd , String [ ] env , File workingDir ) throws IOException { } } private static class ScriptCommandLauncher extends Execute . CommandLauncherProxy { ScriptCommandLauncher ( String script , Execute . CommandLauncher launcher ) { } public Process exec ( Project project , String [ ] cmd , String [ ] env , File workingDir ) throws IOException { } private String myScript ; } private static class PerlScriptCommandLauncher extends Execute . CommandLauncherProxy { private String myScript ; PerlScriptCommandLauncher ( String script , Execute . CommandLauncher launcher ) { } public Process exec ( Project project , String [ ] cmd , String [ ] env , File workingDir ) throws IOException { } } private static class VmsCommandLauncher extends Execute . Java13CommandLauncher { public VmsCommandLauncher ( ) throws NoSuchMethodException { } public Process exec ( Project project , String [ ] cmd , String [ ] env ) throws IOException { } public Process exec ( Project project , String [ ] cmd , String [ ] env , File workingDir ) throws IOException { } private File createCommandFile ( String [ ] cmd , String [ ] env ) throws IOException { } private void deleteAfter ( final File f , final Process p ) { new Thread ( ) { public void run ( ) { try { p . waitFor ( ) ; } catch ( InterruptedException e ) { } <START_BUG> Execute . FILE_UTILS . delete ( f ) ; <END_BUG> } } . start ( ) ; } } }

Fix:
FileUtils . delete ( f ) ;