git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@441945 13f79535-47bb-0310-9956-ffa450edef68master
@@ -230,6 +230,7 @@ Steve Morin | |||||
Steven E. Newton | Steven E. Newton | ||||
Takashi Okamoto | Takashi Okamoto | ||||
Tariq Master | Tariq Master | ||||
Trejkaz Xaoza | |||||
Thomas Butz | Thomas Butz | ||||
Thomas Christen | Thomas Christen | ||||
Thomas Christensen | Thomas Christensen | ||||
@@ -18,6 +18,7 @@ Fixed bugs: | |||||
* Exception reporting in <copy> was broken. Bugzilla report 40300. | * Exception reporting in <copy> was broken. Bugzilla report 40300. | ||||
* Handling of corrupt tar files, TarInputStream.read() never returns EOF. | * Handling of corrupt tar files, TarInputStream.read() never returns EOF. | ||||
Bugzilla report 39924. | Bugzilla report 39924. | ||||
* Some bugs in ReaderInputStream. Bugzilla report 39635. | |||||
Other changes: | Other changes: | ||||
-------------- | -------------- | ||||
@@ -958,6 +958,10 @@ | |||||
<first>Tom</first> | <first>Tom</first> | ||||
<last>Eugelink</last> | <last>Eugelink</last> | ||||
</name> | </name> | ||||
<name> | |||||
<first>Trejkaz</first> | |||||
<last>Xaoz</last> | |||||
</name> | |||||
<name> | <name> | ||||
<first>Ulrich</first> | <first>Ulrich</first> | ||||
<last>Schmidt</last> | <last>Schmidt</last> | ||||
@@ -85,16 +85,13 @@ public class ReaderInputStream extends InputStream { | |||||
} else { | } else { | ||||
byte[] buf = new byte[1]; | byte[] buf = new byte[1]; | ||||
if (read(buf, 0, 1) <= 0) { | if (read(buf, 0, 1) <= 0) { | ||||
result = -1; | |||||
return -1; | |||||
} else { | |||||
result = buf[0]; | |||||
} | } | ||||
result = buf[0]; | |||||
} | |||||
if (result < -1) { | |||||
result += 256; | |||||
} | } | ||||
return result; | |||||
return result & 0xFF; | |||||
} | } | ||||
/** | /** | ||||
@@ -112,7 +109,9 @@ public class ReaderInputStream extends InputStream { | |||||
if (in == null) { | if (in == null) { | ||||
throw new IOException("Stream Closed"); | throw new IOException("Stream Closed"); | ||||
} | } | ||||
if (len == 0) { | |||||
return 0; | |||||
} | |||||
while (slack == null) { | while (slack == null) { | ||||
char[] buf = new char[len]; // might read too much | char[] buf = new char[len]; // might read too much | ||||
int n = in.read(buf); | int n = in.read(buf); | ||||