Fix copy of properties when using a jdbc url.

Constructor Properties(Properties properties) is not a copy constructor.
pull/223/merge
Guillaume Smet 10 years ago committed by Brett Wooldridge
parent a7a84e9497
commit db0231ee5b

@ -35,7 +35,8 @@ public final class DriverDataSource implements DataSource
{
try {
this.jdbcUrl = jdbcUrl;
this.driverProperties = new Properties(properties);
this.driverProperties = new Properties();
this.driverProperties.putAll(properties);
if (username != null) {
driverProperties.put("user", driverProperties.getProperty("user", username));
}

@ -35,7 +35,8 @@ public final class DriverDataSource implements DataSource
{
try {
this.jdbcUrl = jdbcUrl;
this.driverProperties = new Properties(properties);
this.driverProperties = new Properties();
this.driverProperties.putAll(properties);
if (username != null) {
driverProperties.put("user", driverProperties.getProperty("user", username));
}

Loading…
Cancel
Save