commit | ab8ff6fee890f05f4fe22f24eba71b6117030f22 | [log] [tgz] |
---|---|---|
author | Eric Norman <enorman@apache.org> | Thu Sep 09 05:34:32 2010 +0000 |
committer | Eric Norman <enorman@apache.org> | Thu Sep 09 05:34:32 2010 +0000 |
tree | edb7ad68f60a1a51b2cbe097efda428899b6d249 | |
parent | f5f290d6f26ac14aab40ef6de2f271eedeb86a51 [diff] |
SLING-1733 - fix potential ClassCastException git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@995316 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/src/main/java/org/apache/sling/bundleresource/impl/BundleResourceProvider.java b/src/main/java/org/apache/sling/bundleresource/impl/BundleResourceProvider.java index 72870b6..c40222e 100644 --- a/src/main/java/org/apache/sling/bundleresource/impl/BundleResourceProvider.java +++ b/src/main/java/org/apache/sling/bundleresource/impl/BundleResourceProvider.java
@@ -114,7 +114,7 @@ public Iterator<Resource> listChildren(final Resource parent) throws SlingException { - if (((BundleResource)parent).getBundle() == this.bundle) { + if (parent instanceof BundleResource && ((BundleResource)parent).getBundle() == this.bundle) { // bundle resources can handle this request directly when the parent // resource is in the same bundle as this provider. return ((BundleResource) parent).listChildren();