Browse files

Merge pull request #259 from tomjenkinson/JBTM-1612

JBTM-1612 copy streams by hand
  • Loading branch information...
2 parents 674e1aa + 0c86dd5 commit 4273810be86490943db1619fa781d76f2a85e466 @tomjenkinson tomjenkinson committed Apr 5, 2013
View
8 ...naJTS/integration/src/test/java/com/arjuna/ats/jta/distributed/SimpleIsolatedServers.java
@@ -45,7 +45,6 @@
import org.jboss.byteman.contrib.bmunit.BMScript;
import org.jboss.byteman.contrib.bmunit.BMUnitRunner;
import org.jboss.byteman.rule.exception.ExecuteException;
-import org.jfree.io.IOUtils;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
@@ -311,7 +310,12 @@ public void run() {
processBuilder.redirectErrorStream(true);
Process process = processBuilder.start();
InputStream inputStream = process.getInputStream();
- IOUtils.getInstance().copyStreams(inputStream, System.out);
+ final byte[] bytes = new byte[4096];
+ int bytesRead = inputStream.read(bytes);
+ while (bytesRead > -1) {
+ System.out.write(bytes, 0, bytesRead);
+ bytesRead = inputStream.read(bytes);
+ }
}
}

0 comments on commit 4273810

Please sign in to comment.