cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aadamc...@apache.org
Subject svn commit: r688324 - /cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/conf/ConfigSaver.java
Date Sat, 23 Aug 2008 13:54:20 GMT
Author: aadamchik
Date: Sat Aug 23 06:54:20 2008
New Revision: 688324

URL: http://svn.apache.org/viewvc?rev=688324&view=rev
Log:
adding password NPE check that prevents project save errors on invalid modeler inputs

Modified:
    cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/conf/ConfigSaver.java

Modified: cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/conf/ConfigSaver.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/conf/ConfigSaver.java?rev=688324&r1=688323&r2=688324&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/conf/ConfigSaver.java
(original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/conf/ConfigSaver.java
Sat Aug 23 06:54:20 2008
@@ -195,7 +195,7 @@
 
         if (info.getPasswordLocation().equals(DataSourceInfo.PASSWORD_LOCATION_MODEL)) {
             PasswordEncoding encoder = info.getPasswordEncoder();
-            if (encoder != null) {
+            if (encoder != null && info.getPassword() != null) {
                 pw.print(attribute("password", encoder.encodePassword(
                         info.getPassword(),
                         info.getPasswordEncoderKey())));



Mime
View raw message