openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kwsut...@apache.org
Subject svn commit: r1352927 - /openjpa/branches/2.2.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/JDBCStoreManager.java
Date Fri, 22 Jun 2012 15:26:40 GMT
Author: kwsutter
Date: Fri Jun 22 15:26:39 2012
New Revision: 1352927

URL: http://svn.apache.org/viewvc?rev=1352927&view=rev
Log:
OPENJPA-2204.  Detect a potential null value before blindly outputting a trace string.

Modified:
    openjpa/branches/2.2.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/JDBCStoreManager.java

Modified: openjpa/branches/2.2.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/JDBCStoreManager.java
URL: http://svn.apache.org/viewvc/openjpa/branches/2.2.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/JDBCStoreManager.java?rev=1352927&r1=1352926&r2=1352927&view=diff
==============================================================================
--- openjpa/branches/2.2.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/JDBCStoreManager.java
(original)
+++ openjpa/branches/2.2.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/JDBCStoreManager.java
Fri Jun 22 15:26:39 2012
@@ -998,7 +998,9 @@ public class JDBCStoreManager implements
         if (oid == null)
             return null;
         if (_log.isTraceEnabled()) {
-            _log.trace("find: oid="+oid+" "+vm.getDeclaredTypeMapping().getDescribedType());
+            ClassMapping declaredTypeMapping = vm.getDeclaredTypeMapping();
+            Class<?> describedType = (declaredTypeMapping != null) ? declaredTypeMapping.getDescribedType()
: null;
+            _log.trace("find: oid="+oid+", describedType="+describedType);
         }
         Object pc = _ctx.find(oid, fetch, null, null, 0);
         if (pc == null && vm != null) {



Mime
View raw message