Buggy code:
public class Concat extends Task { private static final int BUFFER_SIZE = 8192 ; private File destinationFile = null ; private boolean append = false ; private String encoding = null ; private String outputEncoding = null ; private boolean binary = false ; private StringBuffer textBuffer ; private Vector sources = new Vector ( ) ; private Vector filterChains = null ; private boolean forceOverwrite = true ; private Concat . TextElement footer ; private Concat . TextElement header ; private boolean fixLastLine = false ; private String eolString = System . getProperty ( "line.separator" ) ; private Writer outputWriter = null ; private Vector sourceFiles = new Vector ( ) ; private static FileUtils fileUtils = FileUtils . newFileUtils ( ) ; public void setDestfile ( File destinationFile ) { } public void setAppend ( boolean append ) { } public void setEncoding ( String encoding ) { } public void setOutputEncoding ( String outputEncoding ) { } public void setForce ( boolean force ) { } public Path createPath ( ) { } public void addFileset ( FileSet set ) { } public void addFilelist ( FileList list ) { } public void addFilterChain ( FilterChain filterChain ) { } public void addText ( String text ) { } public void addHeader ( Concat . TextElement header ) { } public void addFooter ( Concat . TextElement footer ) { } public void setFixLastLine ( boolean fixLastLine ) { } public void setEol ( FixCRLF . CrLf crlf ) { } public void setWriter ( Writer outputWriter ) { } public void setBinary ( boolean binary ) { } private void checkAndExecute ( ) { } public void execute ( ) { } public void reset ( ) { } private void resetTask ( ) { } private void checkAddFiles ( File base , String [ ] filenames ) { } private void binaryCat ( ) { } private void cat ( ) { } private void concatenate ( char [ ] buffer , Writer writer , Reader in ) throws IOException { } private void sanitizeText ( ) { } public static class TextElement extends ProjectComponent { private String value = "" ; private boolean trimLeading = false ; private boolean trim = false ; private boolean filtering = true ; private String encoding = null ; public void setFiltering ( boolean filtering ) { } private boolean getFiltering ( ) { } public void setEncoding ( String encoding ) { } public void setFile ( File file ) { if ( ! ( file . exists ( ) ) ) { throw new BuildException ( ( ( "File<seq2seq4repair_space>" + file ) + "<seq2seq4repair_space>does<seq2seq4repair_space>not<seq2seq4repair_space>exist." ) ) ; } BufferedReader reader = null ; try { if ( ( this . encoding ) == null ) { reader = new BufferedReader ( new FileReader ( file ) ) ; } else { reader = new BufferedReader ( new InputStreamReader ( new FileInputStream ( file ) , this . encoding ) ) ; } <START_BUG> value = Concat . fileUtils . readFully ( reader ) ; <END_BUG> } catch ( IOException ex ) { throw new BuildException ( ex ) ; } finally { if ( reader != null ) { try { reader . close ( ) ; } catch ( Throwable t ) { } } } } public void addText ( String value ) { } public void setTrimLeading ( boolean strip ) { } public void setTrim ( boolean trim ) { } public String getValue ( ) { } } private class MultiReader extends Reader { private int pos = 0 ; private Reader reader = null ; private int lastPos = 0 ; private char [ ] lastChars = new char [ eolString . length ( ) ] ; private boolean needAddSeparator = false ; private Reader getReader ( ) throws IOException { } public int read ( ) throws IOException { } public int read ( char [ ] cbuf , int off , int len ) throws IOException { } public void close ( ) throws IOException { } private void addLastChar ( char ch ) { } private boolean isMissingEndOfLine ( ) { } } }

Fix:
value = FileUtils . readFully ( reader ) ;