Author: ieb
Date: Sat Nov 7 17:28:13 2009
New Revision: 833720
URL: http://svn.apache.org/viewvc?rev=833720&view=rev
Log:
SLING-1174
Fixed.
Modified:
sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/ResourceProviderEntry2.java
Modified:
sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/ResourceProviderEntry2.java
URL:
http://svn.apache.org/viewvc/sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/ResourceProviderEntry2.java?rev=833720&r1=833719&r2=833720&view=diff
==============================================================================
---
sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/ResourceProviderEntry2.java
(original)
+++
sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/ResourceProviderEntry2.java
Sat Nov 7 17:28:13 2009
@@ -319,7 +319,7 @@
String[] elements = split(prefix, '/');
List<ResourceProviderEntry2> entryPath = new
ArrayList<ResourceProviderEntry2>();
populateProviderPath(entryPath, elements);
- if (entryPath.size() == elements.length) {
+ if (entryPath.size() > 0 && entryPath.size() == elements.length) {
// the last element is a perfect match;
return
entryPath.get(entryPath.size()-1).removeInternalProvider(new
WrappedResourceProvider(resourceProvider, comparable));
}