You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openjpa.apache.org by dw...@apache.org on 2010/06/15 04:16:27 UTC
svn commit: r954696 -
/openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/conf/ProductDerivations.java
Author: dwoods
Date: Tue Jun 15 02:16:27 2010
New Revision: 954696
URL: http://svn.apache.org/viewvc?rev=954696&view=rev
Log:
OPENJPA-1700 FindBugs - A null pointer is dereferenced here. This will lead to a NullPointerException when the code is executed.
Modified:
openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/conf/ProductDerivations.java
Modified: openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/conf/ProductDerivations.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/conf/ProductDerivations.java?rev=954696&r1=954695&r2=954696&view=diff
==============================================================================
--- openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/conf/ProductDerivations.java (original)
+++ openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/conf/ProductDerivations.java Tue Jun 15 02:16:27 2010
@@ -451,7 +451,7 @@ public class ProductDerivations {
// most specific to least
for (int i = _derivations.length - 1; i >= 0; i--) {
Set<String> members = _derivations[i].getSupportedQueryHints();
- if (members != null || !members.isEmpty())
+ if (members != null && !members.isEmpty())
result.addAll(members);
}
return result;