cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aadamc...@apache.org
Subject svn commit: r1578748 - /cayenne/main/trunk/cayenne-server/src/main/java/org/apache/cayenne/access/ResultScanParentAttachmentStrategy.java
Date Tue, 18 Mar 2014 06:06:25 GMT
Author: aadamchik
Date: Tue Mar 18 06:06:25 2014
New Revision: 1578748

URL: http://svn.apache.org/r1578748
Log:
CAY-1905 Multi-step prefetching NPE : 1..N..1 with absent N and root with no qualifier

fix suggested by Mikaƫl Cluseau (we don't have a test for it)

Modified:
    cayenne/main/trunk/cayenne-server/src/main/java/org/apache/cayenne/access/ResultScanParentAttachmentStrategy.java

Modified: cayenne/main/trunk/cayenne-server/src/main/java/org/apache/cayenne/access/ResultScanParentAttachmentStrategy.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/cayenne-server/src/main/java/org/apache/cayenne/access/ResultScanParentAttachmentStrategy.java?rev=1578748&r1=1578747&r2=1578748&view=diff
==============================================================================
--- cayenne/main/trunk/cayenne-server/src/main/java/org/apache/cayenne/access/ResultScanParentAttachmentStrategy.java
(original)
+++ cayenne/main/trunk/cayenne-server/src/main/java/org/apache/cayenne/access/ResultScanParentAttachmentStrategy.java
Tue Mar 18 06:06:25 2014
@@ -107,6 +107,10 @@ class ResultScanParentAttachmentStrategy
         }
         
         List<DataRow> rows = parentNode.getDataRows();
+        if(rows == null) {
+            return;
+        }
+        
         int size = objects.size();
         for (int i = 0; i < size; i++) {
 



Mime
View raw message