db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t...@apache.org
Subject svn commit: r429648 - /db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/OutBufferedStream.java
Date Tue, 08 Aug 2006 13:21:18 GMT
Author: tmnk
Date: Tue Aug  8 06:21:18 2006
New Revision: 429648

URL: http://svn.apache.org/viewvc?rev=429648&view=rev
Log:
- DERBY-1637 OutBufferedStream.java fails on ibm131/jdk131 jvms. - Patch by Sunitha Kambhampati(ksunithaghm@gmail.com)

Modified:
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/OutBufferedStream.java

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/OutBufferedStream.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/OutBufferedStream.java?rev=429648&r1=429647&r2=429648&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/OutBufferedStream.java
(original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/OutBufferedStream.java
Tue Aug  8 06:21:18 2006
@@ -54,6 +54,10 @@
 public class OutBufferedStream {
     private static NetworkServerControl networkServer = null;
     
+    // Need this to keep track of database has been created or not
+    // to avoid case of DERBY-300
+    private static boolean dbNotCreated = true;
+    
     public static void main(String[] args){
 	
 	try{
@@ -249,10 +253,16 @@
     
     private static Connection getConnection()
 	throws SQLException {
-	
-	return DriverManager.getConnection(TestUtil.getJdbcUrlPrefix("localhost",
+    
+    String dbName = "wombat";
+	if (dbNotCreated)
+    {
+        dbName = dbName + ";create=true";
+        dbNotCreated = false;
+    }
+    return DriverManager.getConnection(TestUtil.getJdbcUrlPrefix("localhost",
 								     1527) + 
-					   "wombat;create=true",
+					   dbName,
 					   "testuser",
 					   "testpassword");
 	



Mime
View raw message