db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kahat...@apache.org
Subject svn commit: r687793 - /db/derby/code/trunk/java/testing/org/apache/derbyTesting/junit/BaseTestCase.java
Date Thu, 21 Aug 2008 16:13:01 GMT
Author: kahatlen
Date: Thu Aug 21 09:13:00 2008
New Revision: 687793

URL: http://svn.apache.org/viewvc?rev=687793&view=rev
Log:
DERBY-3841: Fixed broken logic in BaseTestCase.assertExecJavaCmdAsExpected()

Modified:
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/junit/BaseTestCase.java

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/junit/BaseTestCase.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/junit/BaseTestCase.java?rev=687793&r1=687792&r2=687793&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/junit/BaseTestCase.java (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/junit/BaseTestCase.java Thu Aug
21 09:13:00 2008
@@ -492,9 +492,10 @@
            InputStreamReader inStream;
                inStream = new InputStreamReader(is);
            // keep reading from the stream until all done
-           while ((inStream.read(ca, 0, ca.length)) != -1)
+           int charsRead;
+           while ((charsRead = inStream.read(ca, 0, ca.length)) != -1)
            {
-               output = output + new String(ca).trim();
+               output = output + new String(ca, 0, charsRead);
            }
        } catch (Exception e) {
            fail("Exception accessing inputstream from javacommand", e);



Mime
View raw message