HHH-14936 Avoid NPE in JdbcConnectionContext's static init
This commit is contained in:
parent
c3631970a5
commit
35f374aac7
|
@ -38,8 +38,12 @@ public final class JdbcConnectionContext {
|
|||
password = connectionProperties.getProperty(
|
||||
AvailableSettings.PASS );
|
||||
Properties p = new Properties();
|
||||
p.put( "user", user );
|
||||
p.put( "password", password );
|
||||
if ( user != null ) {
|
||||
p.put( "user", user );
|
||||
}
|
||||
if ( password != null ) {
|
||||
p.put( "password", password );
|
||||
}
|
||||
properties = p;
|
||||
}
|
||||
catch (Exception e) {
|
||||
|
|
Loading…
Reference in New Issue