jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From un...@apache.org
Subject svn commit: r1421853 - /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/session/SessionSaveOperation.java
Date Fri, 14 Dec 2012 13:31:54 GMT
Author: unico
Date: Fri Dec 14 13:31:53 2012
New Revision: 1421853

URL: http://svn.apache.org/viewvc?rev=1421853&view=rev
Log:
JCR-3486 guard against npe due to transient root being null

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/session/SessionSaveOperation.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/session/SessionSaveOperation.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/session/SessionSaveOperation.java?rev=1421853&r1=1421852&r2=1421853&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/session/SessionSaveOperation.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/session/SessionSaveOperation.java
Fri Dec 14 13:31:53 2012
@@ -61,7 +61,9 @@ public class SessionSaveOperation implem
                 LOG.debug("Saving changes under " + path);
             }
         }
-        context.getItemManager().getItem(id).save();
+        if (id != null) {
+            context.getItemManager().getItem(id).save();
+        }
         return this;
     }
 



Mime
View raw message