SLING-3403 Make sure compilation works also with Apple JDK 6

git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1570550 13f79535-47bb-0310-9956-ffa450edef68
SLING-3400 : Sling holds resource providers after they have been unregistered

git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1570565 13f79535-47bb-0310-9956-ffa450edef68