code: public static ClassLoader getClassLoader(final Class<?> c)
     {
        if (System.getSecurityManager() == null)
           return c.getClassLoader();
  
        return AccessController.doPrivileged(new PrivilegedAction<ClassLoader>()
        {
           public ClassLoader run()
           {
              return c.getClassLoader();
           }
        });
     }
docs: Get the classloader.
  @param c The class
  @return The classloader