Buggy code:
public class Manifest { public static final String ATTRIBUTE_MANIFEST_VERSION = "Manifest-Version" ; public static final String ATTRIBUTE_SIGNATURE_VERSION = "Signature-Version" ; public static final String ATTRIBUTE_NAME = "Name" ; public static final String ATTRIBUTE_FROM = "From" ; public static final String ATTRIBUTE_CLASSPATH = "class-path" ; public static final String DEFAULT_MANIFEST_VERSION = "1.0" ; public static final int MAX_LINE_LENGTH = 72 ; public static final int MAX_SECTION_LENGTH = ( Manifest . MAX_LINE_LENGTH ) - 2 ; public static final String EOL = "\r\n" ; public static class Attribute { private String name = null ; private Vector values = new Vector ( ) ; private int currentIndex = 0 ; public Attribute ( ) { } public Attribute ( String line ) throws ManifestException { } public Attribute ( String name , String value ) { } public int hashCode ( ) { } public boolean equals ( Object rhs ) { } public void parse ( String line ) throws ManifestException { } public void setName ( String name ) { } public String getName ( ) { } public String getKey ( ) { } public void setValue ( String value ) { } public String getValue ( ) { } public void addValue ( String value ) { } public Enumeration getValues ( ) { } public void addContinuation ( String line ) { } public void write ( PrintWriter writer ) throws IOException { } private void writeValue ( PrintWriter writer , String value ) throws IOException { } } public static class Section { private Vector warnings = new Vector ( ) ; private String name = null ; private Hashtable attributes = new Hashtable ( ) ; private Vector attributeIndex = new Vector ( ) ; public void setName ( String name ) { } public String getName ( ) { } public String read ( BufferedReader reader ) throws IOException , ManifestException { } public void merge ( Manifest . Section section ) throws ManifestException { } public void write ( PrintWriter writer ) throws IOException { } public Manifest . Attribute getAttribute ( String attributeName ) { } public Enumeration getAttributeKeys ( ) { } public String getAttributeValue ( String attributeName ) { } public void removeAttribute ( String attributeName ) { } public void addConfiguredAttribute ( Manifest . Attribute attribute ) throws ManifestException { } public String addAttributeAndCheck ( Manifest . Attribute attribute ) throws ManifestException { } public Object clone ( ) { } private void storeAttribute ( Manifest . Attribute attribute ) { } public Enumeration getWarnings ( ) { } public int hashCode ( ) { } public boolean equals ( Object rhs ) { } } private String manifestVersion = Manifest . DEFAULT_MANIFEST_VERSION ; private Manifest . Section mainSection = new Manifest . Section ( ) ; private Hashtable sections = new Hashtable ( ) ; private Vector sectionIndex = new Vector ( ) ; public static Manifest getDefaultManifest ( ) throws BuildException { try { String defManifest = "//org//apache//tools//ant//defaultManifest.mf" ; InputStream in = Manifest . class . getResourceAsStream ( defManifest ) ; if ( in == null ) { throw new BuildException ( ( "Could<seq2seq4repair_space>not<seq2seq4repair_space>find<seq2seq4repair_space>default<seq2seq4repair_space>manifest:<seq2seq4repair_space>" + defManifest ) ) ; } try { <START_BUG> Manifest defaultManifest = new Manifest ( new InputStreamReader ( in , "ASCII" ) ) ; <END_BUG> Manifest . Attribute createdBy = new Manifest . Attribute ( "Created-By" , ( ( ( ( System . getProperty ( "java.vm.version" ) ) + "<seq2seq4repair_space>(" ) + ( System . getProperty ( "java.vm.vendor" ) ) ) + ")" ) ) ; defaultManifest . getMainSection ( ) . storeAttribute ( createdBy ) ; return defaultManifest ; } catch ( UnsupportedEncodingException e ) { return new Manifest ( new InputStreamReader ( in ) ) ; } } catch ( ManifestException e ) { throw new BuildException ( "Default<seq2seq4repair_space>manifest<seq2seq4repair_space>is<seq2seq4repair_space>invalid<seq2seq4repair_space>!!" , e ) ; } catch ( IOException e ) { throw new BuildException ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>read<seq2seq4repair_space>default<seq2seq4repair_space>manifest" , e ) ; } } public Manifest ( ) { } public Manifest ( Reader r ) throws IOException , ManifestException { } public void addConfiguredSection ( Manifest . Section section ) throws ManifestException { } public void addConfiguredAttribute ( Manifest . Attribute attribute ) throws ManifestException { } public void merge ( Manifest other ) throws ManifestException { } public void merge ( Manifest other , boolean overwriteMain ) throws ManifestException { } public void write ( PrintWriter writer ) throws IOException { } public String toString ( ) { } public Enumeration getWarnings ( ) { } public int hashCode ( ) { } public boolean equals ( Object rhs ) { } public String getManifestVersion ( ) { } public Manifest . Section getMainSection ( ) { } public Manifest . Section getSection ( String name ) { } public Enumeration getSectionNames ( ) { } }

Fix:
Manifest defaultManifest = new Manifest ( new InputStreamReader ( in , "UTF-8" ) ) ;