Description
In the class org.apache.axiom.attachments.Attachments line 237
--->
while (true) {
int value;
try {
value = pushbackInStream.read();
if ((byte) value == boundary[0]) {
int boundaryIndex = 0;
while ((boundaryIndex < boundary.length)
&& ((byte) value == boundary[boundaryIndex])) {
value = pushbackInStream.read();
if (value == -1)
boundaryIndex++;
}
if (boundaryIndex == boundary.length)
} else if ((byte) value == -1)
{ <--- this byte case is unnecessary, e.g. if the value is 255, after the cast from int to byte, then from byte to int, it will be finally equal to -1 throw new OMException( "Mime parts not found. Stream ended while searching for the boundary"); }} catch (IOException e1)
{ throw new OMException("Stream Error" + e1.toString(), e1); } }
<---