Buggy code:
public class Cab extends MatchingTask { private File cabFile ; private File baseDir ; private Vector filesets = new Vector ( ) ; private boolean doCompress = true ; private boolean doVerbose = false ; private String cmdOptions ; protected String archiveType = "cab" ; private FileUtils fileUtils = FileUtils . newFileUtils ( ) ; public void setCabfile ( File cabFile ) { } public void setBasedir ( File baseDir ) { } public void setCompress ( boolean compress ) { } public void setVerbose ( boolean verbose ) { } public void setOptions ( String options ) { } public void addFileset ( FileSet set ) { } protected void checkConfiguration ( ) throws BuildException { } protected ExecTask createExec ( ) throws BuildException { } protected boolean isUpToDate ( Vector files ) { } protected File createListFile ( Vector files ) throws IOException { } protected void appendFiles ( Vector files , DirectoryScanner ds ) { } protected Vector getFileList ( ) throws BuildException { } public void execute ( ) throws BuildException { checkConfiguration ( ) ; Vector files = getFileList ( ) ; if ( isUpToDate ( files ) ) { return ; } log ( ( ( ( "Building<seq2seq4repair_space>" + ( archiveType ) ) + ":<seq2seq4repair_space>" ) + ( cabFile . getAbsolutePath ( ) ) ) ) ; if ( ! ( Os . isFamily ( "windows" ) ) ) { log ( "Using<seq2seq4repair_space>listcab//libcabinet" , MSG_VERBOSE ) ; StringBuffer sb = new StringBuffer ( ) ; Enumeration fileEnum = files . elements ( ) ; while ( fileEnum . hasMoreElements ( ) ) { sb . append ( fileEnum . nextElement ( ) ) . append ( "\n" ) ; } sb . append ( "\n" ) . append ( cabFile . getAbsolutePath ( ) ) . append ( "\n" ) ; try { Process p = Execute . launch ( getProject ( ) , new String [ ] { "listcab" } , null , ( ( baseDir ) != null ? baseDir : getProject ( ) . getBaseDir ( ) ) , true ) ; OutputStream out = p . getOutputStream ( ) ; LogOutputStream outLog = new LogOutputStream ( this , Project . MSG_VERBOSE ) ; LogOutputStream errLog = new LogOutputStream ( this , Project . MSG_ERR ) ; StreamPumper outPump = new StreamPumper ( p . getInputStream ( ) , outLog ) ; StreamPumper errPump = new StreamPumper ( p . getErrorStream ( ) , errLog ) ; new Thread ( outPump ) . start ( ) ; new Thread ( errPump ) . start ( ) ; out . write ( sb . toString ( ) . getBytes ( ) ) ; out . flush ( ) ; out . close ( ) ; int result = - 99 ; try { result = p . waitFor ( ) ; outPump . waitFor ( ) ; outLog . close ( ) ; errPump . waitFor ( ) ; errLog . close ( ) ; } catch ( InterruptedException ie ) { log ( ( "Thread<seq2seq4repair_space>interrupted:<seq2seq4repair_space>" + ie ) ) ; } <START_BUG> if ( result != 0 ) { <END_BUG> log ( ( "Error<seq2seq4repair_space>executing<seq2seq4repair_space>listcab;<seq2seq4repair_space>error<seq2seq4repair_space>code:<seq2seq4repair_space>" + result ) ) ; } } catch ( IOException ex ) { String msg = ( ( "Problem<seq2seq4repair_space>creating<seq2seq4repair_space>" + ( cabFile ) ) + "<seq2seq4repair_space>" ) + ( ex . getMessage ( ) ) ; throw new BuildException ( msg , getLocation ( ) ) ; } } else { try { File listFile = createListFile ( files ) ; ExecTask exec = createExec ( ) ; File outFile = null ; exec . setFailonerror ( true ) ; exec . setDir ( baseDir ) ; if ( ! ( doVerbose ) ) { outFile = fileUtils . createTempFile ( "ant" , "" , null ) ; exec . setOutput ( outFile ) ; } exec . setExecutable ( "cabarc" ) ; exec . createArg ( ) . setValue ( "-r" ) ; exec . createArg ( ) . setValue ( "-p" ) ; if ( ! ( doCompress ) ) { exec . createArg ( ) . setValue ( "-m" ) ; exec . createArg ( ) . setValue ( "none" ) ; } if ( ( cmdOptions ) != null ) { exec . createArg ( ) . setLine ( cmdOptions ) ; } exec . createArg ( ) . setValue ( "n" ) ; exec . createArg ( ) . setFile ( cabFile ) ; exec . createArg ( ) . setValue ( ( "@" + ( listFile . getAbsolutePath ( ) ) ) ) ; exec . execute ( ) ; if ( outFile != null ) { outFile . delete ( ) ; } listFile . delete ( ) ; } catch ( IOException ioe ) { String msg = ( ( "Problem<seq2seq4repair_space>creating<seq2seq4repair_space>" + ( cabFile ) ) + "<seq2seq4repair_space>" ) + ( ioe . getMessage ( ) ) ; throw new BuildException ( msg , getLocation ( ) ) ; } } } }

Fix:
if ( Execute . isFailure ( result ) ) {